Getting Started With SpaceNet Data
Adam Van Etten

Hi Adam, continue to my previous post,

I am trying to solve the similar error, and working with,

source_ds = ogr.Open(vectorSrc)
 source_layer = source_ds.GetLayer()
 srcRas_ds = gdal.Open(rasterSrc)
 cols = srcRas_ds.RasterXSize
 rows = srcRas_ds.RasterYSize
 geoTrans, poly, ulX, ulY, lrX, lrY = gT.getRasterExtent(srcRas_ds)
 transform_WGS84_To_UTM, transform_UTM_To_WGS84, utm_cs \
 = gT.createUTMTransform(poly)
 line = ogr.Geometry(ogr.wkbLineString)
 line.AddPoint(geoTrans[0], geoTrans[3])
 line.AddPoint(geoTrans[0]+geoTrans[1], geoTrans[3])


I got the following error when I execute the above line,


File “C:\ProgramData\Anaconda2\lib\site-packages\osgeo\”, line 7223, in Transform
 return _ogr.Geometry_Transform(self, *args)

TypeError: in method ‘Geometry_Transform’, argument 2 of type ‘OSRCoordinateTransformationShadow *’

I have look at the variable ‘transform_WGS84_To_UTM’ ,it showing proxy of none. <osgeo.osr.CoordinateTransformation; proxy of None >

I am not moving forward with these errors, kindly help me in this regard. I would be greatly appreciated.

Thank you

One clap, two clap, three clap, forty?

By clapping more or less, you can signal to us which stories really stand out.