-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
The package currently does not support saving or loading regions. This would be an extremely useful feature to support because regions in high-resolution models can take a fairly long time to compute but once they are computed are cheap to reuse.
I have had some success using pickle to locally save and load class instances but there are two fatal flaws to this approach:
- the files written by
pickleare not safe as unknown Python code may be executing while reading in a file - without a stable file structure, it is not guaranteed that files written with one version of
regionatewill be readable by an earlier or later version.
My proposal is to create custom save and load methods that store class attributes using more robust save methods from established packages (e.g. xarray, pandas, json). I have not yet figures out how best to do this, especially when dealing with class inheritance of these methods.
Metadata
Metadata
Assignees
Labels
No labels