DESC icon indicating copy to clipboard operation
DESC copied to clipboard

Dp/jacobian batched vmap

Open dpanici opened this issue 8 months ago • 7 comments

This works well, this is LMN18 equilibrium solve with 1.5 oversampled grid and maxiter=10 memory trace vs time on GPU, where we get 4x memory decrease with negligible runtime increase:

image

Currently uses netket package for its chunked_vmap function, we don't want this as a dependency though so will try to implement a lighter weight version ourselves.

TODO

  • [ ] re-implement without relying on netket
  • [ ] change chunk_size to a better default value (something like 100 would be fine, maybe can dynamically choose based off of size of dim_x)
  • [ ] Add chunk_size argument to every Objective class
  • [ ] Add "chunked" as a deriv_mode to Derivative (or, just as an argument to Derivative to be used when "batched" is used)
  • [ ] add to singular integral calculation as well

Resolves #826

dpanici avatar Jun 13 '24 19:06 dpanici