forked from WING-NUS/sequicity
-
Notifications
You must be signed in to change notification settings - Fork 15
/
run_weather.sh
executable file
·94 lines (77 loc) · 3.57 KB
/
run_weather.sh
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
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
#!/bin/bash
set -xeu
s=15
ss=$s
cuda=5
for idx in 1 2 3 4 5 6 7 8 9
do
# barely test
python model.py -mode test \
-model tsdf-camrest \
-cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500.json" \
db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-DB.json" \
entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-OTGY.json" \
vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
model_path="./models/fixed${idx}_r_b_m${ss}.pkl" \
result_path="./results/fixed${idx}_r_b_m${ss}-r.csv" \
cuda_device=${cuda}
# # adaptation
cp ./models/fixed${idx}_r_b_m${ss}.pkl ./models/fixed${idx}_r_b_m${ss}_adpw.pkl
python model.py -mode adjust \
-model tsdf-camrest \
-cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}.json" \
db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}-DB.json" \
entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}-OTGY.json" \
vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
model_path="./models/fixed${idx}_r_b_m${ss}_adpw.pkl" \
result_path="./results/fixed${idx}_r_b_m${ss}_adpw-w.csv" \
cuda_device=${cuda}
# test again
python model.py -mode test \
-model tsdf-camrest \
-cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500.json" \
db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-DB.json" \
entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-OTGY.json" \
vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
model_path="./models/fixed${idx}_r_b_m${ss}_adpw.pkl" \
result_path="./results/fixed${idx}_r_b_m${ss}_adpw-w.csv" \
cuda_device=${cuda}
done
# # # transfer learning
# s=15
# ss=$s
# cuda=5
# for idx in 1 2 3 4 5 6 7 8 9
# do
# # # barely test
# # python model.py -mode test \
# # -model tsdf-camrest \
# # -cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500.json" \
# # db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-DB.json" \
# # entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-OTGY.json" \
# # vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
# # model_path="./models/orig_fixed${idx}_r_b_m${ss}.pkl" \
# # result_path="./results/orig_fixed${idx}_r_b_m${ss}-r.csv" \
# # cuda_device=${cuda}
# # # adaptation
# cp ../sequicity_orig/models/fixed${idx}_r_b_m${ss}.pkl ./models/orig_fixed${idx}_r_b_m${ss}_adpw.pkl
# python model.py -mode adjust \
# -model tsdf-camrest \
# -cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}.json" \
# db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}-DB.json" \
# entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-${s}-OTGY.json" \
# vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
# model_path="./models/orig_fixed${idx}_r_b_m${ss}_adpw.pkl" \
# result_path="./results/orig_fixed${idx}_r_b_m${ss}_adpw-w.csv" \
# cuda_device=${cuda}
# # test again
# python model.py -mode test \
# -model tsdf-camrest \
# -cfg data="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500.json" \
# db="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-DB.json" \
# entity="../SimDial/1500_data_fixed_${idx}/weather-MixSpec-1500-OTGY.json" \
# vocab_path="./vocab/vocab-fixed${idx}_r_b_m_${s}w.pkl" \
# model_path="./models/orig_fixed${idx}_r_b_m${ss}_adpw.pkl" \
# result_path="./results/orig_fixed${idx}_r_b_m${ss}_adpw-w.csv" \
# cuda_device=${cuda}
# done