Clear Filters
Clear Filters

Neural Network Segmentation confused about the type of input and training.

2 views (last 30 days)
Hi
I am trying to use the neural network toolbox for aiding in image segmentation. After reading alot of answers on how I can do this, I have done as follows.
My images are of size 640x480. I reduced their size to half [320x240] and extracted five different features on them namely, mean, std. dev, kurtosis, entropy and skewness. Each of these area images. So I use (:) operator to turn in to vectors and stack them beside each other. So if I had 5 features for one image then my input matrix is = [ 5, (320x240)]. Is this correct ?
Also for the target I have my ground truth, on which I have extracted the centers and the edges. And again used the (:) and stacked the three of them together as target matrix as such = [3, (320x240)]. Is this also correct ?
I use them to train with the nprtool and from there I am very confused how to get the output and use it to test other images ? I would appreciate any guidance in this matter please.

Answers (1)

Walter Roberson
Walter Roberson on 13 Sep 2016
Your features are probably not going to be (320x240) in length. If the total length of the features is L, then you would end up with an (number of images) by L, or L by (number of images) array. It is not required that each feature type have the same length as the other feature types, only that each feature type have the same length for each image. For example, you could take standard deviation on each 160 x 120 quarter, creating 4 standard deviations, and those 4 together could be one "feature", by you might choose (for whatever reason) to take the mean of the image as a whole, so that might add just 1 (subtotal so far: 5), and so on. You might end up with 5 features with a total length of (say) 12, so you would have 12 by number of images as your input.
  7 Comments

Sign in to comment.

Community Treasure Hunt

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

Start Hunting!