Search

CN-122023206-A - Open-air core box corner extraction and perspective distortion correction method based on multi-scale Retinex fusion

CN122023206ACN 122023206 ACN122023206 ACN 122023206ACN-122023206-A

Abstract

The invention provides a field core box corner extraction and perspective distortion correction method based on multi-scale Retinex fusion, which comprises the steps of S1, core box image preprocessing based on anisotropic diffusion and multi-scale Retinex fusion, S2, core box corner extraction based on topological constraint Shi-Tomasi and graph cut optimization interaction, S3, perspective correction based on thin plate spline transformation and Markov random field fusion, S4, correction result accuracy verification and closed loop feedback based on Hough transformation straight line fitting and geometric moment invariant fusion. The method realizes accurate extraction of the corner points of the core box and efficient distortion correction of the images, and simultaneously completes full-dimensional accuracy verification of correction results, adaptive migration of processing parameters of batch images and light-weight field deployment of algorithms.

Inventors

  • XIAO JIALIANG
  • LOU YUMING
  • ZHAO JUNKANG
  • Zhong Rubiao
  • ZHAN SHULIN
  • GONG JIANSHENG

Assignees

  • 紫金矿业集团西南地质勘查有限公司

Dates

Publication Date
20260512
Application Date
20260415

Claims (10)

  1. 1. The field core box corner extraction and perspective distortion correction method based on multi-scale Retinex fusion is characterized by comprising the following steps of: S1, acquiring a core box of a field exploration site to obtain an original core box image, and processing the original core box image by adopting an iterative algorithm of anisotropic diffusion and multi-scale Retinex fusion to obtain a preprocessed core box image; S2, processing the preprocessed core box image by adopting an iterative algorithm of topological constraint Shi-Tomasi and graph cut optimization interaction to obtain four core box angular point coordinates sequenced in the sequence of upper left, upper right, lower right and lower left; S3, performing perspective transformation correction by adopting an iterative algorithm of thin plate spline transformation and Markov random field fusion and combining the preprocessed core box image and four core box angular point coordinates to obtain a corrected core box image; And S4, performing full-dimensional accuracy verification on the corrected core box image by adopting an algorithm of Hough transformation straight line fitting and geometric moment invariant fusion, obtaining a final corrected core box image if verification is qualified, generating a feedback adjustment instruction if verification is unqualified, transmitting the feedback adjustment instruction to a corresponding step in S1, S2 or S3, and re-executing subsequent steps after adjusting processing parameters of the corresponding step until verification is qualified.
  2. 2. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion according to claim 1 is characterized in that the specific processing mode of an iterative algorithm of anisotropic diffusion and multi-scale Retinex fusion in S1 is that firstly, multi-scale Retinex initial decomposition is carried out on an original core box image to obtain an initial illumination component and an initial reflection component, then, an anisotropic diffusion conduction coefficient is calculated based on the initial illumination component, an intermediate image is obtained by updating the original core box image through the conduction coefficient, then, the reflection component is adjusted through the intermediate image, the illumination component is updated through the adjusted reflection component, and the steps of conduction coefficient calculation, image updating, interaction updating of the reflection component and the illumination component are repeated until iteration converges, and a preprocessed core box image is obtained.
  3. 3. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion is characterized in that the specific processing mode of an iterative algorithm of topological constraint Shi-Tomasi and graph cut optimization interaction in S2 is that an autocorrelation matrix is calculated on a preprocessed core box image, an initial Shi-Tomasi corner point response value is obtained based on a characteristic value of the autocorrelation matrix, a graph cut model containing data items and smooth items is built, the data items are determined by the current Shi-Tomasi corner point response value, the smooth items are determined by rectangular topological constraint of the core box, a minimum cut maximum flow algorithm is adopted to solve the graph cut model to obtain candidate corner points, the topological confidence of the candidate corner points is calculated, the steps of constructing the graph cut model, solving, calculating the topological confidence and adjusting the corner point response value are repeated until four core box corner point coordinates are obtained by means of iterative convergence.
  4. 4. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion is characterized in that the specific processing mode of an iterative algorithm of sheet spline transformation and Markov random field fusion in S3 is that four core box corner point coordinates are used as control points, target correction rectangular corner point coordinates are set, an initial sheet spline transformation matrix is solved through a least square method, initial perspective correction is conducted on a preprocessed core box image to obtain an initial correction image, a Markov random field model containing observation items and smooth items is built again, the observation items are determined by local edge intensity of the initial correction image, the smooth items are determined by difference of coordinate offsets of adjacent pixels, an iterative condition mode algorithm is adopted to solve the Markov random field model to obtain optimal coordinate offsets, the spline transformation matrix is solved again and corrected by adjusting sheet spline transformation control points of the next iteration of the optimal coordinate offsets, and the steps of Markov random field model construction, solving, coordinate offset calculation and control point adjustment are repeated until iterative convergence is achieved, and the corrected core box image is obtained.
  5. 5. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion is characterized in that S4 is characterized in that a full-dimensional accuracy verification is carried out by adopting an algorithm of Hough transformation straight line fitting and geometric moment invariant fusion, wherein four outline straight lines are extracted from corrected core box images through improved probability Hough transformation, orthogonality errors, parallelism errors and side length proportional errors of the straight lines are calculated to obtain straight line fitting comprehensive errors, geometric moment of the corrected core box images is calculated to obtain central moment and normalized central moment based on the geometric moment, seven Hu invariant moment are obtained, sum of relative errors of Hu invariant moment and Hu invariant moment of standard rectangles of the corrected images is calculated to obtain moment invariant moment errors, and finally, the total correction errors are obtained by combining the straight line fitting comprehensive errors and the moment invariant moment errors, and meanwhile, corner point positioning errors, image edge distortion rates, geometric perspective distortion rates and aspect ratio errors are verified, and verification qualification is judged when all indexes meet preset requirements.
  6. 6. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion according to claim 1 is characterized by further comprising the step of carrying out self-adaptive parameter migration on batch core box images after final correction, wherein the final corrected core box images are used as reference images, multi-dimensional feature vectors of the reference images and batch core box images to be processed are extracted, the multi-dimensional feature vectors are mapped into a low-dimensional manifold space by adopting a local linear embedding algorithm to obtain low-dimensional embedded vectors, a domain self-adaptive parameter migration model is constructed, optimal processing parameters of the reference images are used as source domain parameters, the batch images to be processed are used as target domains, feature distribution differences of the source domains and the target domains in the low-dimensional manifold space are reduced by adopting a maximum mean difference criterion, migration parameters of the target domains are obtained by solving, and the migration parameters are applied to S1 to S4 of the batch images to be processed, so that correction processing of the batch core box images is completed.
  7. 7. The method for extracting the field core box corner point and correcting perspective distortion based on multi-scale Retinex fusion is characterized by comprising the specific steps of searching a preset number of neighbor feature vectors for each multi-dimensional feature vector, calculating a weight coefficient of each feature vector linearly reconstructed by the neighbor vectors, wherein the weight coefficient meets a constraint that the sum is one, mapping a high-dimensional feature vector to a low-dimensional manifold space of a preset dimension based on the weight coefficient, and keeping the local linear reconstruction relation of the high-dimensional space unchanged in the mapping process to obtain the low-dimensional embedded vector.
  8. 8. The method for extracting the corner points of the field core box and correcting perspective distortion based on multi-scale Retinex fusion according to claim 1 is characterized by further comprising the steps of taking a full-flow algorithm from S1 to S4 as an original model, pruning the original model by adopting a structure sparsification pruning algorithm with L1 regularization, removing redundant calculation branches and weight parameters to obtain a pruning model, performing fine tuning training on the pruning model to repair precision loss caused by pruning, taking the original model as a teacher model, taking the pruning model as a student model, adopting a knowledge distillation algorithm to enable output distribution of the student model to fit with output distribution of the teacher model, fitting distribution of real labels at the same time to obtain a lightweight model, and performing engineering packaging on the lightweight model to complete deployment after being adapted to field edge equipment.
  9. 9. The method for extracting the corner points of the field core box and correcting the perspective distortion based on the multi-scale Retinex fusion according to claim 8 is characterized in that the training process of a knowledge distillation algorithm is divided into three stages, namely, preheating training, fixing parameters of a teacher model, training only an output layer of a student model, full-scale distillation training, simultaneously training all parameters of the student model, fitting soft output of the teacher model under a preset temperature coefficient and hard output of a real label, and fine-tuning optimization, reducing learning rate, and carrying out fine-tuning training on samples of field extreme scenes to obtain a final lightweight model.
  10. 10. The method for extracting field core box corner points and correcting perspective distortion based on multi-scale Retinex fusion according to claim 5, wherein the specific rules for generating feedback adjustment instructions in S4 and transmitting the feedback adjustment instructions to corresponding steps are that if orthogonality errors and parallelism errors of straight line fitting are over-standard, the feedback adjustment instructions are transmitted to S2, topology constraint weights of a graph cut model are adjusted, if moment invariance errors, length-width errors and geometric perspective distortion rates are over-standard, the feedback adjustment instructions are transmitted to S3, the number of control points of thin plate spline transformation and the smooth term weights of a Markov random field are adjusted, and if the image edge distortion rates and the overall definition of an image are not up to standard, the feedback adjustment instructions are transmitted to S1, and iteration steps of anisotropic diffusion and scale parameters of multi-scale Retinex are adjusted.

