电子测量技术ELECTRONICMEASUREMENTTECHNOLOGY第45卷第23期2022年12月DOI:10.19651/j.cnki.emt.2210023基于改进Census变换和自适应权重的立体匹配算法张杰1,2,3王增才1,2,3闫明1,2,3(1.山东大学机械工程学院济南250061;2.山东大学高效洁净机械制造教育部重点实验室济南250061;3.山东大学机械工程国家级实验教学示范中心济南250061)摘要:针对传统Census算法过于依赖中心像素,从而易受噪声影响和AD-Census算法不能充分利用不同算法的优势等问题,本文提出了一种改进的Census变换和自适应权重的立体匹配算法。首先利用Census变换窗口内的均值及中心点与四个方向邻域像素的信息,将相近像素点自动归为一类,提高了Census变换对噪声的鲁棒性。其次引入SAD算法与Sobel边缘检测,根据梯度信息来确定SAD与Census变换的权重,提高了算法在不同区域的适应性。最后采用十字交叉域的代价聚合方式及后续优化得到最终的视差图。将不同图像的视差图在Middlebury平台上进行验证,本文所提算法的平均误差为9.33%较AD-Census算法下降了3.39%。较其它算法在视差不连续区域及重复纹理区具有更好的匹配精度,对噪声及光照也具有更好的鲁棒性。关键词:Census变换;自适应权重;立体匹配;边缘检测;十字交叉域中图分类号:TP301.6文献标识码:A国家标准学科分类代码:510.4050StereomatchingalgorithmbasedonimprovedCensustransformandadaptiveweightZhangJie1,2,3WangZengcai1,2,3YanMing1,2,3(1.SchoolofMechanicalEngineering,ShandongUniversity,Jinan250061,China;2.KeyLaboratoryofEfficientandCleanMachineryManufacturingofMinistryofEducation,ShandongUniversity,Jinan250061,China;3.MechanicalEngineeringNationalExperimentalTeachingDemonstrationCenter,ShandongUniversity,Jinan250061,China)Abstract:AimingattheproblemthatthetraditionalCensusalgorithmistoodependentonthecenterpixel,whichissusceptibletonoise,andtheAD-Censusalgorithmcannotmakefulluseoftheadvantagesofdifferentalgorithms,thispaperproposesanimprovedCensustransformationandadaptiveweightstereomatchingalgorithm.Firstly,themeanvalueoftheCensustransformwindowandthepixelinformationofthecenterpointandneighborhoodinfourdirectionsareusedtoautomaticallyclassifytheclosepixelsintooneclass,whichimprovestherobustnessoftheCensustransformagainstnoise.Secondly,theSADalgorit...