Jay,

Add the directory of the GDAL installation to the beginning of the system
PATH.
Or alternatively, you can run the GDAL console (to set the environment
correctly) and then start python.exe from this command prompt.

Best regards,

Tamas


2012/8/6 Jay L. <[email protected]>

> All,
>
> I am trying to get the gdal python bindings working with an ArcGIS 10.1
> installation.
>
> I grabbed the core from gisinternals.com/sdk (thanks Tamas!) and
> installed both the 1500 core files (MVS 2008) and the python 2.7 bindings.
> I appended the path as necessary and added the GDAL_DATA directory.  The
> gdal installation appears to be working wonderfully with gdal_translate,
> gdalinfo, and ogr2ogr all functioning as expected.
>
> Any of the python scripts and a straigh import of gdal or ogr are
> failing.  Stack trace below.  Any ideas?  This is a new import error for me.
>
> I attempted the import both from the root directory and the directory gdal
> is in (thinking it still could have been a PATH issue).  I also tried both
> the stable and the nightly builds to see if that was the issue.  Nada.
>
> Thanks,
> Jay
>
> Microsoft Windows [Version 6.1.7601]
> Copyright (c) 2009 Microsoft Corporation.  All rights reserved.
>
> C:\Users\arc_user>python
> Python 2.7.2 (default, Jun 12 2011, 15:08:59) [MSC v.1500 32 bit (Intel)]
> on win
> 32
> Type "help", "copyright", "credits" or "license" for more information.
> >>> import gdal
> Traceback (most recent call last):
>   File "<stdin>", line 1, in <module>
>   File "C:\Python27\ArcGIS10.1\lib\site-packages\gdal.py", line 2, in
> <module>
>     from osgeo.gdal import deprecation_warn
>   File "C:\Python27\ArcGIS10.1\lib\site-packages\osgeo\__init__.py", line
> 21, in
>  <module>
>     _gdal = swig_import_helper()
>   File "C:\Python27\ArcGIS10.1\lib\site-packages\osgeo\__init__.py", line
> 17, in
>  swig_import_helper
>     _mod = imp.load_module('_gdal', fp, pathname, description)
> ImportError: DLL load failed: The device is not ready.
> >>>
>
> _______________________________________________
> gdal-dev mailing list
> [email protected]
> http://lists.osgeo.org/mailman/listinfo/gdal-dev
>
_______________________________________________
gdal-dev mailing list
[email protected]
http://lists.osgeo.org/mailman/listinfo/gdal-dev

Reply via email to