Add train.py `--img-size floor (#4099)
This commit is contained in:
1 parent
3bef77f5cb
commit
2c073cd207
2 files changed
+4
-4
No files matched your search
@@ -207,7 +207,7 @@ def train(hyp, # path/to/hyp.yaml or hyp dictionary
|
||||
# Image sizes
|
||||
gs = max(int(model.stride.max()), 32) # grid size (max stride)
|
||||
nl = model.model[-1].nl # number of detection layers (used for scaling hyp['obj'])
|
||||
imgsz = check_img_size(opt.imgsz, gs) # verify imgsz is gs-multiple
|
||||
imgsz = check_img_size(opt.imgsz, gs, floor=gs * 2) # verify imgsz is gs-multiple
|
||||
|
||||
# DP mode
|
||||
if cuda and RANK == -1 and torch.cuda.device_count() > 1:
|
||||
|
||||
Reference in new issue
Block a user