-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy path03-adapt.template.cfg009.yaml
50 lines (50 loc) · 2.01 KB
/
03-adapt.template.cfg009.yaml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
# standard settings + BPE
SRC1SRC2.CFGID: !LoadSerialized
# This will load the contents of the above experiments that were saved to the
# YAML file specified after filename:
# This will carry out the exact same thing, except that {EXP} is resolved to
# a different value (making sure we don't overwrite the previous model),
# and except for the things explicitly overwritten in the overwrite: section.
# It's possible to change any settings as long as these don't change the number
# or nature of DyNet parameters allocated for the component.
filename: results/01-tri/SRC1SRC2.cfg002.mod
path: ''
overwrite: # list of [path, value] pairs. Value can be scalar or an arbitrary object
- path: exp_global.log_file
val: 'results/03-adapt/{EXP}.log'
- path: exp_global.model_file
val: 'results/03-adapt/{EXP}.mod'
- path: train
val: !SimpleTrainingRegimen
trainer: !AdamTrainer
alpha: 0.001
batcher: !WordSrcBatcher
avg_batch_size: 64
lr_decay: 0.5
patience: 2
restart_trainer: True
dev_zero: True
run_for_epochs: 20
src_file: 'data/SRC1_eng/ted-train.orig.spm8000.SRC1'
trg_file: 'data/SRC1_eng/ted-train.mtok.spm8000.eng'
dev_tasks:
- !AccuracyEvalTask
eval_metrics: bleu
src_file: 'data/SRC1_eng/ted-dev.orig.spm8000.SRC1'
ref_file: 'data/SRC1_eng/ted-dev.mtok.eng'
hyp_file: 'results/03-adapt/{EXP}.dev_hyp'
- !LossEvalTask
src_file: 'data/SRC1_eng/ted-dev.orig.spm8000.SRC1'
ref_file: 'data/SRC1_eng/ted-dev.mtok.spm8000.eng'
- path: evaluate
val:
- !AccuracyEvalTask
eval_metrics: bleu
src_file: 'data/SRC1_eng/ted-dev.orig.spm8000.SRC1'
ref_file: 'data/SRC1_eng/ted-dev.mtok.eng'
hyp_file: 'results/03-adapt/{EXP}.dev_hyp'
- !AccuracyEvalTask
eval_metrics: bleu
src_file: 'data/SRC1_eng/ted-test.orig.spm8000.SRC1'
ref_file: 'data/SRC1_eng/ted-test.mtok.eng'
hyp_file: 'results/03-adapt/{EXP}.tst_hyp'