oocgcm.oceanmodels.nemo.grids.nemo_2d_grid

oocgcm.oceanmodels.nemo.grids.nemo_2d_grid(nemo_coordinate_file=None, nemo_byte_mask_file=None, chunks=None, byte_mask_level=0)

Return a generic 2d grid from nemo coordinate and mask files.

Parameters:

nemo_coordinate_file : str

path to NEMO coordinate file associated to the model configuration.

nemo_byte_mask_file : str

path to NEMO mask file associated to the model configuration.

chunks : dict-like

dictionnary of sizes of chunk for creating xarray.DataArray.

byte_mask_level : int

index of the level from which the masks should be loaded

Returns:

grid : oocgcm.core.grids.generic_2d_grid

grid object corresponding to the model configuration.