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

Why restrict cross entropy to 2D inputs only? #57

Open
hristo-vrigazov opened this issue Sep 11, 2022 · 1 comment
Open

Why restrict cross entropy to 2D inputs only? #57

hristo-vrigazov opened this issue Sep 11, 2022 · 1 comment

Comments

@hristo-vrigazov
Copy link

First, congrats on such a great project!

Basically the title. PyTorch and Tensorflow both support cross entropy in the ND case, and your implementation in Numpy would work for the multi-dimensional case too. However, in every function, there is an assert that the logits are 2D array. I propose to remove those asserts 😄

@christian-westbrook
Copy link

I ran into this problem while using the latest version of https://github.com/bethgelab/foolbox, which uses eagerpy. I would also benefit from support for cross-entropy against more than two dimensions.

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

2 participants