Skip to content
geeksforgeeks
  • Tutorials
    • Python
    • Java
    • Data Structures & Algorithms
    • ML & Data Science
    • Interview Corner
    • Programming Languages
    • Web Development
    • CS Subjects
    • DevOps And Linux
    • School Learning
    • Practice Coding Problems
  • Courses
    • DSA to Development
    • Get IBM Certification
    • Newly Launched!
      • Master Django Framework
      • Become AWS Certified
    • For Working Professionals
      • Interview 101: DSA & System Design
      • Data Science Training Program
      • JAVA Backend Development (Live)
      • DevOps Engineering (LIVE)
      • Data Structures & Algorithms in Python
    • For Students
      • Placement Preparation Course
      • Data Science (Live)
      • Data Structure & Algorithm-Self Paced (C++/JAVA)
      • Master Competitive Programming (Live)
      • Full Stack Development with React & Node JS (Live)
    • Full Stack Development
    • Data Science Program
    • All Courses
  • Python Tutorial
  • Interview Questions
  • Python Quiz
  • Python Glossary
  • Python Projects
  • Practice Python
  • Data Science With Python
  • Python Web Dev
  • DSA with Python
  • Python OOPs
Open In App
Next Article:
Image processing with Scikit-image in Python
Next article icon

Image processing with Scikit-image in Python

Last Updated : 19 Jan, 2023
Comments
Improve
Suggest changes
Like Article
Like
Report

scikit-image is an image processing Python package that works with NumPy arrays which is a collection of algorithms for image processing. Let's discuss how to deal with images in set of information and its application in the real world. 
Important features of scikit-image : 
 

Simple and efficient tools for image processing and computer vision techniques. 
Accessible to everybody and reusable in various contexts. 
Built on the top of NumPy, SciPy, and matplotlib. 
Open source, commercially usable – BSD license.


Note : Before installing scikit-image, ensure that NumPy and SciPy are pre-installed. Now, the easiest way to install scikit-image is using pip : 
 

pip install -U scikit-image


  
Most functions of skimage are found within submodules. Images are represented as NumPy arrays, for example 2-D arrays for grayscale 2-D images.
Code #1 : 
 

Python3
# Python3 program to process  # images using scikit-image  # importing data from skimage from skimage import data  camera = data.camera()   # An image with 512 rows # and 512 columns type(camera)   print(camera.shape) 

Output : 
 

numpy.ndarray (512, 512)


  
Code #2 : skimage.data submodule provides a set of functions returning example images. 
 

Python
# Python3 program to process  # images using scikit-image  # importing filters and # data from skimage from skimage import filters from skimage import data  # Predefined function to fetch data coins = data.coins()   # way to find threshold threshold_value = filters.threshold_otsu(coins)   print(threshold_value) 

Output : 
 

107


  
Code #3 : Load own images as NumPy arrays from image files. 
 

Python
# Python3 program to process  # images using scikit-image import os  # importing io from skimage import skimage from skimage import io  # way to load car image from file file = os.path.join(skimage.data_dir, 'cc.jpg')   cars = io.imread(file)  # way to show the input image io.imshow(cars) io.show() 

Output : 
 


Applications : 
 

  • Analysis of Medical images.
  • Classification of images for detection.


 


Next Article
Image processing with Scikit-image in Python

A

AFZAL ANSARI
Improve
Article Tags :
  • Misc
  • GBlog
  • Technical Scripter
  • Python
  • Image-Processing
  • python-modules
Practice Tags :
  • Misc
  • python

