gala icon indicating copy to clipboard operation
gala copied to clipboard

Dumping some orbital data in long integrations?

Open alekseygenerozov opened this issue 5 years ago • 2 comments

I am finding long integrations (with the integrate_orbit method of the Hamiltonian class) end up eating a lot of memory. Is there a way to dump orbital data from early timesteps to a file, in order to free up some ram? Thank you for your help. (And apologies if this is not the appropriate place to ask this question).

alekseygenerozov avatar Dec 14 '19 00:12 alekseygenerozov

That's a reasonable ask! What kind of API would you find useful? If there was a way to dump information at a regular interval (e.g., every 1000 steps or something) would that be sufficient?

adrn avatar Dec 16 '19 15:12 adrn

I was thinking something along the following lines

orbit = H.integrate_orbit(w0,  dt=step_size, n_steps=num_steps, dump_interval=dump_interval, Integrator=gi.DOPRI853Integrator)

where dump_interval would specify the number of steps between dumps to file. Saving to file at a regular interval is perfectly fine.

alekseygenerozov avatar Dec 17 '19 18:12 alekseygenerozov