Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

...

  • load data from FDB/polytope into xarray datasets.
  • provide a large set of meteorological operators, interpolations, reprojections, etc. 
  • write data in grib.
  • push data into FDB (local and remote).

MeteoSwiss has developed withinis developing a data processing framework in Python that supports already a rich set of functionalities from the categories list above: 

https://github.com/MeteoSwiss-APN/icon_data_processing_incubator/tree/main


In the context of the pilot project we are adapting it to make use of the FDB/polytope data technologies. This framework will be used to implement and deploy the use cases proposed in the pilot project, accessing from EWC the IFS operational data. 

During this quarter we added functionality to the framework to: 

  • access data from FDB and/or polytope
  • write results of the data processing back into grib and FDB/polytope
  • implement application to re-project rotated lat-lon into geographical lat-lon (since it is the only grid supported at the moment by grib-jump) 

Below we show an example of use of the framework that reads data from polytope


Code Block
languagepy
titleidpi
def compute_echo_top(ref_time: dt.datetime, lead_time: int):
    request = mars.Request(
        ("HHL", "DBZ"),
        date=ref_time.strftime("%Y%m%d"),
        time=ref_time.strftime("%H00"),
        expver="0001",
        levelist=tuple(range(1, 82)),
        number=tuple(range(11)),
        step=lead_time,
        levtype=mars.LevType.MODEL_LEVEL,
        model=mars.Model.ICON_CH1_EPS,
        stream=mars.Stream.ENS_FORECAST,
        type=mars.Type.ENS_MEMBER,
    )
    ds = mch_model_data.get(request, ref_param_for_grid="HHL")

    client = get_client()

    # Calculate ECHOTOPinM
    hfl = destagger(ds["HHL"], "z")
    echo_top = interpolate_k2any(hfl, "high_fold", ds["DBZ"], [15.0], hfl)

    echo_top.attrs |= metadata.override(echo_top.message, shortName="ECHOTOPinM")

    with data_source.cosmo_grib_defs():
        client.to_fdb(echo_top)