ocean-transport / lcs-ml

Lagrangian Coherent Structure identification for machine learning
1 stars 0 forks source link

Determining equilibrated state #32

Closed hscannell closed 3 years ago

hscannell commented 3 years ago

Each time step is separately saved when spinning up the model in order to prevent memory issues.

https://github.com/ocean-transport/lcs-ml/blob/a743da0f526d8b10bef86cee4e27be7d990d6012/spin_up.py#L11-L30

However, this produces over 147K files that I would like to reload using

ds = xr.open_mfdataset('/burg/abernathey/users/hillary/spin_up/*.nc')

so that I can plot the EKE as a function of time. Loading all these files is taking a very long time and I have not been successful. Is there an alternative or better way?

rabernat commented 3 years ago

You absolutely do not need to output the position every timestep. The numerical timestep is very small (seconds or minutes) for all numerical modules. But the fields don't change significantly over those timescales. It's enough to output every day, every 5 days, etc.

hscannell commented 3 years ago

OK, I've set tsnapint equal to 5-day output now. https://github.com/ocean-transport/lcs-ml/blob/cb52d00d6d6f07796a16e21bc4333648de4292e3/spin_up.py#L26-L30

hscannell commented 2 years ago

Just to update this issue, as I learned, we do not want to set tsnapint to 5 days. The time interval for snapshots should be the model time interval (m.dt). That being said, we only want to save the model output on daily time intervals.