Ballooning Optimizations - #307
Conversation
…E integration by reducing memory allocations and reusing parameters
…ing ODE integration by using SVector and minimizing interpolated coefficients
…llooning stability computation to enhance performance
…pha boundary calculations
|
@logan-nc I posted the tables, this is done and ready for review |
logan-nc
left a comment
There was a problem hiding this comment.
From my quick skim, this looks good to me.
I leave the rigorous testing to @jmlmir369
|
@matt-pharr the table says Still seems slow IMO... I think the biggest lever should be the psi grid. Why not make a new psi grid for this that is concentrated where it needs to be? For example, if someone uses a |
|
@logan-nc sorry, the 1x means 1x single threaded with all performance improvements made. I updated the table to include the speedup from the single threaded improvements. I will leave the psi grid up to you, but it does run very quickly now. |


The new ballooning feature takes the vast majority of the runtime of the example cases now. There were a few trivial optimizations to make to reduce its runtime by ~60%. The primary one was fixing some repeated allocations in the ode solve.
Speedup timings:
Isolated ballooning scaling on flux — current code
compute_ballooning_stability!ballooning_alpha_boundaryFull DIII-D example (end-to-end
main, warm)maincomputeonly (original one-liner)alpha_boundary:greedy(current state)Regression harness report: