SlideShare une entreprise Scribd logo
1  sur  23
Télécharger pour lire hors ligne
Image processing with scikit-image
Emmanuelle Gouillart
Surface, Glass and Interfaces, CNRS/Saint-Gobain
@EGouillart
The revolution of images
The revolution of images
A flood of images
several 108 images uploaded on Facebook each day
A flood of images
hundreds of terabytes of scientific data for scientific experiment
http://sdo.gsfc.nasa.gov/
A flood of images
hundreds of terabytes of scientific data for scientific experiment
http://sdo.gsfc.nasa.gov/
Image processing
Manipulating images in order to
retrieve new images or image
characteristics (features,
measurements, ...)
Often combined with machine learning
Why use scikit-image?
Lots of excellent tools available: OpenCV (computer vision),
ImageJ (GUI-based software), ITK, ...
Native NumPy
compatibility
Gentle learning curve
Variety of features
Versatile - 3D-friendly
Datasheet
Package statistics
http://scikit-image.org/
Release 0.11 (1 - 2 release per year)
Available in most Scientific Python
Distributions: Canopy, Anaconda, . . .
Packaged on Ubuntu/Debian
Among 1000 best ranked packages on
PyPi
Development model
Mature algorithms
Only Python + Cython code for
easier maintainability
Thorough code review by others:
readability, PEP8, efficiency, ...
Core team of 5 − 10 persons
(close to applications)
Manipulating images as numerical (numpy) arrays
Pixels are arrays elements
import numpy as np
image = np. ones ((5, 5))
image [0, 0] = 0
image [2, :] = 0
x
Manipulating images as numerical (numpy) arrays
Pixels are arrays elements
import numpy as np
image = np. ones ((5, 5))
image [0, 0] = 0
image [2, :] = 0
x
>>> coffee.shape
(400, 600, 3)
>>> red channel =
coffee[..., 0]
>>> image 3d =
np.ones((100, 100, 100))
NumPy-native: images as NumPy arrays
NumPy arrays as arguments and outputs
>>> from skimage import io , f i l t e r s
>>> c am er a a rr ay = i o . imread ( ’ camera image . png ’ )
>>> type( c am er a a rr ay )
<type ’numpy . ndarray ’ >
>>> c am er a a rr ay . dtype
dtype ( ’ uint8 ’ )
>>> f i l t e r e d a r r a y = f i l t e r s . g a u s s i a n f i l t e r (
camera array , sigma =5)
>>> type( f i l t e r e d a r r a y )
<type ’numpy . ndarray ’ >
>>> import m a t p l o t l i b . p y p l o t as p l t
>>> p l t .imshow( f i l t e r e d a r r a y , cmap= ’ gray ’ )
x
An API relying mostly on functions
skimage . f i l t e r s . g a u s s i a n f i l t e r (image , sigma , output =
None, mode= ’ n ea re st ’ , c v a l =0, m u l t i c h a n n e l =None)
Multi - d i m e n s i o n a l Gaussian filter
Parameters
----------
image : array - l i k e
input image ( g r a y s c a l e or c o l o r ) to filter.
sigma : s c a l a r or sequence of s c a l a r s
standard d e v i a t i o n f o r Gaussian k e r n e l . The
standard
d e v i a t i o n s of the Gaussian filter are g i v e n f o r
each a x i s as a
sequence , or as a s i n g l e number , in which case i t
i s equal f o r
all axes .
output : array , o p t i o n a l
The ‘‘ output ‘‘ parameter p a s s e s an a r r a y in which
to s t o r e the
filter output .
Getting started: finding documentation
Gallery of examples
Getting started: finding documentation
Filtering: transforming image data
skimage.filter, skimage.exposure, skimage.restoration
Extracting features
skimage.feature, skimage.filter
Feature extraction followed by classification
Combining scikit-image and scikit-learn
Extract features (skimage.feature)
Pixels intensity values (R, G, B)
Local gradients
More advanced descriptors: HOGs, Gabor, ...
Train classifier with known regions
here, random forest classifier
Classify pixels
Geometrical transformations
skimage.transform
scale, zoom, rotate, swirl, warp, ...
Segmentation: labelling regions
skimage.segmentation
Measures on images
skimage.measure
Versatile use for 2D, 2D-RGB, 3D...
>>> from skimage import measure
>>> l a b e l s 2 d = measure . l a b e l ( image 2d )
>>> l a b e l s 3 d = measure . l a b e l ( image 3d )
x
Try it out! http://scikit-image.org/
Feedback welcome
github.com/scikit-image/scikit-image
Please cite the paper

Contenu connexe

