Noise in GAN Model

How did we choose noise? Why use np.random.normal and not use np.random.randn?

Hey @raunaqsingh10, np.random.normal gives us numbers within range of 0 -1 following gaussina distribution. On the other hand, randn, gives numbers with mean 0 and standard deviation 1, Generally when we are dealing with images, we use minmax scalar, that is we divided every pixel value to be in between 0-1. So it would be famiiliar if we use normal in place of randn.

HOpe this resolved your doubt.
Plz mark the doubt as resolved in my doubts section. :blush:

So we are trying to match real_image distribution in [-1,1] with fake image distribution in [0,1]

Hey @raunaqsingh10, no when we will use randn, there will be no limit set, like numbers can even come of values greater than 1 and even less than -1, we want values in a range, you could use 0-1 as well, or even you could use [-1,1](need to check if results are favourable or not)

“So we are trying to match real_image distribution in [-1,1] with fake image distribution in [0,1]”

First of all 0-1, is not fake images distribution, its the noise vector, secondly yes we are trying to match real_image distribution, with the generator output image, means the image produced by the generator will have same distribution as that of real image, i.e. [-1,1].

Hope this resolved your doubt.
Plz mark it as resolved in my doubts section. :blush:

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.