yjh0410 1 年之前
父節點
當前提交
35fbbe876f
共有 1 個文件被更改,包括 2 次插入1 次删除
  1. 2 1
      train.sh

+ 2 - 1
train.sh

@@ -83,7 +83,8 @@ if [ $WORLD_SIZE == 1 ]; then
             --fp16 \
             --fp16 \
             --multi_scale
             --multi_scale
 elif [[ $WORLD_SIZE -gt 1 && $WORLD_SIZE -le 8 ]]; then
 elif [[ $WORLD_SIZE -gt 1 && $WORLD_SIZE -le 8 ]]; then
-    python -m torch.distributed.run --nproc_per_node=${WORLD_SIZE} --master_port 1669 train.py \
+    MASTER_PORT=$7
+    python -m torch.distributed.run --nproc_per_node=${WORLD_SIZE} --master_port ${MASTER_PORT} train.py \
             --cuda \
             --cuda \
             -dist \
             -dist \
             --dataset ${DATASET} \
             --dataset ${DATASET} \