Re: newbie question: ImportError: No module named Numeric

H

Harry George

rmachne said:
Hi there,

Sorry, if there is a newbie list or this question is answered in tutorials
- I tried but without succes :-( - here is my question:
Using linux,
I need the 'Numerical Python' package, and I installed it on my local
computer (not with the other packages in /usr/local/...) using

~/programs/Numeric-23.0>python setup.py install --home=/scratch/raim

but now the Numeric package / module can't be found:

~/programs/Numeric-23.0/Test> python test.py
Traceback (most recent call last):
File "test.py", line 2, in ?
import Numeric
ImportError: No module named Numeric
Exit 1

I couldn't find out which path variable to change or add. Can anyone
help?
(Test.py works fine when called from within the lib folder with
Numeric.py)

best
rainer

You can set an env variable:
export PYTHONPATH=/scratch/raim
(or whatever your shell syntax is)

This adds the path to your normal defaults.

You can also do this 'export' in a shell script which runs the
application. This is useful if you have several variants of a given
module, and want to use one or the other in a specific case.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Members online

No members online now.

Forum statistics

Threads
473,744
Messages
2,569,484
Members
44,903
Latest member
orderPeak8CBDGummies

Latest Threads

Top