資源簡介
用matlab實現(xiàn)的MPCA算法,需在matlab里安裝張量工具包
代碼片段和文件信息
function?[tUs?odrIdx?TXmean?Wgt]??=?MPCA(TXgndTXtestQmaxK)
%?MPCA:?Multilinear?Principle?Component?Analysis
%
%?%[Prototype]%
%?function?[tUs?odrIdx?TXmean?Wgt]??=?MPCA(TXgndTXtestQmaxK)
%
%?%[Author?Notes]%
%?Author:?Haiping?LU
%?Email?:?hplu@ieee.org???or???eehplu@gmail.com
%?Affiliation:?Department?of?Electrical?and?Computer?Engineering
%??????????????University?of?Toronto
%?Release?date:?June?24?2008?(Version?1.1)
%?Please?email?me?if?you?have?any?problem?question?or?suggestion
%
%?%[Algorithm]%:
%?This?function?implements?the?Multilinear?Principal?Component?Analysis
%?(MPCA)?algorithm?presented?in?the?follwing?paper:
%????Haiping?Lu?K.N.?Plataniotis?and?A.N.?Venetsanopoulos
%????“MPCA:?Multilinear?Principal?Component?Analysis?of?Tensor?objects“
%????IEEE?Transactions?on?Neural?Networks
%????Vol.?19?No.?1?Page:?18-39?January?2008.
%?Please?reference?this?paper?when?reporting?work?done?using?this?code.
%
%?%[Toolbox?needed]%:
%?This?function?needs?the?tensor?toolbox?available?at
%?http://csmr.ca.sandia.gov/~tgkolda/TensorToolbox/
%
%?%[Syntax]%:?[tUs?odrIdx?TXmean?Wgt]??=?MPCA(TXgndTXtestQmaxK)
%
%?%[Inputs]%:
%????TX:?the?input?training?data?in?tensorial?representation?the?last?mode
%????????is?the?sample?mode.?For?Nth-order?tensor?data?TX?is?of?
%????????(N+1)th-order?with?the?(N+1)-mode?to?be?the?sample?mode.
%????????E.g.?30x20x10x100?for?100?samples?of?size?30x20x10
%????????If?your?training?data?is?too?big?resulting?in?the?“out?of?memory“
%????????error?you?could?work?around?this?problem?by?reading?samples?one?
%????????by?one?from?the?harddisk?or?you?could?email?me?for?help.
%
%????gndTX:?the?ground?truth?class?labels?(123...)?for?the?training?data
%???????????E.g.?a?100x1?vector?if?there?are?100?samples
%???????????If?the?class?label?is?not?available?(unsupervised?learning)
%???????????please?set?gndTX=-1;
%
%????testQ:?the?percentage?of?variation?kept?in?each?mode?suggested?value
%???????????is?97?and?you?can?try?other?values?e.g.?from?95?to?100?to
%???????????see?whether?better?performance?can?be?obtained.
%
%????maxK:?the?maximum?number?of?iterations?suggested?value?is?1?and?you?
%??????????can?try?a?larger?value?if?computational?time?is?not?a?concern.
%
%?%[Outputs]%:
%????tUs:?the?multilinear?projection?consiting?of?N
%?????????projection?matrices?one?for?each?mode
%
%????odrIdx:?the?ordering?index?of?projected?features?in?decreasing??
%????????????variance?(if?unsupervised)?or?discriminality?(if?supervised)??
%????????????for?vectorizing?the?projected?tensorial?features
%
%????TXmean:?the?mean?of?the?input?training?samples?TX
%
%????Wgt:?the?weight?tensor?for?use?in?modified?distance?measures.?Please
%?????????refer?to?Section?IV.B?and?IV.C?of?the?paper.
%
%?%[Supported?tensor?order]%
%?This?function?supports?N=234?for?other?order?N?please?modify?the
%?codes?accordingly?or?email?hplu@ieee.org?or?eehplu@gmail.com?fo
評論
共有 條評論