Lac-GwcNet icon indicating copy to clipboard operation
Lac-GwcNet copied to clipboard

About test code?

Open BreezeJing opened this issue 3 years ago • 1 comments

Hello, thank you very much for your code, I would like to ask why you need to input the , gt_tensor to predict the display when testing?

with torch.no_grad():
    pred_disp = model(limg_tensor, rimg_tensor, gt_tensor)

BreezeJing avatar Jul 22 '22 09:07 BreezeJing

Hello, thank you very much for your code, I would like to ask why you need to input the , gt_tensor to predict the display when testing?

with torch.no_grad():
    pred_disp = model(limg_tensor, rimg_tensor, gt_tensor)

Hi,

At the training phase, to average the memory usage to multiple GPUs, we put the loss calculation into the model forward process. If you do not want the disparity GT at the testing phase, you can create another model class which only takes the left image and the right image as the input and you can load the state_dicts from the training model as well.

SpadeLiu avatar Jul 23 '22 03:07 SpadeLiu