[OWSLib-users] (no subject)

Tom Kralidis tomkralidis at hotmail.com
Thu Jan 3 06:01:21 PST 2013


Hi Gianluca: you can get time extents of a layer from the timepositions attribute (i.e. wms['MYDAL2_D_AER_OD'].timepositions), which gives a list of time positions for the layer.  You can then pass a specified timeposition to the GetMap request (i.e. wms.getmap(time=..., )).

Let us know if this works for you.

Date: Tue, 1 Jan 2013 22:52:25 +0100
From: agr.gianluca.massei at gmail.com
To: owslib-users at lists.osgeo.org
Subject: [OWSLib-users] (no subject)

I'm using owslib for study purposes and i'm finding this tool very useful.
I've a question:
in my exercises, I've  handled the WMS service inside the follow piece of code:

from owslib.wms import WebMapService
wms = WebMapService('http://neowms.sci.gsfc.nasa.gov/wms/wms?layers=MYDAL2_D_AER_OD', version='1.1.1')

print wms['MYDAL2_D_AER_OD'].styles
print [op.name for op in wms.operations]
img = wms.getmap(   layers=['MYDAL2_D_AER_OD'],
                     styles=['rgb'],

                     srs='EPSG:4326',
                     bbox=(5, 34, 20, 48),
                     size=(1200, 1200),
                     format='image/jpeg',
                     transparent=False

                     )
out = open('jpl_mosaic_visb.jpg', 'wb')
out.write(img.read())
out.close()

I need to know the acquisition date of MYDAL2_D_AER_OD from the xml file. Can I do that with OWSLib


Thanks in advance

Gianluca



_______________________________________________
OWSLib-users mailing list
OWSLib-users at lists.osgeo.org
http://lists.osgeo.org/cgi-bin/mailman/listinfo/owslib-users 		 	   		  
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/owslib-users/attachments/20130103/2dda5448/attachment.html>


More information about the OWSLib-users mailing list