-
Notifications
You must be signed in to change notification settings - Fork 5
/
run_align.sh
executable file
·48 lines (43 loc) · 1 KB
/
run_align.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
#!/bin/bash
# remember to add --save when you want to save the experiment log
# ./run_align.sh 4 zh_en QuatE --save
GPU=$1
DATASET=$2
MODEL=$3
ARGS="$4 $5 $6 $7"
ALPHA=(0.3)
LAYER=(2)
SEED=(12306)
if [ ${DATASET} == "all" ]
then
DATASETS=("zh_en" "ja_en" "fr_en")
else
DATASETS=(${DATASET})
fi
if [ ${MODEL} == "TransH" ]
then
dim="100"
elif [ ${MODEL} == "TransD" ]
then
dim="100"
else
dim="200"
fi
for dataset in "${DATASETS[@]}"
do
for alpha in "${ALPHA[@]}"
do
for layer in "${LAYER[@]}"
do
for seed in "${SEED[@]}"
do
option="--dataset ${dataset} --dim ${dim} --mode ${MODEL} --learning_rate 0.01
--alpha ${alpha} --beta ${alpha} --layer ${layer} --rel_update
--epochs 20000 --randomseed ${seed} ${ARGS}"
cmd="CUDA_VISIBLE_DEVICES=${GPU} python train_align.py ${option}"
echo $cmd
eval $cmd
done
done
done
done