日韩av黄I国产麻豆传媒I国产91av视频在线观看I日韩一区二区三区在线看I美女国产在线I麻豆视频国产在线观看I成人黄色短片

歡迎訪問 生活随笔!

生活随笔

當前位置: 首頁 > 编程资源 > 编程问答 >内容正文

编程问答

睡眠阶段分期——SVM和ELM分别与粒子群算法结合(function)

發(fā)布時間:2024/8/1 编程问答 38 豆豆
生活随笔 收集整理的這篇文章主要介紹了 睡眠阶段分期——SVM和ELM分别与粒子群算法结合(function) 小編覺得挺不錯的,現(xiàn)在分享給大家,幫大家做個參考.

目錄

importslpdb函數(shù)

loadmatobject函數(shù)

extractfeatures函數(shù)

getindexrange函數(shù)

PSOforELM函數(shù)

?PSOforSVM函數(shù)

?extractresults函數(shù)


importslpdb函數(shù)

——將頭文件、RR文件、注釋文件構(gòu)成結(jié)構(gòu)體:OutputData = struct('filename', fileName, 'time', anTimeGeneratedCell, ...'rr', rrCollection, 'annotation', anClassGeneratedCell, 'age', age, ...'gender', gender, 'weight', weight);

function OutputData = importslpdb(fileName) %Import and synchronize a slpdb recording % Syntax: % OutputData = importslpdb(fileName) % % Input: % *) fileName - slpdb file name to be imported. Example: 'slp01a'. % file must be located in 'slpdb' folder, % three file formats needed: .hea, .rr, and .an % % Output: % *) OutputData - struct contains synchronized RR and annotationfileName = strcat('slpdb/', cell2mat(fileName)); SEC_PER_EPOCH = 30; % amount of seconds in one epoch (value for slpdb is 30) OutputData = []; fprintf('\n%s DATA IMPORT...\n', fileName); %% IMPORT HEADER DATA 導(dǎo)入頭文件數(shù)據(jù)fprintf('Importing header file...\n'); fid = fopen(strcat(fileName, '.hea'), 'r'); headerFile = textscan(fid, '%s%s%s%s%s%s%s%*[^\n]'); fclose(fid); heaSamplingFreq = strsplit(char(headerFile{3}(1)), '/'); heaSamplingFreq = str2double(cell2mat(heaSamplingFreq(1))); heaTotalSamples = str2double(cell2mat(headerFile{4}(1))); heaRecLengthInSec = ceil(heaTotalSamples/heaSamplingFreq); heaTotalEpoch = ceil(heaRecLengthInSec/SEC_PER_EPOCH); heaIdx = size(headerFile{1}, 1); % get last line index of fileif cell2mat(headerFile{1}(end-1)) == '#'% decease index by 1 for 'slp37.hea',% because the last line is not age, gender, and weight information heaIdx = heaIdx - 1; endage = headerFile{2}(heaIdx); gender = headerFile{3}(heaIdx); weight = headerFile{4}(heaIdx);% output of "IMPORT HEADER DATA" section: % *) heaTotalEpoch - total epoch according to header data % *) age - age of the subject % *) gender - gender of the subject % *) weight - weight of the subject % END OF IMPORT HEADER DATA %% IMPORT ANNOTATION DATA 導(dǎo)入注釋數(shù)據(jù)fprintf('Importing annotation file...\n'); fid = fopen(strcat(fileName, '.an'), 'r'); anFile = textscan(fid, '%s%s%s%s%s%s%s%*[^\n]'); fclose(fid);% remove header of annotation data (first line) % remove this string: 'Elapsed time Sample # Type Sub Chan Num Aux'for i=1:size(anFile, 2)anFile{i}(1) = []; end% change first epoch's 'start time' into 0:00.000 anTemp = cell2mat(anFile{1}(1)); anTemp(end-2:end) = 48; anFile{1}(1) = cellstr(anTemp); anTime = anFile{1}; anClass = anFile{7};% output of "IMPORT ANNOTATION DATA" section: % *) anTime - time from annotation file (cell array) % *) anClass - annotation (cell array) % END OF IMPORT ANNOTATION DATA %% IMPORT RR DATA 導(dǎo)入RR數(shù)據(jù)fprintf('Importing RR file...\n'); fid = fopen(strcat(fileName, '.rr'), 'r'); rrFile = textscan(fid, '%s%s%s%s%s%*[^\n]'); fclose(fid);rrConvertedTime = rrFile{1};for i=1:size(rrConvertedTime, 1);rrStartTimeChar = cell2mat(rrConvertedTime(i)); % convert cell into charrrStartTimeChar(end-2:end) = 48; % xx:xx:xx.aaa -> change 'aaa' part to '000'% split start time by ":" into matrix 求時長rrStartTimeMat = strsplit(char(rrConvertedTime(i)), ':')'; % get seconds from the last element rrSecond = str2double(cell2mat(rrStartTimeMat(end)));% epoch groupingrrWhichGroup = floor(rrSecond/SEC_PER_EPOCH)*SEC_PER_EPOCH;% set epoch groupingif rrWhichGroup == 0rrStartTimeChar(end-5) = 48;elseif rrWhichGroup == 30rrStartTimeChar(end-5) = 51;endrrStartTimeChar(end-4) = 48;rrConvertedTime(i) = mat2cell(rrStartTimeChar, 1);end% change RR value from 'array of cell' into 'array of double' 改變RR值屬性rrNum = zeros(size(rrFile{3}, 1), 1);for i=1:size(rrFile{3}, 1)rrNum(i) = str2double(cell2mat(rrFile{3}(i))); endrrTime = rrFile{1};% output of "IMPORT RR DATA" section: % *) rrConvertedTime - rounded RR start time according to the epoch % example: 1:34:31.328 -> 1:34:30.000 % 1:50:13.616 -> 1:50:00.000 % *) rrNum - RR value (array of double) % *) rrTime - start time of un-rounded RR % END OF IMPORT RR DATA %% VALIDITY CHECK 數(shù)據(jù)有效性檢驗(A.注釋、B.RR數(shù)據(jù))fprintf('Data Validity Check:\n');% A. Annotation File Check % *) generate annotation time acocrding to total epoch from header file % *) result: anTimeGeneratedMat -> Matrix size: number of epoch X 3 (h,m,s)anTimeGeneratedMat = zeros(heaTotalEpoch, 3);for i=2:heaTotalEpochanTimeGeneratedMat(i, 3) = anTimeGeneratedMat(i-1, 3) + SEC_PER_EPOCH;anTimeGeneratedMat(i, 2) = anTimeGeneratedMat(i-1, 2);anTimeGeneratedMat(i, 1) = anTimeGeneratedMat(i-1, 1);if anTimeGeneratedMat(i, 3) >= 60anTimeGeneratedMat(i, 3) = 0;anTimeGeneratedMat(i, 2) = anTimeGeneratedMat(i-1, 2) + 1;if anTimeGeneratedMat(i, 2) >= 60anTimeGeneratedMat(i, 2) = 0;anTimeGeneratedMat(i, 1) = anTimeGeneratedMat(i-1, 1) + 1;endendend% convert anTimeGeneratedMat into anTimeGeneratedCell for easier comparisonanTimeGeneratedCell = cell(size(anTimeGeneratedMat, 1), 1);for i = 1:size(anTimeGeneratedMat, 1)if anTimeGeneratedMat(i, 1) == 0 % when the 'hour' is 0anTimeGeneratedCell(i) = ...cellstr(strcat(sprintf('%d',anTimeGeneratedMat(i, 2)), ...sprintf(':%02d.000',anTimeGeneratedMat(i, 3))));elsetemp = strcat(sprintf('%d', anTimeGeneratedMat(i, 1)), ...sprintf(':%02d',anTimeGeneratedMat(i, 2)));anTimeGeneratedCell(i) = ...cellstr(strcat(temp, sprintf(':%02d.000',anTimeGeneratedMat(i, 3))));end end% *) ANNOTATION FILE CHECK 1 (Total epoch of each data): fprintf(' CHECK 1: ');if heaTotalEpoch == size(anTime, 1) && ...size(unique(rrConvertedTime), 1) == size(anTimeGeneratedMat, 1) && ...heaTotalEpoch == size(unique(rrConvertedTime), 1)fprintf('[SUCCESS] heaTotalEpoch (%d) == size(anTime, 1) (%d) == ', ...'size(unique(rrConvertedTime), 1) (%d) == ', ...'size(anTimeGeneratedMat, 1) (%d)\n', heaTotalEpoch, size(anTime, 1), ...size(unique(rrConvertedTime), 1), size(anTimeGeneratedMat, 1)); elsefprintf('[WARNING] heaTotalEpoch (%d) != size(anTime, 1) (%d) != ', ...'size(unique(rrConvertedTime), 1) (%d) != ', ...'size(anTimeGeneratedMat, 1) (%d)\n', heaTotalEpoch, size(anTime, 1), ...size(unique(rrConvertedTime), 1), size(anTimeGeneratedMat, 1)); end% *) ANNOTATION FILE CHECK 2 (Check equality of anTimeGeneratedCell and anTime): fprintf(' CHECK 2: '); if size(anTime, 1) == heaTotalEpochfor i=1:heaTotalEpochif ~strcmp(anTimeGeneratedCell{i}, anTime{i})fprintf('[FAILED ] anTimeGeneratedCell is NOT EQUAL to anTime\n');returnendendfprintf('[SUCCESS] anTimeGeneratedCell is EQUAL to anTime\n'); elsefprintf('[WARNING] size(anTime, 1) (%d) != heaTotalEpoch (%d), ', ...'anTimeGeneratedCell will be used\n', size(anTime, 1), heaTotalEpoch);end% *) ANNOTATION FILE CHECK 3 (Check annotation value must be '1', '2', '3','4', 'W', 'R', or {'MT', 'M' -> these two will be removed later}): fprintf(' CHECK 3: '); distinctClass = char(unique(anClass));for i=1:size(distinctClass, 1)if distinctClass(i) ~= '1' && distinctClass(i) ~= '2' ...&& distinctClass(i) ~= '3' && distinctClass(i) ~= '4' ...&& distinctClass(i) ~= 'W' && distinctClass(i) ~= 'R' ...&& distinctClass(i) ~= 'M'fprintf('[WARNING ] Annotation values is NOT OK\n');returnendendfprintf('[SUCCESS] Annotation values is OK\n');% B. RR File Check % *) RR FILE CHECK 1 (Check equality of size(unique(rrConvertedTime), 1) % and heaTotalEpoch):fprintf(' CHECK 4: ');if size(unique(rrConvertedTime), 1) ~= heaTotalEpochfprintf('[WARNING] size(unique(rrConvertedTime), 1) (%d) != ', ...'heaTotalEpoch (%d)\n', size(unique(rrConvertedTime), 1), heaTotalEpoch); elsefprintf('[SUCCESS] size(unique(rrConvertedTime), 1) (%d) == ', ...'heaTotalEpoch (%d)\n', size(unique(rrConvertedTime), 1), heaTotalEpoch); end% END OF VALIDITY CHECK %% SYNCHRONIZE RR AND ANNOTATION DATA 同步RR和注釋數(shù)據(jù)epochCounter = 1; rrCounter = 1;% rrCollection = each row contains RRs of associated epoch rrCollection = cell(heaTotalEpoch, 1);% rrTimeCollection = each row contains RR time of associated epoch rrTimeCollection = cell(heaTotalEpoch, 1);for i=1:size(rrConvertedTime, 1) % looping for each rrConvertedTime in that fileif strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter))% when i-th RR time is equal to annotation time of current epochrrCollection{epochCounter}(rrCounter) = rrNum(i);rrTimeCollection{epochCounter}(rrCounter) = rrTime(i);rrCounter=rrCounter+1;elseif ~strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter)) ...&& ~strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter+1))% when i-th RR time is not equal to annotation time of current epoch% and i-th RR time is not equal to annotation time of the next epochwhile ~strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter+1))epochCounter = epochCounter + 1;endrrCounter=1;epochCounter=epochCounter+1;rrCollection{epochCounter}(rrCounter) = rrNum(i);rrTimeCollection{epochCounter}(rrCounter) = rrTime(i);rrCounter=rrCounter+1;elseif ~strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter)) ...&& strcmp(rrConvertedTime(i), anTimeGeneratedCell(epochCounter+1))% when i-th RR time is not equal to annotation time of current epoch% and i-th RR time is equal to annotation time of the next epochrrCounter=1;epochCounter=epochCounter+1;rrCollection{epochCounter}(rrCounter) = rrNum(i);rrTimeCollection{epochCounter}(rrCounter) = rrTime(i);rrCounter=rrCounter+1;endend% END OF SYNCHRONIZE RR AND ANNOTATION DATA %% SYNCHRONIZED DATA VALIDITY CHECK 同步數(shù)據(jù)有效性檢驗% generate new annotation matrix, fill the time without annotation 生成新的注釋矩陣,在沒有注釋的情況下填充時間 anClassGeneratedCell = cell(heaTotalEpoch, 1);je = 1;for i=1:heaTotalEpochif strcmp(anTimeGeneratedCell(i), anTime(je))% if the time is the same, copy the annotationanClassGeneratedCell(i) = anClass(je);if je < size(anClass, 1)je = je + 1;endelse% if the time is different, fill with 'none'anClassGeneratedCell(i) = {'none'};endendfprintf('Removing invalid epoch:\n'); isExists = 0;for i=heaTotalEpoch:-1:1flag = 0;if sum(rrCollection{i}) < 28 || sum(rrCollection{i}) > 32% set flag to remove incomplete RR data of that epoch by:% check the sum of RR interval from each epoch,% can't be below 28 or higher than 32% (according to slp04 data, min sum is 29 and max is 30)flag = 1;fprintf(' Epoch %d (time: %s) of %s data is removed because ', ...'incomplete RR data\n', i, anTimeGeneratedCell{i}, fileName);elseif strcmp(anClassGeneratedCell(i), {'none'})% set flag to remove no annotation epochflag = 1;fprintf(' Epoch %d (time: %s) of %s data is removed because ', ...'no annotation\n', i, anTimeGeneratedCell{i}, fileName);elseif strcmp(anClassGeneratedCell(i), {'MT'}) || ...strcmp(anClassGeneratedCell(i), {'M'})% set flag to remove 'MT' or 'M' annotation epochflag = 1;fprintf(' Epoch %d (time: %s) of %s data is removed because ', ...'the annotation is %s\n', i, anTimeGeneratedCell{i}, fileName, ...anClassGeneratedCell{i});end% when the flag is 1, remove the dataif flag == 1anTimeGeneratedCell{i} = [];rrCollection{i} = [];anClassGeneratedCell{i} = [];isExists = 1;endend% print message if no invalid epoch if ~isExistsfprintf('No invalid epoch\n'); end% delete empty row anTimeGeneratedCell = ...anTimeGeneratedCell(~cellfun(@isempty, anTimeGeneratedCell)); rrCollection = rrCollection(~cellfun(@isempty, rrCollection)); anClassGeneratedCell = ...anClassGeneratedCell(~cellfun(@isempty, anClassGeneratedCell));%END OF SYNCHRONIZED DATA VALIDITY CHECK %% PREPARE THE OUTPUT 輸出信息OutputData = struct('filename', fileName, 'time', anTimeGeneratedCell, ...'rr', rrCollection, 'annotation', anClassGeneratedCell, 'age', age, ...'gender', gender, 'weight', weight);% END OF PREPARE THE OUTPUT end

