Exemple #1
0
'''
Do a prediction: save the single-frame output (6-dim vector) of trained network.
'''

import sys, os
script_path = os.path.abspath(sys.argv[0])
proj_path = os.path.join('/', *script_path.split('/')[:-2])
sys.path.append(proj_path)
from Test.TestManager import TestManager
from Training.ErrorModelLearner import ErrorModelLearner
from Dataset.DatasetLoader.generateLocalizationDataSet import config_loc_dataset

if __name__ == '__main__':
    tm = TestManager()
    # Step 1, set data
    dataset = config_loc_dataset(tm.configuration, 'test-pre')

    tm.set_data(*dataset)

    # Step 2, set learner
    learner = ErrorModelLearner()
    tm.set_learner(learner)

    # Step 3, run testing
    tm.model_prediction()
Exemple #2
0
'''

import os
import sys

script_path = os.path.abspath(sys.argv[0])
proj_path = os.path.join('/', *script_path.split('/')[:-2])
sys.path.append(proj_path)
from Test.TestManager import TestManager
from Training.ErrorModelLearner import ErrorModelLearner
from Dataset.DatasetLoader.generateLocalizationDataSet import config_loc_dataset

if __name__ == '__main__':
    tm = TestManager()
    # Step 1, set data
    dataset = config_loc_dataset(tm.configuration, 'test-pre', allfrm=True)

    tm.set_data(*dataset)

    # Step 2, set learner
    learner = ErrorModelLearner()
    tm.set_learner(learner)

    # Step 3, run testing
    fileout = tm.model_prediction()

    infofile = fileout + '.info.csv'

    tm.transNetPrediction2Mat(fileout, infofile, type='info')

    # Step 1, set data
Exemple #3
0
'''
Train the error mapping model.
'''
import sys, os
script_path = os.path.abspath(sys.argv[0])
proj_path = os.path.join('/', *script_path.split('/')[:-2])
sys.path.append(proj_path)
from Training.TrainingManager import TrainingManager
from Training.ErrorModelLearner import ErrorModelLearner
from Dataset.DatasetLoader.generateLocalizationDataSet import config_loc_dataset

if __name__ == '__main__':
    tm = TrainingManager()
    # Step 1, set data
    dataset = config_loc_dataset(tm.configuration, 'train')

    tm.set_data(*dataset)

    # Step 2, set learner
    learner = ErrorModelLearner()
    tm.set_learner(learner)

    # Step 3, run training
    tm.train()
Exemple #4
0
'''
Do a prediction: save the single-frame output (6-dim vector) of trained network.
'''

import sys, os

script_path = os.path.abspath(sys.argv[0])
proj_path = os.path.join('/', *script_path.split('/')[:-2])
sys.path.append(proj_path)
from Test.TestManager import TestManager
from Training.ErrorModelLearner import ErrorModelLearner
from Dataset.DatasetLoader.generateLocalizationDataSet import config_loc_dataset

if __name__ == '__main__':
    tm = TestManager()

    # Step 1, set data
    dataset = config_loc_dataset(tm.configuration, 'test-viewcov')

    tm.set_data(*dataset)

    # Step 2, set learner
    learner = ErrorModelLearner()
    tm.set_learner(learner)

    # Step 3, run testing
    tm.visualize_covariance_sample()
Exemple #5
0
'''
 Find the best scale for cov from traditional method
'''

import sys, os

script_path = os.path.abspath(sys.argv[0])
proj_path = os.path.join('/', *script_path.split('/')[:-2])
sys.path.append(proj_path)
from Test.TestManager import TestManager
from Training.ErrorModelLearner import ErrorModelLearner
from Dataset.DatasetLoader.generateLocalizationDataSet import config_loc_dataset

if __name__ == '__main__':
    tm = TestManager()
    # Step 1, set data
    dataset = config_loc_dataset(tm.configuration, 'test-acc')

    tm.set_data(*dataset)

    # Step 2, run testing
    scalelist = [0.0001, 0.001, 0.01, 0.1, 1, 10, 100, 1000]
    tm.find_best_covscale(scalelist)