Welcome folks today in this blog post we will be adding the
blur effect to the input image file using
pillow library in python. All the full source code of the application is shown below.
In order to get started you need to make an
app.py file and copy paste the following code
#Import required Image library
from PIL import Image, ImageFilter
#Open existing image
OriImage = Image.open('images/boy.jpg')
#Applying GaussianBlur filter
gaussImage = OriImage.filter(ImageFilter.GaussianBlur(5))
#Save Gaussian Blur Image
As you can see we are importing the
pillow library and then we are applying the
gaussian blur to the input image and then we are saving the output image file.