0

So... I'm trying to install SimpleITK on Python 2.7.12 and I tried several ways which none is giving me satisfatory result.

1) by simply using

pip install SimpleITK

I get "No matching distribution found for SimpleITK" (my pip version is 9.0.1)

2) tar file (available here: https://sourceforge.net/projects/simpleitk/files/SimpleITK/1.0.0/Python/): when I run the command

python setup.py install

I get:

Download error on https://pypi.python.org/simple/scikit-build/: [SSL: 
CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590) -- Some 
packages may not be found!
Couldn't find index page for 'scikit-build' (maybe misspelled?)
Download error on https://pypi.python.org/simple/: [SSL: 
CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590) -- Some 
packages may not be found!
No local packages or download links found for scikit-build>=0.5
Traceback (most recent call last):
 File "setup.py", line 50, in <module>
 zip_safe=False
 File "/usr/lib/python2.7/distutils/core.py", line 111, in setup
_setup_distribution = dist = klass(attrs)
 File "/usr/lib/python2.7/dist-packages/setuptools/dist.py", line 269, in 
__init__
self.fetch_build_eggs(attrs['setup_requires'])
File "/usr/lib/python2.7/dist-packages/setuptools/dist.py", line 313, in 
fetch_build_eggs
replace_conflicting=True,
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 
826, in resolve
dist = best[req.key] = env.best_match(req, ws, installer)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 
1092, in best_match
return self.obtain(req, installer)
File "/usr/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 1 
104, in obtain
return installer(requirement)
File "/usr/lib/python2.7/dist-packages/setuptools/dist.py", line 380, in 
fetch_build_egg
return cmd.easy_install(req)
File "/usr/lib/python2.7/dist-
packages/setuptools/command/easy_install.py", 
    line 657, in easy_install
   raise DistutilsError(msg)
 distutils.errors.DistutilsError: Could not find suitable distribution for 
 Requirement.parse('scikit-build>=0.5')

I don't understand what is missing and why I can't use the pratical way (with pip)... =( I also didn't try Python 3 (but I would rather use Python 2.7 as I'm more familiarized with it).

Thank you in advance!

EDIT: FINALLY GOT IT TO WORK!

Here: sudo easy_install for SimpleITK not that easy

user
  • 87
  • 1
  • 10
  • What OS and architecture are you on? What is the output of "python -i -c 'import distutils.util; print(distutils.util.get_platform())'"? What is printing when "python -i" is started? – blowekamp Jul 18 '17 at 20:15
  • Also it looks like you SSL it broken from the error message. What is the output of "pip install -v SimpleITK"? – blowekamp Jul 18 '17 at 20:18
  • Thank you for the answer! Well, I'm on Linux Mint Serena Virtual Box (If my memory is correct). The output of "python -i -c 'import distutils.util; print(distutils.util.get_platform())'" is... ahm... nothing. Just the ">>>" from python shell... When I use "python -i" It's printing "Python 2.7.12 (default, Nov 19 2016, 06:48:10) [GCC 5.4.0 20160609] on linux2 Type "help", "copyright", "credits" or "license" for more information." – user Jul 19 '17 at 11:30
  • Finally, the output of "pip install -v SimpleITK" is a long error message (It's exceeding max characters, so I'm showing just a small part) "Could not fetch URL https://pypi.python.org/simple/simpleitk/: There was a problem confirming the ssl certificate: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590) - skipping Could not find a version that satisfies the requirement SimpleITK (from versions: ) Cleaning up... No matching distribution found for SimpleITK" – user Jul 19 '17 at 11:46
  • A little bit more of the error message "DistributionNotFound: No matching distribution found for SimpleITK Looking up "https://pypi.python.org/pypi/pip/json" in the cache No cache entry available Starting new HTTPS connection (1): pypi.python.org There was an error checking the latest version of pip" ... "SSLError: [SSL: CERTIFICATE_VERIFY_FAILED] certificate verify failed (_ssl.c:590)" – user Jul 19 '17 at 11:47

0 Answers0