Welcome, Guest
Username: Password: Remember me

TOPIC: BINARY ATMOSPHERIC DATA FILE

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45606

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
When I use the script the way you provide in post #455598, I get an error concerning the air temperature. This variable is not included in my netcdf file (see 1rst capture). So the way I found to make the conversion pass is to comment out lines where 't2m' are involved (lines 739 to 744).

error_04.png


After this, the command run_telfile.py alter --ll2utm doesn't work on the selafin file previously generated (see 2nd capture) (My case is between 30N and 31N, so 30N shall work).

error_05.png


Actually the latest error may come from :

- wrong lines I might comment out in ecmwf.py : in which case, how can I pass the conversion from .nc to .slf when there is no 't2m' in the netcdf file ?

- or a difference between the number of points of the mesh and the length of some variables as suggested C. Coulet in post #45572 : what I'm looking at to

- or the need to compile Hermes api as indicated in the warning message (?)...in which case, how can I compile these on ubuntu please ? (my first attempts failed)

Also, would you accept to try to convert my netcdf file (with no 't2m') on your system to check if it pass well ?

Kind regards,
Audrey
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45607

  • TomS
  • TomS's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 71
  • Thank you received: 8
Instead of manipulating the python script it may be easier (and perhaps more advisable) to use a netcdf file that contains the variables windx, windy, pressure and temperature, even though you may not use certain of these variables. I can send you my netcdf file (1.8 Mb) to your email address for you to try if that helps.
The administrator has disabled public write access.
The following user(s) said Thank You: audrey.gno

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45608

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
Yes please, I would like to try yours.

Thank you again.
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45609

  • TomS
  • TomS's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 71
  • Thank you received: 8
Now sent.
The administrator has disabled public write access.
The following user(s) said Thank You: audrey.gno

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45610

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
Alright well received.
I let you know.

Thanks again,
Audrey
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45611

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
Hello Tom,

I test the conversion of your netcdf on my system and each command you wrote on post #45604 work perfectly ! (I have a mesh covering your region)

...and the following rename command works as well :
run_telfile.py alter --rename "WIND VELOCITY U=WINDX" era_april_may_2020_UTM_X_moved.slf era_april_may_2020_UTM_X_moved_rename01.slf

So thank you infinitely !
Now I know I must download the data with t2m whatever the need.

Thanks again,
Audrey
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45612

  • TomS
  • TomS's Avatar
  • OFFLINE
  • Senior Boarder
  • Posts: 71
  • Thank you received: 8
Glad it worked out ok, Audrey.
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45616

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
Hello,

The format NetCDF3 is no more available on the copernicus data store : only GRIB or NetCDF4. And the converter.py ecmwf2srf command doesn't work with NetCDF4. So I'm looking at the way to convert NetCDF4 to NetCDF3.
My first attempts with CDO and the nccopy utility failed.

Someone has a suggestion ?

Kind regards,
Audrey
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45617

  • c.coulet
  • c.coulet's Avatar
  • OFFLINE
  • Moderator
  • Posts: 3722
  • Thank you received: 1031
Hi Audrey
Why not using Grib as this is managed by the script?
Christophe
The administrator has disabled public write access.

BINARY ATMOSPHERIC DATA FILE 1 month 2 weeks ago #45618

  • audrey.gno
  • audrey.gno's Avatar
  • OFFLINE
  • Junior Boarder
  • Posts: 49
  • Thank you received: 2
Hi Christophe,
Yes, I tried with grib.

But when I run :
converter.py ecmwf2srf -f "2013-01-01" -s "2013-12-31" --bl "(42.,-12.)" --tr "(63.,13.)" --dataset data.grib --stream oper data.slf


I get :
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~

Loading essentials from the GRIB

+> identifying relevant files, by variables
Traceback (most recent call last): ] 0% | ---s
File "/home/u0167980/Telemac/v8p5r0_01/scripts/python3/converter.py", line 309, in <module>
main()
File "/home/u0167980/Telemac/v8p5r0_01/scripts/python3/converter.py", line 208, in main
ecmwf2srf(options.tfrom, options.tstop, options.blcorner,
File "/home/u0167980/Telemac/v8p5r0_01/scripts/python3/data_manip/conversion/convert_ecmwf.py", line 339, in ecmwf2srf
write_file(req, file_type, download, dataset, stream,
File "/home/u0167980/Telemac/v8p5r0_01/scripts/python3/data_manip/conversion/convert_ecmwf.py", line 235, in write_file
grb2slf = Grib(dataset, req, stream)
File "/home/u0167980/Telemac/v8p5r0_01/scripts/python3/data_manip/formats/grib.py", line 50, in __init__
grbs = pygrib.open(data)
File "src/pygrib/_pygrib.pyx", line 357, in pygrib._pygrib.open.__cinit__
OSError: [Errno could not open %s] d
The administrator has disabled public write access.
Moderators: pham

The open TELEMAC-MASCARET template for Joomla!2.5, the HTML 4 version.