Similar Reads

    Image Processing with SciPy and NumPy in Python
    In this tutorial, we will discuss Image Processing in Python using the core scientific modules like NumPy and SciPy. The images are made up of NumPy ndarrays so we can process and manipulate images and SciPy provides the submodule scipy.ndimage that provides functions that can operate on the NumPy a
    6 min read
    Multidimensional image processing using Scipy in Python
    SciPy is a Python library used for scientific and technical computing. It is built on top of NumPy, a library for efficient numerical computing, and provides many functions for working with arrays, numerical optimization, signal processing, and other common tasks in scientific computing. Image proce
    14 min read
    Python Image Processing Libraries
    Python offers powerful libraries such as OpenCV, Pillow, scikit-image, and SimpleITK for image processing. They offer diverse functionalities including filtering, segmentation, and feature extraction, serving as foundational tools for a range of computer vision tasks.Python Image Processing Librarie
    11 min read
    Histogram matching with OpenCV, scikit-image, and Python
    Histogram matching is used for normalizing the representation of images, it can be used for feature matching, especially when the pictures are from diverse sources or under varied conditions (depending on the light, etc). each image has a number of channels, each channel is matched individually. His
    3 min read
    Top Python libraries for image processing
    Python has become popular in various tech fields and image processing is one of them. This is all because of a vast collection of libraries that can provide a wide range of tools and functionalities for manipulating, analyzing, and enhancing images. Whether someone is a developer working on image ap
    8 min read
geeksforgeeks-footer-logo
Corporate & Communications Address:
A-143, 7th Floor, Sovereign Corporate Tower, Sector- 136, Noida, Uttar Pradesh (201305)
Registered Address:
K 061, Tower K, Gulshan Vivante Apartment, Sector 137, Noida, Gautam Buddh Nagar, Uttar Pradesh, 201305
GFG App on Play Store GFG App on App Store
Advertise with us
  • Company
  • About Us
  • Legal
  • Privacy Policy
  • In Media
  • Contact Us
  • Advertise with us
  • GFG Corporate Solution
  • Placement Training Program
  • Languages
  • Python
  • Java
  • C++
  • PHP
  • GoLang
  • SQL
  • R Language
  • Android Tutorial
  • Tutorials Archive
  • DSA
  • Data Structures
  • Algorithms
  • DSA for Beginners
  • Basic DSA Problems
  • DSA Roadmap
  • Top 100 DSA Interview Problems
  • DSA Roadmap by Sandeep Jain
  • All Cheat Sheets
  • Data Science & ML
  • Data Science With Python
  • Data Science For Beginner
  • Machine Learning
  • ML Maths
  • Data Visualisation
  • Pandas
  • NumPy
  • NLP
  • Deep Learning
  • Web Technologies
  • HTML
  • CSS
  • JavaScript
  • TypeScript
  • ReactJS
  • NextJS
  • Bootstrap
  • Web Design
  • Python Tutorial
  • Python Programming Examples
  • Python Projects
  • Python Tkinter
  • Python Web Scraping
  • OpenCV Tutorial
  • Python Interview Question
  • Django
  • Computer Science
  • Operating Systems
  • Computer Network
  • Database Management System
  • Software Engineering
  • Digital Logic Design
  • Engineering Maths
  • Software Development
  • Software Testing
  • DevOps
  • Git
  • Linux
  • AWS
  • Docker
  • Kubernetes
  • Azure
  • GCP
  • DevOps Roadmap
  • System Design
  • High Level Design
  • Low Level Design
  • UML Diagrams
  • Interview Guide
  • Design Patterns
  • OOAD
  • System Design Bootcamp
  • Interview Questions
  • Inteview Preparation
  • Competitive Programming
  • Top DS or Algo for CP
  • Company-Wise Recruitment Process
  • Company-Wise Preparation
  • Aptitude Preparation
  • Puzzles
  • School Subjects
  • Mathematics
  • Physics
  • Chemistry
  • Biology
  • Social Science
  • English Grammar
  • Commerce
  • World GK
  • GeeksforGeeks Videos
  • DSA
  • Python
  • Java
  • C++
  • Web Development
  • Data Science
  • CS Subjects
@GeeksforGeeks, Sanchhaya Education Private Limited, All rights reserved
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our Cookie Policy & Privacy Policy
Lightbox
Improvement
Suggest Changes
Help us improve. Share your suggestions to enhance the article. Contribute your expertise and make a difference in the GeeksforGeeks portal.
geeksforgeeks-suggest-icon
Create Improvement
Enhance the article with your expertise. Contribute to the GeeksforGeeks community and help create better learning resources for all.
geeksforgeeks-improvement-icon
Suggest Changes
min 4 words, max Words Limit:1000

Thank You!

Your suggestions are valuable to us.

What kind of Experience do you want to share?

Interview Experiences
Admission Experiences
Career Journeys
Work Experiences
Campus Experiences
Competitive Exam Experiences