Plus de Pôle Systematic Paris-Region

Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick Moy
Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick MoyOsis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick Moy
Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick MoyPôle Systematic Paris-Region
 
Osis18_Cloud : Virtualisation efficace d’architectures NUMA
Osis18_Cloud : Virtualisation efficace d’architectures NUMAOsis18_Cloud : Virtualisation efficace d’architectures NUMA
Osis18_Cloud : Virtualisation efficace d’architectures NUMAPôle Systematic Paris-Region
 
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur Bittorrent
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur BittorrentOsis18_Cloud : DeepTorrent Stockage distribué perenne basé sur Bittorrent
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur BittorrentPôle Systematic Paris-Region
 
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...Pôle Systematic Paris-Region
 
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riot
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riotOSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riot
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riotPôle Systematic Paris-Region
 
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...Pôle Systematic Paris-Region
 
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...Pôle Systematic Paris-Region
 
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...Pôle Systematic Paris-Region
 
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)Pôle Systematic Paris-Region
 
PyParis 2017 / Un mooc python, by thierry parmentelat
PyParis 2017 / Un mooc python, by thierry parmentelatPyParis 2017 / Un mooc python, by thierry parmentelat
PyParis 2017 / Un mooc python, by thierry parmentelatPôle Systematic Paris-Region
 
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...Pôle Systematic Paris-Region
 
PyParis 2017 / Unicode and bytes demystified, by Boris Feld
PyParis 2017 / Unicode and bytes demystified, by Boris FeldPyParis 2017 / Unicode and bytes demystified, by Boris Feld
PyParis 2017 / Unicode and bytes demystified, by Boris FeldPôle Systematic Paris-Region
 
Py paris2017 / promises and perils in artificial intelligence, by Andreas Muller
Py paris2017 / promises and perils in artificial intelligence, by Andreas MullerPy paris2017 / promises and perils in artificial intelligence, by Andreas Muller
Py paris2017 / promises and perils in artificial intelligence, by Andreas MullerPôle Systematic Paris-Region
 
PyParis2017 / Incremental computation in python, by Philip Schanely
PyParis2017 / Incremental computation in python, by Philip SchanelyPyParis2017 / Incremental computation in python, by Philip Schanely
PyParis2017 / Incremental computation in python, by Philip SchanelyPôle Systematic Paris-Region
 
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx Pôle Systematic Paris-Region
 
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael Varoquaux
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael VaroquauxPyparis2017 / Scikit-learn - an incomplete yearly review, by Gael Varoquaux
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael VaroquauxPôle Systematic Paris-Region
 

Plus de Pôle Systematic Paris-Region (20)

Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick Moy
Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick MoyOsis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick Moy
Osis19_IoT: Proof of Pointer Programs with Ownership in SPARK, by Yannick Moy
 
Osis18_Cloud : Pas de commun sans communauté ?
Osis18_Cloud : Pas de commun sans communauté ?Osis18_Cloud : Pas de commun sans communauté ?
Osis18_Cloud : Pas de commun sans communauté ?
 
Osis18_Cloud : Projet Wolphin
Osis18_Cloud : Projet Wolphin Osis18_Cloud : Projet Wolphin
Osis18_Cloud : Projet Wolphin
 
Osis18_Cloud : Virtualisation efficace d’architectures NUMA
Osis18_Cloud : Virtualisation efficace d’architectures NUMAOsis18_Cloud : Virtualisation efficace d’architectures NUMA
Osis18_Cloud : Virtualisation efficace d’architectures NUMA
 
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur Bittorrent
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur BittorrentOsis18_Cloud : DeepTorrent Stockage distribué perenne basé sur Bittorrent
Osis18_Cloud : DeepTorrent Stockage distribué perenne basé sur Bittorrent
 
Osis18_Cloud : Software-heritage
Osis18_Cloud : Software-heritageOsis18_Cloud : Software-heritage
Osis18_Cloud : Software-heritage
 
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...
OSIS18_IoT: L'approche machine virtuelle pour les microcontrôleurs, le projet...
 
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riot
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riotOSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riot
OSIS18_IoT: La securite des objets connectes a bas cout avec l'os et riot
 
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
OSIS18_IoT : Solution de mise au point pour les systemes embarques, par Julio...
 
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...
OSIS18_IoT : Securisation du reseau des objets connectes, par Nicolas LE SAUZ...
 
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...
OSIS18_IoT : Ada and SPARK - Defense in Depth for Safe Micro-controller Progr...
 
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)
OSIS18_IoT : RTEMS pour l'IoT professionnel, par Pierre Ficheux (Smile ECS)
 
