Professional Documents
Culture Documents
Network (CNN)
Day 3
Working with Real World
CNN Architectures
Image dataset
?
MNIST = Mixed National Institute of Standards and Technology - Download the dataset at http://yann.lecun.com/exdb/mnist/
Working
with real
world
data
How to
organize image
data?
Visualize
image data
How to
organize image
data?
Visualize
image data
How to
organize image
data?
Loading Images
for training
Working with Visualize
different image data
image Sizes
How to
organize image
data?
Loading Images
for training
Working with Visualize
different image data
image Sizes
How to
organize image
data?
Class # 1 folder
Class # 2 folder
Class # 3 folder
Training_data folder
Class # 4 folder
Class # 5 folder
main_folder
Class # 1 folder
Class # 2 folder
...
Test_data folder Class # 3 folder
...
Class # 4 folder
...
Class # 5 folder
...
Image files
Class # 1 folder
Class # 2 folder
Class # 3 folder
image_data folder
Class # 4 folder
Class # 5 folder
Another approach
Another approach
Store info about folder/images in csv file
Visualizing image
Using Keras image class
Feeding
images for
training
Daisy
Dandelion
Convert image
Read image Resize image,
data to Numpy Neural Network Rose
from disk if needed
array
Sunflower
Tulip
Daisy
Dandelion
Convert image
Read image Resize image,
data to Numpy Neural Network Rose
from disk if needed
array
Sunflower
Tulip
Memory Error!!!
1,000s of Images available on Disk
1,000s of Images available on Disk
Batch Generator
How do we
get more
data?
Image Augmentation
Creating more images from existing Image
Original image New image
Horizontal flip
Original image New image
Shearing image
Original image New image
Zoomed image
Original image New image
ImageDataGenerator
Building an image classifier using
Image Augmentation