The invention relates to the technical field of stereo vision, in particular to a
stereo matching method. The method solves the problem that the accuracy of disparity correction optimization of the existing
stereo matching method is insufficient. The
stereo matching method based on disparity map
pixel classification correction optimization comprises the following steps that (I)
cost aggregation is conducted by taking a left view and a right view as references and based on a method combining a gray scale difference with a gradient, and a left disparity map and a right disparity map are obtained and subjected to left and right consistency detection to generate an initial reliable disparity map; (II) correlation credibility detection and weak texture area detection are conducted, and a pixel is classified into stable matching pixel points, unstable matching pixel points,
occlusion area pixel points and weak texture area pixel points; (III) the unstable matching points are corrected by an adaptive weight
algorithm based on improvement, and the
occlusion area points and the weak texture area points are corrected by a mismatching pixel
correction method; and (IV) the corrected disparity maps are optimized by an
algorithm based on division, and dense disparity maps are obtained.