Re: Using addfile for .hdf file on server

From: <brownrig_at_nyahnyahspammersnyahnyah>
Date: Mon Mar 03 2014 - 11:24:56 MST

Hi Liz,

I get the same thing attempting to open via addfile from within NCL.
 Do you know for certain that the host e4ftl01.cr.usgs.gov is an
OpenDap server?

Unfortunately I am unable to duplicate the ncl_filedump part -- if I
manually download the file, it can be read just fine by ncl_filedump
on yellowstone, under both NCL versions 6.1.2 and 6.2.0. What
platform are you running on?

Rick

On Mon, 3 Mar 2014 10:54:51 -0700
  burakows@ucar.edu wrote:
> Hi,
>
> I am trying to use addfile to open a file on a USGS server using the
> following code (from example 4 in the online addfile documentation):
>
>>> url = "http://e4ftl01.cr.usgs.gov/MOTA/MCD43A3.005/2013.03.06/"
>
>>> fn = "MCD43A3.A2013065.h12v04.005.2013082100754.hdf"
>
>>> a = addfile ( url + fn , "r")
>
> However, I get an error:
>
> syntax error, unexpected WORD_WORD, expecting SCAN_ATTR or
>SCAN_DATASET or
> SCAN_ERROR
> context: <!DOCTYPE^ HTML PUBLIC "-//IETF//DTD HTML
> 2.0//EN"><html><head><title>404 Not
>Found</title></head><body><h1>Not
>Found</h1><p>The requested URL
> /MOTA/MCD43A3.005/2013.03.06/MCD43A3.A2013065.h12v04.005.2013082100754.hdf.dds
> was not found on this server.</p></body></html>
> fatal:NetCDF: Malformed or inaccessible DAP DDS
> fatal:Could not open
> (http://e4ftl01.cr.usgs.gov/MOTA/MCD43A3.005/2013.03.06/MCD43A3.A2013065.h12v04.005.2013082100754.hdf)
>
> I thought hdf was a supported file format. I'm not sure why I am
>getting
> this error. I know the file exists because I can access it directly
>from
> the site. However, I will need to 100's of files from the online
>archive.
>
> I can pull the file using wget, but ncl_filedump also results in an
>error,
> so I think it has something to do with the file format.
>
>>>ncl_filedump MCD43A3.A2013065.h12v04.005.2013082100754.hdf
>
> fatal:syntax error: line 7 before or near MCD43A3
> ncl_filedump MCD43A3
> -------------------^
>
> Similarly, using ncl_convert2nc results in an error:
>
>>> ncl_convert2nc MCD43A3.A2013065.h12v04.005.2013082100754.hdf
>
> fatal:syntax error: line 3 before or near MCD43A3
> ncl_convert2nc MCD43A3
> ---------------------^
>
> fatal:error in statement
>>>I am using ncl/6.1.2.
>
> Thanks,
>
> Liz.
>
>
>
>
>
> _______________________________________________
> ncl-talk mailing list
> List instructions, subscriber options, unsubscribe:
> http://mailman.ucar.edu/mailman/listinfo/ncl-talk

_______________________________________________
ncl-talk mailing list
List instructions, subscriber options, unsubscribe:
http://mailman.ucar.edu/mailman/listinfo/ncl-talk
Received on Mon Mar 3 11:25:14 2014

This archive was generated by hypermail 2.1.8 : Mon Mar 03 2014 - 14:26:18 MST