Effacer les filtres
Effacer les filtres

Semantic Segmentation Using Deep Learning example error

2 vues (au cours des 30 derniers jours)
woong
woong le 2 Oct 2023
There is a problem executing the following code.
There's no problem here
pretrainedURL = 'https://ssd.mathworks.com/supportfiles/vision/data/deeplabv3plusResnet18CamVid.zip';
pretrainedFolder = fullfile(tempdir,'pretrainedNetwork');
pretrainedNetworkZip = fullfile(pretrainedFolder,'deeplabv3plusResnet18CamVid.zip');
if ~exist(pretrainedNetworkZip,'file')
mkdir(pretrainedFolder);
disp('Downloading pretrained network (58 MB)...');
websave(pretrainedNetworkZip,pretrainedURL);
end
unzip(pretrainedNetworkZip, pretrainedFolder)
That's where the problem comes from
pretrainedNetwork = fullfile(pretrainedFolder,'deeplabv3plusResnet18CamVid.mat');
data = load(pretrainedNetwork); % !! The variable 'metrics' stored in semantic Segmentation Metrics cannot be instantiated as an object and is read as unit32
There's an error here too
net = data.net; % The variable 'net' originally stored in the DAG Network cannot be instantiated as an object and is read as unit32.
.....
classes = string(net.Layers(end).Classes) % This type of variable does not support point indexing.
What's wrong with you?
How can we solve it..

Réponse acceptée

檮杌
檮杌 le 3 Oct 2023
Hi,
Your issue is not reproducible in my end.
Are you sure that you have successfully installed Deep Learning Toolbox? Your MATLAB does not recognize "semanticSegmantationMetrics" or "DAGNetwork" as objects but treats them as "uint32". As indicated in the doc, the example requires not only Computer Vision Toolbox but also Deep Learning Toolbox to begin with. Please check the output of "ver" and see if Deep Learning Toolbox is correctly installed.

Plus de réponses (0)

Produits


Version

R2023b

Community Treasure Hunt

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

Start Hunting!

Translated by