-
Notifications
You must be signed in to change notification settings - Fork 4
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
WIP: e2e: compile Rougier's mandelbrot implementation #165
base: main
Are you sure you want to change the base?
Conversation
ed73c4d
to
dc37920
Compare
The last commit measures elapsed time versus the original NumPy version. Generally, there is a bit of speedup:
However, there is a bit of an issue with
and the peformance drops to worse the original NumPy version. Also this may serve as a nice demo for transformation of a numpy program needed to make it compile. |
This is coming from some input being dynamic, and dynamo not being able to trace it properly. Are you in the last nightly? I think in the last nightly this shouldn't happen. Otherwise, can you post the graph it traces after the first and after the second iteration? |
72e8933
to
781ad00
Compare
This does not happen if I put And yes, it compiles max_iter versions of the inner loop :-). |
Sure, but the point is that it should be able to trace |
Let me retry with the latest nightly (am running a few days stale one) |
Note that loop variable is not traced:
and the trace is
this is with the latest nightly:
|
Can you run the same experiment manually changing the calls to |
Meanwhile, the last commit trivially chunks the loop to compile a chunk of 20 steps:
|
Yes, same:
|
bb3e125
to
12be7fb
Compare
we probably want to pass |
This is an exercise to gauge the workarounds needed to compile an iterative algorithm with complex numbers and fancy indexing.