train.sh 934 Bytes
Newer Older
Rayyyyy's avatar
Rayyyyy committed
1
#!/bin/bash
Rayyyyy's avatar
Rayyyyy committed
2
export HIP_VISIBLE_DEVICES=0,1,2,3 # 自行修改为训练的卡号和数量
Rayyyyy's avatar
Rayyyyy committed
3
4
5
export HSA_FORCE_FINE_GRAIN_PCIE=1
export USE_MIOPEN_BATCHNORM=1

Rayyyyy's avatar
Rayyyyy committed
6
echo "Training start ..."
7
8
## Train
## Train Real-ESRNet
Rayyyyy's avatar
Rayyyyy committed
9
# python -m torch.distributed.launch --nproc_per_node=4 --master_port=4321 realesrgan/train.py -opt options/train_realesrnet_x4plus.yml --launcher pytorch --auto_resume
10
## single
Rayyyyy's avatar
Rayyyyy committed
11
# python realesrgan/train.py -opt options/train_realesrnet_x4plus.yml --auto_resume
12
13
14
15
## Train Real-ESRGAN
# python -m torch.distributed.launch --nproc_per_node=4 --master_port=4321 realesrgan/train.py -opt options/train_realesrgan_x4plus.yml --launcher pytorch --auto_resume
## single
# python realesrgan/train.py -opt options/train_realesrgan_x4plus.yml --debug
Rayyyyy's avatar
Rayyyyy committed
16
17
18

## finetune
python -m torch.distributed.launch --nproc_per_node=4 --master_port=4321 realesrgan/train.py -opt options/finetune_realesrgan_x4plus.yml --launcher pytorch --auto_resume