У меня есть код ниже, где вход - это матрица 91 на 33, а на выходе - вектор 91 на 1.
output1=categorical(output)
trInput=input(1:78,:);
trInput=trInput';
teInput=input(79:end,:);
teInput=teInput';
trOutput=output1(1:78);
trOutput=trOutput';
teOutput=output1(79:end);
teOutput=teOutput';
layers = [ ...
imageInputLayer([33 1 1 ])
convolution2dLayer(1,33,'NumChannels',1 )
reluLayer
maxPooling2dLayer(1)
fullyConnectedLayer(5)
softmaxLayer
classificaationLayer()]
opts = trainingOptions('sgdm','MaxEpochs',2, ...
'InitialLearnRate',0.001);
net = trainNetwork(trInput,trOutput,layers,opts);
YPred = classify(net,teInput);
Я получаю ошибку ниже:
The training images are the wrong size for this network.
Метод проб и ошибок не может дать мне никаких результатов. Что мне делать?