zxhuang1698 / interpretability-by-parts

Code repository for "Interpretable and Accurate Fine-grained Recognition via Region Grouping", CVPR 2020 (Oral)
https://www.biostat.wisc.edu/~yli/cvpr2020-interp/
128 stars 27 forks source link

Normal value for shaping loss #6

Closed milliema closed 3 years ago

milliema commented 3 years ago

May I ask what are the normal value ranges for shaping loss on the three datasets? I tried the method ion my own dataset, yet the value keeps at 1.1 (with coeff of 0.5) and does no decrease. And what's the influences of hyperparameters in shaping loss?

zxhuang1698 commented 3 years ago

Hi @milliema , thanks for your interest. I haven't touched this for a while, but I remember it's normally below 0.05. If the loss plateaus, it might be the case that there are no enough easily-separable concepts for your dataset compared to the number of concepts you set. Also, to make the model better converge, you can try to load a pre-trained model (e.g. first three residual block of ResNet) instead of training from scratch.

Besides, you can play with coefficient, random seed, or epsilon in the loss to see whether they lead to better convergence on your dataset.

milliema commented 3 years ago

Thanks for your prompt response, I'm working on the face recognition dataset actually, and trying to find out if the region grouping idea works for face identity classification. The num_parts is 9, following the settings in Celeb dataset. I'll try the suggested solutions you've mentioned, thanks!

snant commented 3 years ago

how to alter the input image in visualize,input image is 25 by defult in your code

zxhuang1698 commented 3 years ago

You can try to change the number of columns and rows in the visualization code.