Image Processing on Jupyter Notebook

Gani Çalışkan
Turk Telekom Bulut Teknolojileri
3 min readOct 1, 2022

1) What is Jupyter Notebook?

The Jupyter Notebook is the original web application for creating and sharing computational documents. It offers a simple, streamlined, document-centric experience. It is also python based programming platform that provides customers to write python codes free.

2) Let’s start to upload image on Jupyter Notebook

After you install Jupyter Notebook on your desktop, you can click the upload button which is on the top right side of the image. You can clearly upload your favorite picture to your files section.

3) Let’s start to process our image

In this code, the import numpy portion of the code tells Python to bring the NumPy library into your current environment. Matplotlib. pyplot is a collection of command style functions that make matplotlib work which is similar to MATLAB. Each pyplot function makes some change to a figure: e.g., creates a figure, plotting area in a figure, plots some lines in a plotting area, decorates the plot with labels, etc.

Cute dog

PIL is the Python Imaging Library which provides the python interpreter with image editing capabilities. The Image module provides a class with the same name which is used to represent a PIL image. Then as you see on the screen, Image.open command shows the little cute dog.

Note: Image should be in .jpg format !!!

You can see the type of the image that I uploaded on my files. When we convert input to an array, you can see the shape of the array. Therefore, we see the image with a 2-dimensional numpy array.

4) Coloring the image

You can follow all the codes that instructs you how to change the color properly. You are going to realize that multiple colors can designed on the images.

Green Dog
Gray Dog
Red Dog
Blue Dog
Black image

See you in the next part of my Jupyter notebook article series. Hope you enjoyed :)

Photo by Joe Caione on Unsplash

--

--