[gdal-dev] osr transformto error
odonnems at yahoo.com
Fri Aug 8 11:30:55 EDT 2008
I am trying to run a simple script and the class transformto does not appear to be working for me. I have used GDAL before for raster analysis, but I have little experience with OSR. Does anyone have any ideas as to why this is not working? I have also run a script I found online called test_transformation_osr.py and it also produces errors when transforming between spatial references. In other words, there seems to be a problem with the installation or something was not installed that I should have installed. I installed gdal1.5.2 binaries on win32 xp OS system.
Thanks for the help.
import osr, ogr
# CREATE WKT STRING OF POINT COORDS
sample = (' 776041.000', ' 3386618.000')
x = sample
y = sample
wkt = 'POINT(%s %s)' % (x, y)
# CREATE PROJECTION OBJECTS
utm16N = osr.SpatialReference ()
wgs84 = osr.SpatialReference()
# CREATE OGR POINT OBJECT, ASSIGN PROJECTION, REPROJECT
point = ogr.CreateGeometryFromWkt(wkt)
-------------- next part --------------
An HTML attachment was scrubbed...
More information about the gdal-dev