フィルターのクリア

how to set the dimensions for a SOM map?

1 回表示 (過去 30 日間)
maxina dialin
maxina dialin 2012 年 10 月 6 日
While using SOM for clustering an image using the function net=selforgmap([d1,d2]) How to set the values for d1 and d2?

回答 (1 件)

Greg Heath
Greg Heath 2012 年 10 月 7 日
編集済み: Greg Heath 2012 年 10 月 7 日
1. Plot the projection of the data on the dominant PCA plane to get a "good feel" for the data:
a. lookfor 'principal component'
b. Test on the iris_dataset example
2. Create and train a SOM net using defaults:
net = selforgmap;
3. Look at the 6 default training plots. PLOTSOMND, PLOTSOMHITS, and PLOTSOMPOS are probably the most useful for estimating a better choice for [d1,d2].
Hope this helps.
Thank you for formally accepting my answer.
  1 件のコメント
Greg Heath
Greg Heath 2012 年 10 月 7 日
close all, clear all, clc, plt=0;
% x = iris_dataset;
x = simplecluster_dataset;
whos
[ I N ] = size(x) % [ 2 1000 ]
' 1. PROJECT THE DATA ON THE DOMINANT PRINCIPAL COMPONENT PLANE '
plt = plt+1; figure(plt)
plot(x(1,:),x(2,:),'o')
'2. CREATE AND TRAIN A MAP USING DEFAULTS'
net = selforgmap; %default is 8X8
net.IW{:} % Empty matrix: 0-by-64
net.LW{:} % []
net.b{:} % []
net = train(net,x);
net.IW % [64x2 double]
net.LW % { [] }
net.b % { [] }
'3. VIEW THE 6 DEFAULT SOM PLOTS. THE LAST 3 ARE THE MOST USEFUL FOR EVALUATING PERFORMANCE: '
plt = plt+1; figure(plt)
plotsomtop(net) % SOM Topology
plt = plt+1; figure(plt)
plotsomnc(net) % SOM Neighbor Connections
plt = plt+1; figure(plt)
plotsomplanes(net) % SOM Input Planes
plt = plt+1; figure(plt)
plotsomnd(net,x) %(The Neighbor Weight Distances)
plt = plt+1; figure(plt)
plotsomhits(net,x) %(SOM Sample Hits)
plt = plt+1; figure(plt)
plotsompos(net,x) %(SOM Weight Positions))
'4. ASSIGN EACH INPUT TO ONE OF THE d1*d2 SOM CENTERS'
y = net(x); % 64 X 1000
classes = vec2ind(y); % 1 X 1000
example = classes(1:20)

サインインしてコメントする。

Community Treasure Hunt

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

Start Hunting!

Translated by