Hi Eric,
OCAPI uses the OPeNDAP protocol (more information at
http://www.opendap.org/). The THREDDS NetCDF Subsetting Service (NCSS)
is not related to OPeNDAP. The NCSS will require additional conventions
so that requests can be made in lat/lon instead of index space. OPeNDAP,
on the other hand, is limited to index space so doesn't need further
conventions.
You might be able to get NCSS working by changing the appropriate
"units" attributes to "degrees_east" and "degrees_north". There might be
some other details I'm missing. So, here's the link for the netCDF page
on conventions:
http://www.unidata.ucar.edu/software/netcdf/conventions.html. CF is
probably the one you want to follow.
As for OPeNDAP, I don't know OCAPI but it should have a way to include
an Constrained Expression (CE) when you request data. For the dataset
you list below a CE might be something like
"POTENTIAL_TEMPERATURE__MEAN_[0:1:65][0:1:240][0:1:480]"
Which would return all the data for that variable? You can get subsets
by changing the starting index, stride and ending index for each
dimension in the CE (the form is [start:stride:stop] with stride being
optional).
A CE of the above form should also return the depth, lat, and lon
variables (appropriately subset) since they appear to be proper netCDF
coordinate variables which OPeNDAP servers recognize.
Hope that helps,
Ethan
Eric Davies wrote:
Hi Roy,
I'm written a C application using the OCAPI. The application produces
the url, sends it to the server, and accepts binary results.
I want the server to do the subsetitng, and pass the subsetted results
to my application. Presumably this
would be more efficient than asking the application to do it.
The server is stuck behind our firewall I'm afraid. Presumably there
is some configuration magic I still need to do to get ncss to work, if
there is a way for me to use ncss effectively.
Eric.
At 04:12 PM 1/7/2008, Roy Mendelssohn wrote:
Hi Eric:
It is unclear if what you are asking is that you only want the TDS to
display a subset of the data to the user, or if you want to know how
a user can subset the data that is being served by the TDS. If the
latter, what applications do you use or do you just want to use the
hrml page.
Either way, is the TDS publicly accessible?
Thanks,
-Roy M.
On Jan 7, 2008, at 4:04 PM, Eric Davies wrote:
I've got the Thredds Data Server installed and I'm trying to use it
to subset a 3D grid (depth, latitude, longitude) large netcdf file.
The netcdf file was generated by a third parties software, and is
probably not compliant with anything. As subset of its schema is
shown below.
If I rename some coordinate variables, I should be able to make it
compliant with some convention. My question is how do I most
efficiently extract a 3D subset? I want to extract a subset of
depth as well as a subset of longitude and latitude.
Any ideas would be most appreciated.
Thank you.
Eric.
netcdf d7110.subvol {
dimensions:
TIMESTEP = 1 ;
LONGITUDE_T = 481 ;
LATITUDE_T = 241 ;
LONGITUDE_U = 481 ;
LATITUDE_U = 241 ;
DEPTH = 66 ;
DEPTH_EDGES = 67 ;
variables:
int TIMESTEP(TIMESTEP) ;
TIMESTEP:long_name = "Timestep" ;
float LONGITUDE_T(LONGITUDE_T) ;
LONGITUDE_T:long_name = "Longitude" ;
LONGITUDE_T:units = "degrees" ;
LONGITUDE_T:Format = "F10.4" ;
float LATITUDE_T(LATITUDE_T) ;
LATITUDE_T:long_name = "Latitude" ;
LATITUDE_T:units = "degrees" ;
LATITUDE_T:Format = "F10.4" ;
float DEPTH(DEPTH) ;
DEPTH:long_name = "Depth" ;
DEPTH:units = "cm" ;
DEPTH:Format = "F5.2" ;
DEPTH:positive = "down" ;
DEPTH:edges = "DEPTH_EDGES" ;
float POTENTIAL_TEMPERATURE__MEAN_(DEPTH, LATITUDE_T,
LONGITUDE_T) ;
POTENTIAL_TEMPERATURE__MEAN_:long_name = "potential
temperature
(mean)" ;
POTENTIAL_TEMPERATURE__MEAN_:units = "C" ;
POTENTIAL_TEMPERATURE__MEAN_:_FillValue = 0.f ;
POTENTIAL_TEMPERATURE__MEAN_:LEVEL = 0 ;
POTENTIAL_TEMPERATURE__MEAN_:T_GRID = -1 ;
....
}
**********************************************
Eric Davies, M.Sc.
Barrodale Computing Services Ltd.
Tel: (250) 472-4372 Fax: (250) 472-4373
Web: http://www.barrodale.com <http://www.barrodale.com/>
Email: eric@xxxxxxxxxxxxx
**********************************************
Mailing Address:
P.O. Box 3075 STN CSC
Victoria BC Canada V8W 3W2
Shipping Address:
Hut R, McKenzie Avenue
University of Victoria
Victoria BC Canada V8W 3W2
**********************************************
_______________________________________________
thredds mailing list
thredds@xxxxxxxxxxxxxxxx
For list information or to unsubscribe, visit: http:// <http:///>
www.unidata.ucar.edu/mailing_lists/
<http://www.unidata.ucar.edu/mailing_lists/>
**********************
"The contents of this message do not reflect any position of the U.S.
Government or NOAA."
**********************
Roy Mendelssohn
Supervisory Operations Research Analyst
NOAA/NMFS
Environmental Research Division
Southwest Fisheries Science Center
1352 Lighthouse Avenue
Pacific Grove, CA 93950-2097
e-mail: Roy.Mendelssohn@xxxxxxxx (Note new e-mail address)
voice: (831)-648-9029
fax: (831)-648-8440
www: http://www.pfeg.noaa.gov/
"Old age and treachery will overcome youth and skill."
**********************************************
Eric Davies, M.Sc.
Barrodale Computing Services Ltd.
Tel: (250) 472-4372 Fax: (250) 472-4373
Web: _http://www.barrodale.com_ <http://www.barrodale.com/>
Email: eric@xxxxxxxxxxxxx
**********************************************
Mailing Address:
P.O. Box 3075 STN CSC
Victoria BC Canada V8W 3W2
Shipping Address:
Hut R, McKenzie Avenue
University of Victoria
Victoria BC Canada V8W 3W2
**********************************************
------------------------------------------------------------------------
_______________________________________________
thredds mailing list
thredds@xxxxxxxxxxxxxxxx
For list information or to unsubscribe, visit: http://www.unidata.ucar.edu/mailing_lists/
--
Ethan R. Davis Telephone: (303) 497-8155
Software Engineer Fax: (303) 497-8690
UCAR Unidata Program Center E-mail: edavis@xxxxxxxx
P.O. Box 3000
Boulder, CO 80307-3000 http://www.unidata.ucar.edu/
---------------------------------------------------------------------------