Skip to content

SaveState

William Henney edited this page Oct 17, 2019 · 1 revision

PageOutline

What is it?

A mechanism whereby Cloudy can

  • save its current state to a file - density, temperature, level populations, radiation field, advective terms for each zone of the model
  • initialize from a saved state file instead of starting everything from scratch

Why we need this

Possible use cases include the following

Further iterations of a finished run

One may have run a model for 50 iterations and then decide it needs a few more iterations in order to better converge.

More efficient debugging

Say that a model crashes at the beginning of iteration 49, after running for 12 hours. Debugging would be much easier if Cloudy had saved state at the end of iteration 48 and could be restarted from there.

Incremental variations in model parameters

Say I have a dynamic model with an initial velocity of -5 km/s. After many iterations and weeks of CPU time it has converged beautifully. Now I want to run a model with an initial velocity of -6 km/s. It would probably converge much faster if I could use the converged earlier model as its initial state, rather than starting from scratch.

Cloudy as a subroutine

This facility would be a first step on the road to allowing Cloudy to be used by an external hydro code.

Progress to date

See ticket #15

This project has been abandoned as it is too difficult to do. One of the many problems is that the code has lots of pointers that need special attention when saving and restoring state. Even if we pull that off, keeping it aligned with code development would be a nightmare...

Clone this wiki locally