Re: [thredds] Can't get THREDDS WCS GetCoverage to work

  • To: "Signell, Richard" <rsignell@xxxxxxxx>
  • Subject: Re: [thredds] Can't get THREDDS WCS GetCoverage to work
  • From: "Wright, Simon M." <smw@xxxxxxxxx>
  • Date: Fri, 2 Oct 2015 14:28:42 +0000
  • Authentication-results: spf=none (sender IP is ) smtp.mailfrom=smw@xxxxxxxxx;
  • Spamdiagnosticmetadata: NSPM
  • Spamdiagnosticoutput: 1:23
Hi Richard and THREDDS mailing list

Many thanks for your rapid response.  And many thanks for finding the 
school-boy error I was making!  Looks like I need to check my URLs a bit closer.

So, now I'm specifying the correct syntax for the WCS request, I can get 
GeoTIFF or NetCDF3 responses from THREDDS.  However, I've noticed somethings 
that baffling me further.

For a netCDF file with the following metadata:

netcdf Z:/thredds/smwtestwcs/chess_tas_196101_modified.nc {
  dimensions:
    time = 31;
    x = 656;
    y = 1057;
  variables:
    int crs;
      :long_name = "coordinate_reference_system";
      :grid_mapping_name = "transverse_mercator";
      :EPSG_code = "EPSG:27700";
      :semi_major_axis = 6377563.396; // double
      :semi_minor_axis = 6356256.91; // double
      :inverse_flattening = 299.3249646; // double
      :latitude_of_projection_origin = 49.0; // double
      :longitude_of_projection_origin = -2.0; // double
      :false_easting = 400000.0; // double
      :false_northing = -100000.0; // double
      :scale_factor_at_projection_origin = 0.9996012717; // double
      :_CoordinateTransformType = "Projection";
      :_CoordinateAxes = "x y";

    float lat(y=1057, x=656);
      :_CoordinateAxisType = "Lat";
      :long_name = "latitude of grid box centre";
      :standard_name = "latitude";
      :units = "degrees_north";
      :_FillValue = -99999.0f; // float
      :grid_mapping = "crs";

    float lon(y=1057, x=656);
      :_CoordinateAxisType = "Lon";
      :long_name = "longitude of grid box centre";
      :standard_name = "longitude";
      :units = "degrees_east";
      :_FillValue = -99999.0f; // float
      :grid_mapping = "crs";

    float tas(time=31, y=1057, x=656);
      :_FillValue = -99999.0f; // float
      :standard_name = "air_temperature";
      :long_name = "Near-Surface Air Temperature";
      :units = "K";
      :grid_mapping = "crs";
      :comment = "1.2m above surface";
      :_CoordinateAxes = "x y time";
      :_coordinates = "time y x";

    float time(time=31);
      :units = "days since 1961-01-01";
      :calendar = "gregorian";
      :long_name = "Time in days since 1961-01-01";
      :_FillValue = -99999.0f; // float
      :_CoordinateAxisType = "Time";

    float x(x=656);
      :long_name = "easting - OSGB36 grid reference";
      :standard_name = "projection_x_coordinate";
      :units = "m";
      :point_spacing = "even";
      :_FillValue = -99999.0f; // float
      :_CoordinateAxisType = "GeoX";

    float y(y=1057);
      :long_name = "northing - OSGB36 grid reference";
      :standard_name = "projection_y_coordinate";
      :units = "m";
      :point_spacing = "even";
      :_FillValue = -99999.0f; // float
      :_CoordinateAxisType = "GeoY";

  // global attributes:
  :title = "Near-Surface Air Temperature";
  :description = "Near-Surface Air Temperature (K) at 1km resolution over Great 
Britain";
  :date_created = "2015-01-22";
  :geospatial_lat_min = 49.770996f; // float
  :geospatial_lat_max = 59.395187f; // float
  :geospatial_lon_min = -9.004521f; // float
  :geospatial_lon_max = 2.491239f; // float
  :time_coverage_start = "1961-01-01";
  :time_coverage_end = "1961-01-31";
  :Conventions = "CF-1.6";
  :NCO = "4.3.7";
  :version = "v1.0";
  :featureType = "GRID";
}

