Skip to content

The grid class requires a large amount of memory and time to set up #222

@b-barton

Description

@b-barton

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()).

Metadata

Metadata

Assignees

Labels

enhancementNew feature or request

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions