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
Make Canonizer always collapse nested ops #6686
Make Canonizer always collapse nested ops #6686
Conversation
eb402a8
to
5b06db2
Compare
LGTM. I think a more specific test like #6685 would be good. |
@twiecki, the uncommented lines in Theano/theano/tensor/tests/test_opt.py Line 370 in 5b06db2
Theano/theano/tensor/tests/test_opt.py Line 372 in 5b06db2
x + y + z setup as my example in #6685. The assert in Theano/theano/tensor/tests/test_opt.py Line 427 in 5b06db2
Apply node corresponding to the single, collapsed add /mul , which is close to what I would've done within the context of #6685.
Otherwise, I agree with the idea of being more direct by performing the opts exclusively under My only hesitation involves those interactions and the general question "Besides the clearly relevant If the consensus is that those opt interactions shouldn't be there (or at least tested there) and that we don't need a |
By the way, with these changes, the currently disabled |
I'll wait for @nouiz to take a look also. |
I'm reluctant to change that in the current status of Theano (dead). If Theano was still actively developed, I would tell we should do it. Now, if this change was optional and not enabled by default, I would be happy to review the code in detail and merge it when ready. To make it optional, you can check in the file theano/configdefaults.py and add a Theano flags for it. |
As long as the project isn't archived and there are people willing to submit, review and merge PRs, it's still alive! That said, I can understand if you're saying that you personally don't want to review PRs; that's perfectly fine. Otherwise, why not archive the repo? Likewise, I'm not clear on the stated concerns: is the current test suite insufficient for validating these changes? Is the concern for users and external libraries that rely on In light of the aforementioned concerns, adding more code and potential points of failure in lieu of fixing an existing—albeit broken—functionality contract, doesn't sound good. |
I'm fine doing review. This is what I'm doing. But there isn't significant work. Very minimal work is being done in Theano. So I review code with that point of view. The current test could find some possible bad consequence of this PR. But it certainly can't guaranty there isn't. We do not have a speed benchmark for example. What do you think of making this change optional? |
Fixes #6685