Description

Open-air core box corner extraction and perspective distortion correction method based on multi-scale Retinex fusion Technical Field The invention relates to the technical field of image correction and computer vision of field core exploration, in particular to a field core box corner extraction and perspective distortion correction method based on multi-scale Retinex fusion. Background The core box is used as a core carrier for storing and transferring the core, the accurate correction of the images is an important precondition for digital management of the core and accurate extraction of geological parameters, and the actual operation conditions of the field core exploration site bring a plurality of challenges to the acquisition and correction of the images of the core box. The problems of shooting angle deviation, uneven illumination distribution, field vibration interference, complex background environment and the like commonly exist in a field exploration site, the problems of geometric distortion, edge blurring, angular point positioning blurring and the like of an acquired core box image are easily caused, if the image cannot be effectively corrected, the quality of digital archiving of a core is directly affected, and meanwhile, errors are introduced for extracting geological parameters of a follow-up core. The prior core box image correction technology is designed aiming at indoor standard shooting environment mostly, and does not fully consider the actual characteristics of field complex scenes, and a plurality of obvious defects are exposed in field application, namely, firstly, the corner extraction link lacks depth combination with rectangular geometric characteristics of the core box, the extraction algorithm is single and has weak anti-interference capability, corner omission and false detection phenomena are easy to occur, accurate positioning of four corners of the core box cannot be realized, errors of corner positioning can be directly conducted to the subsequent perspective correction link, the correction effect is greatly reduced, secondly, the image preprocessing means is single, a collaborative processing mechanism for denoising and illumination balancing is not constructed, the edge characteristics of the field boxes are difficult to be effectively eliminated, salt and pepper noise are easy to lose in the preprocessing process, hidden danger is caused by the subsequent corner extraction and correction, thirdly, the perspective transformation correction algorithm and the extraction link are out of proportion, distortion elimination is realized only by means of a single transformation model, global geometric structure correction and local edge optimization cannot be realized, distortion suitability caused by different angles is poor, the corrected images are difficult to meet the requirement of digital core box, the full-scale error is difficult to be completely matched, the error of the overall geometric parameters cannot be easily verified, the error of the core box is difficult to be completely matched, the error is difficult to be completely matched with the error of the actual image, and the error is difficult to be completely matched with the image, and has no requirement for the error is suitable for the error due to be compared with the error of the actual image, and has no error, and has no ideal error, and has high quality. The method is not suitable for the operation requirement of field large-scale core exploration, the calculated amount and the parameter amount of the existing correction algorithm are large, targeted light optimization is not performed, the method is difficult to be deployed on portable edge equipment supported by a field high-performance server, field acquisition and field processing of core box images cannot be realized, and the flow cost of core digital processing is increased. In addition, although various researches are carried out on angular point extraction and perspective correction algorithms in the existing image processing field, the rectangular geometric characteristics of a core box and scene characteristics of field exploration are not subjected to customized optimization, image preprocessing, angular point extraction, distortion correction, precision verification, batch processing and light deployment are not integrated, cooperativity and data interactivity are not achieved among algorithms, a closed loop is not formed in a processing flow, the actual requirements of digital processing of the field core box are difficult to meet in the overall processing efficiency and correction precision, and therefore, the research and development of the field core box angular point extraction and perspective distortion correction method which is adaptive to field complex scenes, high in precision, rapid and capable of being deployed on site and based on multi-scale Retinex fusion has important practical significance. Disclosure of Invention The inventio