grey-eye / talking-heads

Our implementation of "Few-Shot Adversarial Learning of Realistic Neural Talking Head Models" (Egor Zakharov et al.)
GNU General Public License v3.0
593 stars 109 forks source link

Discriminator isn't supposed to have sigmoid activation at the end #42

Open nwatab opened 5 years ago

nwatab commented 5 years ago

Hinge loss doesn't expect to get probability as input. From paper,

The objective (6) thus compares the realism of the fake example xˆi(t) and the real example xi(t) and then updates the discriminator parameters to push these scores below −1 and above +1 respectively.

So you can just put inner-product and y_true into hinge loss. y_true is 1 for real and -1 for fake.

rexxar-liang commented 4 years ago

Could someone please raise a PR to fix it?