Simone,

I have tried with 2.7.0 and 2.7.1. I was able to check out and run with the 
latest geotools source code and reproduce the problem there as well. In looking 
at their source code they will only accept "second" or "seconds" and not "secs" 
so that was the problem. Thanks for getting back to me. I'll talk to the person 
who produces our NETCDF to see if they have any control over the format of the 
time in our file. 


Steve Ferguson 

-----Original Message-----
From: simbo...@gmail.com [mailto:simbo...@gmail.com] On Behalf Of Simone 
Giannecchini
Sent: Thursday, June 11, 2015 11:23 AM
To: Ferguson, Steve -FS
Cc: geoserver-users@lists.sourceforge.net
Subject: Re: [Geoserver-users] Unable to consume NETCDF data : Couldn't 
determine time units from unit string 'secs'

Dear Steve,
I'll ping one of the devs about this problem, to me it looks like we are unable 
to recognize the units for the time dimension as "secs"
does not look CF compliant to me.

Just for the records, which version of GeoServer are you using?

Regards,
Simone Giannecchini
==
GeoServer Professional Services from the experts!
Visit http://goo.gl/it488V for more information.
==
Ing. Simone Giannecchini
@simogeo
Founder/Director

GeoSolutions S.A.S.
Via Poggio alle Viti 1187
55054  Massarosa (LU)
Italy
phone: +39 0584 962313
fax:     +39 0584 1660272
mob:   +39  333 8128928

http://www.geo-solutions.it
http://twitter.com/geosolutions_it

-------------------------------------------------------
AVVERTENZE AI SENSI DEL D.Lgs. 196/2003
Le informazioni contenute in questo messaggio di posta elettronica e/o nel/i 
file/s allegato/i sono da considerarsi strettamente riservate.
Il loro utilizzo è consentito esclusivamente al destinatario del messaggio, per 
le finalità indicate nel messaggio stesso. Qualora riceviate questo messaggio 
senza esserne il destinatario, Vi preghiamo cortesemente di darcene notizia via 
e-mail e di procedere alla distruzione del messaggio stesso, cancellandolo dal 
Vostro sistema.
Conservare il messaggio stesso, divulgarlo anche in parte, distribuirlo ad 
altri soggetti, copiarlo, od utilizzarlo per finalità diverse, costituisce 
comportamento contrario ai principi dettati dal D.Lgs. 196/2003.

