Installing ipython notebook on Linux - python

I am trying to install ipython notebook on Linux. System specs are as follows: Red Hat Enterprise Linux Server. PRODUCT VERSION 7.5
Anaconda (Dec 30 2018) with python 3.6 has already been installed.
To install ipython notebook, i was doing the following:
$ pip install ipython
and
$ pip install jupyterlab
and
$ conda install -c conda-forge jupyterlab
However, i was always getting the same error as follows:
any ideas please?

Two issues:
Your computer is not connected to the internet.
Try using
pip3
for python 3.6

Related

Jupyter Lab - Kite is installed but its not working

i've been trying to install Kite in JupyterLab v2.2.6. I have dowloaded and installed Kite, have node.js 15.0.1 and i've run the console commands:
pip install jupyter-kite
jupyter labextension install "#kiteco/jupyterlab-kite"
i have no problems with either and when i check in jupyter extension manager it tells me that it is installed
Kite missing some dependencies error message in jupyterlab
Update for macOS Catalina users, try upgrading JupyterLab > 2.2.9:
Open Terminal:
$ conda install -c conda-forge jupyterlab=3.0.3
Open Kite copilot:
-->
Home
-->
Redo Setup
Open Terminal:
$ pip install "jupyterlab-kite>=2.0.2"
As of this post, Kite works with:
jupyterlab 3.2.7
jupyterlab-kite 2.0.2
JupyterLab:
conda install -c conda-forge jupyterlab=3.2.7
or
pip install jupyterlab==3.2.7
Kite:
pip install jupyterlab-kite>=2.0.2 (only PyPI)
jupyter labextension install "#kiteco/jupyterlab-kite"
Note also that as of this post, there is no Kite extension for VS Code that is compatible with .ipynb. The VS Code Kite extension is compatible with .py .go .js .jsx .vue only.
In addition, you can no longer download the Kite engine from the Kite website.
Adam has posted the installers here.
macOS
Windows
Linux
I had the same problem and for me the following worked:
Reinstalled Anaconda and then I updated the provided JupyterLab version in the (base) terminal. (You would like to update your JupyterLab in the respective virtual environment you are using Anaconda with.)
conda install -c conda-forge jupyterlab==2.2.9
The JupyterLab version in your Anaconda should show 2.2.9 after you restart Anaconda. After this, download node.js and install it on you computer. Then follow the instructions in your Kite desktop app to install the Jupyter Kite extension via the (base) terminal:
pip install jupyter-kite
jupyter labextension install "#kiteco/jupyterlab-kite"
Open your Kite desktop app and click on Redo Setup under the Home section.
In your JupyterLab Kite: Initializing should appear down in the left corner.

How do you completely uninstall jupyter notebook and jupyterlab from a mac when standard uninstall commands have no effect?

