The script python already has the command<div><br><div>from osgeo import ogr</div><div><br></div><div>When I call it from the OSGeo4W shell, I get this message error:</div><div><br></div><div><p class="MsoNormal">E:\test_shp>pylas.py -i 32-2-502-114-23.las -o
32-output.shp > log.txt</p>
<p class="MsoNormal">Traceback (most recent call last):</p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>File
"E:\test_shp\pylas.py", line 43, in <module></p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>from osgeo import
ogr</p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>File
"C:\OSGeo4W\apps\gdal-dev\pymod\osgeo\__init__.py", line 21, in
<module></p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>_gdal =
swig_import_helper()</p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>File
"C:\OSGeo4W\apps\gdal-dev\pymod\osgeo\__init__.py", line 17, in
swig_impo</p>
<p class="MsoNormal">rt_helper</p>
<p class="MsoNormal"><span style="mso-spacerun:yes"> </span>_mod =
imp.load_module('_gdal', fp, pathname, description)</p>
<p class="MsoNormal">ImportError: DLL load failed: The operating system cannot
run %1.</p><div><br></div><div>What I am doing wrong?</div><div><br><br><div class="gmail_quote">2010/9/28 David Fawcett <span dir="ltr"><<a href="mailto:david.fawcett@gmail.com">david.fawcett@gmail.com</a>></span><br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Try:<br>
<br>
from osgeo import ogr<br>
<br>
David<br>
<div><div></div><div class="h5"><br>
<br>
<br>
On Sep 28, 2010, at 6:57 AM, Cecília Cerdeira <<a href="mailto:ccerdeira@gmail.com">ccerdeira@gmail.com</a>> wrote:<br>
<br>
> Hi,<br>
><br>
> I am trying to run a python script in OSGeo4W shell that needs the python bindings to OGR.<br>
><br>
> Anyone knows how to set this?<br>
><br>
> Thanks<br>
><br>
> Cecília<br>
</div></div>> _______________________________________________<br>
> FWTools mailing list<br>
> <a href="mailto:FWTools@lists.maptools.org">FWTools@lists.maptools.org</a><br>
> <a href="http://lists.maptools.org/mailman/listinfo/fwtools" target="_blank">http://lists.maptools.org/mailman/listinfo/fwtools</a><br>
> <a href="http://fwtools.maptools.org/" target="_blank">http://fwtools.maptools.org/</a><br>
</blockquote></div><br></div></div></div>