-
Notifications
You must be signed in to change notification settings - Fork 135
Handle compute_map=None
in Scan
#1435
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
Conversation
Codecov ReportAll modified and coverable lines are covered by tests ✅
Additional details and impacted files@@ Coverage Diff @@
## main #1435 +/- ##
=======================================
Coverage 82.12% 82.12%
=======================================
Files 211 211
Lines 49751 49752 +1
Branches 8817 8818 +1
=======================================
+ Hits 40857 40859 +2
Misses 6714 6714
+ Partials 2180 2179 -1
🚀 New features to boost your workflow:
|
pytensor/scan/op.py
Outdated
@@ -1500,6 +1500,10 @@ def make_thunk(self, node, storage_map, compute_map, no_recycling, impl=None): | |||
node_input_storage = [storage_map[r] for r in node.inputs] | |||
node_output_storage = [storage_map[r] for r in node.outputs] | |||
|
|||
# HACK: Here to handle Blockwise Scans |
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.
It's not a hack, compute map for inner graphs is useless.
Instead of creating a compute_map make an if/else below where rval
is returned and return an rval that doesn't try to assign to compute_map if it was None
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.
@ricardoV94 is this change alright?
compute_map=None
in Scan
Thanks @zaxtax |
Description
This should also fix some regressions in the recent release. Add a
None
check forcompute_map
inmake_thunk
Related Issue
Closes #1425
Type of change