Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > comp.lang.python > #12364 > unrolled thread

Some problems refer to install 3rd party package of Python on mac OS 10.6.8

Started byGee Chen <cnchenji@gmail.com>
First post2011-08-28 17:35 -0700
Last post2011-08-29 08:32 -0700
Articles 3 — 2 participants

Back to article view | Back to comp.lang.python


Contents

  Some problems refer to install 3rd party package of Python on mac OS 10.6.8 Gee Chen <cnchenji@gmail.com> - 2011-08-28 17:35 -0700
    Re: Some problems refer to install 3rd party package of Python on mac OS 10.6.8 Chris Rebert <clp2@rebertia.com> - 2011-08-28 18:14 -0700
      Re: Some problems refer to install 3rd party package of Python on mac OS 10.6.8 Gee Chen <cnchenji@gmail.com> - 2011-08-29 08:32 -0700

#12364 — Some problems refer to install 3rd party package of Python on mac OS 10.6.8

FromGee Chen <cnchenji@gmail.com>
Date2011-08-28 17:35 -0700
SubjectSome problems refer to install 3rd party package of Python on mac OS 10.6.8
Message-ID<07970388-04d2-463f-b550-ad233b2ad404@r40g2000prf.googlegroups.com>
----------------------------------
the Python environment on my mac is:

Python 2.6.4 (r264:75706, Aug 28 2011, 22:29:24)
[GCC 4.2.1 (Apple Inc. build 5664)] on darwin

i686-apple-darwin10-gcc-4.2.1 (GCC) 4.2.1 (Apple Inc. build 5664)
Copyright (C) 2007 Free Software Foundation, Inc.
---------------------------------------------------------------------


I found the download adresses of scipy and numpy from official website
'www.scipy.org'. After downloading 2 latest released dmg files, i
directly installed them with double-click the dmg files.

Then, i opened Python interpreter in Terminal, and tested whether
scipy & numpy work. The result is disappointed!

when i inputed ' import scipy' & 'import numpy', the output is :


>>> import scipy
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/scipy/_init_.py", line 78, in <module>
from numpy import show_config as show_numpy_config
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/_init_.py", line 137, in <module>
import add_newdocs
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/add_newdocs.py", line 9, in <module>
from numpy.lib import add_newdoc
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/lib/_init_.py", line 4, in <module>
from type_check import *
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/lib/type_check.py", line 8, in <module>
import numpy.core.numeric as _nx
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/core/_init_.py", line 5, in <module>
import multiarray
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/
lib/python2.6/site-packages/numpy/core/multiarray.so, 2): no suitable
image found. Did find:
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/numpy/core/multiarray.so: no matching architecture in
universal wrapper
>>>
>>> import numpy
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/_init_.py", line 137, in <module>
import add_newdocs
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/add_newdocs.py", line 9, in <module>
from numpy.lib import add_newdoc
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/lib/_init_.py", line 4, in <module>
from type_check import *
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/lib/type_check.py", line 8, in <module>
import numpy.core.numeric as _nx
File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
site-packages/numpy/core/_init_.py", line 5, in <module>
import multiarray
ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/
lib/python2.6/site-packages/numpy/core/multiarray.so, 2): no suitable
image found. Did find:
/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
packages/numpy/core/multiarray.so: no matching architecture in
universal wrapper
>>>


Is there anybody can tell me where the error exists?

[toc] | [next] | [standalone]


#12366

FromChris Rebert <clp2@rebertia.com>
Date2011-08-28 18:14 -0700
Message-ID<mailman.524.1314580470.27778.python-list@python.org>
In reply to#12364
On Sun, Aug 28, 2011 at 5:35 PM, Gee Chen <cnchenji@gmail.com> wrote:
> ----------------------------------
> the Python environment on my mac is:
>
> Python 2.6.4 (r264:75706, Aug 28 2011, 22:29:24)
> [GCC 4.2.1 (Apple Inc. build 5664)] on darwin

For future reference, when on OS X, it's very helpful to include how
you installed your Python, and whether it's 32-bit or 64-bit.

