Ejemplo n.º 1
0
def main():
    run_single_experiment(MethodMarkov, {'reg_factor': REGULARIZATION_FACTOR},
                          UIData, {'num_test': NUM_TEST_SAMPLES}, 2,
                          FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodBBCF, {
        'reg_factor': REGULARIZATION_FACTOR,
        'num_models': NUM_TASKS
    }, UIData, {'num_test': NUM_TEST_SAMPLES}, 2, FIXED_LENGTHS, 10, fsuffix,
                          RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'euclidean',
        'stride': 1
    }, UIData, {'num_test': NUM_TEST_SAMPLES}, 2, FIXED_LENGTHS, 10, fsuffix,
                          RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'cosine',
        'stride': 1
    }, UIData, {'num_test': NUM_TEST_SAMPLES}, 2, FIXED_LENGTHS, 10, fsuffix,
                          RND_SEED, show_result)

    run_single_experiment(
        MethodLSTM, {
            'max_seq_len': 30,
            'strat': 'sequential',
            'epochs': 20,
            'fname': 'lstm_model'
        }, UIData, {'num_test': NUM_TEST_SAMPLES}, 2, FIXED_LENGTHS, 10,
        fsuffix, RND_SEED, show_result)
Ejemplo n.º 2
0
def main():
    run_single_experiment(MethodMarkov, {'reg_factor': REGULARIZATION_FACTOR},
                          SyntheticData, {
                              'num_samples': NUM_TRAINING_SAMPLES,
                              'seplvl': TASK_SEP,
                              'seed': RND_SEED
                          }, 2, FIXED_LENGTHS, NUM_FOLDS, fsuffix, RND_SEED,
                          show_result)

    run_single_experiment(MethodBBCF, {
        'reg_factor': REGULARIZATION_FACTOR,
        'num_models': NUM_TASKS
    }, SyntheticData, {
        'num_samples': NUM_TRAINING_SAMPLES,
        'seplvl': TASK_SEP,
        'seed': RND_SEED
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'euclidean',
        'stride': 3
    }, SyntheticData, {
        'num_samples': NUM_TRAINING_SAMPLES,
        'seplvl': TASK_SEP,
        'seed': RND_SEED
    }, 2, FIXED_LENGTHS, NUM_FOLDS, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'cosine',
        'stride': 3
    }, SyntheticData, {
        'num_samples': NUM_TRAINING_SAMPLES,
        'seplvl': TASK_SEP,
        'seed': RND_SEED
    }, 2, FIXED_LENGTHS, NUM_FOLDS, fsuffix, RND_SEED, show_result)

    run_single_experiment(
        MethodLSTM, {
            'max_seq_len': 20,
            'strat': 'sequential',
            'epochs': 20,
            'fname': 'lstm_model'
        }, SyntheticData, {
            'num_samples': NUM_TRAINING_SAMPLES,
            'seplvl': TASK_SEP,
            'seed': RND_SEED
        }, 2, FIXED_LENGTHS, NUM_FOLDS, fsuffix, RND_SEED, show_result)
Ejemplo n.º 3
0
def main():
    run_single_experiment(MethodMarkov, {'reg_factor': REGULARIZATION_FACTOR},
                          TaxiData, {
                              'num_samples': TRAIN_SIZE,
                              'grid': GRID_SIZE
                          }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED,
                          show_result)

    run_single_experiment(MethodBBCF, {
        'reg_factor': REGULARIZATION_FACTOR,
        'num_models': NUM_GOALS
    }, TaxiData, {
        'num_samples': TRAIN_SIZE,
        'grid': GRID_SIZE
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'euclidean',
        'stride': 5
    }, TaxiData, {
        'num_samples': TRAIN_SIZE,
        'grid': GRID_SIZE
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'cosine',
        'stride': 5
    }, TaxiData, {
        'num_samples': TRAIN_SIZE,
        'grid': GRID_SIZE
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(
        MethodLSTM, {
            'max_seq_len': 10,
            'strat': 'sequential',
            'epochs': 20,
            'fname': 'lstm_model'
        }, TaxiData, {
            'num_samples': TRAIN_SIZE,
            'grid': GRID_SIZE
        }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)
Ejemplo n.º 4
0
def main():
    run_single_experiment(MethodNN, {
        'distfcn': 'euclidean',
        'stride': STRIDE[SKILL_SET]
    }, KTData, {
        'skill_set': SKILL_SET,
        'merge': True
    }, 1, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'cosine',
        'stride': STRIDE[SKILL_SET]
    }, KTData, {
        'skill_set': SKILL_SET,
        'merge': True
    }, 1, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(
        MethodLSTM, {
            'max_seq_len': 10,
            'strat': 'sequential',
            'epochs': 20,
            'fname': 'lstm_model'
        }, KTData, {
            'skill_set': SKILL_SET,
            'merge': True
        }, 1, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)
Ejemplo n.º 5
0
def main():
    print('{:s}\nNumber of training samples {:d}\n{:s}'.format(
        ''.join(40 * ['-']), TRAIN_SIZE, ''.join(40 * ['-'])))

    run_single_experiment(MethodMarkov, {'reg_factor': REGULARIZATION_FACTOR},
                          SparseTaxiData, {
                              'num_samples': LOAD_SIZE,
                              'num_train': TRAIN_SIZE,
                              'num_test': TEST_SIZE,
                              'num_goals': NUM_GOALS,
                              'grid': [20, 20]
                          }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED,
                          show_result)

    # number of destinations is limited
    run_single_experiment(MethodBBCF, {
        'reg_factor': REGULARIZATION_FACTOR,
        'num_models': NUM_GOALS
    }, SparseTaxiData, {
        'num_samples': LOAD_SIZE,
        'num_train': TRAIN_SIZE,
        'num_test': TEST_SIZE,
        'num_goals': NUM_GOALS,
        'grid': [20, 20]
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'euclidean',
        'stride': 3
    }, SparseTaxiData, {
        'num_samples': LOAD_SIZE,
        'num_train': TRAIN_SIZE,
        'num_test': TEST_SIZE,
        'num_goals': NUM_GOALS,
        'grid': [20, 20]
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)

    run_single_experiment(MethodNN, {
        'distfcn': 'cosine',
        'stride': 3
    }, SparseTaxiData, {
        'num_samples': LOAD_SIZE,
        'num_train': TRAIN_SIZE,
        'num_test': TEST_SIZE,
        'num_goals': NUM_GOALS,
        'grid': [20, 20]
    }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED)

    run_single_experiment(
        MethodLSTM, {
            'max_seq_len': 10,
            'strat': 'sequential',
            'epochs': 20,
            'fname': 'lstm_model'
        }, SparseTaxiData, {
            'num_samples': LOAD_SIZE,
            'num_train': TRAIN_SIZE,
            'num_test': TEST_SIZE,
            'num_goals': NUM_GOALS,
            'grid': [20, 20]
        }, 2, FIXED_LENGTHS, 10, fsuffix, RND_SEED, show_result)