Jupyter is a web-based development environment that is open source and free of cost. This notebook is primarily used for live coding. Jupyter notebook also enables its users to set up and organize workflow in machine learning, computational journalism, and scientific computing. You can share notes, interact with output, write a code in a language of your choice, and use many other important capabilities by utilizing Jupyter.
We are going to examine the method to install, launch, and uninstall the Jupyter notebook on Ubuntu 22.04 in the following post.
How to install Jupyter Notebook on Ubuntu 22.04?
In order to install the Jupyter notebook on Ubuntu 22.04, go through the below-given steps.
Step 1: Install python3
First install python3 if it is not already set up on your system. For doing so, use the command mentioned below:
$ sudo apt install python3
Now move to the next step to install Python3 pip.
Step 2: Install python3-pip
In the second step, install python3-pip on your Ubuntu 22.04 system:
$ sudo apt install python3-pip
Let’s move to the next step to upgrade pip.
Step 3: Upgrade pip version
After installation, upgrade the pip version using the below-given command:
$ sudo pip3 install --upgrade pip
Step 4: Installing Virtual Environment
In the following step, install Virtual Environment “virtualenv” using pip3:
$ sudo pip3 install virtualenv
Step 5: Make and open Jupyter directory
After installing the virtual environment, make a directory named “jupyter” using the “mkdir” command:
$ mkdir jupyter
Then open it using the given “cd” command:
$ cd jupyter
Step 6: Create and activate jup_notebook virtual environment
In the next step, create “jup_notebook” virtual environment:
$ virtualenv jup_notebook
Now activate “jup_notebook” virtual environment using the below-mentioned command:
$ source jup_notebook/bin/activate
Step 7: Install jupyter
Install jupyter on your Ubuntu 22.04 system by executing the provided command:
$ pip3 install jupyter
The given output indicates that Jupyter notebook is successfully installed on our Ubuntu 22.04 system:
How to launch Jupyter notebook on Ubuntu 22.04?
For launching and using Jupyter notebook, run the below-given command on Ubuntu’s terminal:
$ jupyter notebook
If the command runs successfully then it will open the Jupyter notebook on the browser. if it does not open Jupyter notebook then copy the highlighted link and paste it on the browser to open it:
As you can see, we have successfully launched Jupyter notebook on Ubuntu 22.04:
Let’s move to the uninstallation method of Jupyter.
How to uninstall Jupyter notebook on Ubuntu 22.04?
Go through the following command to uninstall Jupyter notebook from Ubuntu 22.04:
$ pip3 uninstall jupyter
We have covered all the required steps for the installation, launch, and uninstallation of Jupyter notebook on Ubuntu 22.04.
Conclusion
In order to install Jupyter on Ubuntu 22.04, first it is required to have python3 on the system. Then install python3-pip by executing the “$ sudo apt install python3-pip” command. Then, create and activate the virtual environment, and install the Jupyter notebook on Ubuntu 22.04 using the “$ pip3 install jupyter” command on the terminal. In this writeup, we have effectively elaborated the method for installing, launching, and uninstalling the Jupyter notebook on Ubuntu 22.04.
TUTORIALS ON LINUX, PROGRAMMING & TECHNOLOGY