HistoGAN
HistoGAN copied to clipboard
No parameters for RGBuvHistBlock?
Hi, I am checking the parameters for RGBuvHistBlock as the gradients for the parameters of the block are being set here - https://github.com/mahmoudnafifi/HistoGAN/blob/dc543f89c046f775b404cc5a4f15271e9d0e1c23/histoGAN/histoGAN.py#L741
What I am seeing is the block doesn't have parameters. Could anyone confirm if this is the case? And if yes, how is the block getting trained without having parameters and hence, no gradients?
I just want to use this block and not the whole GAN architecture for my own case.
Thanks!
That is true, the block does not have learnable params. It comprises a set of differentiable operations to compute the histogram and it is helpful to compute histogram loss (like the case in this paper) or you may use it to compute the histogram of network intermediate images during training (check this paper for example). In the latter case, you may need to introduce some learnable parameters that control some properties of the histogram feature (e.g., the smoothness of each bin).
Thank you so much! The explanation helps a lot. That means the line 741 shared above doesn't makes sense and it can be removed!
Yes, I forgot to remove it after some early experiments that include learnable parameters in the histogram feature.
I can raise a PR to remove it if you want.