shentianxiao / language-style-transfer

Apache License 2.0
553 stars 135 forks source link

Clarification on loss_adv and loss #10

Closed philipskokoh closed 6 years ago

philipskokoh commented 6 years ago

Hi,

It seems that loss_adv and final loss are not the same as eq.8 and eq.9 in the paper (https://arxiv.org/pdf/1705.09655.pdf). https://github.com/shentianxiao/language-style-transfer/blob/f078a9d342705ea62b04dd3ac5926d3467c2ac63/code/style_transfer.py#L131 https://github.com/shentianxiao/language-style-transfer/blob/f078a9d342705ea62b04dd3ac5926d3467c2ac63/code/style_transfer.py#L132

Any additional tricks / optimizations in the implementation?

lorelupo commented 6 years ago

Looking back at the previous git versions of the code, you would find out that the author changed the formulation of the losses in the code several months after having published the article. In particular, it looks like the author opted for the non-saturating loss formulation as suggested in the paper "Generative Adversarial Networks" (Goodfellow et al. - 2014) .

philipskokoh commented 6 years ago

Ah, yes. You are right @WolfLo . Thanks! Reference: 78380ae822d5f951a415acc7f89433d75169f0e1