Coders Packet

Image Editor Using Python

By Surya Sarkar

This is a Python program using which we can Edit the Images swiftly. In this, we will be using the Python Image Processing library that is the PIL library.

What is Pillow Library?

This program will be using the PILLOW library (PIL). Pillow is a free and open-source python library that provides us general image handling and operations. It can be used for many purposes like reading and writing images from computers, creating image thumbnails for the web, and mobile applications, getting useful information from the images, and also getting statistical data from the image. In this, we only need it Image, ImageFilter, ImageOPs module.


Before running this program you need to install the pillow library using pip install Pillow.

In this, we will perform the following functions:-

  1. Crop() - The crop() method in the image module of the pillow library provides us a way to crop the image as per our given dimensions.
  2. Flip() -  If a 3D array can be flip, so an image can also be flipped. But in this flip() method we can only flip 90 degrees and 180 degrees.
  3. Rotate() - In this function, we rotate the image by any angle.
  4. Filters() - Using this function you can add different filters to your images.
  5. Basic_tools() - In this, we perform Increase/Decrease of Brightness, Sharpness, Saturation, and Contrast.

Run this on jupyter Notebook(Recommended)

Example:

Original Image

Original Image

Saturated Image

Saturated Image

 

 

Download Complete Code

Comments

No comments yet