<snip>
> I found the download adresses of scipy and numpy from official website
> 'www.scipy.org'. After downloading 2 latest released dmg files, i
> directly installed them with double-click the dmg files.
>
> Then, i opened Python interpreter in Terminal, and tested whether
> scipy & numpy work. The result is disappointed!
>
> when i inputed ' import scipy' & 'import numpy', the output is :
>
>
>>>> import scipy
> Traceback (most recent call last):
<snip>
> File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
> site-packages/numpy/core/_init_.py", line 5, in <module>
> import multiarray
> ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/
> lib/python2.6/site-packages/numpy/core/multiarray.so, 2): no suitable
> image found. Did find:
> /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
> packages/numpy/core/multiarray.so: no matching architecture in
> universal wrapper
<snip>
> Is there anybody can tell me where the error exists?

I believe you've installed 32-bit libraries for a 64-bit Python (or
possibly vice-versa). It appears that NumPy & SciPy official releases
are 32-bit-only. So, you can either use the alternate, unofficial
64-bit releases of those packages, or install a 32-bit Python (via
Fink, MacPorts, a Python.org installer, etc.). A third option is to
install the Enthought Python Distribution
(http://www.enthought.com/products/epd.php ) or similar, which bundles
Python together with SciPy, NumPy, and other libraries in a single
install.

Cheers,
Chris
--
http://rebertia.com

[toc] | [prev] | [next] | [standalone]


#12405

FromGee Chen <cnchenji@gmail.com>
Date2011-08-29 08:32 -0700
Message-ID<7cfdd69e-fbea-47e7-8a88-8a977c4736df@b34g2000prf.googlegroups.com>
In reply to#12366
On Aug 29, 9:14 am, Chris Rebert <c...@rebertia.com> wrote:
> On Sun, Aug 28, 2011 at 5:35 PM, Gee Chen <cnche...@gmail.com> wrote:
> > ----------------------------------
> > the Python environment on my mac is:
>
> > Python 2.6.4 (r264:75706, Aug 28 2011, 22:29:24)
> > [GCC 4.2.1 (Apple Inc. build 5664)] on darwin
>
> For future reference, when on OS X, it's very helpful to include how
> you installed your Python, and whether it's 32-bit or 64-bit.
>
> <snip>
>
>
>
>
>
>
>
>
>
> > I found the download adresses of scipy and numpy from official website
> > 'www.scipy.org'. After downloading 2 latest released dmg files, i
> > directly installed them with double-click the dmg files.
>
> > Then, i opened Python interpreter in Terminal, and tested whether
> > scipy & numpy work. The result is disappointed!
>
> > when i inputed ' import scipy' & 'import numpy', the output is :
>
> >>>> import scipy
> > Traceback (most recent call last):
> <snip>
> > File "/Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/
> > site-packages/numpy/core/_init_.py", line 5, in <module>
> > import multiarray
> > ImportError: dlopen(/Library/Frameworks/Python.framework/Versions/2.6/
> > lib/python2.6/site-packages/numpy/core/multiarray.so, 2): no suitable
> > image found. Did find:
> > /Library/Frameworks/Python.framework/Versions/2.6/lib/python2.6/site-
> > packages/numpy/core/multiarray.so: no matching architecture in
> > universal wrapper
> <snip>
> > Is there anybody can tell me where the error exists?
>
> I believe you've installed 32-bit libraries for a 64-bit Python (or
> possibly vice-versa). It appears that NumPy & SciPy official releases
> are 32-bit-only. So, you can either use the alternate, unofficial
> 64-bit releases of those packages, or install a 32-bit Python (via
> Fink, MacPorts, a Python.org installer, etc.). A third option is to
> install the Enthought Python Distribution
> (http://www.enthought.com/products/epd.php) or similar, which bundles
> Python together with SciPy, NumPy, and other libraries in a single
> install.
>
> Cheers,
> Chris
> --http://rebertia.com

thanks for your help.   the problem was solved..

[toc] | [prev] | [standalone]


Back to top | Article view | comp.lang.python


csiph-web