SAM-Adapter-PyTorch icon indicating copy to clipboard operation
SAM-Adapter-PyTorch copied to clipboard

!torchrun train.py --config configs/demo.yaml may perform faster

Open YunyaGaoTree opened this issue 1 year ago • 7 comments

Hello authors,

Thanks so much for sharing these codes. The codes are very useful to fine-tune SAM for downstream works : )

I reduced datasize, adapted the codes and run them in Google Colab with one A100 GPU. I found using torchrun is faster and more convenient compared to the original commands as shows below. https://pytorch.org/docs/stable/elastic/run.html

!torchrun train.py --config configs/demo.yaml

CUDA_VISIBLE_DEVICES=0,1,2,3 python -m torch.distributed.launch --nnodes 1 --nproc_per_node 4 loadddptrain.py --config configs/demo.yaml Besides loadddptrain.py seems wrong in the GitHub.

Thanks so much again. Kind regards.

YunyaGaoTree avatar Jun 27 '23 20:06 YunyaGaoTree