The Earth System Modeling Framework (ESMF) is a suite of software tools for developing high-performance, multi-component Earth science modeling applications.
Because dynamic masking does not work with fields that have ungridded dimensions after the geom dimensions, I need to loop over the ungridded dimensions and create temporary fields that are associated with slices of the original data.
This presents several challenges with the existing interfaces:
Needs to be typekind and rank agnostic - results in unfortunate nested block of code and declaration of large numbers of variant local array pointers.
Cannot directly copy the geom.
must first query the field for the type of geom
must then get the geom subtype
must then wrap the subtype in a new geom object
There is apparently no mechanism to detect the staggering of the original field, so the staggering cannot be maintained in this process.
Below is a bit of client code that addresses (2), but skips (1). I suspect that a bit more infrastructure on the ESMF side will make this much cleaner.
Because dynamic masking does not work with fields that have ungridded dimensions after the geom dimensions, I need to loop over the ungridded dimensions and create temporary fields that are associated with slices of the original data.
This presents several challenges with the existing interfaces:
Below is a bit of client code that addresses (2), but skips (1). I suspect that a bit more infrastructure on the ESMF side will make this much cleaner.