Upload
others
View
6
Download
5
Embed Size (px)
Citation preview
1© 2015 The MathWorks, Inc.
Working with Large Sets of Images in MATLAB Just
Got Easier
Avi Nehemiah
3
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
2. Can I find patterns or models to represent my image data?
3. How do I test and visualize my algorithm on many images?
4. What if my desktop or laptop doesn’t have enough computing power?
5. What if my data is too big to fit into memory?
Goal: Show you new functionality in MATLAB to augment existing workflows to
solve these challenges
4
Problem : How to Recognize/Categorize Cars ?
Lightning Mater
Nigel SpareO
5
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet
2. Can I find patterns or models to represent my image data?
3. How do I test and visualize my algorithm on many images?
4. What if my desktop or laptop doesn’t have enough computing power?
5. What if my data is too big to fit into memory?
6
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet
2. Can I find patterns or models to represent my image data?
3. How do I test and visualize my algorithm on many images?
4. What if my desktop or laptop doesn’t have enough computing power?
5. What if my data is too big to fit into memory?
7
Machine Learning
A machine learning algorithm takes examples of inputs and outputs associated
with a task and produces a program that can perform the task.
Hand
Written
Program
If brightness > 0.5
then ‘hat’
If edge_density < 4 and
major_axis > 5
then “boat”
…
‘boats’
‘mugs’
‘hats’
Machine
Learning
𝑚𝑜𝑑𝑒𝑙 = 𝑓𝑖𝑡𝑐svm (image_features, label)
‘boats’
‘mugs’
‘hats’
Computer
Vision
8
Machine Learning Workflow Using Images
Training Data Feature
Extraction
Learning or
Modelling
Classifier / Model ‘Lightning’
Input Image Feature
ExtractionClassification
9
Machine Learning Workflow Using Images
Training Data Feature
Extraction
Learning or
Modelling
Classifier / Model ‘Lightning’
Input Image Feature
ExtractionClassification
imageSet bagOfFeatures
bagOfFeatures
classificationLearner
10
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
4. What if my desktop or laptop doesn’t have enough computing power?
5. What if my data is too big to fit into memory?
11
Other Applications of Same Workflow
Detection and Location
Anomaly Detection/ Verification
‘yes’ ‘no’
‘pass’ ‘fail’
12
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
4. What if my desktop or laptop doesn’t have enough computing power?
5. What if my data is too big to fit into memory?
13
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
– Image Batch Processor App
4. What if my desktop or laptop doesn’t have enough computing power?
5. Can I acquire large sets of images using MATLAB ?
14
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
– Image Batch Processor App
4. What if my desktop or laptop doesn’t have enough computing
power?
5. What if my data is too big to fit into memory?
15
Parallel Computing Toolbox
Parallel Computing with MATLAB
MATLAB
MATLAB Distributed Computing Server
16
17
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
– Image Batch Processor App
4. What if my desktop or laptop doesn’t have enough computing
power?
– Parallel Computing Toolbox , MATLAB Distributed Computing Server
5. What if my data is too big to fit into memory?
18
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
– Image Batch Processor App
4. What if my desktop or laptop doesn’t have enough computing power?
– Parallel Computing Toolbox , MATLAB Distributed Computing Server
5. What if my data is too big to fit into memory?
19
Big Data Stored on Hadoop
On Your Workstation
• Access, explore, and analyze
out-of-memory data
• Prototype MapReduce based
algorithms
• Access portions of data sets
on HDFS
Connected to Hadoop
• Run algorithms on Hadoop
against data in HDFS
Production Hadoop
• Create applications or
components that
execute on Hadoop
Easily migrate programs from workstation to Hadoop
MATLAB Distributed
Computing Server
MATLAB Compiler
20
Scaled Analysis
Explore
Prototype
Access Share/Deploy
ComplexityEmbarrassingly
Parallel
Non-Partitionable
MapReduce
Distributed Memory
SPMD
Load,
Analyze,
Discard
datastore, parfor
Scale
out-of-memory
in-memory
21
Challenges Posed by Large Sets of Images
1. How do I import several thousand images into MATLAB?
– imageSet to manage large collections of images
2. Can I find patterns or models to represent my image data?
– Computer Vision System Toolbox, Statistics and Machine Learning Toolbox
3. How do I test and visualize my algorithm on many images?
– Image Batch Processor App
4. What if my desktop or laptop doesn’t have enough computing power?
– Parallel Computing Toolbox , MATLAB Distributed Computing Server
5. What if my data is too big to fit into memory?
– MapReduce, distributed arrays, SPMD, Hadoop
22
Thank You !