From bf7a0c2d86eb9304f520928c01624cd7f910e267 Mon Sep 17 00:00:00 2001 From: Robert Osinski Date: Thu, 26 Sep 2024 13:57:29 +0000 Subject: [PATCH] 1st submit of changes to mars.step for processed ranges --- definitions/grib2/section.4.def | 10 +++++++++- definitions/grib2/timeproc.def | 1 + definitions/mars/grib.edmm.fc.def | 4 +++- definitions/mars/grib.edmm.ia.def | 4 +++- definitions/mars/grib.edmo.fc.def | 4 +++- definitions/mars/grib.edmo.ssd.def | 4 +++- definitions/mars/grib.eefo.fp.def | 8 ++++++-- definitions/mars/grib.eefo.pf.def | 4 +++- definitions/mars/grib.efas.fu.def | 4 +++- definitions/mars/grib.efas.go.def | 4 +++- definitions/mars/grib.efas.sfo.def | 4 +++- definitions/mars/grib.efcl.go.def | 4 +++- definitions/mars/grib.efcl.sfo.def | 4 +++- definitions/mars/grib.enfo.fp.def | 5 ++++- definitions/mars/grib.enfo.pf.def | 4 +++- definitions/mars/grib.ewmm.fc.def | 4 +++- definitions/mars/grib.mnth.fc.def | 4 +++- definitions/mars/grib.oper.fc.def | 3 ++- definitions/mars/grib.oper.pf.def | 4 +++- 19 files changed, 64 insertions(+), 19 deletions(-) diff --git a/definitions/grib2/section.4.def b/definitions/grib2/section.4.def index f73231b27..1069fb09c 100644 --- a/definitions/grib2/section.4.def +++ b/definitions/grib2/section.4.def @@ -128,6 +128,14 @@ if (paramId >= 140000 && paramId < 141000 && } template timeproc "grib2/timeproc.def"; -alias mars.timeproc = timeproc ; +#alias mars.timeproc = timeproc ; +if ( timeproc is "unknown" || timeproc is "point-in-time" || timeproc is "none"){ +# transient timeproc_alias = timeproc ; + transient timeprocendstep = endStep; + #meta timeprocendstep sprintf("%s(%d)",timeproc,endStep); +} else { + #transient timeprocendstep = endStep; + meta timeprocendstep sprintf("%s(%d)",timeproc,endStep); +} meta md5Section4 md5(offsetSection4,section4Length); diff --git a/definitions/grib2/timeproc.def b/definitions/grib2/timeproc.def index 9c596f355..153b1637a 100644 --- a/definitions/grib2/timeproc.def +++ b/definitions/grib2/timeproc.def @@ -1,4 +1,5 @@ concept timeproc { + "unknown" = { dummy = 1; } # either instantaneous data or processing is specified by mars stream "point-in-time" = {stepType="instant";} "point-in-time" = {stream="swmm"; numberOfTimeRange=1;} diff --git a/definitions/mars/grib.edmm.fc.def b/definitions/mars/grib.edmm.fc.def index 5d94b1664..bd7390003 100644 --- a/definitions/mars/grib.edmm.fc.def +++ b/definitions/mars/grib.edmm.fc.def @@ -20,7 +20,9 @@ alias monthlyVerificationTime = validityTime; if (class is "em" || class is "e2" || class is "ea" || class is "ep" || class is "rd" || class is "mc" || class is "et" || class is "l5") { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { diff --git a/definitions/mars/grib.edmm.ia.def b/definitions/mars/grib.edmm.ia.def index 601cee6df..346039382 100644 --- a/definitions/mars/grib.edmm.ia.def +++ b/definitions/mars/grib.edmm.ia.def @@ -1,4 +1,6 @@ # class e4 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.number=perturbationNumber; diff --git a/definitions/mars/grib.edmo.fc.def b/definitions/mars/grib.edmo.fc.def index dda3104a0..32de59906 100644 --- a/definitions/mars/grib.edmo.fc.def +++ b/definitions/mars/grib.edmo.fc.def @@ -2,7 +2,9 @@ meta verificationDate g1verificationdate(dataDate, dataTime, endStep) : read_only; meta monthlyVerificationDate g1monthlydate(verificationDate) : dump,no_copy; alias mars.date = monthlyVerificationDate; -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; meta verificationYear evaluate(verificationDate/10000); meta monthlyVerificationYear evaluate(monthlyVerificationDate/10000); diff --git a/definitions/mars/grib.edmo.ssd.def b/definitions/mars/grib.edmo.ssd.def index e82cd8bb7..da9f305cc 100644 --- a/definitions/mars/grib.edmo.ssd.def +++ b/definitions/mars/grib.edmo.ssd.def @@ -2,7 +2,9 @@ meta verificationDate g1verificationdate(dataDate, dataTime, startStep) : read_only; alias mars.date = verificationDate; -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; # Only ERA15 has time and step if(class != 3) { diff --git a/definitions/mars/grib.eefo.fp.def b/definitions/mars/grib.eefo.fp.def index 8697a1110..bf6e82911 100644 --- a/definitions/mars/grib.eefo.fp.def +++ b/definitions/mars/grib.eefo.fp.def @@ -4,7 +4,9 @@ if(startStep == endStep) { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { @@ -12,7 +14,9 @@ else { if(startStep == endStep - 24) { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { diff --git a/definitions/mars/grib.eefo.pf.def b/definitions/mars/grib.eefo.pf.def index df5f41102..45f105a36 100644 --- a/definitions/mars/grib.eefo.pf.def +++ b/definitions/mars/grib.eefo.pf.def @@ -1,2 +1,4 @@ -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.number = perturbationNumber; diff --git a/definitions/mars/grib.efas.fu.def b/definitions/mars/grib.efas.fu.def index f29fdfff5..1b21b1b7c 100644 --- a/definitions/mars/grib.efas.fu.def +++ b/definitions/mars/grib.efas.fu.def @@ -1,7 +1,9 @@ # EFAS Fill-up # ECC-701 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.date = dateOfForecast; alias mars.time = timeOfForecast; diff --git a/definitions/mars/grib.efas.go.def b/definitions/mars/grib.efas.go.def index eb09fe436..c03f9d05d 100644 --- a/definitions/mars/grib.efas.go.def +++ b/definitions/mars/grib.efas.go.def @@ -1,7 +1,9 @@ # EFAS Gridded observations # ECC-701 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.date = dateOfForecast; alias mars.time = timeOfForecast; diff --git a/definitions/mars/grib.efas.sfo.def b/definitions/mars/grib.efas.sfo.def index 8660063d7..f5d1873d8 100644 --- a/definitions/mars/grib.efas.sfo.def +++ b/definitions/mars/grib.efas.sfo.def @@ -2,7 +2,9 @@ # Water Balance # ECC-701 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.date = dateOfForecast; alias mars.time = timeOfForecast; diff --git a/definitions/mars/grib.efcl.go.def b/definitions/mars/grib.efcl.go.def index a0c9e2ed9..96ff69b91 100644 --- a/definitions/mars/grib.efcl.go.def +++ b/definitions/mars/grib.efcl.go.def @@ -1,7 +1,9 @@ # EFAS climatology Gridded observations # ECC-701 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.date = dateOfModelVersion; alias mars.time = dataTime; diff --git a/definitions/mars/grib.efcl.sfo.def b/definitions/mars/grib.efcl.sfo.def index 868be2fc6..a6121cb07 100644 --- a/definitions/mars/grib.efcl.sfo.def +++ b/definitions/mars/grib.efcl.sfo.def @@ -2,7 +2,9 @@ # Water Balance # ECC-701 -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.date = dateOfModelVersion; alias mars.time = dataTime; diff --git a/definitions/mars/grib.enfo.fp.def b/definitions/mars/grib.enfo.fp.def index 8697a1110..56f0f6fa9 100644 --- a/definitions/mars/grib.enfo.fp.def +++ b/definitions/mars/grib.enfo.fp.def @@ -5,6 +5,8 @@ if(startStep == endStep) { alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { @@ -13,7 +15,8 @@ else if(startStep == endStep - 24) { alias mars.step = endStep; - } + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { transient patch_precip_fp = 24; diff --git a/definitions/mars/grib.enfo.pf.def b/definitions/mars/grib.enfo.pf.def index df5f41102..45f105a36 100644 --- a/definitions/mars/grib.enfo.pf.def +++ b/definitions/mars/grib.enfo.pf.def @@ -1,2 +1,4 @@ -alias mars.step = endStep; +#alias mars.step = endStep; +meta stepInterval sprintf("%s",timeprocendstep); +alias mars.step = stepInterval; alias mars.number = perturbationNumber; diff --git a/definitions/mars/grib.ewmm.fc.def b/definitions/mars/grib.ewmm.fc.def index ed1cf7d98..add5207f2 100644 --- a/definitions/mars/grib.ewmm.fc.def +++ b/definitions/mars/grib.ewmm.fc.def @@ -16,7 +16,9 @@ alias monthlyVerificationTime = validityTime; if (class is "em" || class is "e2" || class is "ea" || class is "ep" || class is "rd" || class is "mc" || class is "et" || class is "l5") { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { diff --git a/definitions/mars/grib.mnth.fc.def b/definitions/mars/grib.mnth.fc.def index fc25f40af..502c50cda 100644 --- a/definitions/mars/grib.mnth.fc.def +++ b/definitions/mars/grib.mnth.fc.def @@ -15,7 +15,9 @@ alias monthlyVerificationTime = validityTime; if (class is "em" || class is "e2" || class is "ea" || class is "ep" || class is "rd" || class is "mc" || class is "et" || class is "l5") { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } else { diff --git a/definitions/mars/grib.oper.fc.def b/definitions/mars/grib.oper.fc.def index 1ece3366b..a7c81e0cf 100644 --- a/definitions/mars/grib.oper.fc.def +++ b/definitions/mars/grib.oper.fc.def @@ -1,5 +1,6 @@ if (levtype is "o2d" || levtype is "o3d") { alias mars.step = stepRange; } else { - alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } diff --git a/definitions/mars/grib.oper.pf.def b/definitions/mars/grib.oper.pf.def index 48f64b0d4..238dd719a 100644 --- a/definitions/mars/grib.oper.pf.def +++ b/definitions/mars/grib.oper.pf.def @@ -1,7 +1,9 @@ if (levtype is "o2d" || levtype is "o3d") { alias mars.step = stepRange; } else { - alias mars.step = endStep; + #alias mars.step = endStep; + meta stepInterval sprintf("%s",timeprocendstep); + alias mars.step = stepInterval; } alias mars.number = perturbationNumber; \ No newline at end of file