2D array as input to neural network
显示 更早的评论
My neural network has 2 feature variables each with a length of 112. Further I have 5 samples from each person and there are total 5 persons.
input= 2 rows, 112(per class feature vector length), 5 persons and 5 samples per person, so its (2, 112 x 5 x 5)
output = (5 (classes), 112 x 5 x 5)
I intend to specify the basic unit of classification as 2 x 112. Any idea how can I do this ? Currently its consider each column 2 x 1 as one input.
2 个评论
Walter Roberson
2013-2-19
Did you experiment with transposing the input array to 112 x 2, just to see what would happen?
sajid
2013-2-19
采纳的回答
更多回答(1 个)
Walter Roberson
2013-2-19
0 个投票
A feature cannot be a 2D array. You can reshape() to make each feature a column.
5 个评论
sajid
2013-2-19
Walter Roberson
2013-2-19
Were you planning to try to process the different items in different ways? For example tansig the magnitude but not the direction? If not, then in theory having them interleaved should not matter, as neural networks are intended to form their own notion of the relationship between parts of features.
sajid
2013-2-19
Walter Roberson
2013-2-19
I do not know if it is possible to treat different elements differently. Maybe with custom functions of some kind. Greg would know; he might visit the topic in anywhere between 4 hours and 4 days (depending on when he gets enough coffee in his system.)
Greg Heath
2013-2-19
It doesn't matter how your input rows are ordered.
However, I suggest transforming to cartesian coordinates so that
input = [ x ; y ]
with
size(y) = size(x) = [ 112 25 ]
类别
在 帮助中心 和 File Exchange 中查找有关 Modeling and Prediction with NARX and Time-Delay Networks 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!