-
Notifications
You must be signed in to change notification settings - Fork 8
Description
The grid class needs re-working to reduce memory requirements. At the moment it works and is fine for smaller parent and child grids but it doesn't scale well to large grids like UK500 and NAARC (which uses a masked global domain). This means these larger grids need unreasonable amounts of memory allocation on JASMIN (384Gb).
The solution is to start introducing xarray for reading in grid information. PyBDY only needs parent and child grid information along the boundaries. This is:
Parent: bdy +rim +9 surrounding points +2 for calculating grid variables e1, e2, glamu, levels with partial setp etc.
Child: bdy +rim +2 for calculating grid variables.
At the moment is gets grid information for the whole domain for both. With xarray we can work out where we will need grid information and then only extract it along required boundaries (this is similar to what pybdy does for src data with nemo_bdy_extr_assist.get_ind()).