DocF / multispectral-object-detection

Multispectral Object Detection with Yolov5 and Transformer
GNU Affero General Public License v3.0
292 stars 56 forks source link

训练和测试数据加载尺度不一致的问题 #45

Open ysh-strive opened 1 year ago

ysh-strive commented 1 year ago

您好,问您一个问题? 关于FLIR数据集,在dataloader加载时,train阶段数据返回的是640x640,而val阶段返回的是544x672,请问这是怎么回事? 期待您的回复,谢谢。

wangJun09 commented 7 months ago

testloader, testdata = create_dataloader_rgb_ir(test_path_rgb, test_path_ir, imgsz_test, batch_size * 2, gs, opt, # testloader hyp=hyp, cache=opt.cache_images and not opt.notest, rect=opt.rect, rank=rank, world_size=opt.world_size, workers=opt.workers, pad=0, prefix=colorstr('val: '))我也遇到了,在train.py中加载testloader中,将rect参数设置为opt.rect或者False,因为作者代码中这里写的是True,会导致网络自动调整尺寸,还有pad好像也会有些作用,这一点没有调试去看