It tells me that sklearn is missing but that it is up-to-date in /usr/local/lib/python2.7/dist-packages

1

On the server of my company, when I try to start a python file it tells me that I need sklearn but it seems that it already exists.

:~/Eclipse-Stats$ python Main.py 
2017-07-24 14:01:55.852751
Traceback (most recent call last):
  File "Main.py", line 2, in <module>
    import kmeans
  File "/home/ubuntu/Eclipse-Stats/kmeans.py", line 3, in <module>
    import sklearn
ImportError: No module named sklearn
:~/Eclipse-Stats$ pip install -U scikit-learn
Requirement already up-to-date: scikit-learn in /usr/local/lib/python2.7/dist-packages

Maybe the terminal thinks that there is not one on the server but, with the second command, that I have it in the terminal?

It seems that this is a version problem because when I use python3 Main.py , the terminal tells me that:

~/Eclipse-Stats$ python3 Main.py
  File "Main.py", line 113
    print "list of groups you can recommend : "
                                              ^
SyntaxError: Missing parentheses in call to 'print'

It seems to work but sklearn can not work with python2.7

How can I change the sklearn version?

    
asked by ThePassenger 24.07.2017 в 16:24
source

0 answers