PlasmaCalcs.tools.xarray_tools.xarray_masks
File Purpose: tools related to masking xarray objects
for simply filling masked regions with nan, can use xarray_obj.where(…).
But, that can cause a lot of memory full of nan which is not desireable.
Methods in here help with stacking/unstacking mask dimensions,
so it can be possible to keep only the non-nan points.
Datasets are able to store the full mask info as a data_var,
so it is possible to ds.pc.mask() or ds.pc.unmask() if ‘_mask’ already in ds.
DataArrays can’t store extra dimensions,
so mask needs to be passed, e.g. arr.pc.mask(mask), arr.pc.unmask(mask)
Functions
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|