给 GAN 的随机噪声应该保持不变吗?

Should the random noise given to a GAN kept constant?

我正在研究生成对抗网络 (GAN)。在训练的每一步,我调用一个方法 generate_noise,其中 returns 一些随机噪声的张量。

# Generates noise of normal distribution
def generate_noise( shape : tuple ):
    noise = tf.random_normal( shape )
    return noise

当我调用此方法时,我收到一个随机噪声张量,该张量提供给生成器网络。我的问题是:

If the generator receives random inputs everytime ( at every step ) , how can it optimise itself to create a meaningful image ( output )?

那我是不是应该让每一步的噪音都保持恒定呢?也就是说,每一步只传递一个噪声张量。

# Generates noise of normal distribution
noise = tf.random_normal( shape )
def generate_noise( ):
    return noise

Should I make the noise constant so that the generator network has to deal with one input and hence it can create a meaningful output?

参考了很多关于 GAN 的视频和博客。我找不到噪音是否保持不变。感谢任何帮助。

噪音不是恒定的。噪声实际上可以看作是数据的潜在表示,生成器试图以隐式方式学习。 "noise" 向量中的每个维度都可以被认为是赋予生成器的特征,例如 'smile' - 该特征中的值越高,生成的图像将具有更多 'smile'。

不,噪声应该在训练期间保持不变。对于给定的潜在噪声向量,GAN 只能生成单个图像。如果保持噪声不变,GAN 只能生成 一张图像

唯一希望噪声保持不变的情况是,如果您想可视化 GAN 在单个实例训练期间的进展情况.

例如下图就是这样生成的。请注意,在每个点生成相同的图像。这是通过在训练期间的不同阶段将相同的输入噪声向量传递给 GAN 来完成的。