I can get a NetCDF3 file returned when I request the tas variable but not a 
GeoTIFF file.  Furthermore, if I request NetCDF3 or GeoTIFF files for the lon 
and lat variables I just get error messages saying the web page is not 
available.

Is there an obvious reason why?  Do I need to include additional elements in 
the netCDF metadata?  Or am I doing something else wrong?



Many thanks for any help anyone can provide, best wishes, Simon.


>-----Original Message-----
>From: Signell, Richard [mailto:rsignell@xxxxxxxx]
>Sent: 02 October 2015 13:22
>To: Wright, Simon M. <smw@xxxxxxxxx>
>Cc: thredds@xxxxxxxxxxxxxxxx
>Subject: Re: [thredds] Can't get THREDDS WCS GetCoverage to work
>
>Simon,
>
>I think you just don't have your syntax quite right -- you need to specify
>"coverage=tas".
>
>So instead of this:
>http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified.nc?serv
>ice=WCS&version=1.0.0&request=GetCoverage=tas&time=1961-01-
>31T00:00:00Z&format=GeoTIFF
>
>Try this:
>http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified.nc?serv
>ice=WCS&version=1.0.0&request=GetCoverage&coverage=tas&time=1961-01-
>31T00:00:00Z&format=GeoTIFF
>
>
>Just to see if there was some issue with the latest release, I tried a WCS
>GetCoverage request on our TDS 4.6.3 server and it seems okay:
>
>wget -O test.tif
>"http://geoport-
>dev.whoi.edu/thredds/wcs/bathy/gom03_v10?request=GetCoverage&service=WCS&versi
>on=1.0.0&format=GeoTIFF&coverage=topo&bbox=-70.8,41.10,-70.0,41.70"
>
>-Rich
>
>On Fri, Oct 2, 2015 at 3:42 AM, Wright, Simon M. <smw@xxxxxxxxx> wrote:
>> Dear All
>>
>>
>>
>> Can anyone help me with trying to get a WCS 1.0.0 GetCoverage request
>> to work with THREDDS?
>>
>>
>>
>> I'm using THREDDS 4.6.3 and get expected XML responses when I attempt
>> WCS GetCapabilities and DescribeCoverage requests.  However, when I
>> attempt a GetCoverage request, with format equal to GeoTIFF or
>> NetCDF3, I get a "This web page is not available ERR_INVALID_RESPONSE"
>> error and when I show the details I'm told that "The web page at...
>> ...might be temporarily down or it may have moved permenantly to a new web
>address."
>>
>>
>>
>> I tried this initially with gridded data in a British National Grid
>> projection and the GetCoverage request fails.  I therefore created a
>> dummy netCDF file with a latitude longitude projection and have
>> configured a THREDDS instance in a VM on my local machine to test but
>> I am still getting the same error - the GetCapabilities and
>> DescribeCoverage requests work and the GetCoverage request fails.
>>
>>
>>
>> The form of the WCS requests I'm attempting are as follows:
>>
>> http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified
>> .nc?service=WCS&version=1.0.0&request=GetCapabilities
>>
>> http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified
>> .nc?service=WCS&version=1.0.0&request=DescribeCoverage&coverage=tas
>>
>> http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified
>> .nc?service=WCS&version=1.0.0&request=GetCoverage=tas&time=1961-01-31T
>> 00:00:00Z&format=GeoTIFF
>>
>> http://localhost:8080/thredds/wcs/smwtestwcs/chess_tas_196101_modified
>> .nc?service=WCS&version=1.0.0&request=GetCoverage=tas&time=1961-01-31T
>> 00:00:00Z&format=NetCDF3
>>
>>
>>
>> I have used ToolsUI 4.6 to check that the dummy netCDF file is OK and
>> I can successfully display the gridded data in a netCDF file using the
>> FeatureTypes | Grid tab.  I can also display the dummy netCDF file in
>> the
>> Godiva2 viewer in the VM THREDDS instance.
>>
>>
>>
>> The metadata header of the dummy netCDF file is as follows:
>>
>>
>>
>> netcdf C:/smw/Workspace/THREDDS_WCS/Data02/dummy.nc {
>>
>>   dimensions:
>>
>>     latitude = 6;
>>
>>     longitude = 12;
>>
>>   variables:
>>
>>     float latitude(latitude=6);
>>
>>       :_CoordinateAxisType = "Lat";
>>
>>       :units = "degrees_north";
>>
>>
>>
>>     int crs;
>>
>>       :grid_mapping_name = "latitude_longitude";
>>
>>       :longitude_of_prime_meridian = 0.0; // double
>>
>>       :semi_major_axis = 6378137.0; // double
>>
>>       :inverse_flattening = 298.257225363; // double
>>
>>       :_CoordinateTransformType = "Projection";
>>
>>       :_CoordinateAxes = "x y";
>>
>>
>>
>>     float longitude(longitude=12);
>>
>>       :_CoordinateAxisType = "Lon";
>>
>>       :units = "degrees_east";
>>
>>
>>
>>     float pressure(latitude=6, longitude=12);
>>
>>       :_CoordinateAxes = "x y";
>>
>>       :coordinates = "y x";
>>
>>       :long_name = "Pressure";
>>
>>       :units = "hPa";
>>
>>       :grid_mapping = "crs";
>>
>>
>>
>>     float temperature(latitude=6, longitude=12);
>>
>>       :_CoordinateAxes = "x y";
>>
>>       :coordinates = "y x";
>>
>>       :long_name = "Temperature";
>>
>>       :units = "celsius";
>>
>>       :grid_mapping = "crs";
>>
>>
>>
>>   // global attributes:
>>
>>   :cdm_data_type = "GRID";
>>
>>   :Conventions = "CF-1.0";
>>
>>   :featureType = "GRID";
>>
>> }
>>
>>
>>
>> The netCDF file in the British National Grid can also be displayed in
>> ToolsUI 4.6 and Godiva2 viewers.
>>
>>
>>
>> Can anyone shed any light on what I might be doing wrong and why I
>> can't get a GetCoverage WVS request to work?
>>
>>
>>
>>
>>
>>
>>
>> Many thanks, best wishes, Simon.
>>
>>
>>
>>
>>
>> ________________________________
>> This message (and any attachments) is for the recipient only. NERC is
>> subject to the Freedom of Information Act 2000 and the contents of
>> this email and any reply you make may be disclosed by NERC unless it
>> is exempt from release under the Act. Any material supplied to NERC
>> may be stored in an electronic records management system.
>> ________________________________
>>
>> _______________________________________________
>> thredds mailing list
>> thredds@xxxxxxxxxxxxxxxx
>> For list information or to unsubscribe,  visit:
>> http://www.unidata.ucar.edu/mailing_lists/
>
>
>
>--
>Dr. Richard P. Signell   (508) 457-2229
>USGS, 384 Woods Hole Rd.
>Woods Hole, MA 02543-1598
________________________________
 This message (and any attachments) is for the recipient only. NERC is subject 
to the Freedom of Information Act 2000 and the contents of this email and any 
reply you make may be disclosed by NERC unless it is exempt from release under 
the Act. Any material supplied to NERC may be stored in an electronic records 
management system.
________________________________



  • 2015 messages navigation, sorted by:
    1. Thread
    2. Subject
    3. Author
    4. Date
    5. ↑ Table Of Contents
  • Search the thredds archives: