Search

CN-115661382-B - Filtering method based on morphology template corner preservation in three-dimensional relief reconstruction

CN115661382BCN 115661382 BCN115661382 BCN 115661382BCN-115661382-B

Abstract

The invention provides a filtering method based on morphology template corner preservation in three-dimensional landform reconstruction, relates to the technical field of three-dimensional landform reconstruction, solves the problem that the edge and corner points of a landform cannot be accurately identified and reserved by the current surface filtering method, and cannot accurately recover the true contour of the landform, firstly obtains a landform representation graph of a target landform, then designs a plurality of morphology templates based on the regular shape of the corner points, detects the positions of the edge and the corner points to be processed in the landform representation graph by using the morphology templates, and judging whether the pixel code of the landform characterization map is successfully matched with any morphological template, if so, performing corner-preserving weight filtering treatment on the current pixel code, otherwise, performing median filtering on the current pixel code, and finally, performing post-treatment on the filtered landform characterization map, reconstructing a three-dimensional model of the target ground object based on the treatment result, thereby realizing accurate identification and reservation of the edge and the corner point of the ground object, and accurately recovering the real contour of the ground object.

Inventors

  • ZHENG CHUANJIANG
  • YAN ZHIYUAN
  • JIANG GUANGQUAN
  • DU WEIGANG
  • HUANG WEIJIAN
  • YAN LILING
  • LI FEIYA

Assignees

  • 广州南方卫星导航仪器有限公司

Dates

Publication Date
20260505
Application Date
20220923

Claims (7)

  1. 1. A morphological template-based conformal filtering method in three-dimensional relief reconstruction is characterized by comprising the following steps: s1, determining a target ground object to be processed, and obtaining a landform characterization map of the target ground object; S2, determining the regular shape of the corner point, and constructing a plurality of morphological templates with the same window size based on the regular shape of the corner point; s3, collecting a specific window of the landform characterization graph, preprocessing the specific window, and obtaining pixel codes of the specific window; S4, judging whether the pixel code obtained in the step S3 is matched with any morphological template, if so, carrying out conformal weight filtering on the current pixel code by taking a specific window corresponding to the current pixel code as an angular point, and executing the step S5, otherwise, carrying out median filtering on the current pixel code by taking the specific window corresponding to the current pixel code as an edge; in the step S4, the specific mode of performing the conformal weight filtering is that if the landform characterization image is a parallax image or a depth image, the conformal filtering based on the color distance weight is performed on the parallax image or the depth image; the computational expression of the corner-preserving filtering based on the color distance weight is as follows: Wherein, the Representing the color distance, R c 、G c 、B c represents the RGB color value of the center pixel of the specific window of the disparity map or the depth map, R n 、G n 、B n represents the RGB color value of the neighbor pixel corresponding to the center pixel of the specific window of the disparity map or the depth map, respectively, and the color weight calculation expression of the neighbor pixel corresponding to the center pixel of the specific window of the disparity map or the depth map is: wherein alpha represents a hyper-parameter of 0.5 and gamma represents a hyper-parameter of 60; the computational expression of the conformal filtering based on the elevation distance weight is as follows: Wherein, the Representing the elevation distance, depth c represents the elevation value of the center pixel of the particular window of the DSM graph, depth n represents the elevation value of the neighbor pixel corresponding to the center pixel of the particular window of the DSM graph, and Gao Chengquan weight calculation expression of the neighbor pixel corresponding to the center pixel of the particular window of the DSM graph is: wherein alpha represents a hyper-parameter of 0.5 and gamma represents a hyper-parameter of 60; S5, processing the filtered landform characterization map to obtain a processed landform characterization map; s6, reconstructing a three-dimensional model of the target ground object based on the processed landform characterization map obtained in the S5.
  2. 2. The filtering method based on morphology template corner preservation in three-dimensional landform reconstruction according to claim 1, wherein the landform representation map is a depth map, a parallax map or a DSM map, in step S2, each morphology template corresponds to a regular shape of a corner point, the pixel code of the color image and the pixel code of the elevation image in each morphology template are templates of binary strings, the binary code rule is that a difference value between a gray value of a central pixel point and gray values of surrounding pixel points of the morphology templates is used as a binary template string to be coded, if the difference value between the gray value of the central pixel point and the gray value of the surrounding pixel points is larger than a set depth threshold, the binary bit code of the current pixel point is 1, and otherwise, the binary bit code of the current pixel point is 0.
  3. 3. The filtering method based on morphology template corner preservation in three-dimensional relief reconstruction according to claim 1, wherein in step S3, the size of the specific window of the collected relief representation is the same.
  4. 4. The filtering method based on morphology template corner preservation in three-dimensional relief reconstruction according to claim 2, wherein in step S3, the specific process of preprocessing is: S31, taking a pixel of the landform characterization image as a central pixel of a specific window corresponding to the pixel; S32, carrying out graying if the landform characterization map is a depth map or a parallax map, and not carrying out graying if the landform characterization map is a DSM map; s33, coding the current gray level map or DSM map according to a binary coding rule, and outputting pixel codes of a specific window of the landform characterization map.
  5. 5. The method according to claim 4, wherein in step S33, in the process of encoding the pixels of the current gray-scale map or the pixels of the DSM map, the current gray-scale map is binary-encoded pixel by pixel or Gao Chengjin lines of pixels of the current DSM map are binary-encoded pixel by pixel.
  6. 6. The method of claim 5, wherein in step S4, if the binary string of the current pixel code is identical to the binary string of any one of the morphological templates, the matching between the current pixel code and the current morphological template is successful, otherwise, the matching between the current pixel code and the current morphological template is failed.
  7. 7. The method for filtering the three-dimensional relief reconstruction based on the morphological template corner preservation according to claim 6, wherein in the step S5, the processing of the filtered relief representation map comprises the steps of checking the filtered parallax map to obtain a final parallax map if the relief representation map is a parallax map, and carrying out bilateral filtering on the filtered depth map or the DSM map to obtain the final depth map or the DSM map if the relief representation map is a depth map or a DSM map.

