How to do feature extraction using wavelet scattering and then perform neural network classification?
조회 수: 1 (최근 30일)
이전 댓글 표시
% I want to do feature extraction for signals and then apply ANN classification on them,, can you help please?
Fs = 50; sf = waveletScattering('SignalLength', 4950, 'SamplingFrequency', Fs) ;
s = cell(120,1); parfor j = 1:120; r = featureMatrix(sf, f(j, :)) ; s{j, 1} = r; end
h = cell2mat(s) ; b = cell2table(s) ; c = table2dataset(b);
%the single signal was in one row, but after this it becomes 202rows×10columns, and I can't apply ANN like this Any ideas?
답변 (1개)
Suraj Kumar
2024년 10월 7일
Hi Mustafa,
To perform feature extraction using wavelet scattering on signals and then apply ANN classification, you can refer to the following steps:
1. After storing the features in cell array "s", you can convert them into a matrix "featureVectors" suitable for ANN.
% Convert cell array to feature matrix
for i = 1:numSignals
featureVectors(i, :) = s{i}(:)';
end
2. Configure and train the neural network using ‘fitcnet’ function specifying the required parameters. % Train the neural
network net = fitcnet(featureVectors, targetsCategorical, ...
'LayerSizes', hiddenLayerSize, ...
'Standardize', true, ...
'Options', options);
To learn more about ‘fitcnet’ function in MATLAB, refer the below mentioned documentation:
Hope this resolves your query!
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 AI for Signals and Images에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!