Image Regression using .mat Files and a datastore
古いコメントを表示
I would like to train a CNN for image regression using a datastore. My images are stored in .mat files (not png or jpeg). This is not image-to-image regression, rather an image to single regression label problem. Is it possible to do this using a datastore, or at least some other out-of-memory approach?
採用された回答
その他の回答 (2 件)
Johanna Pingel
2019 年 4 月 29 日
編集済み: Johanna Pingel
2019 年 4 月 29 日
0 投票
This examples shows image to single regression label: https://www.mathworks.com/help/deeplearning/examples/train-a-convolutional-neural-network-for-regression.html
I've used a .mat to imagedatastore conversion here:
imds = imageDatastore(ImagesDir,'FileExtensions','.mat','ReadFcn',@matRead);
function data = matRead(filename)
inp = load(filename);
f = fields(inp);
data = inp.(f{1});
2 件のコメント
Matthew Fall
2019 年 4 月 29 日
tianliang wang
2021 年 4 月 28 日
Is it more convenient to use mat files as the training set for the images to vectors regression ?
Lykke Kempfner
2019 年 8 月 16 日
0 投票
I have same problem.
I have many *.mat files with data that can not fit in memory. You may consider the files as not standard images. I have the ReadFunction for the files. I wish to create a datastore (?) where each sample are associated with two single values and not a class.
Are there any solution to this issue ?
2 件のコメント
Tomer Nahshon
2020 年 1 月 22 日
Same here
tanfeng
2020 年 10 月 12 日
You could try this
tblTrain=table(X,Y)
net = trainNetwork(tblTrain,layers,options);
カテゴリ
ヘルプ センター および File Exchange で Deep Learning Toolbox についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!