PyParis 2017 / Un mooc python, by thierry parmentelat
PyParis 2017 / Un mooc python, by thierry parmentelatPyParis 2017 / Un mooc python, by thierry parmentelat
PyParis 2017 / Un mooc python, by thierry parmentelat
 
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...
PyParis2017 / Python pour les enseignants des classes préparatoires, by Olivi...
 
PyParis 2017 / Unicode and bytes demystified, by Boris Feld
PyParis 2017 / Unicode and bytes demystified, by Boris FeldPyParis 2017 / Unicode and bytes demystified, by Boris Feld
PyParis 2017 / Unicode and bytes demystified, by Boris Feld
 
Py paris2017 / promises and perils in artificial intelligence, by Andreas Muller
Py paris2017 / promises and perils in artificial intelligence, by Andreas MullerPy paris2017 / promises and perils in artificial intelligence, by Andreas Muller
Py paris2017 / promises and perils in artificial intelligence, by Andreas Muller
 
PyParis2017 / Incremental computation in python, by Philip Schanely
PyParis2017 / Incremental computation in python, by Philip SchanelyPyParis2017 / Incremental computation in python, by Philip Schanely
PyParis2017 / Incremental computation in python, by Philip Schanely
 
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx
PyParis2017 / How to prepare data for NLP, by Loryfel Nunez.pptx
 
PyParis2017 / Performant python, by Burkhard Kloss
PyParis2017 / Performant python, by Burkhard KlossPyParis2017 / Performant python, by Burkhard Kloss
PyParis2017 / Performant python, by Burkhard Kloss
 
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael Varoquaux
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael VaroquauxPyparis2017 / Scikit-learn - an incomplete yearly review, by Gael Varoquaux
Pyparis2017 / Scikit-learn - an incomplete yearly review, by Gael Varoquaux
 

Dernier

6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...
6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...
6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...Dr Arash Najmaei ( Phd., MBA, BSc)
 
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...Boston Institute of Analytics
 
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...Thomas Poetter
 
INTRODUCTION TO Natural language processing
INTRODUCTION TO Natural language processingINTRODUCTION TO Natural language processing
INTRODUCTION TO Natural language processingsocarem879
 
Cyber awareness ppt on the recorded data
Cyber awareness ppt on the recorded dataCyber awareness ppt on the recorded data
Cyber awareness ppt on the recorded dataTecnoIncentive
 
Bank Loan Approval Analysis: A Comprehensive Data Analysis Project
Bank Loan Approval Analysis: A Comprehensive Data Analysis ProjectBank Loan Approval Analysis: A Comprehensive Data Analysis Project
Bank Loan Approval Analysis: A Comprehensive Data Analysis ProjectBoston Institute of Analytics
 
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...Boston Institute of Analytics
 
convolutional neural network and its applications.pdf
convolutional neural network and its applications.pdfconvolutional neural network and its applications.pdf
convolutional neural network and its applications.pdfSubhamKumar3239
 
modul pembelajaran robotic Workshop _ by Slidesgo.pptx
modul pembelajaran robotic Workshop _ by Slidesgo.pptxmodul pembelajaran robotic Workshop _ by Slidesgo.pptx
modul pembelajaran robotic Workshop _ by Slidesgo.pptxaleedritatuxx
 
Learn How Data Science Changes Our World
Learn How Data Science Changes Our WorldLearn How Data Science Changes Our World
Learn How Data Science Changes Our WorldEduminds Learning
 
