run_finetune.sh 867 字节
Newer Older
K
kinghuin 已提交
1
export FLAGS_eager_delete_tensor_gb=0.0
K
kinghuin 已提交
2
export CUDA_VISIBLE_DEVICES=0
K
kinghuin 已提交
3

K
kinghuin 已提交
4 5 6 7 8 9 10
# Recommending hyper parameters for difference task
# squad: batch_size=8, weight_decay=0, num_epoch=3, max_seq_len=512, lr=5e-5
# squad2.0: batch_size=8, weight_decay=0, num_epoch=3, max_seq_len=512, lr=5e-5
# cmrc2018: batch_size=8, weight_decay=0, num_epoch=2, max_seq_len=512, lr=2.5e-5
# drcd: batch_size=8, weight_decay=0, num_epoch=2, max_seq_len=512, lr=2.5e-5

dataset=cmrc2018
K
kinghuin 已提交
11
python -u reading_comprehension.py \
K
kinghuin 已提交
12
                   --batch_size=8 \
K
kinghuin 已提交
13
                   --use_gpu=True \
K
kinghuin 已提交
14 15
                   --checkpoint_dir=./ckpt_${dataset} \
                   --learning_rate=2.5e-5 \
K
kinghuin 已提交
16 17 18
                   --weight_decay=0.01 \
                   --warmup_proportion=0.1 \
                   --num_epoch=2 \
K
kinghuin 已提交
19 20
                   --max_seq_len=512 \
                   --dataset=${dataset}