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

Forward map(f, ::OneHotLike) to broadcast #1619

Merged
merged 2 commits into from
Jun 15, 2021
Merged

Conversation

darsnack
Copy link
Member

@darsnack darsnack commented Jun 15, 2021

Fixes #958 by forwarding Base.map(f, ::OneHotLike) to Base.broadcast.

PR Checklist

  • Tests are added
  • Entry in NEWS.md
  • Documentation, if applicable
  • API changes require approval from a committer (different from the author, if applicable)

@DhairyaLGandhi
Copy link
Member

This really shouldnt be necessary. Why do we need this?

@darsnack
Copy link
Member Author

Ref the original issue

@DhairyaLGandhi
Copy link
Member

Is that restriction still the case?

@darsnack
Copy link
Member Author

Yes, we still specify the broadcast style for OneHotArray. This PR effectively adds the same for map.

@darsnack
Copy link
Member Author

bors r+

@bors
Copy link
Contributor

bors bot commented Jun 15, 2021

Build succeeded:

@bors bors bot merged commit 7e00a0e into FluxML:master Jun 15, 2021
@darsnack darsnack deleted the kd/fix-958 branch June 15, 2021 15:40
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

Successfully merging this pull request may close these issues.

OneHotMatrix does not support map
3 participants