The information in this message and/or attachments, is intended solely for the 
attention and use of the named addressee(s) and may be confidential or 
proprietary in nature or covered by the provisions of privacy act (Legislative 
Decree June, 30 2003, no.196 - Italy's New Data Protection Code).Any use not in 
accord with its purpose, any disclosure, reproduction, copying, distribution, 
or either dissemination, either whole or partial, is strictly forbidden except 
previous formal approval of the named addressee(s). If you are not the intended 
recipient, please contact immediately the sender by telephone, fax or e-mail 
and delete the information in this message that has been received in error. The 
sender does not give any warranty or accept liability as the content, accuracy 
or completeness of sent messages and accepts no responsibility  for changes 
made after they were sent or for other risks which arise as a result of e-mail 
transmission, viruses, etc.


On Mon, Jun 1, 2015 at 9:41 PM, Ferguson, Steve -FS <sfergu...@fs.fed.us> wrote:
> I am attempting to consume this NETCDF file 
> http://www.mtnweather.info/download/wrfout_d01_2015-05-14_15:00:00.gz 
> (I unzip it before attempting to create a store). Upon doing so I 
> receive an exception shown below (somewhat abbreviated). My question 
> is, is there any way to overcome this exception allowing creation of a store 
> from this file?
> Maybe through configuration, or hints?
>
>
>
> 01 Jun 10:42:23 WARN [org.geotools.coverage.io.netcdf.NetCDFFormat] - 
> Unable to connect
>
> org.geotools.data.DataSourceException: Unable to connect
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFReader.<init>(NetCDFReader.java:
> 158)
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFFormat.getReader(NetCDFFormat.ja
> va:95)
>
>         at
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.
> java:1436)
>
>         at
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.
> java:1364)
>
>         at
> org.geoserver.catalog.impl.CoverageStoreInfoImpl.getGridCoverageReader
> (CoverageStoreInfoImpl.java:59)
>
> …
>
>
>
> Caused by: org.geotools.data.DataSourceException:
> java.lang.IllegalArgumentException: Couldn't determine time units from 
> unit string 'secs'
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFAccess.<init>(NetCDFAccess.java:
> 131)
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFDriver.connect(NetCDFDriver.java
> :92)
>
>         at
> org.geotools.coverage.io.impl.DefaultFileDriver.process(DefaultFileDri
> ver.java:216)
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFReader.<init>(NetCDFReader.java:
> 156)
>
>         ... 118 more
>
> Caused by: java.lang.RuntimeException: java.lang.IllegalArgumentException:
> Couldn't determine time units from unit string 'secs'
>
>         at
> org.geotools.imageio.netcdf.NetCDFImageReader.setInput(NetCDFImageRead
> er.java:266)
>
>         at javax.imageio.ImageReader.setInput(ImageReader.java:380)
>
>         at
> org.geotools.coverage.io.netcdf.NetCDFAccess.<init>(NetCDFAccess.java:
> 120)
>
>         ... 121 more
>
> Caused by: java.lang.IllegalArgumentException: Couldn't determine time 
> units from unit string 'secs'
>
>         at
> org.geotools.imageio.netcdf.cv.TimeCoordinateVariable$TimeBuilder.<ini
> t>(TimeCoordinateVariable.java:79)
>
>         at
> org.geotools.imageio.netcdf.cv.TimeCoordinateVariable.<init>(TimeCoord
> inateVariable.java:131)
>
>         at
> org.geotools.imageio.netcdf.cv.CoordinateVariable.create(CoordinateVar
> iable.java:117)
>
>         at
> org.geotools.imageio.netcdf.NetCDFImageReader.extractCoordinatesVariab
> le(NetCDFImageReader.java:444)
>
>         at
> org.geotools.imageio.netcdf.NetCDFImageReader.init(NetCDFImageReader.j
> ava:510)
>
>         at
> org.geotools.imageio.netcdf.NetCDFImageReader.setInput(NetCDFImageRead
> er.java:264)
>
>         ... 123 more
>
> 01 Jun 10:42:23 INFO [org.geoserver.web] - Getting list of coverages 
> for saved store 
> file:netcdf/mtnweather/wrfout_d01_2015-05-14_15:00:00.nc
>
> java.lang.RuntimeException: Could not list layers for this store, an 
> error occurred retrieving them: Failed to create reader from 
> file:netcdf/mtnweather/wrfout_d01_2015-05-14_15:00:00.nc and hints 
> null
>
>         at
> org.geoserver.web.data.layer.NewLayerPageProvider.getItemsInternal(New
> LayerPageProvider.java:151)
>
>         at
> org.geoserver.web.data.layer.NewLayerPageProvider.getItems(NewLayerPag
> eProvider.java:59)
>
>         at
> org.geoserver.web.wicket.GeoServerDataProvider.fullSize(GeoServerDataP
> rovider.java:242)
>
> ….
>
> Caused by: java.io.IOException: Failed to create reader from 
> file:netcdf/mtnweather/wrfout_d01_2015-05-14_15:00:00.nc and hints 
> null
>
>         at
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.
> java:1438)
>
>         at
> org.geoserver.catalog.ResourcePool.getGridCoverageReader(ResourcePool.
> java:1364)
>
>         at
> org.geoserver.catalog.impl.CoverageStoreInfoImpl.getGridCoverageReader
> (CoverageStoreInfoImpl.java:59)
>
>         at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
>
>         at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.j
> ava:57)
>
>         at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccess
> orImpl.java:43)
>
>         at java.lang.reflect.Method.invoke(Method.java:606)
>
>         at
> org.geoserver.catalog.impl.ModificationProxy.invoke(ModificationProxy.
> java:146)
>
>         at com.sun.proxy.$Proxy14.getGridCoverageReader(Unknown 
> Source)
>
>         at
> org.geoserver.web.data.layer.NewLayerPageProvider.getItemsInternal(New
> LayerPageProvider.java:90)
>
>
>
>
>
> Thanks!
>
> Steve Ferguson
>
>
>
>
> ----------------------------------------------------------------------
> --------
>
> _______________________________________________
> Geoserver-users mailing list
> Geoserver-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/geoserver-users
>
------------------------------------------------------------------------------
_______________________________________________
Geoserver-users mailing list
Geoserver-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/geoserver-users

Reply via email to