From 2c4d564e6c49de311eb8bbcb36ee1093e50f1135 Mon Sep 17 00:00:00 2001 From: tgupta6 <tgupta6@illinois.edu> Date: Mon, 7 Nov 2016 12:36:37 -0600 Subject: [PATCH] add new constants_crunchy --- constants_crunchy.py | 31 ++++++++++++++++++++----------- 1 file changed, 20 insertions(+), 11 deletions(-) diff --git a/constants_crunchy.py b/constants_crunchy.py index add67d3..5776a30 100644 --- a/constants_crunchy.py +++ b/constants_crunchy.py @@ -5,14 +5,14 @@ def mkdir_if_not_exists(dir_name): if not os.path.exists(dir_name): os.mkdir(dir_name) -experiment_name = 'trial_new_rel_feat' +experiment_name = 'ans_through_obj_atr_pretrained_no_rel_bin_feats' ########################################################################## # Machine Specific Paths # ########################################################################## # Global output directory (all subexperiments will be saved here) -global_output_dir = '/home/tanmay/Code/GenVQA/Exp_Results/VQA' +global_output_dir = '/home/tanmay/Code/GenVQA/Exp_Results/models_cvpr/' global_experiment_dir = os.path.join( global_output_dir, @@ -42,9 +42,9 @@ word2vec_binary = '/home/tanmay/Code/word2vec/word2vec-api-master/' + \ vqa_basedir = '/home/ssd/VQA/' # Pretrained obj atr model to be restored -pretrained_model = '/home/tanmay/Code/GenVQA/Exp_Results/VQA/' + \ - 'object_attribute_classifier_wordvec_xform/' + \ - 'object_attribute_classifiers/model-102000' +pretrained_model = '/home/tanmay/Code/GenVQA/Exp_Results/models_cvpr/' + \ + 'obj_atr_through_none_single_feat/answer_classifiers/' + \ + 'model-72000' ########################################################################## # Model Parameters # @@ -93,6 +93,10 @@ regions_json = os.path.join( data_absolute_path, 'restructured/region_with_hypernym_labels.json') +eval_regions_json = os.path.join( + data_absolute_path, + 'restructured/region_with_labels.json') + mean_image_filename = os.path.join( data_absolute_path, 'restructured/mean_image.jpg') @@ -132,7 +136,7 @@ region_model = os.path.join( # Object Attribute Classifier Training Params region_batch_size = 200 region_num_epochs = 20 -region_queue_size = 400 +region_queue_size = 300 region_regularization_coeff = 1e-5 region_lr = 1e-3 @@ -169,7 +173,12 @@ region_attribute_scores_dirname = os.path.join( region_output_dir, 'attribute_scores') +region_object_scores_dirname = os.path.join( + region_output_dir, + 'object_scores') + mkdir_if_not_exists(region_attribute_scores_dirname) +mkdir_if_not_exists(region_object_scores_dirname) ########################################################################## # VQA Parameters # @@ -253,11 +262,11 @@ answer_model = os.path.join( 'model') # Answer classifier training params -answer_train_from_scratch = True +answer_train_from_scratch = False answer_batch_size = 50 answer_num_epochs = 20 -answer_queue_size = 500 +answer_queue_size = 200 answer_regularization_coeff = 1e-5 answer_lr = 1e-3 @@ -285,8 +294,8 @@ model_accuracies_txt = os.path.join( 'model_accuracies.txt') # Answer eval params -answer_eval_on = 'testdev' -answer_model_to_eval = answer_model + '-43000' +answer_eval_on = 'val' +answer_model_to_eval = answer_model + '-68000' vqa_results_dir = os.path.join( answer_output_dir, @@ -315,6 +324,6 @@ raw_vqa_test_ques_json = os.path.join( vqa_basedir, 'MultipleChoice_mscoco_test2015_questions.json') -raw_vqa_val_anno_json = os.path.join( +raw_vqa_test_anno_json = os.path.join( vqa_basedir, 'mscoco_test2015_annotations.json') -- GitLab