forum.alglib.net
http://forum.alglib.net/

Problems using the neural networks
http://forum.alglib.net/viewtopic.php?f=2&t=54
Page 1 of 1

Author:  joamaca [ Thu Sep 02, 2010 12:34 pm ]
Post subject:  Problems using the neural networks

Hi,
i'm a research engineer and I'm trying to use a neural network to classify different patterns of data.
My problem is that i don't know how use the mlptrainlm function. I can?t find the format of the input data.

My reference is the Neural Netwoor Toolbox of Matlab.
In Matlab, there are a matrix with the data (rows are the features and columns the different samples)
and another matrix with the targets (as many rows as classes and columns as samples), and both matrix are inputs to the training.
Is similar with mlptrainlm?
Only there is a double[,] xy variable that i don't know what represent. Is data or targets?


Another question: if i want that the outputs of the NN are between [0,1],
must use mlpcreater0 with A=0 and B=1, or it?s controller in other part?


Please, help me.
Thanks

Author:  Sergey.Bochkanov [ Thu Sep 02, 2010 3:15 pm ]
Post subject:  Re: Problems using the neural networks

1. No, MPLTrain accepts data in another format: one row = one sample. First NVars columns - inputs, next column (or columns) - outputs. You can read more at http://www.alglib.net/dataanalysis/gene ... ciples.php So both inputs and outputs are packed into one matrix.

2. yes, you are right. No other tuning is required.

Author:  joamaca [ Thu Sep 02, 2010 3:28 pm ]
Post subject:  Re: Problems using the neural networks

Thanks to be so quick.

Author:  alkop [ Fri Jan 07, 2011 11:36 am ]
Post subject:  Re: Problems using the neural networks

Thanks for library! I hope it will save me of superfluous efforts, but there were some questions: the data format is not too clear, since parametre NVars is not used at neural network creation, and are used NIn, NOut and NPoints (alglib.mlpbase.mlpcreate1(nIn, nHid, nOut, network)). Whether correctly I have understood, what parametre NPoints corresponds to quantity of input vectors?
For example, if I use the following data set:
double [] inputs = {{0.1, 0.2, 0.0}, {0.3, 0.4, 1.0}, {0.5, 0.6, 0.0}, {0.7, 0.8, 1.0}};
whether it means, what first two units of input vectors will be used as independent variables, and the third - as dependent (class number)?
Correct me if I am not right.
And some more questions:
1. Whether it is possible to use your neural networks for clusterization or nonlinear lowering of dimension (a network with a narrow throat)? Such networks are trained on the inputs (training without the teacher), i.e. NIn = NOut. But I did not manage to create such network because in your algorithm there is a limitation: jmax = nin+nout-1 (in function mlpbase.mlpinitpreprocessor) and if NIn = NOut creating an exception. Whether I can construct such network and how correctly to specify data format in such case?
2. Whether it is possible to save the trained network and then to restore it for a reuse? If it is impossible, I should save what parametres of a neural network (weight, neurons or something else) to use the trained network further?
I thank for the answer. I think, answers to these questions will help not only me

Page 1 of 1 All times are UTC
Powered by phpBB © 2000, 2002, 2005, 2007 phpBB Group
http://www.phpbb.com/