Ombre
Ombre

Reputation: 113

Install python packages on Jupyter Notebook

I am trying to install 2 python packages on Anaconda Jupyter Notebook. The links to the python packages are as follow: 1) https://iapws.readthedocs.io/en/latest/modules.html 2) https://pythonhosted.org/thermopy/iapws.html#module-thermopy.iapws

But I am getting the following error on both installations. Can anyone tell me what is wrong?

Error Screenshot

Upvotes: 0

Views: 9516

Answers (2)

Rob128
Rob128

Reputation: 21

Through Anaconda you should write this on your Jupyter notebook :

# Install a conda package in the current Jupyter kernel
import sys
!conda install --yes --prefix {sys.prefix} packagename

With a normal install of python you should write this on your Jupyter notebook :

# Install a pip package in the current Jupyter kernel
import sys
!{sys.executable} -m pip install packagename

By replacing packagename with the name of your package like numpy.

Cheers

Upvotes: 2

darksky
darksky

Reputation: 2080

Your Jupyter notebook server does not have access to internet. You operating system might have a firewall or limit internet access to third party applications, especially since this is a work laptop.

Regardless, it is easy to install components using pip. If you cannot access the internet from inside the notebook, try opening a Command Prompt as admin and simply type pip install iapws.

Upvotes: 0

Related Questions