deep network designer, how do I test a trained network against a new dataset? I am able to see the predictions for all the images?

2 ビュー (過去 30 日間)
Hi,
So first of all I am not a computer scientist, just starting to use MatLab.
I have tried deep network designer to classify between 3 classes. Saved the script, the results etc. Now I want to use this trained network on a new dataset and also I really need to see the results for each imagine in the dataset. Is this possible and is anyone able to help?
Thanks a lot
Andreea

回答 (1 件)

David Willingham
David Willingham 2022 年 5 月 13 日
Hi Andreea,
Firstly, glad to hear your starting your journey of deep learning in MATLAB!
Your code will likely look like this:
imds = imageDatastore('MyImageFolder', ...
'IncludeSubfolders',true, ...
'LabelSource','foldernames');
[YPred,scores] = classify(mytrainedNet,imds);
idx = randperm(numel(imds.Files),4);
figure
for i = 1:4
subplot(2,2,i)
I = readimage(imds,idx(i));
imshow(I)
label = YPred(idx(i));
title(string(label));
end
I would also recommend studying this example. It shows the suggested workflow for performing transfer learning :

カテゴリ

Help Center および File ExchangeStatistics and Machine Learning Toolbox についてさらに検索

製品


リリース

R2021b

Community Treasure Hunt

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

Start Hunting!

Translated by