On 1/7/10 2:03 AM, Claus wrote: > > On 2010-01-06, at 8:01 PM, Alexander Hansen wrote: > >> -----BEGIN PGP SIGNED MESSAGE----- >> Hash: SHA1 >> >> On 1/6/10 1:46 PM, Claus wrote: >>> >>> On 2010-01-06, at 7:21 PM, Alexander Hansen wrote: >>> >>> On 1/6/10 1:09 PM, Claus wrote: >>>>>> Thanks Robert and Daniel for your responses. >>>>>> I did >>>>>> >>>>>> fink install scipy-py26 >>>>>> >>>>>> it worked and was successful! >>>>>> >>>>>> Now, >>>>>> >>>>>> /sw/lib/python2.6/site-packages >>>>>> >>>>>> is the only place on my computer, as far as spotlight can tell >>>>>> me, where >>>>>> both numpy and scipy reside. >>>>>> When I invoke python on the terminal, and >>>>>> >>>>>> import numpy >>>>>> >>>>>> it works, >>>>>> >>>>>> import scipy >>>>>> >>>>>> results in >>>>>> >>>>>> ImportError: No module named scipy >>>>>> >>>>>> >>>>>> Doing >>>>>> >>>>>> echo $PATH >>>>>> >>>>>> results in >>>>>> >>>>>> >>>>>> /sw/bin:/sw/sbin:/usr/bin:/bin:/usr/sbin:/sbin:/usr/local/bin:/usr/texbin:/usr/X11/bin:/usr/X11R6/bin >>>>>> >>>>>> >>>>>> How can import numpy work, if /sw/lib/python2.6/site-packages is >>>>>> not in >>>>>> the path. But if import numpy works, how come import scipy does >>>>>> not work... >>>>>> ... and what do I need to change? >>>>>> >>>>>> Thanks again, >>>>>> Claus >>>>>> >>>>>> >>>>>> >>> >>> Spotlight's not that useful for searching the system area. >>> >>> What command are you using when you "run python"? And if that's just >>> 'python', then what do you get from 'which python'? >>> >>> If you're not using /sw/bin/python2.6, then whatever interpreter you're >>> running doesn't know about scipy, and you may be importing an arbitrary >>> non-Fink numpy from elsewhere on your system. >>> >> >>> I am using just 'python' in terminal and 'which python' returns >>> '/usr/bin/python' >>> so, >>> - how would I search for other versions/installations of numpy? >> >> It's quite likely that the numpy that you're seeing is that provided >> with the system's Python. You can check by running >> >> locate numpy >> >> If what you see is in /System/Library/Frameworks/Python.framework, then >> that's fine. There may be a way to tell where it comes from after >> importing it from within the Python environment, but I'm not a Python >> person so I don't happen to know how to do that. >> >>> - how could I tell the python I'm using to use /sw/bin/python as >>> well as the site-packages of fink? >> >> Either use >> >> /sw/bin/python2.6 >> >> as your command, or install the fink 'python' package, which creates a >> /sw/bin/python that points to /sw/bin/python2.6. In either case, that >> will automatically pick the right site-packages for you. >> > > > Hm, > > fink list-i > returns > > i python26 1:2.6.2-2 Interpreted, object-oriented > language > > i python26-shlibs 1:2.6.2-2 Interpreted, object-oriented > language > > this means that python is installed via fink, right? > > There is a /sw/bin/python2.6 > However, /sw/bin/python returns 'No such file or directory'. > > If I execute /sw/bin/python2.6 I can successfully import numpy as > well as import scipy > > Now, this might be all good. For some reason I was fixed to the idea > that if I type 'python' in terminal, the version of python should > execute that also has scipy and numpy (I was not aware that OS 10.6. > comes with numpy). > If i keep the current settings of the fink installation and call the > fink-python with /sw/bin/python2.6 is that a way to keep the two > installations of python (the osx one and the fink one) separate? It > would be nice if /sw/bin/python would work... > > This might be a little OT, but does somebody here know how to tell > TextMate and its python package to use /sw/bin/python2.6? > > Thanks, > Claus > I told you already to install "python", by exactly that name.
------------------------------------------------------------------------------ This SF.Net email is sponsored by the Verizon Developer Community Take advantage of Verizon's best-in-class app development support A streamlined, 14 day to market process makes app distribution fast and easy Join now and get one step closer to millions of Verizon customers http://p.sf.net/sfu/verizon-dev2dev
_______________________________________________ Fink-beginners mailing list [email protected] http://news.gmane.org/gmane.os.apple.fink.beginners
