ANN MLP training fase - questions

asked 2016-04-16 06:42:32 -0600

HugoM gravatar image

Hello I am new at ML and I have some questions. My objective is to able to recognize facial expressions.

I using 10k images for training - 32x32 gray scale image

  1. Read the images

  2. I passed the images to Mat. each image in a row

  3. I passed the labels to Mat.
  4. I used a PCA with size 1000 for extract feacture
  5. I passed the images and labels to the ANN MLP

There isn't any information about how the training is going. There is some way that show me any information.?

Second, the training time now is near of 17 hours. Too much time no? Is possible that ANN be stuck?

Third, 1000 neurons for hidden layer are fine or it are to much? any suggestion?

Fourth, there is any way to use the ANN MLP in a GPU?

int size = trainData.cols; //

// create 3 layers for the neural network
layers.row(0) = Scalar(size);
layers.row(1) = Scalar(1000); // hidden layer
layers.row(2) = Scalar(7); // Seven classes, one for each basic facial expression

criteria.max_iter = 1000;
criteria.epsilon = 0.00001f;
criteria.type = CV_TERMCRIT_ITER | CV_TERMCRIT_EPS;

params.train_method = CvANN_MLP_TrainParams::BACKPROP;
params.bp_dw_scale = 0.1f;
params.bp_moment_scale = 0.1f;
params.term_crit = criteria;
mlp.create(layers, CvANN_MLP::SIGMOID_SYM);
edit retag flag offensive close merge delete

Comments

Some remarks:

  • Since ANN MLP got developed when noone was using deconvolution yet, there is no way of seeing what it does inside, at least not untill it has been trained.
  • ANN MLP can train long, keep in mind that it work from a pixel base and then works up to regions using a convolution approach. 17 hours is quite fast if it would finish for 10k images, my guess it will take at least 48 hours, and still then learning a complete new neuron network in 2 days is fast depending on your system!
StevenPuttemans gravatar imageStevenPuttemans ( 2016-04-18 08:57:12 -0600 )edit