Hi Ethan - thanks so much for the help. I'm at a conference today - ill open up
access to our thredds server so you can take a look.
I'm not sure but I believe that time is first in the datasets that aggregate
correctly.
The error I'm getting mentions illegal range for dimension 2.
I apologize for delaying in responding. I will provide more info on this issue
ASAP. Thank you so much for your help!
Erich
On Sep 4, 2013, at 4:21 PM, "Ethan Davis" <edavis@xxxxxxxxxxxxxxxx> wrote:
> Hi Erich,
>
> [I'm a bit rusty on NcML aggregations and John is out of the office this
> week. But here goes ...]
>
> The "joinExisting" section of the NcML aggregation page [1] mentions that
>
> "[a]ny variable that has [the aggregation] dimension as
> its outer dimension is an aggregation variable. The
> dimension must be the outer (slowest varying) dimension."
>
> I always forget the order of the dimensions in an ncdump. But I notice
> that all the examples on the NcML aggregation page [1] show the
> aggregation dimension ("time" in this case) as the first one listed in
> the ncdump output, e.g.
>
> double P(time=31, lat=3, lon=4);
>
> Whereas your ncdump output below shows the aggregation dimension ("day")
> last in the ncdump output
>
> float wind_speed(lat, lon, day) ;
>
> What is the order of the dimensions in the datasets that you are
> successfully aggregating?
>
> If that doesn't seem to pan out, can you send us (or point us to) some
> sample data files? Five or six consecutive year files should do.
>
> Hope that helps,
>
> Ethan
>
> [1]
> http://www.unidata.ucar.edu/software/thredds/current/netcdf-java/ncml/v2.2/Aggregation.html#joinExisting
>
>
> On 8/30/2013 2:30 PM, Seamon, Erich wrote:
>> Hello all – Im trying to aggregate a series of nc files that have ‘day’
>> as the time dimension – with 365 entries in each file – representing
>> daily readings.
>>
>> This is a piece from my catalog.xml
>>
>> <dataset name="MET Maximum Reflectance 1979-2012 Aggregated"
>> ID="agg_met_rmax_1979_2012_WUSA" serviceName="all" harvest="true"
>> urlPath="agg_met_rmax_1979_2012_WUSA.nc">
>>
>> <netcdf xmlns="http://www.unidata.ucar.edu/namespaces/netcdf/ncml-2.2">
>> <aggregation dimName="day" type="joinExisting" timeUnitsChange="true">
>> <scan location="/xxxx/xxxx/xxxx/MET/" regExp="rmax.*\.nc$"
>> subdirs="false" />
>>
>> </aggregation>
>> </netcdf>
>> </dataset>
>>
>>
>> When I attempt to access a subset more than one year – I get a
>> javaexception – ‘illegal range for dimension 2: last requested 753 >
>> 365 max’
>>
>> Ncdump of a file that im trying to aggregate:
>>
>> netcdf vs_2012 {
>> dimensions:
>> day = 366 ;
>> lon = 1386 ;
>> lat = 585 ;
>> variables:
>> float lon(lon) ;
>> lon:units = "degrees_east" ;
>> lon:description = "longitude" ;
>>
>> float lat(lat) ;
>> lat:units = "degrees_north" ;
>> lat:description = "latitude" ;
>>
>> float day(day) ;
>> day:units = "days since 1900-01-01 00:00:00" ;
>> day:calendar = "gregorian" ;
>> day:description = "days since 1900-01-01" ;
>>
>> float wind_speed(lat, lon, day) ;
>> wind_speed:units = "m/s" ;
>> wind_speed:description = "Daily Mean Wind Speed" ;
>> wind_speed:_FillValue = -9999.f ;
>> wind_speed:esri_pe_string =
>> "GEOGCS[\\\"GCS_WGS_1984\\\",DATUM[\\\"D_WGS_1984\\\",SPHEROID[\\\"WGS_1984\\\",6378137.0,298.257223563]],PRIMEM[\\\"Greenwich\\\",0.0],UNIT[\\\"Degree\\\",0.0174532925199433]]"
>> ;
>> wind_speed:coordinates = "lon lat" ;
>> wind_speed:height = "10 m" ;
>> wind_speed:missing_value = -9999. ;
>> }
>>
>>
>> --
>>
>>
>> I have other nc files that are very similar, and they aggregate fine.
>> The main difference is, the files that aggregate correctly have a ‘time’
>> dimension, not ‘day’, and they use the ‘noleap’ calendar.
>>
>> The files that do NOT aggregate have ‘day’ as the time dimension and use
>> the ‘gregorian’ calendar.
>>
>> --
>>
>> Im thinking that my aggregation xml is not structured right, maybe I
>> should use JoinNew and declare ‘day’ as a coordinate variable? It seems
>> that JoinExisting would work given that the ‘day’ dimension exists in
>> all files to aggregate.
>>
>> Anyway, I would appreciate any help, and can provide other log
>> information as necessary.
>>
>> Im running the most recent stable version of TDS, on linux/red hat,
>> under tomcat6
>>
>> Thanks!
>>
>> Erich
>
> --
> Ethan Davis UCAR Unidata Program
> edavis@xxxxxxxxxxxxxxxx http://www.unidata.ucar.edu
>
> _______________________________________________
> thredds mailing list
> thredds@xxxxxxxxxxxxxxxx
> For list information or to unsubscribe, visit:
> http://www.unidata.ucar.edu/mailing_lists/