loadmatobject函數(shù)

——導(dǎo)入第index例樣本的字段及對應(yīng)數(shù)據(jù)?

function Data = loadmatobject(fileName, index)%Load .mat object by index % Syntax: % Data = loadmatobject(dir, index) % % Input: % *) fileName - file name % *) index - index of .mat's variable to be returned % % Output: % *) Data - index-th variable returnedData = load(fileName);fieldName = fieldnames(Data); %返回結(jié)構(gòu)體的字段名稱Data = Data.(fieldName{index}); %返回數(shù)據(jù)end

extractfeatures函數(shù)

——沒有輸出變量,輸出非歸一化、歸一化的特征文件('xlsx', 'mat')

function extractfeatures(SlpdbData, destination, outputFormat)%Extract HRV Features % Syntax: % extractfeatures(SlpdbData, destination, outputFormat) % % Input: % *) SlpdbData - struct generated from importslpdb() function % 從importslpdb()函數(shù)生成的結(jié)構(gòu) % *) destination - directory of the result % *) outputFormat - output format: 'xlsx', 'mat', 'all' % % Output: % No output variables, but there are two files output: % hrv_features_unorm - unnormalized features % hrv_features_norm - normalized features % target - matrix total samples X 6 (1 - 6 classes target)nSamples = size(SlpdbData, 1);nClasses = length(unique([SlpdbData.annotation])); % unique:找出數(shù)據(jù)矩陣中所有不重復(fù)數(shù),確定分類類數(shù)hrv = zeros(nSamples, 25);target = zeros(nSamples, nClasses);target(:, [1 5]) = NaN;for i=1:nSamplesrr_diff = diff(SlpdbData(i).rr); % diff函數(shù)式用于求導(dǎo)數(shù)和差分hrv(i, 1) = HRVFeature.AVNN(SlpdbData(i).rr);hrv(i, 2) = HRVFeature.SDNN(SlpdbData(i).rr);hrv(i, 3) = HRVFeature.RMSSD(rr_diff);hrv(i, 4) = HRVFeature.SDSD(rr_diff);hrv(i, 5) = HRVFeature.NNx(50, rr_diff);hrv(i, 6) = HRVFeature.PNNx(hrv(i, 5), size(SlpdbData(i).rr, 2));hrv(i, 7) = HRVFeature.HRV_TRIANGULAR_IDX(SlpdbData(i).rr);hrv(i, 8) = HRVFeature.SD1(hrv(i, 4));hrv(i, 9) = HRVFeature.SD2(hrv(i, 2), hrv(i, 4));hrv(i, 10) = HRVFeature.SD1_SD2_RATIO(hrv(i, 8), hrv(i, 9));hrv(i, 11) = HRVFeature.S(hrv(i, 8), hrv(i, 9));[TP,pLF,pHF,LFHFratio,VLF,LF,HF,f,Y,NFFT] = ...HRVFeature.fft_val_fun(SlpdbData(i).rr,2);hrv(i, 12) = TP;hrv(i, 13) = pLF;hrv(i, 14) = pHF;hrv(i, 15) = LFHFratio;hrv(i, 16) = VLF;hrv(i, 17) = LF;hrv(i, 18) = HF;% set class annotationswitch SlpdbData(i).annotationcase '1'target(i,6) = 1; % 標記類別target(i,4) = 1;target(i,3) = 1;target(i,2) = 1;case '2'target(i,6) = 2;target(i,4) = 1;target(i,3) = 1;target(i,2) = 1;case '3'target(i,6) = 3;target(i,4) = 2;target(i,3) = 1;target(i,2) = 1;case '4'target(i,6) = 4;target(i,4) = 2;target(i,3) = 1;target(i,2) = 1;case 'R'target(i,6) = 5;target(i,4) = 3;target(i,3) = 2;target(i,2) = 1;case 'W'target(i,6) = 6;target(i,4) = 4;target(i,3) = 3;target(i,2) = 2;otherwisefprintf('Invalid Annotation');returnendendhrv( :, ~any(hrv,1) ) = [];% create a new dir if not existsdirList = dir;isDirExists = 0;for i=1:length(dir)if dirList(i).isdir && strcmp(dirList(i).name, destination)isDirExists = 1;endendif ~isDirExistsmkdir(destination);end% save the data into destinationhrv_features_unorm = hrv;hrv_features_norm = normalizedata(hrv, -1, 1);if strcmp(outputFormat, 'xlsx') || strcmp(outputFormat, 'all') % strcmp是用于做字符串比較,保存成相應(yīng)的特征文件xlswrite(strcat(destination, 'hrv_features_unorm.xlsx'), ...hrv_features_unorm);xlswrite(strcat(destination, 'hrv_features_norm.xlsx'), ...hrv_features_norm);xlswrite(strcat(destination, 'target.xlsx'), target);endif strcmp(outputFormat, 'mat') || strcmp(outputFormat, 'all')save(strcat(destination, 'hrv_features_unorm.mat'), 'hrv_features_unorm');save(strcat(destination, 'hrv_features_norm.mat'), 'hrv_features_norm');save(strcat(destination, 'target.mat'), 'target');endend

getindexrange函數(shù)

——通過index得到輸入向量的范圍

