How to add an image augmentation layer?

3 visualizzazioni (ultimi 30 giorni)
Mona
Mona il 3 Nov 2017
Hi, I am using MATLAB for deep learning. And was wondering how to add an image augmentation layer after the imageInputLayer. I have read that I can use "Create Custom Layer with Learnable Parameters". But I am not sure how to do that. Anyone already tried it?
All I need is to be able to manipulate my input batches right before they are used for training. Specifically, I want to train the VGG-19 from scratch. And there every image is supposed to be rescaled randomly, cropped randomly, and reflected randomly at every epoch.
I found that
imageDataAugmenter
can do the trick for re-scaling the images for example. But the scaling the DataAugmenter applies messes up the aspect ratio of the images because there is an X-scale and Y-scale.
Any idea?
Thank you in advance!

Risposte (0)

Categorie

Scopri di più su Image Data Workflows in Help Center e File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by