[gradsusr] speed difference between displaying variable and defining variable
Jennifer M Adams
jadams21 at gmu.edu
Sat Aug 20 09:51:48 EDT 2016
Hi, Jim —
The data I/O is slow with ‘define’ command because define always loops over T under the hood and is therefore getting one data value at a time. Actually, this is the way GrADS does I/O in general (row by row), but your example meets the requirements for a special case I/O request: netcdf, no pdef, not templated, and no offt. In this special case, a ‘display’ request will get all times in one I/O ping to the server, but with ‘define’ it will always loop over T. Using a server-side analysis request will mean that the 1000 data points will sit in the server’s cache, and if you make this request more than once the I/O will not be repeated on the server side, so your repeated ‘display’ requests may be a bit faster. Something like this:
'sdfopen http://monsoondata.org:9090/dods/precip/_expr_{precip}{anal}{put.your.world.coordinate.dimension.limits.here}'
‘d result’
—Jennifer
On Aug 8, 2016, at 11:32 PM, James T. Potemra <jimp at hawaii.edu<mailto:jimp at hawaii.edu>> wrote:
Hi all,
I'm trying to access a single lat/lon point from a gridded file. I
noticed that displaying the output is very fast (order seconds), while
if I try and define a variable, the response is very slow (order several
minutes).
As an example, the TRMM precip at the monsoondata server is dimensioned
lat/lon/time. Below, I extract 1000 time points at 20N, 158W. The
following displays this time-series and completes in about 5 seconds:
sdfopen http://www.monsoondata.org:9090/dods/precip'
set lat 20
set lon 202
set t 1 1000
d anal
On the other hand, trying to save this as a variable takes about 4 minutes:
sdfopen http://www.monsoondata.org:9090/dods/precip
set lat 20
set lon 202
set t 1 1000
define rain=anal
I'm wondering if there is a server-side constraint I can use to speed
this up? Although I suspect this is not really a server issue since
I've tried a few different servers and datasets/variables with similar
results (and the display works quickly). Alternately maybe there is a
way to more efficiently define a 1D variable? Thanks in advance,
Jim
Using Config: v2.1.a2 little-endian readline grib2 netcdf hdf4-sds hdf5
opendap-grids,stn geotiff shapefile cairo
_______________________________________________
gradsusr mailing list
gradsusr at gradsusr.org<mailto:gradsusr at gradsusr.org>
http://gradsusr.org/mailman/listinfo/gradsusr
--
Jennifer Miletta Adams
Center for Ocean-Land-Atmosphere Studies (COLA)
George Mason University
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://gradsusr.org/pipermail/gradsusr/attachments/20160820/82a95bd6/attachment-0001.html
More information about the gradsusr
mailing list