This has been asked many times - but I cannot for the life of me get rid of jupyter notebook/jupyterlab. I want to not be able to run a jupyter notebebook so that I can re-install everything.
I have tried the simple
pip uninstall jupyterlab pip uninstall notebook pip uninstall jupyter also with pip3 options
I have tried
$ pip3 install pip-autoremove
$ pip-autoremove jupyter -y
and changed pip3 for pip in case that made a difference.
I have followed what has been suggested with this answer
The output to which jupyter is /usr/local/bin/jupyter. I tried sudo /usr/local/bin/python -m pip uninstall jupyter following the comment answer this question.
Whenever I try remove it I just get Skipping jupyter as it is not installed. errors, yet if you run jupyter notebook it runs, and which jupyter continues to return a result.
It was suggested that I re-install Python3, but Jupyter Notebook is running Python2 (on a mac, so can't get rid of that), and I can't uninstall Python3 either following any instructions I can find.
Is there any way to get rid of this program from a mac when all the above fail to do anything?
Far as I know it was installed with pip, but I also checked if it was installed through conda (conda not recognised as a command)
I am running macOS Mojave Version 10.14.6. Python versions are
$ python --version
Python 2.7.15
$ python3 --version
Python 3.6.5

ERROR: ipykernel requires Python version 3.4 or above

I am using Ubuntu 16.04 lts. My default python binary is python2.7. When I am trying to install ipykernel for hydrogen in atom editor, with the following command
python -m pip install ipykernel
It is giving the following errors
ERROR: ipykernel requires Python version 3.4 or above.
I am trying to install ipykernel for python2. I have already installed python3.7. Also ipython and jupyter notebook is installed.
Starting with version 5.0 of the kernel, and version 6.0 of IPython, compatibility with Python 2 was dropped.
As far as I know, the only solution is to install an earlier release.
In order to have Python 2.7 available in the Jupyter Notebook I installed IPython 5.7, and ipykernel 4.10. If you want to install earlier releases of IPython or ipykernel you can do the following:
Uninstall IPython
pip uninstall ipython
Reinstall IPython
python2 -m pip install ipython==5.7 --user
Install ipykernel
python2 -m pip install ipykernel==4.10 --user
Try using Anaconda
You can learn how to install Anaconda from here
After that, try creating a virtual environment via:
conda create -n yourenvname python=2.7 anaconda
And activate it via:
source activate yourenvname
After that, try installing:
pip install ipython
pip intall ipykernel

Can't install tensorflow with pip or anaconda

Does anyone know how to properly install tensorflow on Windows?
I'm currently using Python 3.7 (also tried with 3.6) and every time I get the same "Could not find a version that satisfies the requirement tensorflow-gpu (from versions: )
No matching distribution found for tensorflow-gpu" error
I tried installing using pip and anaconda, both don't work for me.
Found a solution, seems like Tensorflow doesn't support versions of python after 3.6.4. This is the version I'm currently using and it works.
Tensorflow or Tensorflow-gpu is supported only for 3.5.X versions of Python. Try installing with any Python 3.5.X version. This should fix your problem.
Here is what i did to get tensorflow working with windows.
Download python 3.7.0 (64 bit from Python Releases for Windows) Install it and check python version by running below command in cmd:
python --version
Python 3.7.0
Then run below command to upgrade pip to latest
python -m pip install --upgrade pip
Now install tensorflow using pip
pip install tensorflow
That's it you have installed tensorflow on windows. Below image shows what happens when you type above commands
link for tensorflow for python 3x
https://pypi.org/project/tensorflow/#files
tensorflow-1.14.0-cp37-cp37m-win_amd64.whl (68.3 MB)
Unfortunately, tensorflow can't installed correctly on python 3.7 and last version of anaconda: so, the best and effective way to do this is to downgrade your python to python 3.6.7 use the next steps:
1- download the latest version of Anaconda
use Anaconda prompt with administrator privilege
2- conda install python=3.6.7 (need a long time)
3-conda install tensorflow
4- conda install keras
5- conda install numpy
Check whether you have a CPU or GPU, if your system doesn't have GPU, then it will generate error.
If you are going to install tensorflow using Windows command prompt (assuming python is already installed), then just run the following command. Go to the root directory, preferably 'C:' drive then run
For GPU- pip3 install --upgrade tensorflow-gpu
For CPU- pip3 install --upgrade tensorflow
If you are using Anaconda, then open Anaconda Navigator->Environments->Select 'All' from the drop down menu and then search TensorFlow. If you are using CPU, then select 'tensorflow', else for GPU select 'tensorflow-gpu'. Then click Apply.
Screenshot of Anaconda Navigator-In case you are not familiar where to look.
Download the latest version of anaconda from here
I'm using Anaconda 2019.03 for Windows Installer, Python 3.7, 64-bit
Upgrade pip as:
python -m pip install --upgrade pip
(a). Install tensorflow using pip3 as:
pip3 install --user --upgrade tensorflow
(b). If you installed anaconda with all users mode. The above
command will become:
pip3 install --upgrade tensorflow
Check installation success as:
python -c "import tensorflow as tf; print(tf.reduce_sum(tf.random.normal([1000, 1000])))"
As of Feb 2020, Tensorflow is not supported for Python 3.8+
To make it work install a virtualenv w/ Python 3.7 from here: https://www.python.org/downloads/windows/
Tensorflow pip installation for python version 3.5-3.8 requires pip 19.0 or later, as mentioned in the official tensorflow documentation.
Here is a part of this documentation:
System requirements
Python 3.5–3.8
Python 3.8 support requires TensorFlow 2.2 or later.
pip 19.0 or later (requires manylinux2010 support)
Try running pip install --upgrade pip inside your python3 virtualenv.
You mentioned Anaconda. Do you run your python through there?
If so check in Anaconda Navigator --> Environments, if your current environment have got tensorflow installed.
If not, install tensorflow and run from that environment.
Should work.
I had the same problem that yours, happened that I had python at version 3.7. So for installing the Tensorflow with the GPU support I used:
py -3.6 -m pip install tensorflow-gpu
at a Virtualenv ambient. You can see the documentation behind on this website:
https://docs.python.org/3/installing/index.html
I think that this solution is better than downgrade the Python version.
Actually the easiest way to install tensorflow is:
install python 3.5 (not 3.6 or 3.7) you can check wich version you have by typing "python" in the cmd.
When you install it check in the options that you install pip with it and you add it to variables environnement.
When its done just go into the cmd and tipe "pip install tensorflow"
It will download tensorflow automatically.
If you want to check that it's been installed type "python" in the cmd then some that ">>>" will appear, then you write "import tensorflow" and if there's no error, you've done it!
As of November 2018, Tensorflow is not supported for Python 3.6.4+
What to do:
Downgrade Anaconda's Python from 3.7 or 3.6.5+ to 3.6.4
a. Open Command Prompt, find your Anaconda environment, and change your directory
where anaconda or where python
Example path and cd:
cd C:\ProgramData\Anaconda3\bin
b. While in anaconda3/bin in your Command Prompt, source activate your base Anaconda environment
source activate
c. In your Command Prompt, downgrade your base Anaconda environment
conda install python=3.6.4
d. Install Tensorflow
pip install tensorflow
Further reading:
http://docs.anaconda.com/anaconda/user-guide/faq/#how-do-i-get-the-latest-anaconda-with-python-3-5
As of July 2019, I have installed it on python 3.7.3 using py -3 -m pip install tensorflow-gpu
py -3 in my installation selects the version 3.7.3.
The installation can also fail if the python installation is not 64 bit. Install a 64 bit version first.
This is Manas working as a intern in COE-AI lab(CET,BBSR) under tech machindra.
We faced same error. After a little research, we found that there is a glitch in anaconda python 3.7. It does not install tensorflow through pip or conda install command, even if it does..produces same error..
Here is the solution, install conda environment for python=3.6:
go to the directory where conda is installed
cd anaconda3
conda create -n tensorflow python=3.6
conda activate tensorflow
conda install tensorflow python=3.6
python
Import tensorflow.
steps
Do it twice:
enter image description here
enter image description here
-> Not able to install tensorflow , Here I have a solution that worked for me
Step 1 :
- Check version of python(3.7.3)
- Python must be 64 bit Otherwise tensorflow never ever going to be installed it defiitely gives Error.
Step 2 :
pip install tensorflow==2.0.0
Step 3 :
pip install sklearn==0.0
pip install Pillow==8.0.1
pip install h5py==2.10.0
Step 4 :
pip install keras==2.3.1
Now its ready to use.
In Windows 10 with Python 3.8.5, first i tried directly then it was giving following error:
ERROR: Could not find a version that satisfies the requirement tensorflow==1.15 (from versions: none)
Then i installed successfully in virtual environment shown below:
PS E:\udemy\full_stack_web_ai\deeplearning> .\myenv\Scripts\activate
(myenv) PS E:\udemy\full_stack_web_ai\deeplearning> pip install tensorflow
Collecting tensorflow ###
Downloading tensorflow-2.4.1-cp38-cp38-win_amd64.whl (370.7 MB)
Use virtual environment using:
python -m venv myenv
.\myenv\Scripts\activate
Not Enabling the Long Paths can be the potential problem.To solve that,
Steps include:
Go to Registry Editor on the Windows Laptop
Find the key "HKEY_LOCAL_MACHINE"->"SYSTEM"->"CurrentControlSet"->
"File System"->"LongPathsEnabled" then double click on that option and change the value from 0 to 1.
3.Now try to install the tensorflow it will work.

-bash: jupyter: command not found

I installed a copy of Anaconda to play around with, but decided I liked Homebrew better, so I removed it. However, this seems to have messed up my install of Jupyter Notebooks, as I can no longer access it. I reinstalled it with pip install jupyter and when I run pip show jupyter I get:
Version: 1.0.0
Summary: Jupyter metapackage. Install all the Jupyter components in one go.
Home-page: http://jupyter.org
Author: Jupyter Development Team
Author-email: jupyter#googlegroups.org
License: BSD
Location: /usr/local/lib/python2.7/site-packages
Requires: ipywidgets, nbconvert, notebook, jupyter-console, qtconsole, ipykernel
But when I run which -a jupyter I get nothing. I even tried uninstalling and installing python again via Homebrew and it still gives me the error, -bash: jupyter: command not found.
I have python installed correctly, which -a python gives:
/usr/local/bin/python
/usr/bin/python
Any ideas as to why it might not be working?
I'm on Mac and am using Zsh. For some reason, after I installed Python3, the following line:
PATH="/Library/Frameworks/Python.framework/Versions/3.6/bin:${PATH}"
was added to .zprofile instead of .zshrc.
I transferred the line to .zshrc and did source ~/.zshrc. That did the trick.
The below command seems to install only python files (under /usr/local/lib/python2.7/site-packages in your case):
pip install jupyter
You can run the jupyter as a Python's module like this:
python -m jupyter
To see all installed modules you can type the following command from the Python's shell:
help('modules')
As an alternative you can try to upgrade the package:
pip install --upgrade pip
pip install --upgrade jupyter
If you want to access the jupyter by simply typing jupyter in your shell then the path to the jupyter's binary file should be placed inside the PATH variable.
During the installation of Anaconda software the jupyter binary is placed under /usr/local/bin/jupyter (Ubuntu 14.04).
On Mac OS Mojave,
pip3 install jupyter
installs jupyter under
/Library/Frameworks/Python.framework/Versions/3.5/bin/
. Your version may be different from 3.5. You can then link to the binary there as follows.
ln -s /Library/Frameworks/Python.framework/Versions/3.5/bin/jupyter /usr/local/bin/
In the rare case that /usr/local/bin/ is not on your PATH, you may replace it above with some folder that is.
python -m notebook
should do the trick

Categories