Data Factory in Microsoft Fabric (MsBIP #82)
Data Factory in Microsoft Fabric (MsBIP #82)Data Factory in Microsoft Fabric (MsBIP #82)
Data Factory in Microsoft Fabric (MsBIP #82)Cathrine Wilhelmsen
 
Advanced Machine Learning for Business Professionals
Advanced Machine Learning for Business ProfessionalsAdvanced Machine Learning for Business Professionals
Advanced Machine Learning for Business ProfessionalsVICTOR MAESTRE RAMIREZ
 
Predictive Analysis for Loan Default Presentation : Data Analysis Project PPT
Predictive Analysis for Loan Default  Presentation : Data Analysis Project PPTPredictive Analysis for Loan Default  Presentation : Data Analysis Project PPT
Predictive Analysis for Loan Default Presentation : Data Analysis Project PPTBoston Institute of Analytics
 
What To Do For World Nature Conservation Day by Slidesgo.pptx
What To Do For World Nature Conservation Day by Slidesgo.pptxWhat To Do For World Nature Conservation Day by Slidesgo.pptx
What To Do For World Nature Conservation Day by Slidesgo.pptxSimranPal17
 
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdf
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdfEnglish-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdf
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdfblazblazml
 
Networking Case Study prepared by teacher.pptx
Networking Case Study prepared by teacher.pptxNetworking Case Study prepared by teacher.pptx
Networking Case Study prepared by teacher.pptxHimangsuNath
 
SMOTE and K-Fold Cross Validation-Presentation.pptx
SMOTE and K-Fold Cross Validation-Presentation.pptxSMOTE and K-Fold Cross Validation-Presentation.pptx
SMOTE and K-Fold Cross Validation-Presentation.pptxHaritikaChhatwal1
 
Conf42-LLM_Adding Generative AI to Real-Time Streaming Pipelines
Conf42-LLM_Adding Generative AI to Real-Time Streaming PipelinesConf42-LLM_Adding Generative AI to Real-Time Streaming Pipelines
Conf42-LLM_Adding Generative AI to Real-Time Streaming PipelinesTimothy Spann
 
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...KarteekMane1
 

Dernier (20)

6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...
6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...
6 Tips for Interpretable Topic Models _ by Nicha Ruchirawat _ Towards Data Sc...
 
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...
Data Analysis Project Presentation: Unveiling Your Ideal Customer, Bank Custo...
 
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...
Minimizing AI Hallucinations/Confabulations and the Path towards AGI with Exa...
 
INTRODUCTION TO Natural language processing
INTRODUCTION TO Natural language processingINTRODUCTION TO Natural language processing
INTRODUCTION TO Natural language processing
 
Cyber awareness ppt on the recorded data
Cyber awareness ppt on the recorded dataCyber awareness ppt on the recorded data
Cyber awareness ppt on the recorded data
 
Bank Loan Approval Analysis: A Comprehensive Data Analysis Project
Bank Loan Approval Analysis: A Comprehensive Data Analysis ProjectBank Loan Approval Analysis: A Comprehensive Data Analysis Project
Bank Loan Approval Analysis: A Comprehensive Data Analysis Project
 
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...
Data Analysis Project : Targeting the Right Customers, Presentation on Bank M...
 
convolutional neural network and its applications.pdf
convolutional neural network and its applications.pdfconvolutional neural network and its applications.pdf
convolutional neural network and its applications.pdf
 
Data Analysis Project: Stroke Prediction
Data Analysis Project: Stroke PredictionData Analysis Project: Stroke Prediction
Data Analysis Project: Stroke Prediction
 
modul pembelajaran robotic Workshop _ by Slidesgo.pptx
modul pembelajaran robotic Workshop _ by Slidesgo.pptxmodul pembelajaran robotic Workshop _ by Slidesgo.pptx
modul pembelajaran robotic Workshop _ by Slidesgo.pptx
 
Learn How Data Science Changes Our World
Learn How Data Science Changes Our WorldLearn How Data Science Changes Our World
Learn How Data Science Changes Our World
 
Data Factory in Microsoft Fabric (MsBIP #82)
Data Factory in Microsoft Fabric (MsBIP #82)Data Factory in Microsoft Fabric (MsBIP #82)
Data Factory in Microsoft Fabric (MsBIP #82)
 
Advanced Machine Learning for Business Professionals
Advanced Machine Learning for Business ProfessionalsAdvanced Machine Learning for Business Professionals
Advanced Machine Learning for Business Professionals
 
Predictive Analysis for Loan Default Presentation : Data Analysis Project PPT
Predictive Analysis for Loan Default  Presentation : Data Analysis Project PPTPredictive Analysis for Loan Default  Presentation : Data Analysis Project PPT
Predictive Analysis for Loan Default Presentation : Data Analysis Project PPT
 
What To Do For World Nature Conservation Day by Slidesgo.pptx
What To Do For World Nature Conservation Day by Slidesgo.pptxWhat To Do For World Nature Conservation Day by Slidesgo.pptx
What To Do For World Nature Conservation Day by Slidesgo.pptx
 
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdf
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdfEnglish-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdf
English-8-Q4-W3-Synthesizing-Essential-Information-From-Various-Sources-1.pdf
 
Networking Case Study prepared by teacher.pptx
Networking Case Study prepared by teacher.pptxNetworking Case Study prepared by teacher.pptx
Networking Case Study prepared by teacher.pptx
 
SMOTE and K-Fold Cross Validation-Presentation.pptx
SMOTE and K-Fold Cross Validation-Presentation.pptxSMOTE and K-Fold Cross Validation-Presentation.pptx
SMOTE and K-Fold Cross Validation-Presentation.pptx
 
Conf42-LLM_Adding Generative AI to Real-Time Streaming Pipelines
Conf42-LLM_Adding Generative AI to Real-Time Streaming PipelinesConf42-LLM_Adding Generative AI to Real-Time Streaming Pipelines
Conf42-LLM_Adding Generative AI to Real-Time Streaming Pipelines
 
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...
wepik-insightful-infographics-a-data-visualization-overview-20240401133220kwr...
 

PyData Paris 2015 - Track 1.1 Emmanuelle Gouillart

  • 1. Image processing with scikit-image Emmanuelle Gouillart Surface, Glass and Interfaces, CNRS/Saint-Gobain @EGouillart
  • 4. A flood of images several 108 images uploaded on Facebook each day
  • 5. A flood of images hundreds of terabytes of scientific data for scientific experiment http://sdo.gsfc.nasa.gov/
  • 6. A flood of images hundreds of terabytes of scientific data for scientific experiment http://sdo.gsfc.nasa.gov/ Image processing Manipulating images in order to retrieve new images or image characteristics (features, measurements, ...) Often combined with machine learning
  • 7. Why use scikit-image? Lots of excellent tools available: OpenCV (computer vision), ImageJ (GUI-based software), ITK, ... Native NumPy compatibility Gentle learning curve Variety of features Versatile - 3D-friendly
  • 8. Datasheet Package statistics http://scikit-image.org/ Release 0.11 (1 - 2 release per year) Available in most Scientific Python Distributions: Canopy, Anaconda, . . . Packaged on Ubuntu/Debian Among 1000 best ranked packages on PyPi Development model Mature algorithms Only Python + Cython code for easier maintainability Thorough code review by others: readability, PEP8, efficiency, ... Core team of 5 − 10 persons (close to applications)
  • 9. Manipulating images as numerical (numpy) arrays Pixels are arrays elements import numpy as np image = np. ones ((5, 5)) image [0, 0] = 0 image [2, :] = 0 x
  • 10. Manipulating images as numerical (numpy) arrays Pixels are arrays elements import numpy as np image = np. ones ((5, 5)) image [0, 0] = 0 image [2, :] = 0 x >>> coffee.shape (400, 600, 3) >>> red channel = coffee[..., 0] >>> image 3d = np.ones((100, 100, 100))
  • 11. NumPy-native: images as NumPy arrays NumPy arrays as arguments and outputs >>> from skimage import io , f i l t e r s >>> c am er a a rr ay = i o . imread ( ’ camera image . png ’ ) >>> type( c am er a a rr ay ) <type ’numpy . ndarray ’ > >>> c am er a a rr ay . dtype dtype ( ’ uint8 ’ ) >>> f i l t e r e d a r r a y = f i l t e r s . g a u s s i a n f i l t e r ( camera array , sigma =5) >>> type( f i l t e r e d a r r a y ) <type ’numpy . ndarray ’ > >>> import m a t p l o t l i b . p y p l o t as p l t >>> p l t .imshow( f i l t e r e d a r r a y , cmap= ’ gray ’ ) x
  • 12. An API relying mostly on functions skimage . f i l t e r s . g a u s s i a n f i l t e r (image , sigma , output = None, mode= ’ n ea re st ’ , c v a l =0, m u l t i c h a n n e l =None) Multi - d i m e n s i o n a l Gaussian filter Parameters ---------- image : array - l i k e input image ( g r a y s c a l e or c o l o r ) to filter. sigma : s c a l a r or sequence of s c a l a r s standard d e v i a t i o n f o r Gaussian k e r n e l . The standard d e v i a t i o n s of the Gaussian filter are g i v e n f o r each a x i s as a sequence , or as a s i n g l e number , in which case i t i s equal f o r all axes . output : array , o p t i o n a l The ‘‘ output ‘‘ parameter p a s s e s an a r r a y in which to s t o r e the filter output .
  • 13. Getting started: finding documentation
  • 15. Getting started: finding documentation
  • 16. Filtering: transforming image data skimage.filter, skimage.exposure, skimage.restoration
  • 18. Feature extraction followed by classification Combining scikit-image and scikit-learn Extract features (skimage.feature) Pixels intensity values (R, G, B) Local gradients More advanced descriptors: HOGs, Gabor, ... Train classifier with known regions here, random forest classifier Classify pixels
  • 22. Versatile use for 2D, 2D-RGB, 3D... >>> from skimage import measure >>> l a b e l s 2 d = measure . l a b e l ( image 2d ) >>> l a b e l s 3 d = measure . l a b e l ( image 3d ) x
  • 23. Try it out! http://scikit-image.org/ Feedback welcome github.com/scikit-image/scikit-image Please cite the paper