jzbontar / mc-cnn

Stereo Matching by Training a Convolutional Neural Network to Compare Image Patches
BSD 2-Clause "Simplified" License
707 stars 232 forks source link

a puzzle about my modified network #25

Open Jessie2014 opened 7 years ago

Jessie2014 commented 7 years ago

Hi, I modified the fast network recently, which I replaced the first two layer with a 55 convolutional kernel. However, in the training process, the loss was decending just like the original fast network and the values were almost the same, but in the testing phase, the error were quite high and I think the disparity were total wrong. I really cannot understand the result. I wonder whether the 55 kernel is too large for the 9*9 patch, the parameters are not suitable for the network, or there is something wrong with my training. Wish you can give me some advice about the problem.Looking forward to your reply.

jzbontar commented 7 years ago

Hi Jessie,

I didn't run the code for a long time, so my advice might be a bit off. First, the patch size should be 17x17 and not 9x9 if you use 5x5 instead of 3x3 kernels. My code should compute this here, but you might want to check that it gets computed correctly. I would also plot the 17x17 patches to see if they look okay. Other than that, 5x5 kernels should work fine.

fengyiliu11 commented 7 years ago

@jzbontar I got a smilar puzzle, I replaced the layer with 5x5 convolutional kernel, and changed the patch to 17x17. In the training process, the loss was lower than 3x3 convolutional kernel with 9x9 image patch, however, the errors of disparity map became larger. I wonder whether the parameters of the stereo method are not suitable for large image patch?

Jessie2014 commented 7 years ago

Ok, I will try the 1717 patch with 55 kernel. But, I am afraid the results will be the same as @fengyiliu11 's description. Wish the 5*5 kernel works well.Thanks a lot.

Jessie2014 commented 7 years ago

Hi jzbontar, I tried the 55 kernel, the loss were lower than 33 kernel in the training phase just as @fengyiliu11 have said before, but the result was quite daunting. I predicted the samples with the saved network, the disparity map were almost black. I just changed the ks into 5, other parameters remained the same. Were there any other parameters need to be changed? I completely cannot understand that the loss is very low while the error is so high.

fengyiliu11 commented 7 years ago

@Jessie2014 hi, Jessie. Have you still worked on MC-CNN?