-
Notifications
You must be signed in to change notification settings - Fork 6
/
Copy pathrun.sh
45 lines (39 loc) · 1008 Bytes
/
run.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
datadir=data
gpu=$1
method=$2
model=$3
data_name=$4
exp_name=$5
hops_num=1
change_level=1
if [ $# != 5 ]; then
echo "usage: $0 <GPU_ID> <method> <model> <data> <exp_name>"
echo "e.g.: $0 1 train Qadpt hgzhz Qadpt_hgzhz_v1_1"
exit 1;
fi
resultsdir=results/$data_name/$exp_name
datapath=$datadir/$data_name/$data_name.txt
modeldir=model_ckpts/$data_name/$exp_name
datatype=test
. $data_name.sh
echo "$task; VOCAB SIZE:$vocabsize; SIZE:$size*$numlayers"
echo "BatchSize:$batchsize;"
echo "LearningRate:$lr; DecayFactor:$lrdecay"
CUDA_VISIBLE_DEVICES=$gpu python3 -i main.py \
--model=$model \
--model-dir=$modeldir \
--results-dir=$resultsdir \
--data-path=$datapath \
--data-type=$datatype \
--size=$size \
--num-layers=$numlayers \
--hops-num=$hops_num \
--kgpath-len=$kgpath_len \
--vocab-size=$vocabsize \
--fact-size=$factsize \
--lr=$lr \
--lr-decay=$lrdecay \
--buckets=$buckets \
--batch-size=$batchsize \
--test-type=$method \
--change-level=$change_level