Open mlzxy opened 7 years ago
Hi @BenBBear , I'm afraid this answer might be a bit late but f2
, as far as I understand from the author's reference (https://arxiv.org/abs/1701.00160) and reading the code, is the minibatch discrimination set of distances for the fake part of the data. If you observe at the beginning of the code there is:
batch_size = int(image.get_shape()[0])
assert batch_size == 2 * self.batch_size
which means that for every minibatch of real data there is also an appended minibatch of fake data, such that distances to both types can be computed for a discriminator inference. I paste the author's description from the referenced tutorial for clarification (pg. 36): "The basic idea of minibatch features is to allow the discriminator to compare an example to a minibatch of generated samples and a minibatch of real samples. By measuring distances to these other samples in latent spaces, the discriminator can detect if a sample is unusually similar to other generated samples".
is there any available code for minibatch discriminator in TensorFlow?
What is
f2
? I thinkf1
is the whole thing based on the definition in the paper. Moreover, the second one will give a empty slice, which will give a exception in tensorflow from my experience (not tried yet).Thank you for clarification.