Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
G
GenVQA
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
Vision
GenVQA
Commits
ef44688d
Commit
ef44688d
authored
8 years ago
by
tgupta6
Browse files
Options
Downloads
Patches
Plain Diff
constants gpu1 change
parent
3758e7a5
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
answer_classifier_cached_features/train.py
+3
-2
3 additions, 2 deletions
answer_classifier_cached_features/train.py
constants_vision_gpu_1.py
+9
-7
9 additions, 7 deletions
constants_vision_gpu_1.py
with
12 additions
and
9 deletions
answer_classifier_cached_features/train.py
+
3
−
2
View file @
ef44688d
...
...
@@ -418,7 +418,7 @@ class graph_creator():
self
.
mil_atr_loss
+=
losses
.
mil_loss
(
self
.
attribute_scores_with_answers
[
j
],
self
.
plh
[
'
positive_a
ttribut
es_vec_enc
'
][
j
],
self
.
plh
[
'
positive_a
djectiv
es_vec_enc
'
][
j
],
'
atr
'
)
self
.
mil_obj_loss
=
self
.
mil_loss_wt
*
self
.
mil_obj_loss
/
self
.
batch_size
...
...
@@ -690,7 +690,8 @@ class attach_optimizer():
self
.
learning_rate
=
tf
.
train
.
exponential_decay
(
self
.
lr
,
self
.
global_step
,
self
.
decay_step
)
self
.
decay_step
,
self
.
decay_rate
)
self
.
optimizer
=
multi_rate_train
.
MultiRateOptimizer
(
tf
.
train
.
AdamOptimizer
)
...
...
This diff is collapsed.
Click to expand it.
constants_vision_gpu_1.py
+
9
−
7
View file @
ef44688d
...
...
@@ -5,7 +5,7 @@ def mkdir_if_not_exists(dir_name):
if
not
os
.
path
.
exists
(
dir_name
):
os
.
mkdir
(
dir_name
)
experiment_name
=
'
QA_pretrain_genome_split
'
experiment_name
=
'
obj_atr_through_ans_mil
'
#experiment_name = 'object_attribute_classifier_large_images'
# Global output directory (all subexperiments will be saved here)
global_output_dir
=
'
/data/tanmay/GenVQA_Exp_Results
'
...
...
@@ -100,11 +100,10 @@ pretrained_vocab_word_vectors_npy = os.path.join(
# Object Attribute Classifier Training Params
region_batch_size
=
200
# region_num_samples = num_train_regions
region_num_epochs
=
4
region_num_epochs
=
20
region_offset
=
0
region_queue_size
=
400
region_regularization_coeff
=
1e-
4
region_regularization_coeff
=
1e-
5
region_lr
=
1e-3
region_log_every_n_iter
=
500
region_output_dir
=
os
.
path
.
join
(
...
...
@@ -180,15 +179,18 @@ vqa_answer_vocab_json = os.path.join(
# num_test_questions = 0
# Answer classifier training params
answer_batch_size
=
5
0
answer_num_epochs
=
1
0
answer_batch_size
=
2
5
answer_num_epochs
=
2
0
answer_offset
=
0
answer_obj_atr_loss_wt
=
0.0
answer_obj_atr_loss_wt
=
1.0
answer_ans_loss_wt
=
0.1
answer_mil_loss_wt
=
0.2
answer_regularization_coeff
=
1e-5
answer_queue_size
=
500
answer_embedding_dim
=
600
answer_lr
=
1e-3
answer_log_every_n_iter
=
500
answer_train_from_scratch
=
True
answer_output_dir
=
os
.
path
.
join
(
global_experiment_dir
,
'
answer_classifiers
'
)
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment