当前位置:网站首页>[elm classification] classification of UCI data sets based on nuclear limit learning machine and limit learning machine, with matlab code
[elm classification] classification of UCI data sets based on nuclear limit learning machine and limit learning machine, with matlab code
2022-07-27 23:26:00 【Matlab scientific research studio】
1 Content introduction
Extreme learning machine (extreme learning machine,ELM) As a new machine learning method , It has become a hot research direction . ELM Randomly determine the input weights and hidden layer node offsets of the single hidden layer network , The output weight can be obtained by simple calculation , It not only accelerates the learning speed , And it has good generalization ability . Kernel function ELM Introduce kernel function into limit learning machine theory , The least square optimization solution can be obtained , It's solved
ELM Algorithm random initialization problem , It has good robustness to model learning parameters , With more stable 、 Better generalization performance .



2 Simulation code
clcclear allDataSetName = 'waveform'; % With matlab The name of the dataset stored in the formatTrainSamplesPartio = 0.5; % Proportion of training samples of each typeC = 100; % Regularization factorDataSet = load(DataSetName, '-mat'); % Load file into programDataSet = getfield(DataSet, DataSetName);% Get the data in the fileKindIdx = DataSet(:,1); % Get category number , Data number one 1 List as category numberKindCount = length(unique(KindIdx)); % Total number of categoriesSortedDataSet = sortrows(DataSet, 1); % Arrange data by class label , Rearrange data from small to large according to class label , Facilitate random data extraction laterclear DataSetEachKindCount = zeros(1,KindCount); % Number of data of each typefor i=1:KindCountEachKindCount(i) = sum(sum( i == SortedDataSet(:,1))); % The first i Number of class dataendTrainData = [];TestData = [];% Put all kinds of training data and test data into a matrixTrainTemp = [];TestTemp = [];for i=1:KindCountif i==1TempIdx1(1:TrainSamCountEachKind(i),1) = i; % Mark the training data class labelTempIdx2(1:size(TestDataEachKind{i},1),1) = i; % Mark the test data class labelTrainData = [TempIdx1 TrainDataEachKind{1,i}]; % The first column is the class labelTestData = [TempIdx2 TestDataEachKind{1,i}];TempIdx1 = []; % Clear the class label here , Otherwise, wrong class labels may be generated , Because the number of each type of data may be differentTempIdx2 = [];TrainTemp = TrainData;TestTemp = TestData;elseTempIdx1(1:TrainSamCountEachKind(i),1) = i;TempIdx2(1:size(TestDataEachKind{i},1),1) = i;TrainData = [TrainTemp;[TempIdx1 TrainDataEachKind{1,i}]];TestData = [TestTemp;[TempIdx2 TestDataEachKind{1,i}]];TrainTemp = TrainData;TestTemp = TestData;TempIdx1 = [];TempIdx2 = [];endendclear TrainTemp TestTemp TrainDataEachKind TestDataEachKind% The statistical results[label_index_actual, label_index_expected, TrainingAccuracy, TestingAccuracy] = elm(TrainData, TestData, 1, KindCount, 'sig');% Format and output relevant information , It can be modified according to your own needsfprintf('Run Information:\n')fprintf('+-----------------------------------------------+\n')fprintf('|KindIdx | EachKindCount | EachTrainKindCount |\n');fprintf('+-----------------------------------------------+\n')Msgemat='| %2d |%9d |%11d |\n';for i=1:KindCountfprintf(Msgemat, i, EachKindCount(i), TrainSamCountEachKind(i));fprintf('+-----------------------------------------------+\n')endfprintf('+------------------------------------------------------+\n')figureplot(label_index_actual,'rs')hold onplot( label_index_expected,'bo')xlabel(' sample ')legend(' True value ',' Test value ')title([' Test accuracy =',num2str(TestingAccuracy)])
3 Running results


4 reference
[1] Wang Li , LAN Zhi , Yang Rong , etc. . Based on kernel limit learning machine and wavelet packet transform EEG classification method [J]. Beijing Biomedical Engineering , 2018, 37(5):8.
[2] Wang Li et al . " Based on kernel limit learning machine and wavelet packet transform EEG classification method .".
About bloggers : Good at intelligent optimization algorithms 、 Neural networks predict 、 signal processing 、 Cellular automata 、 The image processing 、 Path planning 、 UAV and other fields Matlab Simulation , relevant matlab Code problems can be exchanged by private letter .
Some theories cite network literature , If there is infringement, contact the blogger to delete .
边栏推荐
- Bubbling, fast sorting, heap sorting and cardinality sorting of the eight sorts
- Basic lighting of unity
- [C language] simulate and implement string functions (Part 1)
- 你不知道的Redis那些事,我来详解Redis底层数据结构
- 2022/3/22 examination summary
- Pyqt5 rapid development and practice 4.9 dialog controls
- Px4 module design part 13: workqueue design
- 测试文章
- 寻找和利用 XXE – XML 外部实体注入
- Convnext:a convnet for the 2020s - model Brief
猜你喜欢

【ELM分类】基于核极限学习机和极限学习机实现UCI数据集分类附matlab代码

Basic SQL DQL

Exercise --- BFS

Implicit indicators for evaluating the advantages and disadvantages of automated testing

Read an article to understand artificial neural network

Do you want to be dismissed? Let's take a look at the "exit tips" of programmers

用户画像在科技期刊微信公众号精准推送中的应用

AWS DynamoDB运用技巧

Deploy dolphin scheduler high availability cluster based on rainbow

Pyqt5 rapid development and practice 4.10 window drawing controls
随机推荐
Pro multi store version system, versatile is it!
CSDN dedicated killer technology -- Google browser plug-in
你不知道的Redis那些事,我来详解Redis底层数据结构
iMeta | 国际标准刊号ISSN印刷版正式确认,双ISSN申请完成
微信安装包11年膨胀575倍,UP主:“98%的文件是垃圾”;苹果应用商店被曝大量色情App;四大科技巨头呼吁废除闰秒|极客头条
8000字讲透OBSA原理与应用实践
Bubbling, fast sorting, heap sorting and cardinality sorting of the eight sorts
C language explanation series -- understanding of functions (5) function recursion and iteration
评价自动化测试优劣的隐性指标
Cloud native enthusiast weekly: a complete collection of client go examples
强化学习——PyTorch 实现 Advantage Actor-Critic (A2C)
Quartus:Instantiation of ‘sdram_ model_ plus‘ failed. The design unit was not found.
Tips and extensions of graph theory
Deploy dolphin scheduler high availability cluster based on rainbow
习题 --- BFS
With double-digit growth in revenue and profit, China Resources Yibao has quietly created these new products worth more than 100 million
Exam summary on May 31, 2022
Px4 module design part 13: workqueue design
Test article
Library management system based on SSM framework