Image Enhancement with Python using skimage Library in python Image Enhancement with Python using skimage Library in python
Adil Khan 6 years ago

Image Enhancement with Python using skimage Library in python

Scanned Image Enhancement in Python

# -*- coding: utf-8 -*-
 """
 Created on Fri Feb 14 17:11:32 2020
 This program is to show that how to enhance a scanned image
 @author: AdilKhan
 """
import matplotlib.pyplot as plt 
 from skimage import data
 from IPython import get_ipython
 get_ipython().run_line_magic('matplotlib', 'qt')
directory = 'C:/Users/AdilKhan/Desktop/Scanner/' #directory address
 imageName = 'input.jpg' # image name
inputFile = directory + imageName #image path
 page = data.load(inputFile) #load image
plt.subplot(1,3,1)
 plt.title('Original Image')
 plt.imshow(page)
threashold = 180 # set threashold
 mask = page > threashold # create mask
#textColor = [69,130,222] #text color blue
 textColor = 0
scanned = page
 scanned[:] = textColor
 scanned[mask] = 255
 plt.subplot(1,3,2)
 plt.title('Scanned Image')
 plt.imshow(scanned)
 plt.imsave(directory + 'output.jpg',scanned)
cropped = scanned[60:2850,150:2150,:] #crop image
 plt.subplot(1,3,3)
 plt.title('Cropped Image')
 plt.imshow(cropped)
 plt.imsave(directory + 'cropped.jpg',cropped)


 

Image Enhancement with Python using skimage Library in python _ 0.zip

Download: Image Enhancement with Python using skimage Library in python _ 0.zip

0
1.1K
Smart Front End and Reporting System

The entire project has been built around python and .NET. It is controlling the peripheral...

1675638330.png
Adil Khan
1 year ago
Resturant WebSite With Food Ordering System

Online Food Ordering System is a part of e-commerce. E-commerce or business through the ne...

1675638330.png
Adil Khan
1 year ago
Thermal Overload Protection and Temperature Monitoring of Transformer...

Main aim of our project is to avoid transformer blasting due to Overload. Temperature humi...

1675638330.png
Adil Khan
1 year ago
Deep Learning Based Metallic Surface Detection

Metallic surface defect detection is an essential and necessary process to control the qua...

1675638330.png
Adil Khan
1 year ago
Buy Best

Buy Best Search Engine will allow the user to enter his requirements (price range, brand n...

1675638330.png
Adil Khan
1 year ago