Self Organizing Map (SOM) plot interval saving process

4 ビュー (過去 30 日間)
ChoHwan Oh
ChoHwan Oh 2020 年 4 月 27 日
回答済み: Srivardhan Gadila 2020 年 5 月 3 日
I want to save the figure of SOM (ex:plotsompos) according to the iteration(or epoch).
My code is written in below, and I want to save the plotsompos according to the epoch (at epoch 100, 200, 300, 400).
However, I don't know the way, and downward code just give the plotsompos at epoch 1000.
Is there any way to save the figure according to the epoch?
net = selforgmap([dimension1,dimension2]);
net.trainParam.epochs = 1000;
[net,tr] = train(net,X3);
figure(); plotsompos(net,X3); title('whole')

回答 (1 件)

Srivardhan Gadila
Srivardhan Gadila 2020 年 5 月 3 日
From the documentation of selforgmap, Neural Network Object Properties & Neural Network Subobject Properties I cannot find any inbuilt method to plot and save in between epochs. As a workaround you can write a for loop to get the plots at required intervals as follows:
net = selforgmap([dimension1,dimension2]);
net.trainParam.epochs = 100;
for i=1:10
[net,tr] = train(net,X3);
figure(); plotsompos(net,X3); title("plot after "+num2str(i*100)+" epochs")
end

カテゴリ

Help Center および File ExchangeSequence and Numeric Feature Data Workflows についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by