Re: Dense CRF with DGM
Posted: Mon Jan 15, 2018, 21:09
In my opinion, the code that you attached is OK. I have used variables m and i for testing on multiple images. Since you perform testing on a single image, these variable are not needed.
Please see attached the modified code. I have deleted the redundant code and added the dgm::vis::CMarker class represent the results in the same colours.
I saw, that the denseCRF produces worse results. However, I have noticed that with the small amount of iterations (e.g. 1) the result is more or less OK. The best results I got is 86,07% with 1 iteration:
I had approximately the same results with very small classes, when using denseCRF in my experiments with micro-organism dataset.
In order to enhance the results I would suggest to do 2 steps:
Please see attached the modified code. I have deleted the redundant code and added the dgm::vis::CMarker class represent the results in the same colours.
I saw, that the denseCRF produces worse results. However, I have noticed that with the small amount of iterations (e.g. 1) the result is more or less OK. The best results I got is 86,07% with 1 iteration:
I had approximately the same results with very small classes, when using denseCRF in my experiments with micro-organism dataset.
In order to enhance the results I would suggest to do 2 steps:
- Play with the parameters of the crf.addPairwiseGaussian(3, 3, 3); and crf.addPairwiseBilateral(60, 60, 20, 20, 20, img.data, 10); functions. I think, that the inference may simply “overblur” the minor classes. Reducing “stddev” values may help.
- During the training in DGM, use more train images. That will probably make the unary potentials more strong.