Search

CN-122023439-A - Multi-region segmentation method and system for cutter abrasion image

CN122023439ACN 122023439 ACN122023439 ACN 122023439ACN-122023439-A

Abstract

The invention discloses a multi-region segmentation method and a multi-region segmentation system for a cutter abrasion image, comprising the steps of acquiring the cutter abrasion image, wherein the cutter abrasion image comprises a background region, a cutter surface region and an abrasion region; the method comprises the steps of modeling a cutter abrasion image, constructing a label field, establishing an image segmentation optimization model based on a maximum posterior probability criterion, carrying out initial segmentation on the cutter abrasion image by adopting a K-means clustering algorithm based on the image segmentation optimization model to obtain an initial label field, and carrying out iterative optimization on the initial label field to realize multi-region accurate segmentation of the cutter abrasion image. The method solves the problem of fine separation of the background, the cutter matrix and the abrasion area, and lays a solid foundation for accurately calculating the abrasion ratio.

Inventors

  • TANG YUYANG
  • ZHANG JUN
  • Yan jiaxing
  • LIANG YUTONG
  • CHAO SHUAIJUN

Assignees

  • 西安交通大学

Dates

Publication Date
20260512
Application Date
20260123

Claims (10)

  1. 1. A method for multi-region segmentation of a tool wear image, comprising: acquiring a cutter abrasion image comprising a background area, a cutter surface area and an abrasion area; modeling the cutter abrasion image, constructing a tag field and establishing an image segmentation optimization model based on a maximum posterior probability criterion; Based on an image segmentation optimization model, carrying out initial segmentation on a cutter abrasion image by adopting a K-means clustering algorithm to obtain an initial tag field; and carrying out iterative optimization on the initial tag field to realize the multi-region accurate segmentation of the cutter abrasion image.
  2. 2. The method of claim 1, wherein the acquiring the tool wear image includes a background region, a tool face region, and a wear region, and comprises: The method comprises the steps of collecting images of a front cutter face, a rear cutter face and a cutter tip area of a cutter arranged on a machine tool spindle by using a high-resolution CCD or CMOS industrial camera and matching with a point light source or a coaxial light source which is arranged at a specific angle, and carrying out necessary pretreatment on the original images, wherein the pretreatment comprises graying, median filtering noise reduction and limited-contrast self-adaptive histogram equalization.
  3. 3. The method of claim 1, wherein modeling the tool wear image, constructing a tag field and constructing an image segmentation optimization model based on a maximum posterior probability criterion comprises: selecting a second-order neighborhood system and a point group as an infrastructure of a Markov random field; determining a potential function form based on the MLL model, and constructing an energy function; Assuming that the pixel gray value of each region obeys Gaussian distribution, calculating the mean value and variance of each region, and constructing a likelihood function.
  4. 4. A method for multi-region segmentation of a tool wear image according to claim 3, comprising: Defining the image to be segmented as a Markov random field, and setting the observation image as The corresponding tag field is Wherein Respectively representing three categories of background, cutter matrix and abrasion area; The Potts model is used as a priori distribution to encourage the spatially adjacent pixels to have the same label, its energy function Expressed as: Wherein, the For a set of all adjacent pixel pairs, As a function of the kronecker function, As a coupling coefficient, controlling the region smoothness; Suppose that at a given tag Under the condition of (1) observing gray value Obeying gaussian distribution Likelihood energy The method comprises the following steps: According to Bayes' theorem, the segmentation problem is converted into solution to make posterior probability Maximum tag configuration I.e. maximum a posteriori probability MAP estimation; equivalent to minimizing the total energy function: 。
  5. 5. The method for multi-region segmentation of a tool wear image according to claim 1, wherein the performing initial segmentation on the tool wear image by using a K-means clustering algorithm based on the image segmentation optimization model to obtain an initial tag field comprises: carrying out rapid rough segmentation on the preprocessed gray level image by adopting K-means clustering; calculating a gray level histogram of an image, equally spacing and initially selecting three intervals in a gray level range, and taking gray level modes of the intervals as initial clustering centers; Iterative updating, namely taking Euclidean distance as a measure, distributing each pixel to the nearest class center, recalculating the gray average value of each class as a new center, and repeating until the change of the class center is smaller than a threshold value Or the maximum number of iterations is reached; Output, namely directly mapping the clustering result of the K-means into an MRF label field Is set to be a constant value.
  6. 6. The method for multi-region segmentation of a tool wear image according to claim 1, wherein the iterative optimization of the initial tag field achieves multi-region accurate segmentation of the tool wear image, comprising: To output (output) Taking a Gibbs sampling frame as a starting point, and integrating a simulated annealing strategy to solve the problem of energy minimization; conditional probability computation by scanning each pixel sequentially or randomly in each iteration, for each pixel Fixing the neighborhood label, calculating the neighborhood label belongs to the first Local conditional probability of class: Wherein, the Is a pixel Is used in the neighborhood of (a), Is the first Temperature parameters at the time of iteration; random sampling and updating, namely, according to the calculated three-dimensional probability vector, carrying out random sampling and determining a new label of the pixel; Simulated annealing schedule, namely setting a higher initial temperature And decays the temperature according to the geometric cooling schedule: wherein The system is easy to explore a solution space at high temperature, and gradually stabilizes in a low-energy state along with the reduction of the temperature; parameter on-line estimation, in the sampling process, every certain iteration times according to the current label field Re-estimating various distribution parameters Enabling the model to adapt to image content; convergence determination when global energy between successive iterations The variation of (2) is less than a threshold Or the temperature is reduced to the lower limit When the algorithm is terminated, the final segmentation result is output 。
  7. 7. The method of claim 6, wherein after obtaining the accurate three-region segmentation mask: extracting all pixels with labels of 'wearing areas', and calculating the total area ; Extracting all pixels with labels of 'cutter matrix' and 'abrasion region', and calculating total area ; Calculating the key index-the abrasion area proportion ; Will be And comparing the wear state with a preset wear threshold value to realize automatic judgment and early warning of the wear state of the cutter.
  8. 8. A tool wear image multi-region segmentation system, comprising: The data acquisition module is used for acquiring a cutter abrasion image, and comprises a background area, a cutter face area and an abrasion area; the model construction module is used for modeling the cutter abrasion image, constructing a label field and constructing an image segmentation optimization model based on the maximum posterior probability criterion; The initial segmentation module is used for carrying out initial segmentation on the cutter abrasion image by adopting a K-means clustering algorithm based on the image segmentation optimization model to obtain an initial tag field; and the output module is used for carrying out iterative optimization on the initial tag field and realizing the multi-region accurate segmentation of the cutter abrasion image.
  9. 9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that the processor implements the steps of a tool wear image multi-region segmentation method according to any one of claims 1 to 7 when the computer program is executed.
  10. 10. A computer readable storage medium storing a computer program, characterized in that the computer program when executed by a processor implements the steps of a tool wear image multi-region segmentation method according to any one of claims 1 to 7.

