-
Notifications
You must be signed in to change notification settings - Fork 63
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
problem with tullio #1279
Comments
Since I know tulio does odd things under the hood and has custom derivative rules defined for other AD tools, I think the correct solution here is to define custom enzyme rules within Tulio.jl. Open an issue on Tulio.jl and cc me? |
However @pagnani what is your julia/os/enzyme version. On my system (julia 1.10, ubuntu, latest Enzyme), this succeeds:
|
never mind, you already uploaded that. Can you upload the full stack trace? |
Hi @wsmoses thanks for the timely reply. Here the complete (and scary) stacktrace.
Yes, the loopy version, as in my original issue, works for me too, is the Tullio version which is not working. The original problem is in a much more complicated loss function, but I found out that also this minimal case is not working. Il will also open an issue on Tullio and cross-link it here later. Also, unrelated to this issue, is this way of computing the gradient over two sets of variables ( i.e. by making two closures over A, and B) the correct thing to do? Zygote allows to make lambdas over variable as
but I did not manage to find an equivalent in Enzyme. Thanks for your work! |
Added this issue on Tullio's repo. A |
@pagnani this code succeeds for me on present Enzyme.
It is still likely desirable that Tullio add EnzymeRules, but in any case everything works otherwise. Closing, please reopen if it persists. |
Hi there,
I experience a problem with Enzyme interacting with Tullio. The MWE is the computation of the trace of the product with two matrices$tr(A*B)$ . I wrote a method with loops and one using Tullio.
Then I constructed a wrapper to compute the gradient of the two methods
Test:
The tullio version does not work. Below the very long stacktrace that I had to cut because could not fit the limit size of issues. A t the end my versioninfo and my package status).
Package status:
Versioninfo
The text was updated successfully, but these errors were encountered: