1
$\begingroup$

My question concerns the notation used in the Value function of a GAN

Value Function of Gan

Does "x ~ p_data(x)" mean $$ E_{x\sim p_{data}}[log(D(x)]= \sum_{x} logD(x)(x)p_{data}(x)$$ ??

Many thanks,

$\endgroup$
3
$\begingroup$

Your notation is a little confusing, but I suspect this is because you're not reading the original equation exactly right. $\mathbb{E}_{x \sim p_{data}(x)}$ means "the expectation over $x$ drawn from the distribution described by $p_{data}(x)$". It looks like you're trying to multiply the expected value of $x$ times $\log(D(x))$ for all $x$, which isn't what's going on here and doesn't quite make sense in this notation.

The way to understand this formula is to relate it to the goal of the GAN paradigm. The first term represents "the expected ability of the discriminator to tell that real data is real". The second term means "The expected ability of the discriminator to tell that the generated data is generated". The goal is to maximize with respect to $D$ and then minimize with respect to $G$; this means "we want our discriminator to be really good at telling fake (generated) data from real data" and then "we want our generator to be really good at fooling the really good discriminator".

Hope this helps, good luck!

| improve this answer | |
$\endgroup$
0
$\begingroup$

'x ~ p_data(x)' means:

$E_{x \sim p_{data}(x)} [log D(x)] = \sum_x p_{data}(x) log D(x)$

where:

  • The summation is over all data points x in the dataset
  • p_data(x) is the probability of sampling a specific datapoint x when we sample from the dataset. For example, if we were to sample uniformly, then p_data(x) = count(x) / Number of data point in the dataset.
| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.