function range = getindexrange(nSamplesEachData, index)%Get range of inputted vector by index. For example [2 3 4 5] is the %inputted nSamplesEachData and index is 2. Then, the output is [3 4 5]. %Explanation: %The sum of [2 3 4 5] is 14 (there are 14 items). %If index = 1, so the output is [1 2] -> total elements are 2 %If index = 2, so the output is [3 4 5] -> total elements are 3 %If index = 3, so the output is [6 7 8 9] -> total elements are 4 %If index = 4, so the output is [10 11 12 13 14] -> total elements are 5 % Syntax: % range = getindexrange(nSamplesEachData, index) % % Input: % *) nSamplesEachData - total number of data in each index % 每個index中的數(shù)據(jù)總數(shù) % *) index - index to be retrieved % % Output: % *) range - a vector contains ordered number of associated index % 包含相關(guān)index的有序數(shù)量向量if sum(index > length(nSamplesEachData)) >= 1disp('Index limit exceeded');returnendrange = [];for i=1:length(index)if index(i) == 1startNum = 1;endNum = nSamplesEachData(index(i));elsestartNum = sum(nSamplesEachData(1:index(i)-1)) + 1;endNum = startNum + nSamplesEachData(index(i)) - 1;endrange = [range startNum:endNum];end end

PSOforELM函數(shù)

——PSO的初始化、結(jié)合ELM的PSO迭代

function [result, startTime, endTime] = PSOforELM(nFeatures, trainingData, ...testingData, PSOSettings)%Running PSO with ELM for feature selection and number of hidden nodes % 使用ELM運行PSO來選擇特征和隱藏節(jié)點的數(shù)量 %optimization % Syntax: % [result, startTime, endTime] = PSOforELM(nFeatures, trainingData, ... % testingData, PSOSettings) % % Input: % *) nFeatures - total number of features to be selected % *) trainingData - training data (Matrix size: total samples X nFeatures) % *) testingData - testing data (Matrix size: total samples X nFeatures) % *) PSOSettings - struct contains PSO parameters, examples: % PSOSettings.MAX_ITERATION = MAX_ITERATION; % PSOSettings.nParticles = 20; % PSOSettings.W = 0.6; % PSOSettings.c1 = 1.2; % PSOSettings.c2 = 1.2; % PSOSettings.Wa = 0.95; % PSOSettings.Wf = 0.05; % % Output: % *) result - struct contains records of PSO ELM result % 此結(jié)構(gòu)包含PSO ELM結(jié)果的記錄 % *) startTime - time when the experiment starts % *) endTime - time when the experiment endsstartTime = clock;%% PSO PARAMETER PREPARATION PSO各參數(shù)定義及初始化% max total bits for hidden nodes nHiddenBits = length(dectobin(size(trainingData, 1))); % dectobin十-二進制轉(zhuǎn)換 populationPosition = rand(PSOSettings.nParticles, nFeatures+nHiddenBits) > 0.5; % 隨機矩陣中的每一個數(shù)與0.5比較,若值小于0.5,populationPosition矩陣中相對應(yīng)的值返回1,否則返回0% 不符合條件的重新更新 for i=1:PSOSettings.nParticleswhile bintodec(populationPosition(i, nFeatures+1:end)) < nFeatures || ...bintodec(populationPosition(i, nFeatures+1:end)) > size(trainingData, 1) || ...sum(populationPosition(i, 1:nFeatures)) == 0populationPosition(i, :) = rand(1, nFeatures+nHiddenBits) > 0.5; end endpopulationVelocity = int64(zeros(PSOSettings.nParticles, 1)); % 初始化為0(十進制)% 定義pBest結(jié)構(gòu)體的字段:position、fitness、trainingAccuracy、testingAccuracy pBest(PSOSettings.nParticles).position = []; pBest(PSOSettings.nParticles).fitness = []; pBest(PSOSettings.nParticles).trainingAccuracy = []; pBest(PSOSettings.nParticles).testingAccuracy = [];% 各字段初始化 for i=1:PSOSettings.nParticlespBest(i).position = false(1, nFeatures+nHiddenBits); % max fitness valuepBest(i).fitness = repmat(-1000000, PSOSettings.nParticles, 1);pBest(i).trainingAccuracy = 0;pBest(i).testingAccuracy = 0; end% 定義gBest結(jié)構(gòu)體的字段:position、fitness、trainingAccuracy、testingAccuracy、fromIteration、fromParticle gBest.position = false(1, nFeatures+nHiddenBits); gBest.fitness = -1000000; % max fitness value all particle all iteration gBest.trainingAccuracy = []; gBest.testingAccuracy = []; gBest.fromIteration = []; gBest.fromParticle = [];% 定義result結(jié)構(gòu)體的字段 result(PSOSettings.MAX_ITERATION+1).iteration = []; result(PSOSettings.MAX_ITERATION+1).populationPosition = []; result(PSOSettings.MAX_ITERATION+1).pBest = []; result(PSOSettings.MAX_ITERATION+1).time = []; result(PSOSettings.MAX_ITERATION+1).trainingAccuracy = []; result(PSOSettings.MAX_ITERATION+1).testingAccuracy = []; result(PSOSettings.MAX_ITERATION+1).model = []; result(PSOSettings.MAX_ITERATION+1).gBest = [];% END OF PSO PARAMETER PREPARATION %% INITIALIZATION STEP 初始化步驟 %fitness function evaluation 適應(yīng)度函數(shù)的評價[modelArr, trainAccArr, testAccArr, timeArr, populationFitness, pBest] = ...evaluatefitness(PSOSettings, nFeatures, trainingData, testingData, ...populationPosition, pBest); % evaluatefitness函數(shù)具體見本節(jié)最后gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, populationFitness, ...populationPosition, gBest, 0); % gbestupdate函數(shù)具體見本節(jié)最后% save initial data 保存原始數(shù)據(jù) result(1).iteration = 0; result(1).populationPosition = populationPosition; result(1).pBest = pBest; result(1).time = timeArr; result(1).trainingAccuracy = trainAccArr; result(1).testingAccuracy = testAccArr;%result(1).model = modelArr; result(1).gBest = gBest;% END OF INITIALIZATION STEP %% PSO ITERATION PSO的迭代for iteration=1:PSOSettings.MAX_ITERATION% Update Velocityr1 = rand();r2 = rand();for i=1:PSOSettings.nParticles% calculate velocity value 計算速度值positionDec = int64(bintodec(populationPosition(i, :)));populationVelocity(i, 1) = PSOSettings.W * populationVelocity(i, 1) + ...PSOSettings.c1 * r1 * (bintodec(pBest(i).position) - positionDec) ...+ PSOSettings.c2 * r2 * (bintodec(gBest.position) - positionDec);% update particle positionnewPosDec = abs(int64(positionDec + populationVelocity(i, 1)));newPosBin = dectobin(newPosDec);% if the total bits is lower than nFeatures + nHiddenBits,add zeros in frontif size(newPosBin, 2) < (nFeatures + nHiddenBits)newPosBin = ...[zeros(1, (nFeatures + nHiddenBits) - size(newPosBin, 2)) ...newPosBin];end% if the number of hidden node is more than the number of samplesif bintodec(newPosBin(1, nFeatures+1:end)) > size(trainingData, 1) ...|| size(newPosBin(1, nFeatures+1:end), 2) > nHiddenBitsnewPosBin = ...[newPosBin(1, 1:nFeatures) dectobin(size(trainingData, 1))];end% if the number of selected features is 0 如果選擇的特征數(shù)量為0while sum(newPosBin(1, 1:nFeatures)) == 0newPosBin(1, 1:nFeatures) = rand(1, nFeatures) > 0.5;end% set the new value of positionpopulationPosition(i, :) = newPosBin;end% fitness function evaluation[modelArr, trainAccArr, testAccArr, timeArr, populationFitness, pBest] = ...evaluatefitness(PSOSettings, nFeatures, trainingData, testingData, ...populationPosition, pBest);gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, ...populationFitness, populationPosition, gBest, iteration+1);% save dataresult(iteration+1).iteration = iteration;result(iteration+1).populationPosition = populationPosition;result(iteration+1).pBest = pBest;result(iteration+1).time = timeArr;result(iteration+1).trainingAccuracy = trainAccArr;result(iteration+1).testingAccuracy = testAccArr;%result(iteration+1).model = modelArr;result(iteration+1).gBest = gBest; end% END OF PSO ITERATION endTime = clock; end

?PSOforSVM函數(shù)

