akanimax / pro_gan_pytorch

Unofficial PyTorch implementation of the paper titled "Progressive growing of GANs for improved Quality, Stability, and Variation"

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

implementation of MinibatchStdDev

SaoYan opened this issue · comments

The official implementation is here.

  1. It seems that in your implementation there are multiple options, which don't exist in the official code. May I ask why?

  2. Your default option is "all", which points to this line. However, the size of vals here is 1x1xHxW, that is you keep the spatial dimension. But according to both the paper and the official code, vals should be one single value (the average over all channels and pixels).

  3. In your option "group", the code is actually not correct.

vals = vals.view(self.n, self.shape[1] / self.n, self.shape[2], self.shape[3])
vals = th.mean(vals, 0, keepdim=True).view(1, self.n, 1, 1)

The size of tensors would be incompatible.

Please check the latest commit. I have made many changes..

Thank you