Description

Filtering method based on morphology template corner preservation in three-dimensional relief reconstruction Technical Field The invention relates to the technical field of three-dimensional relief reconstruction, in particular to a morphological template-based conformal filtering method in three-dimensional relief reconstruction. Background When the ground surface building is restored to the real ground feature, the three-dimensional reconstruction is usually carried out on the building through multi-view images, the method is to carry out corresponding post-processing optimization on a parallax image, a depth image or a digital ground surface model (Digital Surface Model, DSM image) of the middle result, and the parallax image, the depth image and the DSM image of the ground feature can be directly reversely calculated to the target ground feature point cloud through the photo pose of a camera, so that the clear, smooth and complete feature of the ground feature in the parallax image and the depth image can be ensured, and a better point cloud initial value can be provided for a follow-up reconstructed higher-quality three-dimensional model, so that the real three-dimensional reconstructed ground feature contour feature is restored. The traditional method generally carries out filtering post-treatment on the parallax image, the depth image or the DSM image directly through median filtering, bilateral filtering and other methods, but only can ensure that the image has a certain smooth effect at the edge, and a better real contour is difficult to recover at the corner point of the ground object so as to influence the quality and the precision of a subsequent reconstructed model. The prior art discloses a surface filtering method, firstly, buildings in a digital orthophoto map are extracted, then, building extraction results and geometric information of the DSM map are weighted, building factors in a sliding window of the DSM map are calculated, filtering parameters in the sliding window are dynamically adjusted according to topography, progressive morphological filtering of self-adaptive parameters is finally realized, non-ground points can be filtered, and meanwhile, ground objects are protected from being lost, but edges and corner points of the ground objects cannot be accurately identified and reserved, and information of the images cannot be fully utilized. Disclosure of Invention In order to solve the problem that the current surface filtering method cannot accurately identify and reserve edges and corner points of ground objects, so that the real contours of the ground objects cannot be accurately restored, the invention provides a filtering method based on morphological template corner preservation in three-dimensional landform reconstruction, which is used for carrying out weighted filtering treatment on the positions of the edges and corner points to be processed in an image, accurately identifying and reserving the edges and the corner points of the ground objects and accurately restoring the real contours of the ground objects. In order to achieve the technical effects, the technical scheme of the invention is as follows: a morphological template-based conformal filtering method in three-dimensional relief reconstruction comprises the following steps: s1, determining a target ground object to be processed, and obtaining a landform characterization map of the target ground object; S2, determining the regular shape of the corner point, and constructing a plurality of morphological templates with the same window size based on the regular shape of the corner point; s3, collecting a specific window of the landform characterization graph, preprocessing the specific window, and obtaining pixel codes of the specific window; S4, judging whether the pixel code obtained in the step S3 is matched with any morphological template, if so, carrying out conformal weight filtering on the current pixel code by taking a specific window corresponding to the current pixel code as an angular point, and executing the step S5, otherwise, carrying out median filtering on the current pixel code by taking the specific window corresponding to the current pixel code as an edge; S5, processing the filtered landform characterization map to obtain a processed landform characterization map; s6, reconstructing a three-dimensional model of the target ground object based on the processed landform characterization map obtained in the S5. In the technical scheme, firstly, a target ground object to be processed is determined, a ground feature representation graph of the target ground object is obtained, then, a plurality of morphological templates with the same specification are designed based on the regular shapes of the corner points, the purpose is to contain the shapes of all the regular corner points, the matching and the reservation of the subsequent corner points are facilitated, then, the designed morphological templates are u