run_fp32_singleCard.sh 690 Bytes
Newer Older
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

#! /bin/bash

echo "STARTING TIMING RUN AT $start_fmt"

# run benchmark
set -x
RESULTS_DIR='results/gnmt_wmt16'

GPUS=4
CPUS=1
CORES_PER_CPU=32

TRAIN_BATCH_SIZE=64
NUMEPOCHS=1
TRAIN_SEQ_LEN=50

MATH="fp16"
GLOBAL_BATCH_SIZE=`expr ${GPUS} \* ${TRAIN_BATCH_SIZE}`
${TRAIN_BATCH_SIZE} \* ${GPUS}
echo "running benchmark"

# run training
python3 -m torch.distributed.launch --nproc_per_node=${GPUS} train.py   --seed 2   --epochs ${NUMEPOCHS}  --train-batch-size ${TRAIN_BATCH_SIZE}   --train-global-batch-size ${GLOBAL_BATCH_SIZE}  --train-max-length ${TRAIN_SEQ_LEN}  --math ${MATH} ;


set +x
# end timing
end=$(date +%s)
end_fmt=$(date +%Y-%m-%d\ %r)
echo "ENDING TIMING RUN AT $end_fmt"