0

I'm working with a code in python. Today I moved from the text editor Kate to Geany because some people recommended me to do this. This morning I was running from Geany without any problem, now I run the same code and get this error:

Traceback (most recent call last):
  File "bmag2.py", line 6, in <module>
      from scipy.optimize import curve_fit
ImportError: No module named scipy.optimize

If I run the file "bmag2.py" from the terminal, everything is ok.

Do you know what could be happening? How can I fix this?

Baum mit Augen
  • 49,044
  • 25
  • 144
  • 182
Vladimir Vargas
  • 1,744
  • 4
  • 24
  • 48
  • Python code isn't compiled, it's interpreted. – Ethan Bierlein May 11 '15 at 22:48
  • Maybe your PATH changed and the library `scipy` is no longer available? – wallyk May 11 '15 at 23:29
  • @wallyk where can I check that? (I didn't do anything manual) – Vladimir Vargas May 11 '15 at 23:30
  • If you are on Linux or Unix, type `which python` (or `which python3` or whatever you use to run python), then look in nearby directories for python-3.2.3/lib (for example) for `scipy.py` or `scipy.pyc` etc. For example, if `which` says `/usr/local/bin/python` look in `/usr/local/python-3`-something. – wallyk May 11 '15 at 23:33
  • You can check this also easy by starting a an interactive python shell e.g. from inside a termnal and import the modul over there – frlan May 12 '15 at 05:09

0 Answers0