Versions Compared

Key

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

...

Code Block
languagebash
module load ecmwf-toolbox
grib_ls t.grb

How many messages messages does the GRIB file containscontain? Does it match to the number of expected fields retrieved from MARS?

Expand
titleSolution

grib_ls t.grb 

t.grb

edition      centre       typeOfLevel  level        dataDate     stepRange    dataType     shortName    packingType  gridType     gridType
1            ecmf         isobaricInhPa  1000         20231015     0            an           t            spectral_complex  sh          
1            ecmf         isobaricInhPa  850          20231015     0            an           t            spectral_complex  sh          
1            ecmf         isobaricInhPa  700          20231015     0            an           t            spectral_complex  sh          
1            ecmf         isobaricInhPa  500          20231015     0            an           t            spectral_complex  sh          

4 of 4 messages in t.grb
4 of 4 total messages in 1 files

...

Expand
titleSolution

module load ecmwf-toolbox

grib_ls t.gg.grb t.gg.grb

edition      centre       typeOfLevel  level        dataDate     stepRange    dataType     shortName    packingType  gridType     

1            ecmf         isobaricInhPa  1000         20231025     48           fc           t            grid_simple  reduced_gg 


grib_ls t.ll.grb

t.ll.grb

edition      centre       typeOfLevel  level        dataDate     stepRange    dataType     shortName    packingType  gridType     

1            ecmf         isobaricInhPa  1000         20231025     48           fc           t            grid_simple  regular_ll 

...

Expand
titlesolution
retrieve,
class=od,
date=-7,
expver=1,
levtype=sfc,
param=167.128/168.128,
step=48/to/96/by/24,
stream=enfo,
time=12,
type=cf,
target = "$SCRATCH/ensemble.[type].{shortName}.grb"


Note that this time we user used the MARS keyword "type" and the ecCodes key "shortName" in the name of the target file. How many target files did the requests create?

...

Code Block
languagebash
>module load ecmwf-toolbox
>grib_to_netcdf -o windspeed.nc windspeed

grib_to_netcdf: Version 2.30.2
grib_to_netcdf: Processing input file 'windspeed'.
grib_to_netcdf: Processing input file 'windspeed'.
grib_to_netcdf: Found 1 GRIB field in 2 files.
grib_to_netcdf: Ignoring key(s): method, type, stream, refdate, hdate
grib_to_netcdf: Creating netCDF file 'windspeed.nc'
grib_to_netcdf: NetCDF library version: 4.9.1 of Feb  9 2023 13:54:09 $
grib_to_netcdf: Creating large (64 bit) file format.
grib_to_netcdf: Defining variable 'u10'.
grib_to_netcdf: Done.

...