Description

Multi-region segmentation method and system for cutter abrasion image Technical Field The invention belongs to the technical field of intelligent manufacturing and machine vision intersection, and particularly relates to a multi-region segmentation method and system for a cutter abrasion image. Background In the fields of high-end numerical control machining, aerospace component manufacturing, precision die machining and the like, the health state of a cutter directly determines the machining precision, surface quality and production cost of a workpiece. The tool wear is a progressive and unavoidable process, and its wear pattern mainly includes rake face wear, flank face wear, nose tipping, etc. The automatic, high-precision and real-time detection of the cutter abrasion is realized, and the method is one of key technologies for pushing the intelligent manufacturing production line to upgrade in an unmanned way and an intelligent way. The detection technology based on machine vision has become the main research direction of tool state monitoring because of the advantages of non-contact, high resolution, rich information and the like. The key technical challenge is how to stably, accurately and efficiently separate three key areas, namely a background area, an intact cutter matrix area and a wearing area from an acquired cutter image. The proportion of the wear area to the effective cutting area of the cutter is a core index for quantitatively evaluating the residual life of the cutter. At present, the technical scheme in the field mainly has the following bottlenecks: 1. the limitations of the traditional image segmentation method are that the widely used global threshold method, otsu method, region growing method and the like are basically two classification methods. They can roughly separate the worn portion from the non-worn portion, but cannot further subdivide the "non-worn portion" into a "tool base" and a "background". This makes it impossible to calculate the key index "wear area/total tool face area" because the denominator (total tool face area) cannot be defined accurately. 2. The robustness problem under the complex scene is that factors such as uneven illumination of an industrial field, reflection of cutting fluid, interference of cutter surface textures, image noise and the like are extremely easy to cause failure of a segmentation algorithm based on simple gray scale or edge characteristics, and over-segmentation or under-segmentation is generated. 3. The existing advanced model contradicts the calculation efficiency and the precision, namely the Markov Random Field (MRF) and other probability map models can well describe the spatial context relation among image pixels, and the segmentation robustness is improved. However, the classical algorithm for solving the MRF model, iterative Conditional Mode (ICM), relies heavily on the initial tag field. Random initialization can lead to slow convergence, unstable results and easy sinking into a locally optimal solution, and the calculation efficiency is low. Although the combination of K-means initialization can be improved, the characteristic of greedy update of ICM makes it difficult to jump out of local extremum, and for cutter abrasion areas with small gray scale difference and fuzzy boundary, the segmentation precision is still not ideal. 4. The system integration and real-time challenges that many academic methods perform well on ideal data sets, but the algorithm complexity is too high to meet the timeliness requirements of the production line on online and real-time detection. In view of the above, the prior art has not yet provided a tool wear image multi-region segmentation solution that combines high accuracy, high efficiency, and strong robustness. Disclosure of Invention The invention aims to provide a multi-region segmentation method and a multi-region segmentation system for a cutter abrasion image, so as to solve the problems. In order to achieve the above purpose, the present invention adopts the following technical scheme: in a first aspect, the present invention provides a method for multi-region segmentation of a tool wear image, comprising: acquiring a cutter abrasion image comprising a background area, a cutter surface area and an abrasion area; modeling the cutter abrasion image, constructing a tag field and establishing an image segmentation optimization model based on a maximum posterior probability criterion; Based on an image segmentation optimization model, carrying out initial segmentation on a cutter abrasion image by adopting a K-means clustering algorithm to obtain an initial tag field; and carrying out iterative optimization on the initial tag field to realize the multi-region accurate segmentation of the cutter abrasion image. Further, the acquiring a tool wear image including a background area, a tool face area, and a wear area includes: The method comprises the steps of collecting images of a front cutter face,