Reduce the peak memory usage of skillmodels#76
Conversation
… second element of the tuple returned by jax.lax.scan.
…ts first argument and using in tests.
| the sigma_point algorithm chosen. | ||
| sigma_weights (jax.numpy.array): 1d array of length n_sigma with non-negative | ||
| sigma weights. | ||
| transition_info (dict): Dict with the entries "func" (the actual transition |
There was a problem hiding this comment.
Was the docstring of transition_info outdated or did you actually change this? If you changed it, why is the mapping from columns to positions no longer needed?
There was a problem hiding this comment.
I did not change any functionality, but did check that the only thing ever used was the function. No idea when this stopped being required, for sure had been the case 2.5 years ago.
There was a problem hiding this comment.
(so yes, I did actually change from passing a dict to passing the function only)
There was a problem hiding this comment.
Maybe this was before we went full dags? But if it wasn't used you can of course remove it.
|
Check out this pull request on See visual diffs & provide feedback on Jupyter Notebooks. Powered by ReviewNB |
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #76 +/- ##
==========================================
+ Coverage 91.42% 91.43% +0.01%
==========================================
Files 39 40 +1
Lines 3066 3070 +4
==========================================
+ Hits 2803 2807 +4
Misses 263 263 ☔ View full report in Codecov by Sentry. |
|
For the record: The 8 lines of missed coverage are |
It looks like memory consumption of
loglike_and_gradis rising about linearly in the number of observations (and probably also parameters) at present, making it the limiting factor for real-world applications. This PR aims at reducing peak memory usage.Table to keep track of mem usage of
pixi run mem-on-clean-repowill be in MEMTRACKER.md. Delete upon merging.