MIToolbox Mutual Information functions for C and M开源项目

我要开发同款
匿名用户2021年11月23日
90阅读

技术信息

开源地址
https://github.com/didi/di18n
授权协议
BSD-3-Clause License

作品详情

MIToolbox

v3.0.1forC/C++adMATLAB/Octave

MIToolboxcotaisasetoffuctiostocalculateiformatiotheoreticquatitiesfromdata,suchastheetropyadmutualiformatio.ThetoolboxcotaisimplemetatiosofthemostpopularShaoetropies,adalsothelesserkowReyietropy.Thetoolboxalsoprovidesimplemetatiosoftheweightedetropyadweightedmutualiformatiofrom"IformatioTheorywithApplicatio",S.Guiasu(1977).Thetoolboxolysupportsdiscretedistributios,asopposedtocotiuous.Allreal-valuedumberswillbeprocessedbyx=floor(x).

Thesefuctiosaretargetedforusewithfeatureselectioalgorithmsratherthacommuicatiochaelsadsoexpectallthedatatobeavailablebeforeexecutioadsampletheirowprobabilitydistributiosfromthedata.

Allfuctiosexpecttheiputstobevectorsormatricesofdoubles.

Fuctioscotaied:

EtropyCoditioalEtropyMutualIformatioCoditioalMutualIformatiogeeratigajoitvariablegeeratigaprobabilitydistributiofromadiscreteradomvariableReyi'sEtropyReyi'sMutualIformatioWeightedEtropyWeightedMutualIformatioWeightedCoditioalMutualIformatio

Note:allfuctiosarecalculatedilogbase2,soreturuitsof"bits".

MIToolboxworksodiscreteiputs,adallcotiuousvaluesmustbediscretisedbeforeusewithMIToolbox.Real-valuediputswillbediscretisedwithx=floor(x)toesurecompatibility.MIToolboxproducesureliableresultswheusedwithcotiuousiputs,russlowlyadusesmuchmorememorythausual.Thediscreteiputsshouldhavesmallcardiality,MIToolboxwilltreatvalues{1,10,100}thesamewayittreats{1,2,3}adthelatterwillbebothfasteraduselessmemory.Thislimitatioisduetothedifficultiesiestimatigiformatiotheoreticfuctiosofcotiuousvariables.

======

Examples:

>>y=[11100]';>>x=[10110]';>>mi(x,y)%%mutualiformatioI(X;Y)as=0.0200>>h(x)%%etropyH(X)as=0.9710>>codh(x,y)%%coditioaletropyH(X|Y)as=0.9510>>h([x,y])%%joitetropyH(X,Y)as=1.9219>>joit([x,y])%%joitradomvariableXYas=12134

======

Allcodeisliceseduderthe3-clauseBSDlicese.

Compilatioistructios:

MATLAB/OCTAVEruCompileMIToolbox.mfromthematlabdirectory.LiuxCsharedlibraryrumakex86ormakex64for32-bitor64-bitversiosrespectively.rusudomakeistalltoistallMIToolboxito/usr/local/libad/usr/local/icludeWidowsCdllistallMiGWfromhttps://sourceforge.et/projects/migw-w64/addMiGWbiariesfolderstoPATH,e.g.migw/bi,migw/msys/birumakex64_witocompilea64-bitWidowsdll.

UpdateHistory

08/02/2017-v3.0.1-BugfixtoesureANSICcompatibility.07/01/2017-v3.0.0-Refactorediteralstoexposeitegeriformatiotheoreticcalculatios.10/01/2016-v2.1.2-RelicesefromLGPLtoBSD.AddedcheckstoesureiputMATLABtypesaredoubles.02/02/2015-v2.1.1-FixeduptheMakefilesoitistallstheheaderstoo.22/02/2014-v2.1-Fixedacoupleofbugsrelatedtomemoryhadlig.AddedamakeistallforcompatibilitywithPyFeast.30/07/2011-v2.00-Addedimplemetatiosoftheweightedetropyadweightedmutualiformatio.MorecleaupofMexetrypoittofurtherchecktheiputs.08/11/2011-v1.03-MiordocumetatiochagestoaccompaytheJMLRpublicatio.15/10/2010-v1.02-FixedbugwhereMIToolboxwouldcauseasegmetatiofaultifaxby0emptymatrixwaspassedi.Nowpritsaerrormessageadretursgracefully.02/09/2010-v1.01-FixedabugiCMIM.mwherethelastfeaturewouldotbeselectedfirstifithadthehighestMI.07/07/2010-v1.00-IitialRelease.

功能介绍

MIToolbox v3.0.1 for C/C++ and MATLAB/Octave MIToolbox contains a set of functions to calculate i...

声明:本文仅代表作者观点,不代表本站立场。如果侵犯到您的合法权益,请联系我们删除侵权资源!如果遇到资源链接失效,请您通过评论或工单的方式通知管理员。未经允许,不得转载,本站所有资源文章禁止商业使用运营!
下载安装【程序员客栈】APP
实时对接需求、及时收发消息、丰富的开放项目需求、随时随地查看项目状态

评论