what is difference between augmentedImageDatastore and ImageDatastore

7 ビュー (過去 30 日間)
Simon
Simon 2020 年 5 月 25 日
If an ImageDatastore (e.g., imdsTrain) object has the class/label information, where is the class/label info in the augmentedImageDatastore that was derived using augmentedImageDatastore
(e.g., augmentedImageDatastore(inputSize(1:2),imdsTrain, ...
'DataAugmentation',imageAugmenter)
)?
Many thanks for your help.

採用された回答

Simon
Simon 2020 年 5 月 26 日
Soved: I found Labels is inside augimdsTrain. But it's a private parameter, can be seen using [data,info]=read(augimdsTrain).
Thanks for those replied and viewed.
  2 件のコメント
Prasobhkumar P. P.
Prasobhkumar P. P. 2020 年 12 月 5 日
Awesome, searched almost half day for this. Thank you so much
Oluwatobi John Oluwafemi
Oluwatobi John Oluwafemi 2021 年 2 月 21 日
I needed this!

サインインしてコメントする。

その他の回答 (1 件)

Image Analyst
Image Analyst 2020 年 5 月 25 日
With the augmented version you have to give it instructions how to modify the original image, like rotate it or scale it. So it creates modified images on the fly from original images, giving you essentially a much larger training set.
  1 件のコメント
Simon
Simon 2020 年 5 月 26 日
Hi MVP, really thank you for answering my question. However, maybe I didnot make the question clear, so I try to state it again below to see if I could get more accurate answer:
I have
imdsTrain =
ImageDatastore with properties:
Files: {
' ...\MerchData\MathWorks Cap\Hat_0.jpg';
' ...\MerchData\MathWorks Cap\Hat_123.jpg';
' ...\MerchData\MathWorks Cap\Hat_148.jpg'
... and 52 more
}
Labels: [MathWorks Cap; MathWorks Cap; MathWorks Cap ... and 52 more categorical]
AlternateFileSystemRoots: {}
ReadSize: 1
ReadFcn: @readDatastoreImage
After I ran
augimdsTrain = augmentedImageDatastore(net.Layers(1).InputSize(1:2),imdsTrain, ...
'DataAugmentation',imageAugmenter);
I got:
augimdsTrain =
augmentedImageDatastore with properties:
NumObservations: 55
Files: {55×1 cell}
AlternateFileSystemRoots: {}
MiniBatchSize: 128
DataAugmentation: [1×1 imageDataAugmenter]
ColorPreprocessing: 'none'
OutputSize: [224 224]
OutputSizeMode: 'resize'
DispatchInBackground: 0
Then question is:
The original Labe information in imdsTrain is not shown in augimdsTrain. Is it because I use the function augmentedImageDatastore wrongly, or I suppose to get the label info from another variable? I do need to know/see where the label/classification is so I can program further.
Many Thanks!

サインインしてコメントする。

カテゴリ

Help Center および File ExchangeImage Data Workflows についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by