training-progress plots not available
4 vues (au cours des 30 derniers jours)
Afficher commentaires plus anciens
Hi all,
I'm training a dlnetwork and want to plot the accuracy, FScore and Loss as it trains. However only Loss is showing as follows:

My training options are as follows:
options = trainingOptions("sgdm",...
LearnRateSchedule="piecewise",...
LearnRateDropPeriod=6,...
LearnRateDropFactor=0.1,...
Momentum=0.9,...
InitialLearnRate=1e-2,...
L2Regularization=0.005,...
ValidationData=dsVal,...
MaxEpochs=18,...
MiniBatchSize=4,...
Metrics = ["accuracy","fscore"], ...
Shuffle="every-epoch",...
CheckpointPath=tempdir,...
VerboseFrequency=10,...
ValidationPatience=4, ...
Plots="training-progress");
3 commentaires
colordepth
le 15 Avr 2025
Please share the values of the metrics recorded in your 'info' variable. I wonder if they are being stored as NaN for some reason.
tHistory = info.TrainingHistory; % This table contains the recorded training metrics.
disp(tHistory.TrainingAccuracy);
I cannot imagine why it would contain NaN values, or why the accuracy would not be calculated at each training iteration. This may be worth an investigation though, please share the output of the above commands.
Réponses (1)
Adarsh
le 2 Mai 2025
I understand that you are following the “https://uk.mathworks.com/help/deeplearning/ug/semantic-segmentation-using-deep-learning.html”
Example to train a segmentation model in MATLAB and facing issues with the “Metric” attribute in the “trainingOptions” object.
However, in a segmentation model, the outputs are pixel-wise results other than just class-based probabilities that are expected in a general classification problem.
From what I found in the documentation, “accuracyMetric” is designed for general classification tasks not for pixel-wise classification tasks, So when the output of the model is passed for calculation of accuracy it receives an pixel-wise array of 3 channel outputs rather than a single array of class-based probabilities, hence due to this inconsistency the Accuracy and F1-Score plots are empty.
For this reason, the metrics for segmentation models is computed in a different manner which is shown in the example that you are following.
In the example, “semanticseg” function is used to run the inference and it returns a “pixelLabelDatastore” object which is then passed to “evaluateSemanticSegmentation” function for the computation of the Metrics required.
The “evaluateSemanticSegmentation” returns the metrics such as “accuracy”, “bfscore”, “global-accuracy”, “iou” and “weighted-iou”.
For more information, you can refer to the following documentation links:
- https://www.mathworks.com/help/releases/R2024b/deeplearning/ref/deep.metric.accuracymetric.html
- https://www.mathworks.com/help/releases/R2024b/vision/ref/semanticsegmentationmetrics.html
- https://www.mathworks.com/help/releases/R2024b/vision/ref/pixellabeldatastore.html
- https://www.mathworks.com/help/releases/R2024b/vision/ref/evaluatesemanticsegmentation.html
I hope this helps!
0 commentaires
Voir également
Catégories
En savoir plus sur Image Data Workflows dans Help Center et File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!