Thread Subject: How??

Subject: How??

From: chris Austin

Date: 9 Feb, 2010 16:00:22

Message: 1 of 1

Hi guys,
I am a newbie trying to get my head round matlab for my project. Here i am trying to train a feedforward Neural net that takes a binary image, i set the target as stated below but when i call the train function it displays the error message..

??? Error using ==> network.train at 146
Targets are incorrectly sized for network.
Matrix must have 1 columns.

here is my tiny implimentation. please kindly tell me what i am doing wrong or what i should do.

img=imread('1000001.png'); %160-by-120 binary image size(basically just black and white)
target1 = [0 0 0 0 0 1 0 0 0 0 0];
ims = double(img);
[r, c] = size(img);

im = reshape(ims, r*c, 1);

nets = newff(im,target1, 10);

net = train(nets, im, target1);

Tags for this Thread

Everyone's Tags:

Add a New Tag:

Separated by commas
Ex.: root locus, bode

What are tags?

A tag is like a keyword or category label associated with each thread. Tags make it easier for you to find threads of interest.

Anyone can tag a thread. Tags are public and visible to everyone.

Tag Activity for This Thread
Tag Applied By Date/Time
neural networks chris Austin 9 Feb, 2010 11:04:09
rssFeed for this Thread

Contact us at files@mathworks.com