Azzera filtri
Azzera filtri

How to change plotting options in deep learning networks?

5 visualizzazioni (ultimi 30 giorni)
Fatma Diab
Fatma Diab il 11 Nov 2021
Risposto: Jaynik il 28 Giu 2024 alle 11:36
I have trained a deep learning network, and the training progress graph appeared from trainNetwork function. This curve shows training accuracy, smoothed training accuracy, and validation accuracy. I need to remove smoothed training accuracy curve from the graph. Could you please help me? https://ch.mathworks.com/help/deeplearning/ref/trainingoptions.html?fbclid=IwAR0zK3F4pzPV_DqbAkRk_Ou7CmN3viJMXVx-ovnEmLfvc_M8dNWw3vZvMPs

Risposte (1)

Jaynik
Jaynik il 28 Giu 2024 alle 11:36
Hi,
There is no direct way to remove the smoothed training accuracy curve from the graph. If possible, you can upgrade MATLAB and use the "trainnet" function introduced in R2023a. The plots don't provide the smoothed accuracy. Since R2024a, the "trainNetwork" function is not recommended.
Alternately, if it is possible to use custom loops for training the data, you can use the "trainingProgressMonitor" object. It allows for creating animated custom metric plots and record custom metrics during training. Following is an example of using "trainingProgressMonitor":
monitor = trainingProgressMonitor;
addMetrics(monitor, ["TrainingAccuracy", "ValidationAccuracy"]);
% Training loop example
for epoch = 1:numEpochs
% Perform training and validation steps here
% Update custom metrics
recordMetrics(monitor, epoch, ["TrainingAccuracy", trainingAccuracy, "ValidationAccuracy", validationAccuracy]);
end
% Display the training progress monitor
show(monitor);
You can refer the following documentation links to learn about these functions:
Hope this helps!

Categorie

Scopri di più su Sequence and Numeric Feature Data Workflows in Help Center e File Exchange

Prodotti


Release

R2020a

Community Treasure Hunt

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

Start Hunting!

Translated by