train a neural network in matlab

1 view (last 30 days)
rana
rana on 21 May 2013
Commented: Saud Alramzi on 20 Apr 2016
my project is about facial expression recognition.
for the classification of the emotions i want to train a neural network having an input 20 points taken from the whole face by the vision.CornerDetector function. so each point feature is represented by its X and its Y.
my database contain 110 smiling photos and 95 neutral ones. so that, the whole matrix of smiling faces, for example, has a size of 20x220.
any ideas about how to train my neural network using these features?
  1 Comment
Saud Alramzi
Saud Alramzi on 20 Apr 2016
Hello,
I am working on the same project, did it work for you by chance?
Thanks, Saud

Sign in to comment.

Accepted Answer

Greg Heath
Greg Heath on 31 May 2013
Use patternnet
Ns = 110, Nn = 95, N=Ns+Nn = 205 (NOT 220), I = 20, O = 2
[ I N ] = size(input)
[ O N ] = size(target)
with
target = [ targets targetn ]
targets = repmat([1;0],1,Ns)
targetn = repmat([0;1],1,Nn)
Hope this helps.
Thank you for formally accepting my answer
Greg

More Answers (0)

Categories

Find more on Sequence and Numeric Feature Data Workflows in Help Center and File Exchange

Community Treasure Hunt

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

Start Hunting!