NOAA-EMC / RDASApp

Regional DAS
GNU Lesser General Public License v2.1
0 stars 5 forks source link

Creating mgbf interface in saber/jedi #31

Open TingLei-NOAA opened 2 weeks ago

TingLei-NOAA commented 2 weeks ago

As a part of the EMC efforts for MGBF (Multigrid Beta function modeling of background error covariances) for regional JEDI, a MGBF interface in saber/jedi using the newly developed oops interfaced MGBF lib is being created, which is supposed to be used as starting point/testbed for MGBF developers directly to work on JEDI applications. This issue will facilitate communications and collaborations for MGBF with JEDI. Relevant important design decisions by MGBF developers at EMC include: the regular grids will be used for the filtering grids and the mapping between these filtering grids and the analysis grids (native model grids in jedi) will be deal with by a rather generic atlas based JEDI interpolator which is actively being developed by JEDI core team.
It is noted: the GSIBE component in saber has been used as a good example for this work.

TingLei-NOAA commented 2 weeks ago

An update on May 1,2024:

1) It was planned to create a mgbf owned interpolation class as the subclass of the central block to do the interpolation (and its adjoint) to provide the mapping between the mgbf filtering grids and the analysis grids. However, it is found the saber::interpolation is being developed, the interface of which has been in saber, to be available maybe in several weeks to be tested/made use of (Thanks to F. Herbert at JCSDA) . Hence, our mgbf interpolation part is given up and a thus-simplified mgbf-jedi interface was done with a few imiportant details to be implemented later, which including the passing of data between jedi fieldset and mgbf "native grid". This version is at the private branch feature/mgbf_tl 2) A important problem to be addressed is that the atlas support to regional domain is found still to be developed . see https://github.com/JCSDA-internal/oops/issues/2575#issuecomment-2085124575 and https://github.com/ecmwf/atlas/discussions/190. Further exploring on this is ongoing and how to proceed in collaboration with jedi core teams is to be discussed and decided.

TingLei-NOAA commented 2 weeks ago

Thanks to suggestions from @danholdaway , it is decided to use Saber::gsi::interpolation, which has been working for conversion between unstructured grids and lat/lon grids on global domains and Dan believe it should also work for regional domains. Hence it is a good tool for what current mgbf needs.

danholdaway commented 2 weeks ago

@TingLei-NOAA as I mentioned, the biggest thing we now need to ensure is that the domain of the model is completely contained by the domain of the background error model. We should put our heads together to figure out a generic way to do that. It should be a check in Saber somewhere.

TingLei-NOAA commented 2 weeks ago

@danholdaway Sure. That needs to be taken care of when the "mgbf grids" is created, which is now to be planned to create on fly. There are some tricky things I need to sort out when the layout of mpi ranks are pre-defined. I will keep discussions among us ,maybe, in various ways.

TingLei-NOAA commented 3 days ago

A mgbf in jedi/saber using unstructured interpolator from saber::gsi had been created with successful compiling. A key choice is the definition of the type of the mgbf grids. Now it is defined as

  const atlas::StructuredGrid grid(conf);
//clt  how about PointCloud functionspace
   const atlas::functionspace::StructuredColumns mgbfGridFuncSpace_(grid);

Sanity tests are being setup. The following coding/debugging through various tests would delve into "under-the-hood" workings of Atlas and the unstructured interpolator on regional domains