working with large sets of images in matlab just got easier...7 machine learning a machine learning...

25
1 © 2015 The MathWorks, Inc. Working with Large Sets of Images in MATLAB Just Got Easier Avinash Nehemiah Product Marketing Manager: Computer Vision

Upload: others

Post on 08-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

1© 2015 The MathWorks, Inc.

Working with Large Sets of Images in MATLAB Just

Got Easier

Avinash Nehemiah

Product Marketing Manager: Computer Vision

Page 2: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

2

Why Are We Talking About Large Sets of Images ?

100 hours of video uploaded to YouTube per minute1

Explosive increase in number of imaging devices

– Webcams

– Smartphone Cameras

– IP Cameras

– Industrial Cameras

1- KPCB 2013 Internet Trends http://www.kpcb.com/blog/2013-internet-trends

Page 3: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

Goal: Show you new functionality in MATLAB to augment existing workflows to

solve these challenges

Page 4: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

4

Problem: Image Category Classification

Given a large set of images of cars, planes and motorbikes

How to model the data to recognize which category an image belongs to ?

Data from Caltech 101: L. Fei-Fei, R. Fergus and P. Perona. Learning generative visual models from few training examples: an incremental Bayesian

approach tested on 101 object categories. IEEE. CVPR 2004, Workshop on Generative-Model Based Vision. 2004

http://www.vision.caltech.edu/Image_Datasets/Caltech101/

Image

Processing

Algorithm

‘motorbike’

Page 5: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

Page 6: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

Page 7: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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

Page 8: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

9

Machine Learning Workflow Using Images

Training Data Feature

Extraction

Learning or

Modelling

Training

Classifier / Model ‘hat’

Input Image Feature

ExtractionClassification

Classification

Page 9: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

10

Machine Learning Workflow Using Images

Training Data Feature

Extraction

Learning or

Modelling

Classifier / Model ‘hat’

Input Image Feature

ExtractionClassification

imageSet

imageSet

bagOfFeatures

bagOfFeatures

trainImageCategoryClassifier

evaluate

Page 10: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

11

Everyday Applications of Machine Learning

Page 11: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

Page 12: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

13

Additional Algorithms Available*

Cascade Object Detector

– Pre-trained models for faces, facial

features etc.

– Framework for training

People Detector

Optical Character Recognition

* Requires Computer Vision System Toolbox

Page 13: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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?

4. What if my desktop or laptop doesn’t have enough computing power?

5. Can I acquire large sets of images using MATLAB ?

Page 14: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

15

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 ?

Page 15: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

16

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 ?

Page 16: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

17

Parallel Computing Toolbox

Parallel Computing with MATLAB

MATLAB

MATLAB Distributed Computing Server

Page 17: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

Page 18: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

19

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. Can I acquire large sets of images using MATLAB ?

Page 19: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

20

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 20: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 21: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

22

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 22: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

23

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 23: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

24

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 24: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

25

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. Can I acquire large sets of images using MATLAB ?

– Hardware support packages: IP cameras, webcams, low-cost hardware, industrial

cameras

Page 25: Working with Large Sets of Images in MATLAB Just Got Easier...7 Machine Learning A machine learning algorithm takes examples of inputs and outputs associated with a task and produces

26

Thank You !