简体   繁体   中英

Shape recognition Neural Network poor performance

I am trying to implement a Neural Network for shape recognition - actually those shapes are letters. I would like to implement this network to work on Fourier Descriptors retrieved from shapes. My problem is that, whatever I do, change number of hidden layer neurons, use different training function and so on, I always get performance of Network more or less equal to 0.25. I've been struggling with this for a couple of days now and I really hit a brick wall here, so I would appreciate any help on that matter.

images = readImages(path, str_format);
Tindex = 1;

T = zeros(size(images,1),size(images,1)/4);
[F Z] = GetLetterDescriptors(images{1});
descriptors = zeros(length(F),size(T,1));
for i = 1 : size(images,1)    
    [F, Z] = GetLetterDescriptors(images{i});
    descriptors(:,i) = F;
    T(i,Tindex) = 1;
    Tindex = Tindex + 1;
end


net = feedforwardnet(35);
T = T';
net.layers{2}.transferFcn = 'logsig';
net.layers{1}.transferFcn = 'logsig';
net = trainscg(net,descriptors,T,nnMATLAB);
y = sim(net,descriptors,[],[]);
perf = perform(net,T,y);

F are real values Fourier Descriptors.

I managed to solve this problem actually quite some time ago but I've totally forgotten about this post. To solve this particullar problem I had to use patternet function instead of feedforwardnet , then the net could successfully learn in couple of epochs.

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM