forked from donglixp/coarse2fine
-
Notifications
You must be signed in to change notification settings - Fork 0
/
pretrain.sh
executable file
·30 lines (24 loc) · 941 Bytes
/
pretrain.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
DATANAME=$1
GPU_ID=$2
PWD_DIR=$(pwd)
WORK_DIR=$(dirname "$(readlink -f $0)")
cd $WORK_DIR
DATA_DIR=$WORK_DIR/data_model/$DATANAME
MODEL_PATH=$DATA_DIR/pretrain.pt
if [ $DATANAME = "geoqueries" ] ; then
cd logical
CUDA_VISIBLE_DEVICES=$GPU_ID python evaluate.py -root_dir "$WORK_DIR/data_model/" -dataset $DATANAME -split test -model_path "$MODEL_PATH"
fi
if [ $DATANAME = "atis" ] ; then
cd logical
CUDA_VISIBLE_DEVICES=$GPU_ID python evaluate.py -root_dir "$WORK_DIR/data_model/" -dataset $DATANAME -split test -model_path "$MODEL_PATH"
fi
if [ $DATANAME = "django" ] ; then
cd $DATANAME
CUDA_VISIBLE_DEVICES=$GPU_ID python evaluate.py -root_dir "$WORK_DIR/data_model/" -dataset $DATANAME -split test -model_path "$MODEL_PATH"
fi
if [ $DATANAME = "wikisql" ] ; then
cd $DATANAME
CUDA_VISIBLE_DEVICES=$GPU_ID python evaluate.py -split test -data_path "$DATA_DIR" -model_path "$MODEL_PATH"
fi
cd $PWD_DIR