Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Question of Generator Loss of MaliGAN #47

Open
cyk1337 opened this issue Aug 24, 2020 · 0 comments
Open

Question of Generator Loss of MaliGAN #47

cyk1337 opened this issue Aug 24, 2020 · 0 comments

Comments

@cyk1337
Copy link

cyk1337 commented Aug 24, 2020

Is the generator loss of MaliGAN correct? It should be:

image

self.g_loss = -tf.reduce_sum(

        self.g_loss = -tf.reduce_sum(
            tf.reduce_sum(
                tf.one_hot(tf.to_int32(tf.reshape(self.x, [-1])), self.num_vocabulary, 1.0, 0.0) * tf.log(
                    tf.clip_by_value(tf.reshape(self.g_predictions, [-1, self.num_vocabulary]), 1e-20, 1.0)
                ), 1) * tf.reshape(self.rewards, [-1])
        )
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant