-
Notifications
You must be signed in to change notification settings - Fork 2
/
run_pt.sh
executable file
·46 lines (39 loc) · 1.76 KB
/
run_pt.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
#!/bin/bash
#SBATCH --time=6-00:00:00
#SBATCH -A sumanmichael
#SBATCH --partition=long
#SBATCH --gres=gpu:1
#SBATCH --mem-per-cpu=2G
#SBATCH -c 20
#SBATCH [email protected]
#SBATCH --mail-type=ALL
echo "Running on $(hostname)"
#echo "Loading Cuda Modules" &&
module load cuda/10.2 &&
module load cudnn/7.6.5-cuda-10.2 &&
#echo "Loaded cuda modules" &&
echo "Starting Data Transfer"
echo "-----------------------------------"
echo "Annotations Transfer:"
rsync -az --info=progress2 [email protected]:/share3/sumanmichael/annotation_txt_files /ssd_scratch/cvit/sumanmichael/ &&
echo "Images Transfer:"
rsync -az --info=progress2 [email protected]:/share3/bvk_cvit/img_data /ssd_scratch/cvit/sumanmichael/ &&
echo "Codebase Transfer:"
rm -rf /ssd_scratch/cvit/sumanmichael/seq2seq-attention-ocr-pytorch
rsync -az --info=progress2 [email protected]:/home2/sumanmichael/seq2seq-attention-ocr-pytorch /ssd_scratch/cvit/sumanmichael/ &&
echo "Data Transfer successful"
echo "-----------------------------------"
source /home2/sumanmichael/miniconda3/etc/profile.d/conda.sh &&
conda activate pl &&
echo "conda env Activated!" &&
cd /ssd_scratch/cvit/sumanmichael/seq2seq-attention-ocr-pytorch &&
echo "-------------------------------"
echo " CUDA VERSIONS "
echo "--------nvidia-smi-------------"
nvidia-smi
echo "--------nvcc-------------------"
nvcc --version
echo "---------pytorch-cuda----------"
python -c "import torch; print('TORCH_CUDA_V:',torch.version.cuda)"
echo "-------------------------------"
UDA_LAUNCH_BLOCKING=1;HYDRA_FULL_ERROR=1 python train_pt.py --train_list /ssd_scratch/cvit/sumanmichael/annotation_txt_files/c1_10l.txt --eval_list /ssd_scratch/cvit/sumanmichael/annotation_txt_files/val.txt --num_epochs 100 --learning_rate 0.1