瀏覽代碼

Add torch DP warning (#3698)

modifyDataloader
Glenn Jocher GitHub 3 年之前
父節點
當前提交
c1af67dcd4
沒有發現已知的金鑰在資料庫的簽署中 GPG 金鑰 ID: 4AEE18F83AFDEB23
共有 1 個檔案被更改,包括 2 行新增0 行删除
  1. +2
    -0
      train.py

+ 2
- 0
train.py 查看文件

@@ -198,6 +198,8 @@ def train(hyp, # path/to/hyp.yaml or hyp dictionary

# DP mode
if cuda and RANK == -1 and torch.cuda.device_count() > 1:
logging.warning('DP not recommended, instead use torch.distributed.run for best DDP Multi-GPU results.\n'
'See Multi-GPU Tutorial at https://github.com/ultralytics/yolov5/issues/475 to get started.')
model = torch.nn.DataParallel(model)

# SyncBatchNorm

Loading…
取消
儲存