|
From: K. -M. A. <kmi...@go...> - 2010-04-13 15:18:49
|
Dear all, maybe this should go to the Enthought list, but as the failure is directly related to the pylab switch of ipython, I thought I try it here first: On OSX I have trouble with using the pylab switch for ipython after I copied the gdal.pth into the Enthought site-packages folder (to be able to use my KyngChaos GDAL Frameworks inside the Enthought Python). The gdal.pth does the following to the sys.path: import sys; sys.path.insert(0,'/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages') and in that folder there is: -rw-rw-r-- 1 root admin 128B 8 Feb 20:52 gdal.py -rw-r--r-- 1 root admin 274B 3 Mar 23:20 gdal.pyc -rw-rw-r-- 1 root admin 143B 8 Feb 20:52 gdalconst.py -rw-r--r-- 1 root admin 304B 3 Mar 23:20 gdalconst.pyc -rw-rw-r-- 1 root admin 147B 8 Feb 20:52 gdalnumeric.py -rw-r--r-- 1 root admin 309B 3 Mar 23:20 gdalnumeric.pyc drwxrwxr-x 42 root admin 1.4K 3 Mar 23:20 numpy -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 ogr.py -rw-r--r-- 1 root admin 286B 3 Mar 23:20 ogr.pyc drwxrwxr-x 21 root admin 714B 3 Mar 23:20 osgeo -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 osr.py -rw-r--r-- 1 root admin 286B 3 Mar 23:20 osr.pyc Maybe the double import of a potentially different numpy compared to the Enthought numpy creates the Bus Error? If so, how can I avoid it? For a complete picture, here is my sys.path: ['', '/Library/Frameworks/Python.framework/Versions/6.1/bin', '/Users/aye/Library/Python/2.6/site-packages/ipython-0.10-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/pydot-1.0.2-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/pyparsing-1.5.2-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/simplejson-2.0.9-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/python_twitter-0.6-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/PIL-1.1.7-py2.6-macosx-10.6-universal.egg', '/Users/aye/Library/Python/2.6/site-packages/Sphinx-0.6.3-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/docutils-0.6-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/Jinja2-2.2.1-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/Pygments-1.1.1-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/spyder-1.0.3-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/scikits.image-0.2.2-py2.6-macosx-10.5-i386.egg', '/Users/aye/Library/Python/2.6/site-packages/PyXML-0.8.4-py2.6-macosx-10.6-universal.egg', '/Users/aye/Library/Python/2.6/site-packages/pyfo-0.6-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/Amara-2.0a4-py2.6-macosx-10.6-universal.egg', '/Users/aye/Library/Python/2.6/site-packages/setuptools-0.6c11-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/distribute-0.6.10-py2.6.egg', '/Users/aye/Library/Python/2.6/site-packages/pip-0.6.3-py2.6.egg', '/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python26.zip', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/plat-darwin', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/plat-mac', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/plat-mac/lib-scriptpackages', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/lib-tk', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/lib-old', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/lib-dynload', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/site-packages/PIL', '/Library/Frameworks/Python.framework/Versions/6.1/lib/python2.6/site-packages/setuptools-0.6c11-py2.6.egg-info', '/Users/aye/Library/Python/2.6/site-packages', '/Users/aye/Library/Python/2.6/site-packages/PIL', '/Users/aye/Library/Python/2.6/site-packages/ipython-0.10-py2.6.egg/IPython/Extensions', u'/Users/aye/.ipython'] I am grateful for any hint how to make the -pylab switch working again in this scenario. Best regards, Michael |
|
From: Robert K. <rob...@gm...> - 2010-04-13 15:31:37
|
On 2010-04-13 10:18 AM, K. -Michael Aye wrote: > Dear all, > > maybe this should go to the Enthought list, but as the failure is directly related to the pylab switch of ipython, I thought I try it here first: > > On OSX I have trouble with using the pylab switch for ipython after I copied the gdal.pth into the Enthought site-packages folder (to be able to use my KyngChaos GDAL Frameworks inside the Enthought Python). > > The gdal.pth does the following to the sys.path: > import sys; sys.path.insert(0,'/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages') > > and in that folder there is: > > -rw-rw-r-- 1 root admin 128B 8 Feb 20:52 gdal.py > -rw-r--r-- 1 root admin 274B 3 Mar 23:20 gdal.pyc > -rw-rw-r-- 1 root admin 143B 8 Feb 20:52 gdalconst.py > -rw-r--r-- 1 root admin 304B 3 Mar 23:20 gdalconst.pyc > -rw-rw-r-- 1 root admin 147B 8 Feb 20:52 gdalnumeric.py > -rw-r--r-- 1 root admin 309B 3 Mar 23:20 gdalnumeric.pyc > drwxrwxr-x 42 root admin 1.4K 3 Mar 23:20 numpy > -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 ogr.py > -rw-r--r-- 1 root admin 286B 3 Mar 23:20 ogr.pyc > drwxrwxr-x 21 root admin 714B 3 Mar 23:20 osgeo > -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 osr.py > -rw-r--r-- 1 root admin 286B 3 Mar 23:20 osr.pyc > > Maybe the double import of a potentially different numpy compared to the Enthought numpy creates the Bus Error? Not so much a double import. Only one version ever gets imported, but the GDAL Python bindings expect its version and matplotlib expects another version. > If so, how can I avoid it? You would have to rebuild the GDAL Python bindings against Enthought's numpy. -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco |
|
From: K. -M. A. <kmi...@go...> - 2010-04-13 16:13:50
|
> > On 2010-04-13 10:18 AM, K. -Michael Aye wrote: >> Dear all, >> >> maybe this should go to the Enthought list, but as the failure is directly related to the pylab switch of ipython, I thought I try it here first: >> >> On OSX I have trouble with using the pylab switch for ipython after I copied the gdal.pth into the Enthought site-packages folder (to be able to use my KyngChaos GDAL Frameworks inside the Enthought Python). >> >> The gdal.pth does the following to the sys.path: >> import sys; sys.path.insert(0,'/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages') >> >> and in that folder there is: >> >> -rw-rw-r-- 1 root admin 128B 8 Feb 20:52 gdal.py >> -rw-r--r-- 1 root admin 274B 3 Mar 23:20 gdal.pyc >> -rw-rw-r-- 1 root admin 143B 8 Feb 20:52 gdalconst.py >> -rw-r--r-- 1 root admin 304B 3 Mar 23:20 gdalconst.pyc >> -rw-rw-r-- 1 root admin 147B 8 Feb 20:52 gdalnumeric.py >> -rw-r--r-- 1 root admin 309B 3 Mar 23:20 gdalnumeric.pyc >> drwxrwxr-x 42 root admin 1.4K 3 Mar 23:20 numpy >> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 ogr.py >> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 ogr.pyc >> drwxrwxr-x 21 root admin 714B 3 Mar 23:20 osgeo >> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 osr.py >> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 osr.pyc >> >> Maybe the double import of a potentially different numpy compared to the Enthought numpy creates the Bus Error? > > Not so much a double import. Only one version ever gets imported, but the GDAL > Python bindings expect its version and matplotlib expects another version. > >> If so, how can I avoid it? > > You would have to rebuild the GDAL Python bindings against Enthought's numpy. > But why does everything work fine, when I start an Enthought ipython withOUT the -pylab switch? Importing 'from osgeo import gdal' and using it works fine in this case (Tried ReadAsArray from a gdal dataset and imshow'ed it without problems, apart from that I had to call show() because of the lack of the -pylab switch, but other than that, fine). PS.: Sorry for the mail-list noob question, but how can I nicely reply to your answer like you replied to my question, with 'Robert Kern wrote' and so on? There's no reply possible on sourceforge and the digest contains obviously many emails, so how do you do this? ;) |
|
From: Robert K. <rob...@gm...> - 2010-04-13 16:53:49
|
On 2010-04-13 11:13 AM, K. -Michael Aye wrote: >> >> On 2010-04-13 10:18 AM, K. -Michael Aye wrote: >>> Dear all, >>> >>> maybe this should go to the Enthought list, but as the failure is directly related to the pylab switch of ipython, I thought I try it here first: >>> >>> On OSX I have trouble with using the pylab switch for ipython after I copied the gdal.pth into the Enthought site-packages folder (to be able to use my KyngChaos GDAL Frameworks inside the Enthought Python). >>> >>> The gdal.pth does the following to the sys.path: >>> import sys; sys.path.insert(0,'/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages') >>> >>> and in that folder there is: >>> >>> -rw-rw-r-- 1 root admin 128B 8 Feb 20:52 gdal.py >>> -rw-r--r-- 1 root admin 274B 3 Mar 23:20 gdal.pyc >>> -rw-rw-r-- 1 root admin 143B 8 Feb 20:52 gdalconst.py >>> -rw-r--r-- 1 root admin 304B 3 Mar 23:20 gdalconst.pyc >>> -rw-rw-r-- 1 root admin 147B 8 Feb 20:52 gdalnumeric.py >>> -rw-r--r-- 1 root admin 309B 3 Mar 23:20 gdalnumeric.pyc >>> drwxrwxr-x 42 root admin 1.4K 3 Mar 23:20 numpy >>> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 ogr.py >>> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 ogr.pyc >>> drwxrwxr-x 21 root admin 714B 3 Mar 23:20 osgeo >>> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 osr.py >>> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 osr.pyc >>> >>> Maybe the double import of a potentially different numpy compared to the Enthought numpy creates the Bus Error? >> >> Not so much a double import. Only one version ever gets imported, but the GDAL >> Python bindings expect its version and matplotlib expects another version. >> >>> If so, how can I avoid it? >> >> You would have to rebuild the GDAL Python bindings against Enthought's numpy. >> > But why does everything work fine, when I start an Enthought ipython withOUT the -pylab switch? > Importing 'from osgeo import gdal' and using it works fine in this case (Tried ReadAsArray from a gdal dataset and imshow'ed it without problems, apart from that I had to call show() because of the lack of the -pylab switch, but other than that, fine). Hmm, don't know. Getting a gdb traceback for the bus error would help identify the problem. > PS.: Sorry for the mail-list noob question, but how can I nicely reply to your answer like you replied to my question, with 'Robert Kern wrote' and so on? There's no reply possible on sourceforge and the digest contains obviously many emails, so how do you do this? ;) I use an NNTP newsreader to read this list via GMane, but you can just change your subscription to not use the digest. Scroll down to the bottom of this page to log in and edit your delivery options: https://lists.sourceforge.net/lists/listinfo/matplotlib-users You will get every message in your inbox individually. You should do this if you are going to be replying to messages. Please consider the digest as read-only. -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco |
|
From: K.-Michael A. <kmi...@go...> - 2010-04-13 22:00:19
|
On 2010-04-13 18:13:40 +0200, K. -Michael Aye said: >> >> >> On 2010-04-13 10:18 AM, K. -Michael Aye wrote: >>> Dear all, >>> >>> maybe this should go to the Enthought list, but as the failure is >>> directly related to the pylab switch of ipython, I thought I try it >>> here first: >>> >>> On OSX I have trouble with using the pylab switch for ipython after I >>> copied the gdal.pth into the Enthought site-packages folder (to be able >>> to use my KyngChaos GDAL Frameworks inside the Enthought Python). >>> >>> The gdal.pth does the following to the sys.path: >>> import sys; >>> sys.path.insert(0,'/Library/Frameworks/GDAL.framework/Versions/1.7/Python/site-packages') and >>> >>> in that folder there is: >>> >>> -rw-rw-r-- 1 root admin 128B 8 Feb 20:52 gdal.py >>> -rw-r--r-- 1 root admin 274B 3 Mar 23:20 gdal.pyc >>> -rw-rw-r-- 1 root admin 143B 8 Feb 20:52 gdalconst.py >>> -rw-r--r-- 1 root admin 304B 3 Mar 23:20 gdalconst.pyc >>> -rw-rw-r-- 1 root admin 147B 8 Feb 20:52 gdalnumeric.py >>> -rw-r--r-- 1 root admin 309B 3 Mar 23:20 gdalnumeric.pyc >>> drwxrwxr-x 42 root admin 1.4K 3 Mar 23:20 numpy >>> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 ogr.py >>> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 ogr.pyc >>> drwxrwxr-x 21 root admin 714B 3 Mar 23:20 osgeo >>> -rw-rw-r-- 1 root admin 125B 8 Feb 20:52 osr.py >>> -rw-r--r-- 1 root admin 286B 3 Mar 23:20 osr.pyc >>> >>> Maybe the double import of a potentially different numpy compared to >>> the Enthought numpy creates the Bus Error? >> >> Not so much a double import. Only one version ever gets imported, but the GDAL >> Python bindings expect its version and matplotlib expects another version. >> >>> If so, how can I avoid it? >> >> You would have to rebuild the GDAL Python bindings against Enthought's numpy. >> > But why does everything work fine, when I start an Enthought ipython > withOUT the -pylab switch? > Importing 'from osgeo import gdal' and using it works fine in this case > (Tried ReadAsArray from a gdal dataset and imshow'ed it without > problems, apart from that I had to call show() because of the lack of > the -pylab switch, but other than that, fine). Sorry, seems that I had messed up my config somehow, now GDAL does not work anymore inside the EPD Python. Hmm, have to make some clean tests... > > PS.: Sorry for the mail-list noob question, but how can I nicely reply > to your answer like you replied to my question, with 'Robert Kern > wrote' and so on? There's no reply possible on sourceforge and the > digest contains obviously many emails, so how do you do this? ;) Trying Unison via the GMane NNTP now, but weird that nabble has your last answer already for long time, whereas GMane still does not show it. Does the NNTP pull the mailing lists on a low frequency. Man, I think it's 10 years ago or so since I have used NNTP. Used it a lot in my first net years, 94/95 ;) Thanks for the GMane tip, the nabble reply web interface does not even quote properly, very strange thing, or i do something wrong. |
|
From: Robert K. <rob...@gm...> - 2010-04-13 22:21:06
|
On 2010-04-13 16:55 PM, K.-Michael Aye wrote: > Trying Unison via the GMane NNTP now, but weird that nabble has your > last answer already for long time, whereas GMane still does not show > it. Does the NNTP pull the mailing lists on a low frequency. The latency is variable, but it's been getting pretty bad recently. -- Robert Kern "I have come to believe that the whole world is an enigma, a harmless enigma that is made terrible by our own mad attempt to interpret it as though it had an underlying truth." -- Umberto Eco |