Error opening Anaconda package spykeviewer - python

I am running Anaconda on macOS Sierra utilising Python 2.7. I want to be able to run spykeviewer https://anaconda.org/pypi/spykeviewer
however I keep receiving this error:
*Traceback (most recent call last):
File "/Users/becky/anaconda/envs/spykeviewer-en/bin/spykeviewer", line 11, in <module>
sys.exit(main())
File "/Users/becky/anaconda/envs/spykeviewer-en/lib/python2.7/site-packages/spykeviewer/start.py", line 42, in main
from ui.main_window_neo import MainWindowNeo
File "/Users/becky/anaconda/envs/spykeviewer-en/lib/python2.7/site-packages/spykeviewer/ui/main_window_neo.py", line 16, in <module>
from spyderlib.widgets.variableexplorer.collectionseditor import \
ImportError: No module named spyderlib.widgets.variableexplorer.collectionseditor*
I have all of the dependent packages downloaded and I have reinstalled spyder as the error seems to be pointing to this module but I still get the same import error.
Here is how I installed the different packages:
conda install pyqt=4
conda install scipy
conda install gdata
conda install matplotlib
conda install pytables
conda install spyder
tables already installed in the environment
from terminal -> into guidata folder -> python setup.py install
from terminal -> into quiqwt -> python setup.py install
both are then in root —> open terminal in spykeviewer-en —> pip install guidata
condo install cython
pip install guiqwt
pip install neo
pip install spykeutils
pip install spykeviewerenter

Related

Prioritize conda pip over pip

I installed pip and installed python for terminal use for a previous course. The course I am currently in, specified I install Anaconda. I installed Anaconda and when using JupyterLab for python and plotly, I installed the plotly-geo package. It says it is not installed though and when I try to install again it says it is installed.
Is it because I installed pip python prior? How would I remove all of pip and reinstall it for Anaconda?
Traceback (most recent call last):
File "./Desktop/Data_Visualization/p3_source/p3.py", line 25, in <module>
exponent_format=True,
File "/Library/Frameworks/Python.framework/Versions/3.7/lib/python3.7/site-packages/plotly/figure_factory/_county_choropleth.py", line 622, in create_choropleth
"""
ValueError:
The create_choropleth figure factory requires the plotly-geo package.
Install using pip with:
$ pip install plotly-geo
Or, install using conda with
$ conda install -c plotly plotly-geo
The path of the site packages from your error suggests that you are executing your script with the non-anaconda version of python. I would suggest to uninstall it and only keep your anaconda distribution, as you can just create virtual environments should you need another python version

Python3.6 ImportError: cannot import name 'main' after upgrading pip from 8.1.1 to 19.0.1

After I upgraded pip from 8.1.1 to 19.0.1 by running
pip install --upgrade pip
I tried to test the version of pip by running
pip -V
But I got the following error
Traceback (most recent call last):
File "/usr/bin/pip3", line 9, in <module>
from pip import main
ImportError: cannot import name 'main'
I set the python3 and pip3 to be default by putting the following in ~/.bashrc
alias python=python3
alias pip=pip3
My system is ubuntu 16.04
This is a common issue as referenced here : https://github.com/pypa/pip/issues/5221
You are trying to use the pip, which is shipped with the Debian system. You better try to avoid using that pip at any cost.
Please use python3 -m pip install package instead of the system pip which you have in the debian system.
I also recommend using venv - virtual environments for keeping your system environment safe.

Some issues with pip installation

I tried to install pip manager using the file get-pip.py as mentioned in the documentation- https://pip.pypa.io/en/stable/installing/
So, I downloaded the file and ran python get-pip.py and as a result, I had permission issues. So I again ran sudo python get-pip.py and it worked.
Now I wanted to install numpy. So I ran pip install numpy and it showed me the Import Error saying-
Traceback (most recent call last):
File "/usr/local/bin/pip", line 7, in <module>
from pip import main
ImportError: No module named pip
But again when I ran sudo pip install numpy, it worked and got installed. Now, for every python script involving these pip packages, I have to run the script using sudo which I don't like. So how can I resolve these permission issues?
Just to mention-
python v2.7.12
pip v9.0.1
pip installation location- /usr/local/lib/python2.7/dist-packages

Python : setuptools module is already installed but still shows import error

I am trying to install something using "python setup.py install" but it shows me this error :-
Traceback (most recent call last):
File "setup.py", line 3, in <module>
from setuptools import setup
ImportError: No module named setuptools
I have installed this missing module using "pip install setuptools". But still it shows me the same error .I have also tried to install this using "sudo apt-get install python-setuptools" but the problem still remains the same. Help me in this issue
If you have Python 2 >=2.7.9 or Python 3 >=3.4 installed from python.org, you will already have pip and setuptools, but will need to upgrade to the latest version:
On Linux or macOS:
pip install -U pip setuptools
On Windows:
python -m pip install -U pip setuptools
If you’re using a Python install on Linux that’s managed by the system package manager (e.g “yum”, “apt-get” etc…), and you want to use the system package manager to install or upgrade pip, then see link

ImportError: No module named shutil_get_terminal_size

I have started to install SciPy using:
pip install --user numpy scipy matplotlib ipython jupyter pandas simply nose
It installed but when I want to go into ipython I get this error:
ImportError: No module named shutil_get_terminal_size
I tried uninstalling python then reinstalling it as well as uninstalling and reinstalling SciPy. I've also upgraded pip setup tools as well as python. It says that shutil_get_terminal_size has been installed:
Traceback (most recent call last):
File "/usr/local/bin/ipython", line 7, in <module>
from IPython import start_ipython
File "/usr/local/lib/python2.7/site-packages/IPython/__init__.py", line 48, in <module>
from .core.application import Application
File "/usr/local/lib/python2.7/site-packages/IPython/core/application.py", line 25, in <module>
from IPython.core import release, crashhandler
File "/usr/local/lib/python2.7/site-packages/IPython/core/crashhandler.py", line 28, in <module>
from IPython.core import ultratb
File "/usr/local/lib/python2.7/site-packages/IPython/core/ultratb.py", line 128, in <module>
from IPython.utils.terminal import get_terminal_size
File "/usr/local/lib/python2.7/site-packages/IPython/utils/terminal.py", line 22, in <module>
from backports.shutil_get_terminal_size import get_terminal_size as _get_terminal_size
ImportError: No module named shutil_get_terminal_size
I just need to be able to get SciPy and ipython working.
You need to update your version of pip and then install ipython again.
sudo pip install --upgrade setuptools pip
pip uninstall --user ipython
pip install --user ipython
I have also faced the same issue.This is the issue of conda environment. That's why it is giving the error in ipython notebook.Try out this one.
conda update conda
conda update ipython
After trying this,if you are facing same issue.then try to install ipython inside your conda environment.Activate your conda environment first.then do as follows.
pip install --upgrade setuptools pip
ex: (dato-env) pydev#Optimus:~$ pip install --upgrade setuptools pip
then install ipython inside conda environment
pip install -U ipython
ex : (dato-env) pydev#Optimus:~$ pip install -U ipython
then open Jupyter notebook from the terminal and it will open jupyter on your browser.
(dato-env) pydev#Optimus:~$ jupyter notebook
Hope it helps.

Categories

Resources