Dadep
Dadep

Reputation: 2788

PyDSTool do not recognize SciPy version

I have installed PyDSTool package :

pip install PyDSTool==0.90.2

It return :

Requirement already satisfied: PyDSTool==0.90.2 in /usr/local/lib/python2.7/dist-packages/PyDSTool-0.90.2-py2.7.egg
Requirement already satisfied: six in /usr/local/lib/python2.7/dist-packages (from PyDSTool==0.90.2)
Requirement already satisfied: scipy>=0.9 in /usr/local/lib/python2.7/dist-packages (from PyDSTool==0.90.2)    
Requirement already satisfied: numpy>=1.6 in /usr/local/lib/python2.7/dist-packages (from PyDSTool==0.90.2)

It tell me that requirement for scipy is already satisfied but in python:

~$ python
Python 2.7.12 (default, Dec  4 2017, 14:50:18) 
[GCC 5.4.0 20160609] on linux2
Type "help", "copyright", "credits" or "license" for more information.
>>> import PyDSTool
Traceback (most recent call last):
  File "<stdin>", line 1, in <module>
  File "/usr/local/lib/python2.7/dist-packages/PyDSTool-0.90.2-py2.7.egg/PyDSTool/__init__.py", line 76, in <module>
    raise RuntimeError("SciPy v0.5.1 or above is required")
RuntimeError: SciPy v0.5.1 or above is required

I already try the solution from this post and also saw this unanswered post which seems to have a similar problem but using conda instead of pip.

EDIT :

I also try to download package and install with the setup.py associated but I still have the same problem

EDIT 2:

To solve this problem an other option is to downgrade scipy :

pip install scipy==0.19.1

Upvotes: 2

Views: 693

Answers (2)

joshua
joshua

Reputation: 21

PyDSTool has a bug in line 76 of __init__.py

The original code is as follows:

if vernums[1] < 5:
    raise RuntimeError("SciPy v0.5.1 or above is required")

I have changed the code like this and then the problem was gone:

if vernums[1] < 5:
    if vernums[0] == 0:
        raise RuntimeError("SciPy v0.5.1 or above is required")

The problem was that the original code didn't check the first version code.

Upvotes: 2

Pierre de Buyl
Pierre de Buyl

Reputation: 7293

The PyDSTool project homepage at sourceforge is down: http://pydstool.sourceforge.net/ points to http://www.ni.gsu.edu/~rclewley/PyDSTool/FrontPage.html that returns "file not found".

The project has moved to GitHub: https://github.com/robclewley/pydstool

There are several issues in line with yours there. The problem is that, currently, the development of SciPy's integrate module has broken the calls from PyDSTool.

One solution: use an older version of SciPy. The alternatives are either to find yourself the points of failure or to use the fork here: https://github.com/tkf/pydstool/tree/tkf

Upvotes: 2

Related Questions