function [result, startTime, endTime] = PSOforSVM(nFeatures, trainingData, ...testingData, PSOSettings)%Running PSO with SVM for feature selection % Syntax: % [result, startTime, endTime] = PSOforSVM(nFeatures, trainingData, ... % testingData, PSOSettings) % % Input: % *) nFeatures - total number of features to be selected % *) trainingData - training data (Matrix size: total samples X nFeatures) % *) testingData - testing data (Matrix size: total samples X nFeatures) % *) PSOSettings - struct contains PSO parameters, examples: % PSOSettings.MAX_ITERATION = MAX_ITERATION; % PSOSettings.nParticles = 20; % PSOSettings.W = 0.6; % PSOSettings.c1 = 1.2; % PSOSettings.c2 = 1.2; % PSOSettings.Wa = 0.95; % PSOSettings.Wf = 0.05; % % Output: % *) result - struct contains records of PSO SVM result % *) startTime - time when the experiment starts % *) endTime - time when the experiment endsstartTime = clock;%% PSO PARAMETER PREPARATION populationPosition = rand(PSOSettings.nParticles, nFeatures) > 0.5;for i=1:PSOSettings.nParticleswhile sum(populationPosition(i, 1:nFeatures)) == 0populationPosition(i, :) = rand(1, nFeatures) > 0.5;end endpopulationVelocity = int64(zeros(PSOSettings.nParticles, 1)); % in decimal value% pBest pBest(PSOSettings.nParticles).position = []; pBest(PSOSettings.nParticles).fitness = []; pBest(PSOSettings.nParticles).trainingAccuracy = []; pBest(PSOSettings.nParticles).testingAccuracy = [];for i=1:PSOSettings.nParticlespBest(i).position = false(1, nFeatures);% max fitness valuepBest(i).fitness = repmat(-1000000, PSOSettings.nParticles, 1);pBest(i).trainingAccuracy = 0;pBest(i).testingAccuracy = 0; end% gBest gBest.position = false(1, nFeatures); gBest.fitness = -1000000; % max fitness value all particle all iteration gBest.trainingAccuracy = []; gBest.testingAccuracy = []; gBest.fromIteration = []; gBest.fromParticle = [];% initialize struct data result(PSOSettings.MAX_ITERATION+1).iteration = []; result(PSOSettings.MAX_ITERATION+1).populationPosition = []; result(PSOSettings.MAX_ITERATION+1).pBest = []; result(PSOSettings.MAX_ITERATION+1).time = []; result(PSOSettings.MAX_ITERATION+1).trainingAccuracy = []; result(PSOSettings.MAX_ITERATION+1).testingAccuracy = []; result(PSOSettings.MAX_ITERATION+1).gBest = [];% END OF PSO PARAMETER PREPARATION %% INITIALIZATION STEP%fitness function evaluation [trainAccArr, testAccArr, timeArr, populationFitness, pBest] = ...evaluatefitness(PSOSettings, nFeatures, trainingData, testingData, ...populationPosition, pBest);gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, populationFitness, ...populationPosition, gBest, 0);% save initial data result(1).iteration = 0; result(1).populationPosition = populationPosition; result(1).pBest = pBest; result(1).time = timeArr; result(1).trainingAccuracy = trainAccArr; result(1).testingAccuracy = testAccArr; result(1).gBest = gBest;% END OF INITIALIZATION STEP %% PSO ITERATIONfor iteration=1:PSOSettings.MAX_ITERATION% Update Velocityr1 = rand();r2 = rand();for i=1:PSOSettings.nParticles% calculate velocity valuepositionDec = int64(bintodec(populationPosition(i, :)));populationVelocity(i, 1) = PSOSettings.W * populationVelocity(i, 1) + ...PSOSettings.c1 * r1 * (bintodec(pBest(i).position) - positionDec) ...+ PSOSettings.c2 * r2 * (bintodec(gBest.position) - positionDec);% update particle positionnewPosDec = abs(int64(positionDec + populationVelocity(i, 1)));newPosBin = dectobin(newPosDec);% if the total bits is lower than nFeatures, add zeros in frontif size(newPosBin, 2) < nFeaturesnewPosBin = [zeros(1, (nFeatures)-size(newPosBin, 2)) newPosBin];end% if the total bits is higher than nFeatures, get first nFeaturesif size(newPosBin, 2) > nFeaturesnewPosBin = newPosBin(1, 1:nFeatures);end% if the number of selected features is 0while sum(newPosBin(1, 1:nFeatures)) == 0newPosBin(1, 1:nFeatures) = rand(1, nFeatures) > 0.5;end% set the new value of positionpopulationPosition(i, :) = newPosBin;end% fitness function evaluation[trainAccArr, testAccArr, timeArr, populationFitness, pBest] = ...evaluatefitness(PSOSettings, nFeatures, trainingData, testingData, ...populationPosition, pBest);gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, ...populationFitness, populationPosition, gBest, iteration+1);% save dataresult(iteration+1).iteration = iteration;result(iteration+1).populationPosition = populationPosition;result(iteration+1).pBest = pBest;result(iteration+1).time = timeArr;result(iteration+1).trainingAccuracy = trainAccArr;result(iteration+1).testingAccuracy = testAccArr;result(iteration+1).gBest = gBest; end% END OF PSO ITERATION endTime = clock;end

?

?

?extractresults函數(shù)

——沒有輸出變量,有Excel輸出文件(每次實驗結(jié)果、所有實驗的最好結(jié)果)、保存gBest隨迭代變化圖片

function extractresults(resultRootFolder, nFeatures, classNum, nExperiments, ...nIterations)%Extract raw results of experiment using PSOELM or PSOSVM method % Syntax: % extractresults(resultRootFolder, nFeatures, classNum, nExperiments, ... % nIterations) % % Input: % *) resultRootFolder - root directory of the results % *) nFeatures - total features % *) classNum - number of class in vector -> [2 3 4 6] % *) nExperiments - total experiments of PSO % *) nIterations - total iterations of each PSO % % Output: % No output variables, there are excel output files: % [method]_[filename]_extracted_result - results of each experiment % [method]_result - best of all experiments % % Parameter Example: % resultRootFolder = 'PSOELM_raw_result'; % nFeatures = 18; % classNum = [2 3 4 6]; % nExperiments = 25; % nIterations = 100;fileNames = {'slp01a' 'slp01b' 'slp02a' 'slp02b' 'slp03' 'slp04' ...'slp14' 'slp16' 'slp32' 'slp37' 'slp41' 'slp45' 'slp48' ...'slp59' 'slp60' 'slp61' 'slp66' 'slp67x'}; method = strsplit(resultRootFolder, '_');method = method{1}; % PSOSVM | PSOELMnClassClassifiers = length(classNum); % 4headerEachExp = [];switch methodcase 'PSOELM'headerEachExp = {'Experiment', 'gBestFitness', 'TrainAcc', ...'TestAcc', 'ProcessTime(Sec)', 'HiddenNodes', 'SelectedFeatures'};case 'PSOSVM'headerEachExp = {'Experiment', 'gBestFitness', 'TrainAcc', ...'TestAcc', 'ProcessTime(Sec)', 'SelectedFeatures'};endheaderBestExp = headerEachExp;headerBestExp{1} = 'RecordingName';% write header for main excel result (only 1 excel)for i=1:length(classNum)xlswrite(sprintf('%s/%s_result.xlsx', resultRootFolder, method), ...headerBestExp, sprintf('%d classes', classNum(i)));endfor iFile=1:length(fileNames) % loop for each file% eachFileFolder example: PSOELM_raw_result/PSOELM_slp01a_raw_resulteachFileFolder = sprintf('%s/%s_%s_raw_result', resultRootFolder, ...method, fileNames{iFile});for iClass=1:nClassClassifiers % loop for each class numbermatFileName = sprintf('%s/%s_%s_%dclasses_raw_result.mat', ...eachFileFolder, method, fileNames{iFile}, classNum(iClass));ExperimentResult = loadmatobject(matFileName, 1);temp = zeros(nExperiments, length(headerEachExp)-1);nBits = ...length(ExperimentResult(4). ...iterationResult(end).gBest.position) - nFeatures;gBestParticles = false(nExperiments, nFeatures+nBits);tempCell = cell(nExperiments, 1);% get the last gBest result of each experimentfor iExp=1:nExperimentslastResult = ExperimentResult(iExp).iterationResult(end);temp(iExp, 1) = iExp;temp(iExp, 2) = lastResult.gBest.fitness;temp(iExp, 3) = lastResult.gBest.trainingAccuracy;temp(iExp, 4) = lastResult.gBest.testingAccuracy;temp(iExp, 5) = ...etime(ExperimentResult(iExp).endTime, ...ExperimentResult(iExp).startTime);if strcmp(method, 'PSOELM')temp(iExp, 6) = ...bintodec(lastResult.gBest.position(nFeatures+1:end));endtempCell(iExp, 1) = ...{bintostringorder(lastResult.gBest.position(1, 1:nFeatures))};gBestParticles(iExp, :) = lastResult.gBest.position;endeachFileExcelPath = sprintf('%s/%s_%s_extracted_result.xlsx', ...eachFileFolder, method, fileNames{iFile});xlswrite(eachFileExcelPath, headerEachExp, ...sprintf('%d classes', classNum(iClass)), 'A1');xlswrite(eachFileExcelPath, temp, ...sprintf('%d classes', classNum(iClass)), 'A2');xlswrite(eachFileExcelPath, tempCell, ...sprintf('%d classes', classNum(iClass)), ...sprintf('%s2', getexcelcolumncode(length(headerEachExp))));% get the best experiment of each classificationbestExpIdx = find(temp(:, 2) == max(temp(:, 2)));if length(bestExpIdx) > 1% if have the same gBest fitness value, get the max of testAccbestExpIdx = ...bestExpIdx(temp(bestExpIdx, 4) == max(temp(bestExpIdx, 4)));if length(bestExpIdx) > 1% if have the same testAcc, get the max of trainAccbestExpIdx = bestExpIdx(temp(bestExpIdx, 3) == ...max(temp(bestExpIdx, 3)));if length(bestExpIdx) > 1% if have the same trainAcc,% get the min of selected featuresbestExpIdx = bestExpIdx( ...sum(gBestParticles(bestExpIdx, 1:nFeatures), 2) == ...min(sum(gBestParticles(bestExpIdx, 1:nFeatures), 2)));if length(bestExpIdx) > 1% if have the same selected feature,% check the method usedswitch methodcase 'PSOELM'bestExpIdx = ...bestExpIdx(temp(bestExpIdx, 6) == ...min(temp(bestExpIdx, 6)));if length(bestExpIdx) > 1% if have the same selected feature,% get the firstbestExpIdx = bestExpIdx(1);endcase 'PSOSVM'bestExpIdx = bestExpIdx(1);endendendendend% mark the best indexxlswrite(eachFileExcelPath, {'BEST EXPERIMENT'}, ...sprintf('%d classes', classNum(iClass)), ...sprintf('%s%d', ...getexcelcolumncode(length(headerEachExp)+1), bestExpIdx+1));%{% gather gBest fitness of the best experimentgBest = zeros(nIterations, 1);for iItr=1:nIterationsgBest(iItr) = ...ExperimentResult(bestExpIdx). ...iterationResult(iItr+1).gBest.fitness;end% save graphicsf = figure;plot(1:nIterations, gBest);ylabel('gBest Fitness'); xlabel('Iteration');title(sprintf('[%s] Best Experiment of %s (%d classes)', ...method, fileNames{iFile}, classNum(iClass)));saveas(f, ...sprintf('%s/[%s] Best Experiment of %s (%d classes).png', ...eachFileFolder, method, fileNames{iFile}, classNum(iClass)));close all;%}% save result to main excelswitch methodcase 'PSOELM'xlswrite( ...sprintf('%s/%s_result.xlsx', resultRootFolder, ...method), ...[fileNames(iFile) temp(bestExpIdx, 2) ...temp(bestExpIdx, 3) temp(bestExpIdx, 4) ...temp(bestExpIdx, 5) temp(bestExpIdx, 6) ...tempCell(bestExpIdx)], ...sprintf('%d classes', classNum(iClass)), ...sprintf('A%d', iFile+1));case 'PSOSVM'xlswrite( ...sprintf('%s/%s_result.xlsx', resultRootFolder, ...method), ...[fileNames(iFile) temp(bestExpIdx, 2) ...temp(bestExpIdx, 3) temp(bestExpIdx, 4) ...temp(bestExpIdx, 5) tempCell(bestExpIdx)], ...sprintf('%d classes', classNum(iClass)), ...sprintf('A%d', iFile+1));endendendend

?evaluatefitness、gbestupdate函數(shù)

function [modelArr, trainAccArr, testAccArr, timeArr, populationFitness, ...pBest] = evaluatefitness(PSOSettings, nFeatures, trainingData, ...testingData, populationPosition, pBest)modelArr(PSOSettings.nParticles).inputWeight = []; % 定義modelArr結(jié)構(gòu)體字段inputWeight、outputWeightmodelArr(PSOSettings.nParticles).outputWeight = []; trainAccArr = zeros(PSOSettings.nParticles, 1);testAccArr = zeros(PSOSettings.nParticles, 1);timeArr = zeros(PSOSettings.nParticles, 1);populationFitness = zeros(PSOSettings.nParticles, 1);for i=1:PSOSettings.nParticlestic;% TRAININGmaskedTrainingFeature = featuremasking(trainingData, ... % featuremasking函數(shù)具體見最后populationPosition(i, 1:nFeatures)); % remove unselected features% prepare the target data% (example: transformation from 4 into [0 0 0 1 0 0])trainingTarget = full(ind2vec(trainingData(:,end)'))'; [Model, trainAcc] = trainELM(maskedTrainingFeature, trainingTarget, ... % trainELM函數(shù)具體見最后bintodec(populationPosition(i, nFeatures+1:end)));% TESTINGmaskedTestingFeature = featuremasking(testingData, ... % featuremasking函數(shù)具體見最后populationPosition(i, 1:nFeatures)); % remove unselected features% prepare the target data% (example: transformation from 4 into [0 0 0 1 0 0])testingTarget = full(ind2vec(testingData(:,end)'))';testAcc = testELM(maskedTestingFeature, testingTarget, Model); % testELM函數(shù)具體見最后populationFitness(i, 1) = fitness(PSOSettings.Wa, PSOSettings.Wf, ... testAcc, populationPosition(i, 1:nFeatures)); % function fitnessValue = fitness(Wa, Wf, acc, featureMask)% fitnessValue = Wa * acc + Wf * (1 - (sum(featureMask)/length(featureMask)));% end% pBest updateischanged = 0;% 滿足以下任意一條件,更新變量if populationFitness(i, 1) > pBest(i).fitnessischanged = 1;elseif populationFitness(i, 1) == pBest(i).fitnessif pBest(i).testingAccuracy < testAccischanged = 1;elseif pBest(i).trainingAccuracy < trainAccischanged = 1;elseif sum(pBest(i).position(1, 1:nFeatures)) > ...sum(populationPosition(i, 1:nFeatures))ischanged = 1;elseif bintodec(pBest(i).position(1, nFeatures+1:end)) > ...bintodec(populationPosition(i, nFeatures+1:end))ischanged = 1;endendif ischangedpBest(i).fitness = populationFitness(i, 1);pBest(i).position = populationPosition(i, :);pBest(i).trainingAccuracy = trainAcc;pBest(i).testingAccuracy = testAcc;end% end of pBest updatemodelArr(i) = Model;timeArr(i) = toc;trainAccArr(i) = trainAcc;testAccArr(i) = testAcc;end end function gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, ...populationFitness, populationPosition, gBest, iteration)if max(populationFitness) >= gBest.fitnessfound = find(populationFitness == max(populationFitness));if length(found) > 1% if have the same gBest fitness value, get the max of testAcc 如果具有相同的gBest適應(yīng)度值,則獲取testAcc的最大值found = found(testAccArr(found) == max(testAccArr(found)));if length(found) > 1% if have the same testAcc, get the max of trainAcc 如果有相同的testAcc,得到trainAcc的最大值found = found(trainAccArr(found) == max(trainAccArr(found)));if length(found) > 1% if have the same trainAcc, get the min of selected features 如果具有相同的trainAcc,則獲取所選特征的最小值found = ...found(sum(populationPosition(found, 1:nFeatures), 2) ...== min(sum(populationPosition(found, 1:nFeatures), 2)));if length(found) > 1% if have the same selected feature,get the min of hidden nodehn = zeros(length(found), 1);for i=1:length(found)hn(i, 1) = bintodec(populationPosition(found(i), ...nFeatures+1:end));endfound = found(hn == min(hn));if length(found) > 1found = found(1);endendendendendgBest.fitness = populationFitness(found);gBest.position = populationPosition(found, :);gBest.trainingAccuracy = trainAccArr(found);gBest.testingAccuracy = testAccArr(found);gBest.fromIteration = iteration;gBest.fromParticle = found;end end

?

function [trainAccArr, testAccArr, timeArr, populationFitness, pBest] = ...evaluatefitness(PSOSettings, nFeatures, trainingData, testingData, ...populationPosition, pBest)trainAccArr = zeros(PSOSettings.nParticles, 1);testAccArr = zeros(PSOSettings.nParticles, 1);timeArr = zeros(PSOSettings.nParticles, 1);populationFitness = zeros(PSOSettings.nParticles, 1);for i=1:PSOSettings.nParticlestic;% TRAININGmaskedTrainingFeature = featuremasking(trainingData, ...populationPosition(i, 1:nFeatures)); % remove unselected featuresModel = trainSVM(maskedTrainingFeature, trainingData(:,end), 'RBF');trainAcc = testSVM(maskedTrainingFeature, trainingData(:,end), Model);% TESTINGmaskedTestingFeature = featuremasking(testingData, ...populationPosition(i, 1:nFeatures)); % remove unselected featurestestAcc = testSVM(maskedTestingFeature, testingData(:,end), Model);populationFitness(i, 1) = fitness(PSOSettings.Wa, PSOSettings.Wf, ...testAcc, populationPosition(i, 1:nFeatures));% pBest updateischanged = 0;if populationFitness(i, 1) > pBest(i).fitnessischanged = 1;elseif populationFitness(i, 1) == pBest(i).fitnessif pBest(i).testingAccuracy < testAccischanged = 1;elseif pBest(i).trainingAccuracy < trainAccischanged = 1;elseif sum(pBest(i).position(1, 1:nFeatures)) > ...sum(populationPosition(i, 1:nFeatures))ischanged = 1;endendif ischangedpBest(i).fitness = populationFitness(i, 1);pBest(i).position = populationPosition(i, :);pBest(i).trainingAccuracy = trainAcc;pBest(i).testingAccuracy = testAcc;end% end of pBest updatetimeArr(i) = toc;trainAccArr(i) = trainAcc;testAccArr(i) = testAcc;end endfunction gBest = gbestupdate(nFeatures, trainAccArr, testAccArr, ...populationFitness, populationPosition, gBest, iteration)if max(populationFitness) >= gBest.fitnessfound = find(populationFitness == max(populationFitness));if length(found) > 1% if have the same gBest fitness value, get the max of testAccfound = found(testAccArr(found) == max(testAccArr(found)));if length(found) > 1% if have the same testAcc, get the max of trainAccfound = found(trainAccArr(found) == max(trainAccArr(found)));if length(found) > 1% if have the same trainAcc, get the min of selected featuresfound = ...found(sum(populationPosition(found, 1:nFeatures), 2) ...== min(sum(populationPosition(found, 1:nFeatures), 2)));if length(found) > 1% if have the same selected feature, get the firstfound = found(1);endendendendgBest.fitness = populationFitness(found);gBest.position = populationPosition(found, :);gBest.trainingAccuracy = trainAccArr(found);gBest.testingAccuracy = testAccArr(found);gBest.fromIteration = iteration;gBest.fromParticle = found;end end

featuremasking、trainELM、testELM函數(shù)

function maskedFeature = featuremasking(feature, mask) %Retrieve masked features % Syntax: % maskedFeature = featuremasking(feature, mask) % % Input: % *) feature - feature collection % (Matrix size: total samples X total features) % *) mask - logical matrix, 1 means selected, 0 is not selected % (Matrix size: 1 X total features) % Output: % *) maskedFeature - matrix with selected features only % (Matrix size: total samples X total selected featuresmaskedFeature = zeros(size(feature, 1), sum(mask));j = 1;for i=1:sum(mask)if mask(1, i) == 1maskedFeature(:, j) = feature(:, i);j = j + 1;endend endfunction [ELMModel, trainAcc] = trainELM(feature, target, nHiddenNode) %Train Extreme Learning Machine (ELM) model % Syntax: % [ELMModel, trainAcc] = trainELM(feature, target, nHiddenNode) % % Input: % *) feature - feature collection % (Matrix size: total samples X total features) % *) target - target of each sample % (Matrix size: total samples X total classes) % Example: class 4 -> target is [0 0 0 1] % *) nHiddenNode - total hidden nodes of ELM % % Output: % *) ELMModel.inputWeight - input weight of ELM % (Matrix size: nHiddenNode (+1 for bias) X total features) % *) ELMModel.outputWeight - output weight of ELM % (Matrix size: total classes X nHiddenNode) % *) trainAcc - training accuracyif size(feature, 2) == 0fprintf('Someting went wrong, no feature selected.');returnend% STEP 1: RANDOMLY ASSIGN INPUT WEIGHT AND BIAS 隨機分配輸入權(quán)重和偏差minWeight = -1;maxWeight = 1;inputWeight = (maxWeight-minWeight) .* ...rand(nHiddenNode, size(feature, 2)+1) + minWeight;% STEP 2: CALCULATE THE HIDDEN LAYER OUTPUT MATRIX H 計算隱含層輸出矩陣H% linear combination of hidden output 線性組合的隱藏輸出hiddenOutput = (inputWeight(:, 1:end-1) * feature')+ ...repmat(inputWeight(:, end), 1, size(feature, 1));% apply activation function on hidden output 對隱藏輸出應(yīng)用激活函數(shù)hiddenOutput = sigmoid(hiddenOutput); % function y = sigmoid(x)% y = 1./(1 + exp(-1.*x));% end% STEP 3: CALCULATE THE OUTPUT WEIGHT B 計算輸出權(quán)值B% estimate output weightoutputWeight = target' * pinv(hiddenOutput); % pinv函數(shù)-求矩陣的偽逆矩陣% STEP 4: APPLY MODEL TO TRAINING DATA 將模型應(yīng)用訓練數(shù)據(jù)% linear combination of predicted output 預(yù)測輸出的線性組合predictedOutput = outputWeight * hiddenOutput;% apply activation function on predicted output 對預(yù)測輸出應(yīng)用激活函數(shù)predictedOutput = sigmoid(predictedOutput);maxPred = max(predictedOutput); predictedClass = zeros(size(predictedOutput, 2), 1);for i=1:size(predictedOutput, 2)class = find(predictedOutput(:, i) == maxPred(i));predictedClass(i) = class(1, 1);endtrainAcc = sum(predictedClass == vec2ind(target')')/ ... % vec2ind:向量到索引,向量中每一列中的所有元素有且只能有一個為1,向量的列數(shù)即為索引矩陣的列數(shù)size(predictedOutput, 2) * 100;ELMModel.inputWeight = inputWeight;ELMModel.outputWeight = outputWeight; endfunction testAcc = testELM(feature, target, ELMModel) %Test Extreme Learning Machine (ELM) model % Syntax: % testAcc = testELM(feature, target, ELMModel) % % Input: % *) feature - feature collection % (Matrix size: total samples X total features) % *) target - target of each sample % (Matrix size: total samples X total classes) % Example: class 4 -> target is [0 0 0 1] % *) ELMModel - ELMModel generated from trainELM() function % % Output: % *) testAcc - testing accuracy% linear combination of hidden outputhiddenOutput = (ELMModel.inputWeight(:, 1:end-1) * feature')+ ...repmat(ELMModel.inputWeight(:, end), 1, size(feature, 1)); % apply activation function on hidden outputhiddenOutput = sigmoid(hiddenOutput);% linear combination of predicted outputpredictedOutput = ELMModel.outputWeight * hiddenOutput;% apply activation function on predicted outputpredictedOutput = sigmoid(predictedOutput);maxPred = max(predictedOutput);predictedClass = zeros(size(predictedOutput, 2), 1);for i=1:size(predictedOutput, 2)class = find(predictedOutput(:, i) == maxPred(i));predictedClass(i) = class(1, 1);endtestAcc = sum(predictedClass == vec2ind(target')')/ ...size(predictedOutput, 2) * 100; end

?

?

總結(jié)

以上是生活随笔為你收集整理的睡眠阶段分期——SVM和ELM分别与粒子群算法结合(function)的全部內(nèi)容,希望文章能夠幫你解決所遇到的問題。

如果覺得生活随笔網(wǎng)站內(nèi)容還不錯,歡迎將生活随笔推薦給好友。

亚洲va天堂va欧美ⅴa在线 | 超碰在线公开免费 | 99精品免费久久久久久久久日本 | 激情综合网色播五月 | 丁香花中文字幕 | 国产精品中文在线 | .国产精品成人自产拍在线观看6 | 国产成人在线网站 | 午夜视频导航 | 国产91精品看黄网站在线观看动漫 | 国产999精品久久久久久 | 在线黄色免费av | 婷婷色伊人 | 国产盗摄精品一区二区 | 欧美日韩国产mv | 99久久网站 | 黄色av免费 | 中文字幕国产 | 精品综合久久久 | 久久视奸 | 97在线观看免费观看 | 色丁香婷婷 | 久草在线最新免费 | 色婷婷丁香| 中文字幕精品三级久久久 | 久久综合色8888 | 色网免费观看 | 视频一区二区国产 | 天天天综合 | 国产精品视频免费看 | 黄色免费网战 | 久久中文网 | 久久这里只有精品23 | 色福利网站 | 国产精品69久久久久 | 日日夜夜添 | www.在线观看视频 | 在线观看久久久久久 | 美国av大片| 色综合天天综合 | 美女福利视频 | 久久婷婷久久 | 日韩免费电影在线观看 | www.天天干| 久久亚洲婷婷 | 久久综合九色欧美综合狠狠 | 亚洲最新av网站 | 伊人亚洲综合网 | 91av蜜桃| 五月黄色 | 韩国av一区二区三区 | 韩国三级一区 | 一级黄色a视频 | 99视频| 久草在线免费看视频 | 免费h在线观看 | 欧美 激情在线 | 天天色婷婷| 天天拍天天操 | 国产精品免费一区二区 | 中文字幕av网站 | 婷婷丁香在线观看 | 久久免费视频在线观看6 | 亚洲精品在线观看不卡 | 美女网站在线观看 | 国产免费叼嘿网站免费 | 国产精品婷婷午夜在线观看 | 亚洲乱亚洲乱亚洲 | 久久这里只有精品首页 | 99国产精品久久久久久久久久 | 91最新网址| 中文字幕一区在线 | 欧美国产视频在线 | 四虎成人精品永久免费av | 午夜视频在线瓜伦 | 欧美人交a欧美精品 | 又长又大又黑又粗欧美 | 欧美精品久久久久久 | 国产在线v| 国产又粗又硬又爽视频 | 色网站在线观看 | 亚洲精选在线观看 | 麻豆免费视频网站 | 国产亲近乱来精品 | 欧美成人h版 | 深夜免费福利在线 | 精品999在线 | 国产精品大全 | 国产做aⅴ在线视频播放 | 91精品综合在线观看 | 狠狠狠综合 | 欧美91精品 | 欧美激情综合色 | 国产又粗又猛又爽又黄的视频免费 | 99视频精品全部免费 在线 | 国产 字幕 制服 中文 在线 | 欧美日韩在线观看不卡 | www.com久久久 | 亚洲午夜久久久综合37日本 | 欧美激情视频一区二区三区免费 | 精品国产电影一区二区 | 五月综合婷 | 亚洲1区在线 | 欧美激情第一区 | 亚洲国产精品999 | 欧美 亚洲 另类 激情 另类 | 97在线观看免费视频 | 亚洲无吗视频在线 | 亚洲另类人人澡 | 五月综合色婷婷 | 日韩一区二区三区高清在线观看 | 91精品国产91p65 | 在线三级av | 亚洲天堂精品视频 | 精品一区二区电影 | 欧美日韩一区二区在线观看 | 91成品人影院 | 亚洲涩涩网 | 热久久最新地址 | 99久久夜色精品国产亚洲96 | 免费99精品国产自在在线 | 欧美激情va永久在线播放 | 五月激情六月丁香 | 在线免费观看成人 | 成人av视屏| 精品国产精品久久 | 一级免费av | 激情五月av | 中文国产成人精品久久一 | 又黄又刺激的视频 | 91精品国产综合久久久久久久 | 亚洲精品乱码久久久久v最新版 | 久久视频在线免费观看 | 亚洲精品国产自产拍在线观看 | 免费日韩一区二区三区 | 免费福利小视频 | 国产亚洲精品成人av久久影院 | 日韩免费精品 | 99婷婷狠狠成为人免费视频 | 在线视频99| 久久久久久国产精品免费 | 日本中文不卡 | 精品在线视频观看 | 二区三区在线 | 韩国一区二区三区视频 | 国产一级视频在线免费观看 | 97超碰免费在线 | 国产99视频在线观看 | 国产精品久久久久久久久久久久 | 亚洲在线日韩 | 六月婷操| 99久久夜色精品国产亚洲96 | 国产欧美精品一区二区三区 | 香蕉网在线观看 | 99国产高清| 久久视频免费在线观看 | 激情网综合 | 波多野结衣一区 | 最新中文字幕 | 亚洲一区视频在线播放 | 亚洲在线观看av | 一区二区在线不卡 | 天天色成人网 | 国产专区在线看 | 久久久精品在线观看 | 伊人宗合网 | 高清av中文字幕 | 在线观看一区二区精品 | 成人h电影在线观看 | 91人人网| 香蕉一区 | 探花视频在线观看免费版 | 五月婷婷影院 | 午夜精品久久久久久久久久久久久久 | 成人黄色小视频 | 中文字幕第一页在线视频 | 天堂av在线网 | 国产视频美女 | 天天操天天爽天天干 | 伊人久久婷婷 | 久久99久久99精品 | 最近最新mv字幕免费观看 | 免费一级毛毛片 | 国产成人精品综合久久久久99 | 久草久草久草久草 | 国产成人福利在线 | 国产成人精品一区二区三区福利 | 久久高清国产视频 | 国产五月 | 亚洲香蕉在线观看 | 久久av免费| 香蕉在线观看 | 国产在线精品观看 | 97在线观看视频 | 在线观看av中文字幕 | 亚洲视频在线免费看 | 国产精品免费观看久久 | 国内外成人在线视频 | 国产黄色精品在线观看 | 国产精品毛片一区二区三区 | 精品国产资源 | 日韩一区二区三区高清免费看看 | 免费日韩一级片 | 激情五月五月婷婷 | 亚洲综合在线播放 | 97超碰成人在线 | 三三级黄色片之日韩 | 97视频一区| 日韩一区二区三区观看 | 久9在线| 天天干夜夜夜 | 婷婷五综合 | 国产三级在线播放 | 五月激情丁香婷婷 | 四虎成人精品永久免费av | 久久精品在线 | 最近中文字幕完整视频高清1 | 婷婷亚洲五月色综合 | 久久69精品 | 9999在线观看| 美女视频黄是免费的 | 亚洲人人av | 精品999在线 | 中文字幕999 | 日日干干| 久久久久久久久久网 | 久久97视频| 99久久精品久久亚洲精品 | 黄色app网站在线观看 | 亚洲精品在线观看av | 国产婷婷一区二区 | 欧美超碰在线 | 91完整版观看 | 日本护士三级少妇三级999 | 91黄色视屏 | 五月婷婷另类国产 | 激情五月在线观看 | 久久精品视频2 | 97国产精品亚洲精品 | 免费看的国产视频网站 | 中文字幕资源在线 | 日韩激情视频在线 | 国产精品久久久久久久久免费看 | 激情丁香综合 | 深爱激情站| 国产91在| 久草精品电影 | 成人理论在线观看 | 在线中文字幕电影 | 亚洲h色精品 | 亚洲精品视频在线 | 国产精品久久片 | 在线视频观看亚洲 | 日韩高清一二区 | www.久艹| 日韩手机在线 | 久久免费在线 | 久草在线免费看视频 | 中文国产成人精品久久一 | 热精品| 免费观看国产精品视频 | 亚洲精品88欧美一区二区 | 伊人激情综合 | 97超级碰 | 最新中文字幕在线资源 | 中文字幕一区二区三 | 黄色成人在线网站 | .精品久久久麻豆国产精品 亚洲va欧美 | 大型av综合网站 | 久久免费国产视频 | 日韩在线免费视频观看 | 婷婷久久婷婷 | 午夜黄色影院 | 一区二区视频在线观看免费 | 亚洲欧洲国产精品 | 亚洲成av人片在线观看无 | 日韩av黄| 久久久久久久久久久久久9999 | 91自拍视频在线观看 | 久久精品视 | 色婷婷六月| 国产视频高清 | 日韩免费高清在线 | 超碰在线公开免费 | 国产专区在线播放 | 亚洲视频免费视频 | 国产成人香蕉 | 色久天| 久久亚洲免费视频 | 日韩综合视频在线观看 | 91九色porn在线资源 | av丝袜天堂 | 国产精品黄网站在线观看 | 992tv在线观看网站 | 国产成人亚洲在线电影 | 国产手机视频精品 | 高清免费av在线 | 四川bbb搡bbb爽爽视频 | 免费在线观看污 | 欧美精品在线视频 | 午夜精品久久久久久久99热影院 | 91成人看片| 九九热只有精品 | 国产一区二区三区视频在线 | 中文字幕在线观看视频网站 | 天天干,天天草 | 国产视频黄 | 美女视频黄免费 | 在线日本看片免费人成视久网 | 久久精品电影 | 超碰在线观看av | 天堂av最新网址 | 狠狠干夜夜爱 | 91麻豆文化传媒在线观看 | 精品国产不卡 | 久草av在线播放 | 久久不见久久见免费影院 | 国产精品普通话 | 深爱五月激情五月 | av午夜电影 | 综合久久五月天 | www.狠狠色 | 久久综合爱 | 玖草影院 | 亚洲女欲精品久久久久久久18 | 丁香婷婷射 | 中文字幕在线观看av | 18做爰免费视频网站 | 97超碰人人澡人人爱学生 | 在线看v片成人 | 日韩在线短视频 | 天天操夜夜做 | 不卡的av在线播放 | 精品96久久久久久中文字幕无 | 国产无套精品久久久久久 | 亚洲v欧美v国产v在线观看 | 91精品第一页 | 成年人在线观看网站 | 日本黄色免费观看 | 91亚瑟视频 | 免费福利片 | 综合久久一本 | 首页av在线| 亚洲黄色影院 | 久久精品一区二区三区国产主播 | 亚洲 欧美 日韩 综合 | ,午夜性刺激免费看视频 | 91精品视屏 | 91视视频在线直接观看在线看网页在线看 | 日韩色视频在线观看 | 园产精品久久久久久久7电影 | 天天爱av导航 | 免费a视频在线观看 | 国产精品免费大片视频 | 亚洲精品在线免费播放 | 在线免费av网站 | 日韩精品一区二区三区第95 | av中文字幕网 | 国产精品久久久久久久7电影 | 2019av在线视频 | 亚洲精品国产品国语在线 | 黄色在线观看免费网站 | av在观看 | 国产美女精品视频免费观看 | 国产视频1| 国产精品专区h在线观看 | 麻豆播放| 热久久99这里有精品 | 人人爽人人爽人人片 | 天天操夜| 亚洲精品tv| 91精品国自产拍天天拍 | 免费黄色a级毛片 | 国产免费高清 | 激情欧美在线观看 | 亚洲精选在线观看 | 亚洲综合国产精品 | 91久久在线观看 | 亚州av网站大全 | 免费看黄的 | 久久国产精品精品国产色婷婷 | 激情久久一区二区三区 | 成人黄色电影免费观看 | 亚洲欧美精品在线 | 日韩色综合 | 天天射夜夜爽 | 在线播放av网址 | 激情视频二区 | 2019中文最近的2019中文在线 | 黄色三级av | 国产一级片直播 | 麻豆免费看片 | 日韩网站一区 | 国产精品99爱 | 特级毛片网站 | 波多野结衣视频一区二区 | 日日夜夜国产 | 免费高清在线观看成人 | 欧美日韩在线播放一区 | 九九久久成人 | 韩国在线一区 | 91成年人在线观看 | www.成人sex | 欧产日产国产69 | 欧美超碰在线 | 久久久久久久久久久网 | 国产成人精品免高潮在线观看 | 成人精品视频 | 91传媒在线播放 | 国产午夜三级一二三区 | 日韩精品一区在线观看 | 999日韩| 午夜影院先 | 三级性生活视频 | 久久av中文字幕片 | 国产精品网在线观看 | 在线国产不卡 | 91国内在线视频 | 免费在线观看日韩视频 | 久久精品网站免费观看 | 日韩在线观看网址 | 午夜国产一区二区 | 免费福利在线播放 | 五月天亚洲精品 | 日韩3区| 在线观看国产日韩欧美 | 国产视频精品久久 | 一区二区久久久久 | 日韩va亚洲va欧美va久久 | 中国一区二区视频 | 国内精品一区二区 | 色999视频| 精品超碰 | 国产午夜在线观看视频 | 国产精品一区二区三区在线免费观看 | 色视频网站在线观看一=区 a视频免费在线观看 | 日韩在线电影观看 | 国产精品12 | 婷婷久草 | 国产黄色一级片在线 | 四虎影视精品永久在线观看 | 天天摸日日摸人人看 | 欧美日韩国产在线精品 | 伊人天天操 | 91九色蝌蚪视频 | 98超碰在线| 国产高清视频在线 | 91毛片在线 | 日韩久久久久久久久久 | 日韩精品一区二区在线视频 | 国产一区在线不卡 | 久久成人精品电影 | 久久久www成人免费精品张筱雨 | wwwav视频| 99精品国产aⅴ | 日韩大片在线免费观看 | 久久这里只有精品1 | 在线草| 91桃色国产在线播放 | 天堂激情网 | 日本护士撒尿xxxx18 | 波多在线视频 | 欧美极品少妇xbxb性爽爽视频 | 一级做a视频 | 久久久亚洲影院 | 久久香蕉国产精品麻豆粉嫩av | 在线看片成人 | 国产精品 亚洲精品 | 日本69hd| 国产九九九精品视频 | 欧美91视频| 91在线视频播放 | 亚州av网站大全 | 久久一区91 | a√资源在线 | 久久人人爽av | 国产精品久久一区二区三区, | 超碰在97| 91精品视频在线免费观看 | 99视频免费在线观看 | 九九精品久久久 | 天天操夜夜干 | 色综合久久综合网 | 国产精品一区二区精品视频免费看 | 久久免费视频在线观看30 | 中午字幕在线观看 | 正在播放国产91 | 日韩国产欧美在线视频 | 成年人免费电影在线观看 | 91在线观看欧美日韩 | 免费黄a大片 | 亚洲高清视频一区二区三区 | 成人精品一区二区三区中文字幕 | 亚洲精品色婷婷 | 国产国语在线 | 伊人宗合网 | 狠狠色狠狠色综合系列 | 在线观看中文字幕av | 国产精品av在线 | 亚州国产精品 | 国产精品美女999 | 99精品国产兔费观看久久99 | 久久成人人人人精品欧 | 日韩欧美在线观看一区二区 | 91av电影在线观看 | 欧美与欧洲交xxxx免费观看 | 91热视频在线观看 | 97电影手机版 | 天天插天天操天天干 | 91在线免费播放视频 | 欧美日比视频 | 亚洲成年片 | 国产91电影在线观看 | 亚洲首页 | 99色在线视频 | 色婷五月天 | 狠狠操狠狠 | av午夜电影| 亚洲精品国产综合99久久夜夜嗨 | 最新在线你懂的 | 国产欧美日韩视频 | 97在线视频观看 | 亚洲五月婷婷 | 九九热99视频 | 国产久视频 | 91麻豆精品国产自产在线 | 欧美激情视频一区二区三区 | 成人在线一区二区三区 | 亚洲精品在线观看免费 | 六月丁香激情综合色啪小说 | www亚洲一区 | 一区二区欧美激情 | 黄色毛片观看 | 日韩美女免费线视频 | 美女网站免费福利视频 | 视频一区二区国产 | 91av手机在线 | 在线观影网站 | 天天操狠狠操夜夜操 | 久久精品视频在线 | 欧美日韩一区二区三区不卡 | 国产精品2区 | 午夜影视av | 99久久免费看 | 夜夜躁天天躁很躁波 | 在线中文字幕网站 | 91九色视频国产 | 狠狠狠干狠狠 | 国产一级二级三级在线观看 | 欧美精品xx| 五月天久久婷婷 | 综合网天天 | 欧美精品色 | 日本久久精品视频 | 9色在线视频 | 91成人精品在线 | 免费看亚洲毛片 | 亚洲精品在线一区二区三区 | 在线小视频 | 亚洲一区免费在线 | 国产亚洲精品中文字幕 | 日本中文字幕网址 | 成人超碰在线 | 中日韩免费视频 | 黄视频网站大全 | 人人操日日干 | 国产高清综合 | 日本久久久久 | 亚洲精品国产精品国自 | 免费观看国产成人 | 久草在线免费在线观看 | 亚洲男男gaygayxxxgv | 九九视频热 | 欧美日韩视频免费 | 久草视频资源 | 日韩一区二区三区在线看 | 2021av在线 | 欧美日本啪啪无遮挡网站 | av在线一二三区 | 片黄色毛片黄色毛片 | 国产精品自在线 | 美女久久久久久久久久 | 外国av网| 五月婷香 | 久久99在线视频 | 一级片在线 | 九九视频精品在线 | 欧美成年网站 | 国产精品刺激对白麻豆99 | 免费观看一级成人毛片 | 一级性生活片 | 日韩av在线免费播放 | 亚洲黄色影院 | 色狠狠综合天天综合综合 | 久久久不卡影院 | 亚洲黄色影院 | 国产亚洲成人精品 | 欧美精品久久久久久久久免 | 婷婷精品国产一区二区三区日韩 | 在线观看国产区 | 黄色特级毛片 | 国产黄色特级片 | 区一区二区三在线观看 | 欧美日韩在线电影 | 免费看黄色小说的网站 | 99亚洲精品在线 | 亚洲精品国产精品国自产在线 | 这里有精品在线视频 | 激情深爱.com | 91精品小视频| 国产最新在线观看 | 九九热精品视频在线观看 | 久久精品最新 | 亚洲免费精彩视频 | 视频国产精品 | 99精品免费在线 | 亚洲婷婷综合色高清在线 | 99久久精品视频免费 | 日韩视频精品在线 | 欧美乱淫视频 | 欧美亚洲一区二区在线 | av电影不卡 | 精品国产精品一区二区夜夜嗨 | 精品视频网站 | 欧美一区二区三区特黄 | 在线国产黄色 | 天天干天天射天天操 | 久久字幕网 | 天天操天天怕 | 色婷婷精品 | 四虎影视精品永久在线观看 | 亚洲最新av在线网站 | 日韩高清在线一区二区三区 | 国产精品破处视频 | 久久久精品国产免费观看一区二区 | 看国产黄色大片 | 婷婷在线精品视频 | 91av视频在线观看免费 | 成人丁香花 | 久草在线中文视频 | 欧美视频日韩 | 成人动态视频 | 成 人 黄 色 视频免费播放 | 91视频一8mav | 色a4yy| 狠狠色丁香久久婷婷综合五月 | 久久综合婷婷综合 | 超碰在线最新地址 | 视频在线观看99 | 永久免费毛片 | 久久成人精品视频 | 国产一级片不卡 | 在线天堂v | 91最新国产| 国产一区成人在线 | 免费成人看片 | 欧美日韩精品区 | 波多野结衣久久精品 | 国模视频一区二区三区 | 天天做夜夜做 | 婷婷激情小说网 | 91在线观看欧美日韩 | 成人在线观看资源 | 婷婷国产在线 | 欧美午夜性生活 | 91精品国产自产老师啪 | 91精品国产网站 | 97视频人人 | 国产69精品久久久久99 | 在线免费性生活片 | 国产精品久久久av | 国产精品久久久久久久久久东京 | 成年人看片网站 | 色网免费观看 | 国产精品视频最多的网站 | 久久色中文字幕 | 免费看成人 | 国产美女视频黄a视频免费 久久综合九色欧美综合狠狠 | 午夜av网站 | 欧美五月婷婷 | 国产精品一区二区在线播放 | 99久久精品国产观看 | 超碰夜夜 | 九色91在线视频 | 欧美精品网站 | 免费av网址大全 | 狠狠操狠狠干天天操 | 日韩中字在线观看 | 国产精品一区二区在线看 | 日韩一区二区免费视频 | 在线播放国产一区二区三区 | 日韩中文字幕电影 | 国产短视频在线播放 | 久久综合九色欧美综合狠狠 | 久久看片网 | 探花视频在线版播放免费观看 | 特级西西人体444是什么意思 | 亚洲成人av一区二区 | 成人试看120秒 | 久久久久网站 | 日本精品二区 | 日韩亚洲国产中文字幕 | 在线免费看片 | 精品亚洲成a人在线观看 | 蜜臀av性久久久久av蜜臀三区 | 成人久久电影 | 国产精品免费在线播放 | 欧美十八 | 96国产精品| 亚洲精品成人网 | 精品在线视频播放 | 中文字幕一区在线观看视频 | 丁香六月婷婷开心婷婷网 | 九九九九精品九九九九 | 在线免费观看视频a | 国产在线黄色 | 不卡av在线播放 | 五月婷婷黄色 | 在线视频 成人 | 精品视频国产 | 久久久999精品视频 国产美女免费观看 | 玖玖爱在线观看 | 成人教育av | 国产美女在线观看 | 日韩av高潮 | 麻豆视传媒官网免费观看 | 中文字幕日韩一区二区三区不卡 | 亚洲精品自在在线观看 | av青草| 激情文学丁香 | 亚洲高清在线 | 精品国产一区在线观看 | 国产精品99久久久久久宅男 | 久久国产精品久久精品国产演员表 | 久久精品理论 | 韩日成人av | 五月在线视频 | 国产在线观看a | 日韩三级视频在线看 | 久久男人免费视频 | av在线播放国产 | 波多野结衣在线视频一区 | 麻豆国产网站 | 国产精品热视频 | 亚洲 中文字幕av | 国产九色视频在线观看 | 日韩免费电影一区二区三区 | 国产精品久久久久久久久毛片 | 黄色毛片大全 | 欧美日韩在线免费观看 | 中文字幕视频三区 | 国产专区精品视频 | 日韩久久久久久久久久久久 | 午夜美女福利 | 久久精品99久久久久久 | 成人日韩av| 亚洲专区在线视频 | 国产护士在线 | 国产热re99久久6国产精品 | 国产视频第二页 | 亚洲电影网站 | 免费一级片久久 | 亚洲国产精品va在线看黑人动漫 | 成人三级网站在线观看 | 亚洲精品播放 | 午夜精品福利一区二区三区蜜桃 | 欧美日韩国产精品一区二区 | 久久另类视频 | 免费一级特黄毛大片 | 97偷拍视频 | 精品国产乱码久久久久久1区二区 | 精品久久久久久久久久久久久久久久 | 中文字幕在线观看亚洲 | av在线免费网| 成人黄色大片 | 国产免费久久av | 天天躁天天操 | 日韩精品视频在线观看免费 | 久久免费视频4 | www.eeuss影院av撸| 婷婷深爱 | 亚洲精品在线观看中文字幕 | 麻豆一区二区 | 亚洲国产精彩中文乱码av | 国产美女视频黄a视频免费 久久综合九色欧美综合狠狠 | av夜夜操| 国产69久久 | 欧美精品在线观看 | 国产在线播放一区二区 | 最新中文字幕在线播放 | h动漫中文字幕 | 日韩在线一级 | 久久久久久久久影院 | 国产直播av| 色偷偷中文字幕 | 国产精品国产三级国产不产一地 | 黄色av观看 | 91网在线看 | 久久久国产精品亚洲一区 | 久久久国产日韩 | 天天玩天天操天天射 | 99热网站| 99性视频| 日韩在线理论 | 亚洲国内精品在线 | 国产精品一区二区免费 | 麻豆影视在线播放 | 超碰在线公开 | 天堂v中文| 五月激情丁香图片 | 日韩电影精品一区 | 91精品国产乱码在线观看 | 亚欧日韩av | 久草免费电影 | 91精品啪在线观看国产81旧版 | 久久国产精品区 | 99久久99久国产黄毛片 | av一级片网站| 一本一本久久a久久精品牛牛影视 | 久久9精品 | 久久综合一本 | 国产三级av在线 | 日韩爱爱片 | 国产精品免费看 | 女人魂免费观看 | 国产高清在线观看av | 久久精品视频在线免费观看 | 久久国产精品一区二区三区四区 | 国产精品一区二区av影院萌芽 | 精品视频国产一区 | 久久国产精品视频免费看 | a在线播放 | 久久久麻豆精品一区二区 | 亚洲国产高清在线 | 欧美精品999| 精品极品在线 | 日本中文字幕在线观看 | 国产精品自在欧美一区 | 国产精品va在线观看入 | 日韩丝袜视频 | 国内成人精品视频 | 国产日韩精品一区二区三区 | 手机在线欧美 | 97免费中文视频在线观看 | 久久久九色精品国产一区二区三区 | 99r国产精品| 国产精品一区二区在线播放 | 国产视频999| 久久免费在线观看视频 | 91丨九色丨91啦蝌蚪老版 | 欧美黑人巨大xxxxx | 在线看国产日韩 | 在线观看免费黄视频 | 96看片| 天天操天天是 | 国产v在线 | 视频成人免费 | 久久久久久久久久久高潮一区二区 | 精品亚洲免a | 久久久久久久久久久久久9999 | 亚洲精选久久 | 欧美专区国产专区 | 精品亚洲国产视频 | 99精品欧美一区二区三区黑人哦 | 亚洲精品国产精品国自产观看 | 色综合久久中文综合久久牛 | 久久看免费视频 | 精品99久久| 丁香久久激情 | 中文字幕第一页在线vr | 精品人人爽 | 精品一区二区久久久久久久网站 | 日本精品在线 | 国产精品丝袜在线 | 国产69久久久 | 国产成在线观看免费视频 | 有码中文字幕在线观看 | 91在线精品播放 | 国产 av 日韩| 激情五月婷婷 | 黄色小网站免费看 | 在线观看一级片 | 久久久久亚洲国产精品 | 人人干狠狠干 | 国产精品五月天 | 久久久国产一区二区三区四区小说 | 青青河边草观看完整版高清 | 日韩三级一区 | 四虎影视精品永久在线观看 | 中文字幕精品三区 | 亚洲精品视频网址 | 在线免费观看成人 | 精品国产精品国产偷麻豆 | 91色亚洲 | 最新国产视频 | 久久精久久精 | 91精品1区 | 插综合网 | 高清不卡一区二区三区 | 麻豆影视在线观看 | 欧美日韩高清一区二区三区 | 午夜在线国产 | 国产亚洲人| 国产免费一区二区三区最新 | 四川妇女搡bbbb搡bbbb搡 | 黄色在线观看免费 | 99电影 | 国产精品你懂的在线观看 | 亚洲黄色三级 | 免费合欢视频成人app | 91九色精品 | 国产精品一区二区三区电影 | 91精品伦理 | 日韩精品欧美一区 | 69精品| 日韩高清不卡一区二区三区 | 亚洲一区日韩在线 | 91网站在线视频 | av大片免费在线观看 | 久久国语 | 99视频免费在线观看 | www.夜夜干.com | 五月的婷婷 | 免费观看一区二区三区视频 | 不卡av在线免费观看 | av色图天堂网| 高清不卡一区二区三区 | 91色吧| 五月av在线 | 久久久久高清毛片一级 | 国产午夜在线 | 亚洲精品永久免费视频 | 久久久久女教师免费一区 | 久久免费在线观看 | 福利区在线观看 | www亚洲精品 | 国产精品一区在线观看 | av高清网站在线观看 | 天天干天天摸 | 在线观看中文字幕网站 | 国产精品专区一 | 日本久久成人中文字幕电影 | 一区二区欧美在线观看 | 国产亚洲午夜高清国产拍精品 | 午夜av免费 | 久久亚洲电影 | 国产午夜三级一区二区三桃花影视 | 黄色成人毛片 | 国产成人综合在线观看 | 91欧美视频网站 | www久久久久 | 日日成人网 | 992tv成人免费看片 | 亚洲美女视频在线 | a在线v | 国产高清 不卡 | 激情五月亚洲 | 亚洲精品乱码久久久一二三 | 欧美俄罗斯性视频 | 99在线精品视频观看 | 欧美激情视频在线观看免费 | 亚洲国产日韩欧美 | 九七视频在线观看 | 日韩欧美高清一区二区三区 | 国产高清视频免费 | 91精品亚洲影视在线观看 | 看黄色91| 91免费黄视频 | 成人av资源 | 成年人免费看的视频 | 日韩视频免费在线 | 午夜av免费在线观看 | 欧美va天堂在线电影 | 国产一级在线 | 久久精品伊人 | 色噜噜噜| 日韩激情视频在线观看 | 国产一区二区三区久久久 | 婷婷色中文字幕 | 天天综合网天天综合色 | 久久成人免费电影 | 麻豆视频国产在线观看 | 射九九| 亚洲精品免费在线视频 | 亚洲手机天堂 | 国产小视频免费在线观看 | 国产 日韩 在线 亚洲 字幕 中文 | 日韩欧美视频免费观看 | 亚洲精品视频免费观看 | 国产免费亚洲高清 | 在线观看免费版高清版 | 国产五十路毛片 | 美女精品| 国产一区二区三区午夜 | 亚洲影院国产 | 在线观看国产一区 | 天天天射 | 国产欧美久久久精品影院 |