How to create GFS data grib2 using Python?

I would like to have a chart of temperatures for the next days on my website and the Global Forecasting System is the best fit for my needs. How to plot GRIB2 data in matplotlib and create a PNG image from a graph?

I spend a lot of time on the internet asking people who know how to do this (they don't help at all) and I don't know where to start. The GFS data can be found here: ftp://ftp.ncep.noaa.gov/pub/data/nccf/com/gfs/prod/ If possible, I would like it to be lightweight and not waste too much server space.

+3


source to share


1 answer


When you feel that you are easy on the use and storage of data, you can use other forms of data besides GRIB. GRIB files usually contain data from all over the world, which is pretty useless if you only want to build a specific domain.

I can highly recommend using data from NOAA-NCEP opendap data server. You can get data from this server using netCDF4. Unfortunately, this server is known to be several times unstable, which can cause delays when updating runs and / or malformed datasets. Although, in 95% of cases, I have all the data I need.



Note. This data server can be slow due to high trade after a new run is released. The data server can be accessed here: http://nomads.ncdc.noaa.gov/data.php?name=access#hires_weather_datasets

With Matplotlib and Basemap sets, it is quite easy to print data. Some examples including using GFS datasets can be found here: http://matplotlib.org/basemap/users/examples.html

+3


source







All Articles