netcdf PREVIMER_WW3-AQUITAINE-200M_20120101T00Z {
dimensions:
time = UNLIMITED ; // (1 currently)
longitude = 561 ;
latitude = 1501 ;
variables:
double time(time) ;
time:units = "days since 1990-01-01T00:00:00Z" ;
time:long_name = "julian day (UT)" ;
time:standard_name = "time" ;
time:conventions = "relative julian days with decimal part
(as parts of the day )" ;
time:scale_factor = 1.f ;
time:add_offset = 0.f ;
time:valid_min = 0.f ;
time:valid_max = 30000.f ;
time:axis = "T" ;
float longitude(longitude) ;
longitude:units = "degrees_east" ;
longitude:long_name = "longitude" ;
longitude:standard_name = "longitude" ;
longitude:valid_min = -180.f ;
longitude:valid_max = 180.f ;
longitude:axis = "X" ;
float latitude(latitude) ;
latitude:units = "degrees_north" ;
latitude:long_name = "latitude" ;
latitude:standard_name = "latitude" ;
latitude:valid_min = -90.f ;
latitude:valid_max = 90.f ;
latitude:axis = "Y" ;
short uabr(time, latitude, longitude) ;
uabr:units = "m" ;
uabr:_FillValue = -32767s ;
uabr:long_name =
"rms_of_bottom_displacement_amplitude_zonal" ;
uabr:standard_name =
"rms_of_bottom_displacement_amplitude_zonal" ;
uabr:scale_factor = 0.01f ;
uabr:add_offset = 0.f ;
uabr:valid_min = -18000s ;
uabr:valid_max = 18000s ;
short vabr(time, latitude, longitude) ;
vabr:units = "m" ;
vabr:_FillValue = -32767s ;
vabr:long_name =
"rms_of_bottom_displacement_amplitude_meridional" ;
vabr:standard_name =
"rms_of_bottom_displacement_amplitude_meridional" ;
vabr:scale_factor = 0.01f ;
vabr:add_offset = 0.f ;
vabr:valid_min = -18000s ;
vabr:valid_max = 18000s ;
short CgE(time, latitude, longitude) ;
CgE:units = "kW/m" ;
CgE:_FillValue = -32767s ;
CgE:long_name = "Wave_energy_flux" ;
CgE:standard_name = "sea_surface_wind_wave_energy_flux" ;
CgE:scale_factor = 0.1f ;
CgE:add_offset = 0.f ;
CgE:valid_min = 0s ;
CgE:valid_max = 9990s ;
short foc(time, latitude, longitude) ;
foc:units = "W/m2" ;
foc:_FillValue = -32767s ;
foc:long_name = "wave_to_ocean_energy_flux" ;
foc:standard_name = "wave_to_ocean_energy_flux" ;
foc:scale_factor = 0.1f ;
foc:add_offset = 0.f ;
foc:valid_min = 0s ;
foc:valid_max = 9990s ;
short hs(time, latitude, longitude) ;
hs:units = "m" ;
hs:_FillValue = -32767s ;
hs:long_name = "significant_wave_height" ;
hs:standard_name =
"significant_height_of_wind_and_swell_waves" ;
hs:scale_factor = 0.002f ;
hs:add_offset = 0.f ;
hs:valid_min = 0s ;
hs:valid_max = 32000s ;
short hs0(time, latitude, longitude) ;
hs0:units = "m" ;
hs0:_FillValue = -32767s ;
hs0:long_name = "significant_wave_height_partition_0" ;
hs0:standard_name =
"sea_surface_swell_0_wave_significant_height" ;
hs0:scale_factor = 0.002f ;
hs0:add_offset = 0.f ;
hs0:valid_min = 0s ;
hs0:valid_max = 32000s ;
short hs1(time, latitude, longitude) ;
hs1:units = "m" ;
hs1:_FillValue = -32767s ;
hs1:long_name = "significant_wave_height_partition_1" ;
hs1:standard_name =
"sea_surface_swell_1_wave_significant_height" ;
hs1:scale_factor = 0.002f ;
hs1:add_offset = 0.f ;
hs1:valid_min = 0s ;
hs1:valid_max = 32000s ;
short hs2(time, latitude, longitude) ;
hs2:units = "m" ;
hs2:_FillValue = -32767s ;
hs2:long_name = "significant_wave_height_partition_2" ;
hs2:standard_name =
"sea_surface_swell_2_wave_significant_height" ;
hs2:scale_factor = 0.002f ;
hs2:add_offset = 0.f ;
hs2:valid_min = 0s ;
hs2:valid_max = 32000s ;
short mssx(time, latitude, longitude) ;
mssx:units = "1" ;
mssx:_FillValue = -32767s ;
mssx:long_name = "east_west_mean_square_slope" ;
mssx:standard_name = "east_west_mean_square_slope" ;
mssx:scale_factor = 1.e-05f ;
mssx:add_offset = 0.f ;
mssx:valid_min = 0s ;
mssx:valid_max = 30000s ;
short mssy(time, latitude, longitude) ;
mssy:units = "1" ;
mssy:_FillValue = -32767s ;
mssy:long_name = "south_north_mean_square_slope" ;
mssy:standard_name = "south_north_mean_square_slope" ;
mssy:scale_factor = 1.e-05f ;
mssy:add_offset = 0.f ;
mssy:valid_min = 0s ;
mssy:valid_max = 30000s ;
short spr(time, latitude, longitude) ;
spr:units = "degree" ;
spr:_FillValue = -32767s ;
spr:long_name = "directional_spread" ;
spr:standard_name = "sea_surface_wave_directional_spread" ;
spr:scale_factor = 0.1f ;
spr:add_offset = 0.f ;
spr:valid_min = 0s ;
spr:valid_max = 900s ;
short t(time, latitude, longitude) ;
t:units = "s" ;
t:_FillValue = -32767s ;
t:long_name = "mean_period_Tm01" ;
t:standard_name =
"sea_surface_wind_wave_mean_period_from_variance_spectral_density_first_frequency_moment"
;
t:scale_factor = 0.01f ;
t:add_offset = 0.f ;
t:valid_min = 0s ;
t:valid_max = 5000s ;
short t02(time, latitude, longitude) ;
t02:units = "s" ;
t02:_FillValue = -32767s ;
t02:long_name = "mean_period_Tm02" ;
t02:standard_name =
"sea_surface_wind_wave_mean_period_from_variance_spectral_density_second_frequency_moment"
;
t02:scale_factor = 0.01f ;
t02:add_offset = 0.f ;
t02:valid_min = 0s ;
t02:valid_max = 5000s ;
short utus(time, latitude, longitude) ;
utus:units = "m2s-1" ;
utus:_FillValue = -32767s ;
utus:long_name = "eastward_Stokes_transport" ;
utus:standard_name = "eastward_Stokes_transport" ;
utus:scale_factor = 0.001f ;
utus:add_offset = 0.f ;
utus:valid_min = -9900s ;
utus:valid_max = 9990s ;
short vtus(time, latitude, longitude) ;
vtus:units = "m2s-1" ;
vtus:_FillValue = -32767s ;
vtus:long_name = "northward_Stokes_transport" ;
vtus:standard_name = "northward_Stokes_transport" ;
vtus:scale_factor = 0.001f ;
vtus:add_offset = 0.f ;
vtus:valid_min = -9900s ;
vtus:valid_max = 9990s ;
short uubr(time, latitude, longitude) ;
uubr:units = "ms-1" ;
uubr:_FillValue = -32767s ;
uubr:long_name = "rms_of_bottom_velocity_amplitude_zonal" ;
uubr:standard_name =
"rms_of_bottom_velocity_amplitude_zonal" ;
uubr:scale_factor = 0.01f ;
uubr:add_offset = 0.f ;
uubr:valid_min = -18000s ;
uubr:valid_max = 18000s ;
short vubr(time, latitude, longitude) ;
vubr:units = "ms-1" ;
vubr:_FillValue = -32767s ;
vubr:long_name =
"rms_of_bottom_velocity_amplitude_meridional" ;
vubr:standard_name =
"rms_of_bottom_velocity_amplitude_meridional" ;
vubr:scale_factor = 0.01f ;
vubr:add_offset = 0.f ;
vubr:valid_min = -18000s ;
vubr:valid_max = 18000s ;
short uuss(time, latitude, longitude) ;
uuss:units = "m/s" ;
uuss:_FillValue = -32767s ;
uuss:long_name = "eastward_surface_Stokes_drift" ;
uuss:standard_name = "eastward_surface_Stokes_drift" ;
uuss:scale_factor = 0.0005f ;
uuss:add_offset = 0.f ;
uuss:valid_min = -9900s ;
uuss:valid_max = 9900s ;
short vuss(time, latitude, longitude) ;
vuss:units = "m/s" ;
vuss:_FillValue = -32767s ;
vuss:long_name = "northward_surface_Stokes_drift" ;
vuss:standard_name = "northward_surface_Stokes_drift" ;
vuss:scale_factor = 0.0005f ;
vuss:add_offset = 0.f ;
vuss:valid_min = -9900s ;
vuss:valid_max = 9900s ;
short uust(time, latitude, longitude) ;
uust:units = "m/s" ;
uust:_FillValue = -32767s ;
uust:long_name = "eastward_friction_velocity" ;
uust:standard_name = "eastward_friction_velocity" ;
uust:scale_factor = 0.01f ;
uust:add_offset = 0.f ;
uust:valid_min = -9900s ;
uust:valid_max = 9900s ;
short vust(time, latitude, longitude) ;
vust:units = "m/s" ;
vust:_FillValue = -32767s ;
vust:long_name = "northward_friction_velocity" ;
vust:standard_name = "northward_friction_velocity" ;
vust:scale_factor = 0.01f ;
vust:add_offset = 0.f ;
vust:valid_min = -9900s ;
vust:valid_max = 9900s ;
short U10(time, latitude, longitude) ;
U10:units = "m/s" ;
U10:_FillValue = -32767s ;
U10:long_name = "eastward_wind" ;
U10:standard_name = "eastward_wind" ;
U10:scale_factor = 0.1f ;
U10:add_offset = 0.f ;
U10:valid_min = -990s ;
U10:valid_max = 990s ;
short V10(time, latitude, longitude) ;
V10:units = "m/s" ;
V10:_FillValue = -32767s ;
V10:long_name = "northward_wind" ;
V10:standard_name = "northward_wind" ;
V10:scale_factor = 0.1f ;
V10:add_offset = 0.f ;
V10:valid_min = -990s ;
V10:valid_max = 990s ;
short dir(time, latitude, longitude) ;
dir:units = "degree" ;
dir:_FillValue = -32767s ;
dir:long_name = "wave_mean_direction" ;
dir:standard_name = "sea_surface_wave_from_direction" ;
dir:scale_factor = 0.1f ;
dir:add_offset = 0.f ;
dir:valid_min = 0s ;
dir:valid_max = 3600s ;
short dp(time, latitude, longitude) ;
dp:units = "degree" ;
dp:_FillValue = -32767s ;
dp:long_name = "peak_direction" ;
dp:standard_name = "peak_direction" ;
dp:scale_factor = 1.f ;
dp:add_offset = 0.f ;
dp:valid_min = 0s ;
dp:valid_max = 360s ;
short th0(time, latitude, longitude) ;
th0:units = "degree" ;
th0:_FillValue = -32767s ;
th0:long_name = "mean_direction_swell_partition_0" ;
th0:standard_name =
"sea_surface_swell_0_wave_from_mean_direction" ;
th0:scale_factor = 1.f ;
th0:add_offset = 0.f ;
th0:valid_min = 0s ;
th0:valid_max = 360s ;
short th1(time, latitude, longitude) ;
th1:units = "degree" ;
th1:_FillValue = -32767s ;
th1:long_name = "mean_direction_swell_partition_1" ;
th1:standard_name =
"sea_surface_swell_1_wave_from_mean_direction" ;
th1:scale_factor = 1.f ;
th1:add_offset = 0.f ;
th1:valid_min = 0s ;
th1:valid_max = 360s ;
short th2(time, latitude, longitude) ;
th2:units = "degree" ;
th2:_FillValue = -32767s ;
th2:long_name = "mean_direction_swell_partition_2" ;
th2:standard_name =
"sea_surface_swell_2_wave_from_mean_direction" ;
th2:scale_factor = 1.f ;
th2:add_offset = 0.f ;
th2:valid_min = 0s ;
th2:valid_max = 360s ;
short fp(time, latitude, longitude) ;
fp:units = "s-1" ;
fp:_FillValue = -32767s ;
fp:long_name = "wave_peak_frequency" ;
fp:standard_name = "sea_surface_wave_peak_frequency" ;
fp:scale_factor = 0.001f ;
fp:add_offset = 0.f ;
fp:valid_min = 0s ;
fp:valid_max = 10000s ;
short tp0(time, latitude, longitude) ;
tp0:units = "s" ;
tp0:_FillValue = -32767s ;
tp0:long_name = "peak_period_swell_partition_0" ;
tp0:standard_name = "sea_surface_swell_0_wave_peak_period"
;
tp0:scale_factor = 0.01f ;
tp0:add_offset = 0.f ;
tp0:valid_min = 0s ;
tp0:valid_max = 10000s ;
short tp1(time, latitude, longitude) ;
tp1:units = "s" ;
tp1:_FillValue = -32767s ;
tp1:long_name = "peak_period_swell_partition_1" ;
tp1:standard_name = "sea_surface_swell_1_wave_peak_period"
;
tp1:scale_factor = 0.01f ;
tp1:add_offset = 0.f ;
tp1:valid_min = 0s ;
tp1:valid_max = 10000s ;
short tp2(time, latitude, longitude) ;
tp2:units = "s" ;
tp2:_FillValue = -32767s ;
tp2:long_name = "peak_period_swell_partition_2" ;
tp2:standard_name = "sea_surface_swell_2_wave_peak_period"
;
tp2:scale_factor = 0.01f ;
tp2:add_offset = 0.f ;
tp2:valid_min = 0s ;
tp2:valid_max = 10000s ;
short U(time, latitude, longitude) ;
U:units = "m/s" ;
U:_FillValue = -32767s ;
U:long_name = "eastward_current" ;
U:standard_name = "eastward_current" ;
U:scale_factor = 0.01f ;
U:add_offset = 0.f ;
U:valid_min = -990s ;
U:valid_max = 990s ;
short V(time, latitude, longitude) ;
V:units = "m/s" ;
V:_FillValue = -32767s ;
V:long_name = "northward_current" ;
V:standard_name = "northward_current" ;
V:scale_factor = 0.01f ;
V:add_offset = 0.f ;
V:valid_min = -990s ;
V:valid_max = 990s ;
// global attributes:
:data_type = "OCO straight grid" ;
:format_version = "1.2" ;
:title = "WAVEWATCH-III FORECAST" ;
:Conventions = "CF-1.5" ;
:netcdf_version = "4.11" ;
:product_name =
"PREVIMER_WW3-AQUITAINE-200M_20120101T00Z.nc" ;
:software_version = "3.14-Ifremer-SHOM_rev65" ;
:references = "http://wwz.ifremer.fr/iowaga/" ;
:source = "MODEL WAVEWATCH III (R) NORGAS-UG" ;
:comment = "" ;
:area = "AQUITAINE-200M" ;
:easting = "longitude" ;
:northing = "latitude" ;
:grid_projection = "n/a" ;
:southernmost_latitude = " 43.2999992" ;
:northernmost_latitude = " 45.7999992" ;
:latitude_resolution = " 0.0016667" ;
:westernmost_longitude = " -1.9000000" ;
:easternmost_longitude = " -0.5000000" ;
:longitude_resolution = " 0.0025000" ;
:minimum_altitude = "-12000 m" ;
:maximum_altitude = "9000 m" ;
:altitude_resolution = "n/a" ;
:field_type = "hourly" ;
:forecast_range = "6 day forecast" ;
:forecast_type = "forecast" ;
:institution = "SHOM and Ifremer" ;
:institution_references = "http://www.previmer.org/" ;
:data_centre = "IFREMER OCO DATA CENTER" ;
:data_centre_references = "http://www.previmer.org/" ;
:contact = "cdoco-expl...@ifremer.fr" ;
:distribution_statement = "No restrictions" ;
:operational_status = "operational" ;
:quality_index = "0" ;
:creation_date = "2012-01-02T05:19:15Z" ;
:product_version = "1.0" ;
:history = "2012-01-02T05:19:15Z :
Creation,2012-01-02T05:48:57Z : Interpolation in regular grid" ;
:run_time = "2012-01-02T05:19:15Z" ;
:date_cycle = "2012010112" ;
:forcing_wind = "wind_cel25" ;
:forcing_ice = "no" ;
:forcing_level = "MARSD1_lev" ;
:forcing_current = "MARSD1_cur" ;
:SWELLF = "0.1" ;
:ZWND = "15." ;
:IQTYPE = "3" ;
:NDEPTH = "3" ;
:BETAMAX = "1.25" ;
:EXPFSN = "F" ;
:GAMMA = "0.15" ;
:CICE0 = "0.25" ;
:CICEN = "0.75" ;
:FLAGTR = "4" ;
:NX\*SX = "360." ;
:start_date = "2012-01-01T00:00:00Z" ;
:stop_date = "2012-01-01T00:00:00Z" ;
}
Dear Gerd,
Thank you for your python code, it is like gold bar for me!
Okay, so it looks very simple now.
I’ll port it to c# soon, and report you my result (but I’m feeling
optimistic)
By “projection & matrix information”, I was meaning basically :
- “Projection” : The 6 geographic coefficients, called GeoTransform in
GDAL, that define the data location. These are 6 numbers, but practically
only 4 are used
0 left position of the datas
1 size of one cell in X direction
2 rotation (rarely used)
3 Top position of the datas
4 rotation (rarely used)
5 size of one cell in Y direction
I’m sure you see what I’m talking about. Usually it is not enough since
the projection type should be known (Lambert, UTM, Polyconic, Mercator
...) but in my case it is just Lat/Lon WGS84
How to retreive these coefficients?
- “matrix information”
I was meaning the data buffer or array itself, but OK you give this in
your sample!
Best regards,
Mathieu
From: Gerd Heber
Sent: Monday, August 13, 2012 3:47 PM
To: 'HDF Users Discussion List'
Subject: Re: [Hdf-forum] Can Hdf5DotNet replace GDAL# in my case?
Mathieu, yes you can. Here’s a simple example that reads the dataset at
‘/hs’ and prints
its dimensions and values. (You’ll need IronPython
http://ironpython.net/)
I’m not sure what you mean by “projection and matrix information”. Where
do
they live? In attributes? You can look at the file in HDFView
(http://www.hdfgroup.org/hdf-java-html/hdfview/)...
Cheers, G.
From: hdf-forum-boun...@hdfgroup.org
[mailto:hdf-forum-boun...@hdfgroup.org] On Behalf Of Mathieu
Sent: Sunday, August 12, 2012 7:39 AM
To: hdf-forum@hdfgroup.org
Subject: [Hdf-forum] Can Hdf5DotNet replace GDAL# in my case?
Dear all,
I am a windows C# developer, I develop a weather forecast web site for
french surfers.
I am working with a oceanographic data provider since 3 years, and until
now I was using Gdal# to read their HDF (.nc) data.
Recently, this data provider released a new product, and used a new
version of HDF : V5.
GDAL# cannot read these data. After some researchs on the web and
discussions with the data provider, Gfdal#'s HDF library is too old. Gdal
does not plan to update it in a near future.
As a consequence I am looking for an alternative library to read HDF
data.
Then I found HDF5DotNet.
I have started to study the library, but I fell I will have to invest a
lot to adapt my tools to this library.
That's why before to start working on HDF5DotNet, I would like to ensure
that this library is able to read these data I want to be compatible
with.
So my request is :
Could anybody who is confortable with HDF5DotNet try to open this file
with this library?
I know it is not a common request, but it would save me so much time!
The sample file is here :
www.yadusurf.com/PREVIMER_WW3-AQUITAINE-200M_20120101T00Z.nc
(It is quiet big, 54Mo, but the server has a quiet good bandwidth)
Basically my need is to :
- Read projection and matrix information (projection is just position of
the grid and cell size/size of the grid)
- Read the band "hs" (there are other intersecting datasets but
validating this one is enough)
In advance, thanks
Mathieu
_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org
_______________________________________________
Hdf-forum is for HDF software users discussion.
Hdf-forum@hdfgroup.org
http://mail.hdfgroup.org/mailman/listinfo/hdf-forum_hdfgroup.org