pcmepp icon indicating copy to clipboard operation
pcmepp copied to clipboard

About resampling

Open ahustr opened this issue 11 months ago • 2 comments

image Hello! While studying your code, I found that when resampling is used here, it seems to be calculated directly using the variance. In my understanding, resampling seems to be using the standard deviation, so the equation logsigma.unsqueeze(1) should be divided by 2. I wonder if I missed something.

ahustr avatar Mar 15 '24 15:03 ahustr

Hi, thanks for your question.

First, I would like to clarify that this function is not used for PCME++, but only for sampling-based one, PCME. Hence it does not change the results of PCME++.

Second, your question looks correct, and that means I made a mistake when I implemented PCME (https://github.com/naver-ai/pcme). In general, I think it is not a very critical issue because, during training, it only affects the Monte-Carlo sampling-based pairwise distance and VIB loss (=KL divergence). It would not predict the correct PCME loss as the original design, but as the standard deviation value is usually much smaller than the mean distances, I think the corrected version and the wrong implementation will show almost similar empirical performances.

SanghyukChun avatar Mar 16 '24 06:03 SanghyukChun

Yes, it is more like a weighting parameter, thanks for your wonderful paper!

ahustr avatar Mar 16 '24 06:03 ahustr