StereoNet icon indicating copy to clipboard operation
StereoNet copied to clipboard

Cost Volume computation

Open lynnezixuan opened this issue 5 years ago • 1 comments

In CostVolume function, I print the value of leftMinusRightMove for each disparity but it seems that all of them are equal. I used both torch.all(torch.eq(org, leftMinusRightMove)) and torch.equal(org, leftMinusRightMove) to test it, and both of them return True.

Also from the code,

left_move = torch.cat((origin, zero_padding), 3) leftMinusRightMove = left_move[:, :, :, :origin.shape[3]] - candidate or leftMinusRightMove = torch.cat((left_move[:, :, :, :origin.shape[3]], candidate), 1)

It seems that left_move[:, :, :, :origin.shape[3]] will be always equal to origin.

If it is true, cost_volume may save the same value for each disparity. I am a beginner in stereo matching. Please correct me, if I am wrong.

lynnezixuan avatar Jul 03 '19 21:07 lynnezixuan

Copy that. I’m a little busy these days. I’ll check it ASAP.

zhixuanli avatar Jul 04 '19 03:07 zhixuanli