Cannot install nupic on my virtualenv

I have created virtualenv for python 2 and install nupic.

It shown error "Command "python setup.py egg_info" failed with error code 1 in /tmp/pip-install-zbwv_vt0/unittest2/".

Then I try to unintall nupic -y, I got “Skipping nupic as it is not installed.”

I do pip uninstall nupic.bindings. -y, I got the error as follows;

Invalid requirement: 'nupic.bindings.'
Traceback (most recent call last):
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/packaging/requirements.py", line 93, in  **init**
req = REQUIREMENT.parseString(requirement_string)
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 1654, in parseString
raise exc
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 1644, in parseString
loc, tokens = self._parse( instring, 0 )
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 1402, in _parseNoCache
loc,tokens = self.parseImpl( instring, preloc, doActions )
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 3417, in parseImpl
loc, exprtokens = e._parse( instring, loc, doActions )
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 1406, in _parseNoCache
loc,tokens = self.parseImpl( instring, preloc, doActions )
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/pyparsing.py", line 3205, in parseImpl
raise ParseException(instring, loc, self.errmsg, self)
pip._vendor.pyparsing.ParseException: Expected stringEnd (at char 14), (line:1, col:15)

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_intern
al/req/constructors.py", line 253, in install_req_from_line
req = Requirement(req)
File "/home/toon/repos/numenta_explained/numenta_explained/lib/python3.6/site-packages/pip/_vendor
/packaging/requirements.py", line 96, in  **init**
requirement_string[e.loc:e.loc + 8], e.msg
pip._vendor.packaging.requirements.InvalidRequirement: Parse error at "'.'": Expected stringEnd

What should I do next? Thank you

Looks like the errors you’ve provided are not enough to debug your issue. Please provide information on how you have tried to install nupic. I would suggest post the steps from creating your virtualenv up to installing your nupic, until the point where you got the errors, please show the commands and the error log.

Hi Jose.

Thank you. The problem have been solved, it can run in my environment.

2 Likes

Did you find out what the problem was? Maybe you can share in case someone else has the same issue. :smiley:

Hi, I have also created a virtualenv for python 2.7 and cannot install nupic since I am getting a similar error to what you have previously experienced. How did you solve the problem?
Thanks!

These are the errors that I get:

ERROR: Complete output from command python setup.py egg_info:
    ERROR: Download error on https://pypi.org/simple/setuptools_scm/: [Errno 10054] An existing connection was forcibly closed by the remote host -- Some packages may not be found!
    Download error on https://pypi.org/simple/setuptools-scm/: [Errno 10054] An existing connection was forcibly closed by the remote host -- Some packages may not be found!
    Couldn't find index page for 'setuptools_scm' (maybe misspelled?)
    Download error on https://pypi.org/simple/: [Errno 10054] An existing connection was forcibly closed by the remote host -- Some packages may not be found!
    No local packages or working download links found for setuptools_scm
    Traceback (most recent call last):
      File "<string>", line 1, in <module>
      File "c:\users\shahar~1\appdata\local\temp\pip-install-_axg1z\pytest-xdist\setup.py", line 37, in <module>
        'Programming Language :: Python :: 3',
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\setuptools\__init__.py", line 144, in setup
        _install_setup_requires(attrs)
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\setuptools\__init__.py", line 139, in _install_setup_requires
        dist.fetch_build_eggs(dist.setup_requires)
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\setuptools\dist.py", line 717, in fetch_build_eggs
        replace_conflicting=True,
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\pkg_resources\__init__.py", line 782, in resolve
        replace_conflicting=replace_conflicting
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\pkg_resources\__init__.py", line 1065, in best_match
        return self.obtain(req, installer)
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\pkg_resources\__init__.py", line 1077, in obtain
        return installer(requirement)
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\setuptools\dist.py", line 784, in fetch_build_egg
        return cmd.easy_install(req)
      File "c:\users\shahardror\documents\assignment2\htm\htm\lib\site-packages\setuptools\command\easy_install.py", line 673, in easy_install
        raise DistutilsError(msg)
    distutils.errors.DistutilsError: Could not find suitable distribution for Requirement.parse('setuptools_scm')
    ----------------------------------------
ERROR: Command "python setup.py egg_info" failed with error code 1 in c:\users\shahar~1\appdata\local\temp\pip-install-_axg1z\pytest-xdist\

Probably because NuPIC is still Python 2?

:see_no_evil: No idea why it’s still in Python 3, thank you for catching that!

1 Like

CPython 2.7 won’t be supported much longer.

  You probably should try nupic.cpp. It runs on CPython 3.x.  But

check that the license is compatible with what you want to do.

Has anyone tried running Numenta’s version of nupic on Pypy - the
mostly-CPython-2.7-compatible one?