-
Notifications
You must be signed in to change notification settings - Fork 96
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
cross entropy is wrong #32
Comments
I'm not sure why you said |
The kl function and entropy imply the self._logits is already the logarithm of the probability. If not, the calculation of kl divergence and entropy are wrong |
Ok, I saw what confused you. This issue can also be solved together with #31. In our implementation, I will close both issues. If you find other problems, feel free to report them! |
in https://github.com/tensorlayer/RLzoo/blob/master/rlzoo/common/distributions.py#L96, I think it should modified to "return -tf.reduce_sum(x*self._logits, axis=1)" for returning cross entropy because self._logits is already the logarithm of the probability .
The text was updated successfully, but these errors were encountered: