ECC-1563: GRIB2: Introduce new local section 4 templates for extra large ensembles

This commit is contained in:
Shahram Najm 2023-04-01 18:43:29 +01:00
parent 2dbe057cb8
commit a0f8af1ae6
4 changed files with 16 additions and 3 deletions

View File

@ -1,3 +1,3 @@
# Code table 4.0 - Product definition template number
65533 65533 individual member for large ensemble forecast, control and perturbed, at a horizontal level or in a horizontal layer at a point in time
65534 65534 Individual member for large ensemble forecast, control and perturbed, at a horizontal level or in a horizontal layer, in a continuous or non-continuous interval
65533 65533 Individual member for large ensemble forecast, control and perturbed, at a horizontal level or in a horizontal layer at a point in time
65534 65534 Individual member for large ensemble forecast, control and perturbed, at a horizontal level or in a horizontal layer, in a continuous or non-continuous interval

View File

@ -16,6 +16,7 @@ temp1=temp1.$label.grib2
temp2=temp2.$label.grib2
temp=temp.$label.grib2
tempFilt=temp.$label.filt
tempText=temp.$label.txt
sample2=$ECCODES_SAMPLES_PATH/GRIB2.tmpl
@ -123,5 +124,17 @@ $tools_dir/grib_compare -b productDefinitionTemplateNumber $temp1 $temp2
$tools_dir/grib_set -s productDefinitionTemplateNumber=40033 $sample2 $temp
$tools_dir/grib_set -s productDefinitionTemplateNumber=40034 $sample2 $temp
# ECC-1563: new local section 4 templates for extra large ensembles
$tools_dir/grib_set -s localTablesVersion=1,productDefinitionTemplateNumber=65533,perturbationNumber=2e8 $sample2 $temp
grib_check_key_equals $temp perturbationNumber '200000000'
$tools_dir/grib_dump -O -p section_4 $temp > $tempText
grep -q "Individual member for large ensemble forecast.*point in time" $tempText
rm -f $temp $temp1 $temp2 $tempFilt
$tools_dir/grib_set -s localTablesVersion=1,productDefinitionTemplateNumber=65534,perturbationNumber=2e8 $sample2 $temp
grib_check_key_equals $temp perturbationNumber,typeOfStatisticalProcessing '200000000 255'
$tools_dir/grib_dump -O -p section_4 $temp > $tempText
grep -q "Individual member for large ensemble forecast.*continuous or non-continuous interval" $tempText
# Clean up
rm -f $temp $temp1 $temp2 $tempFilt $tempText