-
-
Notifications
You must be signed in to change notification settings - Fork 154
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
Allow broadcasting in Elemwise.c_code
#928
Allow broadcasting in Elemwise.c_code
#928
Conversation
1b2c08b
to
6c1c49f
Compare
b3f6c8a
to
8cbe18e
Compare
d3b3d5c
to
ba58923
Compare
Codecov Report
@@ Coverage Diff @@
## main #928 +/- ##
==========================================
- Coverage 78.92% 78.92% -0.01%
==========================================
Files 152 152
Lines 47701 47713 +12
Branches 10862 10862
==========================================
+ Hits 37649 37658 +9
- Misses 7550 7551 +1
- Partials 2502 2504 +2
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some minor updates; otherwise, I don't see anything obviously amiss, so we might be able to merge this and simply be ready to fix and/or revert if anything comes up.
Elemwise.c_code
ba58923
to
961f098
Compare
After looking at this and working on the If you're feeling adventurous, give that thread a read and see if you can construct a |
961f098
to
9fea42b
Compare
How would Cython make our lives easier? Mainly to avoid having to write code as Python strings? |
It helps with correctness as well, since Cython will take care of all the reference counting. Also, some (or potentially a lot) of the C code we have implemented as Python strings is already implemented via Cython. For instance, |
This removes an inconsistency between Numpy and Aesara broadcasting rules, where a variable dimension with unknown shape was always assumed to be non-broadcastable (i.e., different than 1)
9fea42b
to
aaa9c3b
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
All right, let's do this.
I think this removes any necessity for
unbroadcast
uses mentioned in #915 and #916.Closes #335