CN116612162B - Hole site calibration analysis method, system and storage medium based on image comparison model - Google Patents
Hole site calibration analysis method, system and storage medium based on image comparison model Download PDFInfo
- Publication number
- CN116612162B CN116612162B CN202310899075.7A CN202310899075A CN116612162B CN 116612162 B CN116612162 B CN 116612162B CN 202310899075 A CN202310899075 A CN 202310899075A CN 116612162 B CN116612162 B CN 116612162B
- Authority
- CN
- China
- Prior art keywords
- image
- hole site
- machining
- processing
- center point
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000004458 analytical method Methods 0.000 title claims abstract description 22
- 238000003860 storage Methods 0.000 title claims abstract description 10
- 238000012545 processing Methods 0.000 claims abstract description 152
- 238000003754 machining Methods 0.000 claims abstract description 145
- 238000000034 method Methods 0.000 claims abstract description 24
- 230000000295 complement effect Effects 0.000 claims description 43
- 238000010586 diagram Methods 0.000 claims description 11
- 238000013507 mapping Methods 0.000 claims description 10
- 238000004590 computer program Methods 0.000 claims description 7
- 238000006073 displacement reaction Methods 0.000 claims description 5
- 230000007547 defect Effects 0.000 abstract description 11
- 238000005516 engineering process Methods 0.000 abstract description 7
- 238000005553 drilling Methods 0.000 description 8
- 230000008569 process Effects 0.000 description 8
- 238000001514 detection method Methods 0.000 description 4
- 230000006870 function Effects 0.000 description 4
- 238000004891 communication Methods 0.000 description 3
- 230000008878 coupling Effects 0.000 description 3
- 238000010168 coupling process Methods 0.000 description 3
- 238000005859 coupling reaction Methods 0.000 description 3
- 238000005259 measurement Methods 0.000 description 3
- 229910000881 Cu alloy Inorganic materials 0.000 description 2
- 230000002950 deficient Effects 0.000 description 2
- 230000003068 static effect Effects 0.000 description 2
- 239000013589 supplement Substances 0.000 description 2
- 230000002159 abnormal effect Effects 0.000 description 1
- 229910045601 alloy Inorganic materials 0.000 description 1
- 239000000956 alloy Substances 0.000 description 1
- 230000003872 anastomosis Effects 0.000 description 1
- 230000009286 beneficial effect Effects 0.000 description 1
- 239000003086 colorant Substances 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 238000013135 deep learning Methods 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000011161 development Methods 0.000 description 1
- 238000000605 extraction Methods 0.000 description 1
- 238000010191 image analysis Methods 0.000 description 1
- 238000004519 manufacturing process Methods 0.000 description 1
- 230000003287 optical effect Effects 0.000 description 1
- 238000007781 pre-processing Methods 0.000 description 1
- 239000000047 product Substances 0.000 description 1
- 238000012216 screening Methods 0.000 description 1
- 239000011265 semifinished product Substances 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/30—Determination of transform parameters for the alignment of images, i.e. image registration
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/0002—Inspection of images, e.g. flaw detection
- G06T7/0004—Industrial image inspection
- G06T7/001—Industrial image inspection using an image reference approach
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/60—Analysis of geometric attributes
- G06T7/62—Analysis of geometric attributes of area, perimeter, diameter or volume
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06T—IMAGE DATA PROCESSING OR GENERATION, IN GENERAL
- G06T7/00—Image analysis
- G06T7/70—Determining position or orientation of objects or cameras
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06V—IMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
- G06V10/00—Arrangements for image or video recognition or understanding
- G06V10/70—Arrangements for image or video recognition or understanding using pattern recognition or machine learning
- G06V10/74—Image or video pattern matching; Proximity measures in feature spaces
- G06V10/75—Organisation of the matching processes, e.g. simultaneous or sequential comparisons of image or video features; Coarse-fine approaches, e.g. multi-scale approaches; using context analysis; Selection of dictionaries
-
- Y—GENERAL TAGGING OF NEW TECHNOLOGICAL DEVELOPMENTS; GENERAL TAGGING OF CROSS-SECTIONAL TECHNOLOGIES SPANNING OVER SEVERAL SECTIONS OF THE IPC; TECHNICAL SUBJECTS COVERED BY FORMER USPC CROSS-REFERENCE ART COLLECTIONS [XRACs] AND DIGESTS
- Y02—TECHNOLOGIES OR APPLICATIONS FOR MITIGATION OR ADAPTATION AGAINST CLIMATE CHANGE
- Y02P—CLIMATE CHANGE MITIGATION TECHNOLOGIES IN THE PRODUCTION OR PROCESSING OF GOODS
- Y02P90/00—Enabling technologies with a potential contribution to greenhouse gas [GHG] emissions mitigation
- Y02P90/30—Computing systems specially adapted for manufacturing
Landscapes
- Engineering & Computer Science (AREA)
- Computer Vision & Pattern Recognition (AREA)
- Physics & Mathematics (AREA)
- Theoretical Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computing Systems (AREA)
- Health & Medical Sciences (AREA)
- Artificial Intelligence (AREA)
- Geometry (AREA)
- Databases & Information Systems (AREA)
- Evolutionary Computation (AREA)
- General Health & Medical Sciences (AREA)
- Medical Informatics (AREA)
- Software Systems (AREA)
- Multimedia (AREA)
- Quality & Reliability (AREA)
- Image Analysis (AREA)
Abstract
The application discloses a hole site calibration analysis method, a system and a storage medium based on an image comparison model, which relate to the technical field of image recognition and comprise the following steps: acquiring a station image and an object image to be processed; establishing a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to establish a processing reference model; the method is used for solving the problem that the identification and calibration of the machining hole site are not accurate and comprehensive enough due to the fact that the identification of the hole site depth defect is lack in the existing hole site image identification technology.
Description
Technical Field
The application relates to the technical field of image recognition, in particular to a hole site calibration analysis method, a system and a storage medium based on an image comparison model.
Background
Image recognition, which is a technology for processing, analyzing and understanding images by using a computer to recognize targets and objects in various modes, is a practical application of applying a deep learning algorithm, and generally, the image recognition flow is divided into four steps: along with the development of image recognition technology, the application fields of image acquisition, image preprocessing, feature extraction and image recognition are also more and more extensive, for example, in the hole site processing process of industrial parts, the screening efficiency of defective products can be improved through image recognition comparison.
In the prior art, in the process of performing hole site identification by using an image identification technology, the method is generally used for identifying and acquiring the position of a hole site, and the workpiece assembly is assisted by acquiring the position of the hole site, for example, in the patent of the application with the publication number of CN114219802B, a skin connecting hole site detection method based on image processing is disclosed, and the method is used for acquiring the position of the hole site by using the image identification technology; for example, in the application patent with publication number of CN116245725a, a "super-resolution image construction method for high-precision assembly pose measurement of hole axis" is disclosed, the method improves measurement precision by changing pose measurement, both the above two methods adopt a plane recognition mode to determine the position of the hole site, and lack recognition and analysis of processing defects of the hole site itself; for example, in the application patent with publication number of CN111598832a, a "method, device and storage medium for marking hole defects" is disclosed, in which, when hole defects are identified, defect comparison and identification are performed on hole sites only by means of the number parameter, position parameter, shape parameter, size parameter and area parameter in the hole parameters, the above parameters are also used only for detecting the processing position and shape defect of the hole sites, if the surface processing position, shape and area of a hole site are accurate, but the hole site is inclined in the depth direction, and calibration and identification after image comparison are difficult to achieve by the above method.
Disclosure of Invention
The application aims to solve at least one of the technical problems in the prior art to a certain extent, and can supplement the identification and calibration of the hole site depth defects on the basis of hole site surface detection by longitudinally identifying the hole site depth so as to solve the problem that the identification and calibration of the machining hole site are not accurate and comprehensive due to the lack of the identification of the hole site depth defects in the existing hole site image identification technology.
In order to achieve the above object, in a first aspect, the present application provides a hole site calibration analysis method based on an image comparison model, including: acquiring a station image and an object image to be processed;
establishing a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to establish a processing reference model;
setting machining hole site parameters in a structure diagram to be machined in a machining reference model, wherein the machining hole site parameters comprise hole site depth and hole site diameter;
and acquiring a machined machining image, extracting a machined hole site image in the machined image, and aligning the machined image to a machining reference model to calibrate the machined hole site image.
Further, establishing a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to establish a processing reference model further comprises: setting an X axis, a Y axis and a Z axis for the three-dimensional coordinate system, and keeping the upper surface of the station image parallel to the plane where the X axis and the Y axis are located;
setting the upper surface of the station image as a processing table top, acquiring the outline of the processing table top, and setting the outline of the processing table top as the outline of the table top;
setting a first number of reference points at the edge of the table outline, and determining the coordinates of the reference points in a three-dimensional coordinate system;
acquiring a surface to be punched in an image of an object to be processed, setting the surface opposite to the surface to be punched as an anastomotic surface, acquiring the outline of the anastomotic surface, and setting the outline as an anastomotic outline;
and correspondingly arranging the coincident profile in the profile of the table top to ensure that the coincident surface is in contact with the processing table top, so as to obtain a processing reference model after the image of the object to be processed is coincident with the station image.
Further, setting the machining hole site parameters in the structure diagram to be machined in the machining reference model further includes: acquiring the hole site depth and the hole site diameter in the machining hole site parameters, establishing a hole site model according to the hole site depth and the hole site diameter, and corresponding the hole site model to a machining reference model;
acquiring the joint surface of the hole site model and the processing table top, and setting the joint surface as the joint surface of the hole site;
and determining the coordinates of the center point of the hole site joint surface.
Further, acquiring a machined image after machining, and extracting a machined hole site image in the machined image includes: acquiring a center point of a processing table top, and acquiring a processing image right above the processing table top;
and arranging a light reflecting panel on the surface of the processing table surface, carrying out gray scale treatment on the processing image, and extracting the top surface contour, the bottom surface contour and the contour of the reference point of the processing hole position image in the processing image through gray scale value distinction.
Further, aligning the machining image with the machining reference model to calibrate the machining hole site image includes: matching the outline of the reference point with the reference point in the processing reference model, and mapping the processing image into the processing reference model;
outputting a machining vertical precision signal when the top surface contour and the bottom surface contour of the machining hole site image are coincident, and outputting a machining vertical deviation signal when the top surface contour and the bottom surface contour of the machining hole site image are not fully coincident.
Further, aligning the machining image with the machining reference model to calibrate the machining hole site image further includes: when a machining vertical accurate signal is output, setting the bottom surface contour of a machining hole position image to be a combined contour;
acquiring coordinates of a central point of the coincident profile, and comparing the coordinates of the central point of the coincident profile with the coordinates of the central point of the hole site attaching surface;
outputting a processing hole position accurate signal when the coordinates of the center point of the coincident profile are the same as the coordinates of the center point of the hole position joint surface; outputting a processing hole position deviation signal when the coordinates of the central point of the coincident profile are different from the coordinates of the central point of the hole position joint surface;
calibrating the machining hole site image by corresponding the machining image to the machining reference model further comprises: when a processing hole position deviation signal is output, setting the center point coordinate of the coincident profile as a processing center point, and setting the center point of the hole position joint surface as a hole position reference center point;
the machining center point and the hole site reference center point are connected, the deviation line is set, the direction of the hole site reference center point towards the machining center point is set as the deviation direction, and the length of the deviation line is set as the deviation distance.
Further, aligning the machining image with the machining reference model to calibrate the machining hole site image further includes: when a machining vertical deviation signal is output, setting a machining circle through the hole site diameter, and complementing the top surface contour of a machining hole site image by using the machining circle to obtain a top surface complementing contour;
vertically corresponding the top surface complement profile to a processing table top to obtain a processing corresponding profile;
acquiring coordinates of a center point of a corresponding contour;
comparing the coordinates of the center point of the corresponding contour with the coordinates of the center point of the hole site attaching surface;
outputting a machining hole site inclination signal when the coordinates of the center point of the machining corresponding outline are the same as the coordinates of the center point of the hole site attaching surface; and outputting a machining hole site inclination deviation signal when the coordinates of the center point of the machining corresponding outline are different from the coordinates of the center point of the hole site attaching surface.
Further, aligning the machining image with the machining reference model to calibrate the machining hole site image further includes: when a machining hole position inclination signal is output, the bottom surface outline of a machining hole position image is complemented through a machining circle, and a bottom surface complement outline is obtained;
acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain a hypotenuse inclined line;
connecting the center point of the machined corresponding outline with the center point of the top surface complement outline to obtain a vertical connecting line;
the included angle between the vertical connecting line and the inclined line of the hypotenuse is set as an inclined included angle.
Further, aligning the machining image with the machining reference model to calibrate the machining hole site image further includes: when a machining hole site inclination deviation signal is output, connecting a center point of a machining corresponding profile with a center point of a hole site attaching surface to obtain an inclination deviation displacement;
setting the direction of the central point of the hole site joint surface towards the central point of the corresponding contour to be processed as an inclined deviation direction;
the bottom surface outline of the processed hole site image is complemented through the processing circle, and a bottom surface complement outline is obtained;
acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain an inclined deviation line;
connecting the center point of the machined corresponding profile with the center point of the top surface complement profile to obtain a vertical deviation connecting line;
and setting the included angle between the vertical deviation connecting line and the inclined deviation line as an inclined deviation included angle.
In a second aspect, the application provides a storage medium having stored thereon a computer program, which when executed by a processor, performs the steps of the method as claimed in any one of the preceding claims.
The application has the beneficial effects that: the method has the advantages that the processed images can be compared through the processing stations as reference standards, so that the accuracy of image comparison is realized;
according to the application, the processing hole site parameters in the structure diagram to be processed are set in the processing reference model, the processing hole site parameters comprise the hole site depth and the hole site diameter, the processing hole site model can be conveniently obtained through the hole site depth and the hole site diameter, the positions of the processing hole sites before processing can be accurately corresponding, the accurate comparison of processed images is convenient, the image recognition accuracy of the hole sites in the processing depth direction is improved, and the comprehensiveness of hole site recognition is increased;
according to the application, the processing hole site image in the processing image is extracted by acquiring the processing image after processing, the processing image is mapped to the processing reference model to calibrate the processing hole site image, meanwhile, the calibrated reference object is compared by the reference point coordinates on the processing station, so that the comparison accuracy can be improved, and meanwhile, the hole site defect detection efficiency can be improved by utilizing the image comparison and analysis method.
Additional features and advantages of the application will be set forth in the description which follows, and in part will be obvious from the description, or may be learned by practice of the application. The objectives and other advantages of the application will be realized and attained by the structure particularly pointed out in the written description and claims hereof as well as the appended drawings.
Drawings
FIG. 1 is a flow chart of the steps of the method of the present application;
FIG. 2 is a schematic block diagram of the system of the present application;
FIG. 3 is a top view of a station image and an image of an object to be processed according to the present application;
fig. 4 is a schematic diagram of the acquisition of the inclination angle of the present application.
Detailed Description
The following description of the embodiments of the present application will be made clearly and completely with reference to the accompanying drawings, in which it is apparent that the embodiments described are only some embodiments of the present application, but not all embodiments. All other embodiments, which can be made by those skilled in the art based on the embodiments of the application without making any inventive effort, are intended to be within the scope of the application.
Referring to fig. 1, the present application provides a hole site calibration analysis method based on an image comparison model, which can supplement the identification and calibration of hole site depth defects on the basis of hole site surface detection by longitudinally identifying the hole site depth, so as to solve the problem that the existing hole site image identification technology lacks identification of hole site depth defects, resulting in insufficient accurate and comprehensive identification and calibration of machining hole sites; for example, when a copper alloy object with a certain thickness is processed, because the strength of the copper alloy is not very high, if the surface hole position of the alloy object is accurately positioned, but deviation exists in the processing in the depth direction, the problem that the processing hole position is inclined easily occurs, and the object is defined as a defective object;
specifically, referring to fig. 1, the hole site calibration analysis method based on the image comparison model includes the following steps: step S1, a station image and an object image to be processed are acquired, wherein the station image is a structural view of a processing panel in the processing process, the station image is of a rectangular structure in general, the object to be processed belongs to a semi-finished product which is cut and processed, a design drawing is provided, the structural view can be directly acquired for use, as shown in FIG. 3, FIG. 3 is a top view of the station image and the object image to be processed, the top view of the object image to be processed in FIG. 3 is of a ring-shaped structure, and processing hole sites are distributed in a ring-shaped array; the station image is of a rectangular structure, and the reference points are arranged at four corners of the station image.
Step S2, a three-dimensional coordinate system is established, a station image and an object image to be processed are corresponding to the three-dimensional coordinate system, and the object image to be processed is arranged above the station image to establish a processing reference model; step S2 further comprises the following sub-steps: s21, setting an X axis, a Y axis and a Z axis for a three-dimensional coordinate system, and keeping the upper surface of a station image parallel to a plane where the X axis and the Y axis are located;
s22, setting the upper surface of the station image as a processing table, acquiring the outline of the processing table, and setting the outline of the processing table as the outline of the table;
step S23, a first number of reference points are arranged on the edge of the outline of the table top, the coordinates of the reference points in a three-dimensional coordinate system are determined, when the method is implemented, the first number is set to be 4, one reference point is respectively arranged at four vertexes of a rectangular processing table top, meanwhile, different colors are adopted for setting the reference points, the reference points are set to be circular, and the outline of the reference points and the positions of the outline of the reference points on the processing table top can be rapidly and accurately extracted during subsequent image acquisition and analysis;
step S24, obtaining a surface to be punched in an image of an object to be processed, setting the surface opposite to the surface to be punched as an anastomotic surface, obtaining the outline of the anastomotic surface, and setting the outline as an anastomotic outline;
step S25, correspondingly arranging the coincident outline inside the outline of the table top, enabling the coincident surface to be attached to the processing table top, and obtaining a processing reference model after the image of the object to be processed is coincident with the station image, wherein the processing reference model after the image of the object to be processed is coincident with the station image is the processing position of the object to be processed in processing, and the accuracy of subsequent comparison can be ensured after the relative position is determined.
Step S3, setting machining hole site parameters in a structure diagram to be machined in a machining reference model, wherein the machining hole site parameters comprise hole site depth and hole site diameter; step S3 further comprises the following sub-steps: s31, acquiring the hole site depth and the hole site diameter in machining hole site parameters, establishing a hole site model according to the hole site depth and the hole site diameter, and corresponding the hole site model to a machining reference model; s32, acquiring the joint surface of the hole site model and the processing table top, and setting the joint surface as a hole site joint surface; and S33, determining the coordinates of the center point of the hole site attaching surface, and rapidly detecting the hole site vertically punched by the technical scheme of the application when detecting, wherein the vertically punched hole site can be communicated on the processing table top in the vertical direction.
S4, acquiring a machined image, extracting a machined hole position image in the machined image, and aligning the machined image to a machined reference model to calibrate the machined hole position image; step S4 further comprises the sub-steps of: step S411, a center point of a processing table top is obtained, and a processing image is obtained right above the processing table top; the processing table top is rectangular, and the center of the rectangle is the center of the processing table top;
step S412, setting a light reflecting panel on the surface of the processing table, carrying out gray scale treatment on the processing image, and extracting the top surface contour, the bottom surface contour and the contour of the reference point of the processing hole position image in the processing image by gray scale value distinction, wherein the setting of the light reflecting panel only needs to ensure that the light reflecting panel can be well distinguished from the image of the object during image analysis, and ensures that the gray scale value distinction has obvious difference, thereby being convenient for extracting the contour of the corresponding position during gray scale analysis of the image;
step S413, performing calibration of the machining hole site image by mapping the machining image to the machining reference model includes: matching the outline of the reference point with the reference point in the processing reference model, and mapping the processing image into the processing reference model; by setting the reference point, anastomosis and correspondence can be performed more rapidly in the image comparison process;
in step S414, when the top surface contour and the bottom surface contour of the machined hole site image are coincident, a machining vertical precision signal is output, when the top surface contour and the bottom surface contour of the machined hole site image are not fully coincident, a machining vertical deviation signal is output, if the top surface contour and the bottom surface contour of the machined hole site image are coincident, only whether the machined hole site has a position deviation is detected, and if the top surface contour and the bottom surface contour of the machined hole site image are not fully coincident, both the inclination and the position deviation of the machined hole site are detected.
Step S4 further comprises the sub-steps of: step S421, when a machining vertical accurate signal is output, setting the bottom surface contour of a machining hole position image to be a combined contour;
step S422, obtaining the coordinates of the center point of the coincident profile, and comparing the coordinates of the center point of the coincident profile with the coordinates of the center point of the hole site attaching surface;
step S423, outputting a processing hole position accurate signal when the coordinates of the center point of the coincident profile are the same as the coordinates of the center point of the hole position attaching surface; when the coordinates of the central point of the coincident profile are different from those of the central point of the hole site joint surface, a processing hole site deviation signal is output, wherein the processing hole site deviation signal indicates that the position of a preset processing hole site is deviated.
Step S4 further comprises the sub-steps of: step S431, when a processing hole position deviation signal is output, setting the center point coordinate of the coincident profile as a processing center point, and setting the center point of the hole position joint surface as a hole position reference center point; step S432, a machining center point and a hole site reference center point are connected, a deviation line is set, the direction of the hole site reference center point towards the machining center point is set as a deviation direction, the length of the deviation line is set as a deviation distance, and deviation parameters when machining position deviation occurs can be obtained through step S431 and step S432, so that a reference basis is provided for subsequent machining calibration.
Step S4 further comprises the sub-steps of: step S441, when a machining vertical deviation signal is output, a machining circle is set through the hole site diameter, and the top surface profile of a machining hole site image is complemented by using the machining circle, so that a top surface complemented profile is obtained;
step S442, vertically corresponding the top surface complement contour to the processing table top to obtain a processing corresponding contour; step S443, obtaining coordinates of a center point of the corresponding contour; step S444, comparing the coordinates of the center point of the corresponding contour with the coordinates of the center point of the hole site attaching surface; step S445, outputting a processed hole site inclination signal when the coordinates of the center point of the processed corresponding contour are the same as the coordinates of the center point of the hole site attaching surface; outputting a machining hole position inclination deviation signal when the coordinates of the center point of the machining corresponding outline are different from those of the center point of the hole position attaching surface, wherein when the coordinates of the center point of the machining corresponding outline are the same as those of the center point of the hole position attaching surface, the hole position drilling point position in the surface machining is accurate, only deviation occurs in the drilling process, and when the coordinates of the center point of the machining corresponding outline are different from those of the center point of the hole position attaching surface, the deviation occurs in the hole position drilling point position in the machining process and the inclination occurs in the drilling process; and if no point appears on the bottom surface contour of the machined hole position image in the image, indicating that machining inclination deviation is large, and directly outputting a machining inclination abnormal signal.
Referring to fig. 4, step S4 further includes the following sub-steps: step S451, when a machining hole position inclination signal is output, the bottom surface outline of a machining hole position image is complemented by a machining circle, and a bottom surface complemented outline is obtained; the processing circles are the same as the circles of the cross sections of the processing hole sites, and the top surface contours and the bottom surface contours of the thermal images of the processing hole sites after deviation can be better subjected to complement treatment by arranging the processing circles;
step S452, obtaining coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain a hypotenuse inclined line; step S453, connecting the center point of the machined corresponding contour with the center point of the top surface complement contour to obtain a vertical connecting line;
in step S454, the included angle between the vertical connection line and the oblique line of the hypotenuse is set as an oblique included angle, and in step S451 to step S454, the deviation condition is that the point of drilling the hole site during processing is accurate, only the deviation occurs during the drilling process, the obtained oblique included angle can provide reference data for subsequent calibration, and Rq in fig. 4 is the oblique included angle.
Step S4 further comprises the sub-steps of: step S461, when a machining hole site inclination deviation signal is output, connecting a center point of a machining corresponding outline with a center point of a hole site attaching surface to obtain an inclination deviation displacement; step S462, setting the direction of the center point of the hole site attaching surface towards the center point of the machining corresponding contour as an inclined deviation direction; step 463, complementing the bottom surface contour of the machined hole site image through the machining circle to obtain a bottom surface complementing contour; step S464, obtaining coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain an inclined deviation line; step S465, connecting the center point of the machined corresponding profile with the center point of the top surface complement profile to obtain a vertical deviation connecting line; in step S461 to step S466, the deviation condition is that the drilling point of the hole site is deviated during the processing, and the drilling process is inclined, and the obtained inclination deviation included angle and inclination deviation displacement can provide reference data for the subsequent calibration.
Referring to fig. 2, the present application further provides a hole site calibration analysis system based on an image comparison model, where the hole site calibration analysis system based on the image comparison model includes an image acquisition module, an image reference model establishment module, a parameter addition module, and an image recognition calibration module;
specifically, the image acquisition module is used for acquiring a station image and an image of an object to be processed.
The image reference model building module is used for building a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to build a processing reference model; the image reference model building module is configured with a model building policy comprising: setting an X axis, a Y axis and a Z axis for the three-dimensional coordinate system, and keeping the upper surface of the station image parallel to the plane where the X axis and the Y axis are located; setting the upper surface of the station image as a processing table top, acquiring the outline of the processing table top, and setting the outline of the processing table top as the outline of the table top; setting a first number of reference points at the edge of the table outline, and determining the coordinates of the reference points in a three-dimensional coordinate system; acquiring a surface to be punched in an image of an object to be processed, setting the surface opposite to the surface to be punched as an anastomotic surface, acquiring the outline of the anastomotic surface, and setting the outline as an anastomotic outline; and correspondingly arranging the coincident profile in the profile of the table top to ensure that the coincident surface is in contact with the processing table top, so as to obtain a processing reference model after the image of the object to be processed is coincident with the station image.
The parameter adding module is used for setting machining hole site parameters in a structure diagram to be machined in the machining reference model, the machining hole site parameters comprise hole site depth and hole site diameter, the parameter adding module is configured with a parameter adding strategy, and the parameter adding strategy comprises the following steps: acquiring the hole site depth and the hole site diameter in the machining hole site parameters, establishing a hole site model according to the hole site depth and the hole site diameter, and corresponding the hole site model to a machining reference model; acquiring the joint surface of the hole site model and the processing table top, and setting the joint surface as the joint surface of the hole site; and determining the coordinates of the center point of the hole site joint surface.
The image recognition and calibration module is used for acquiring a machined image, extracting a machined hole position image in the machined image, and aligning the machined image to a machined reference model to calibrate the machined hole position image; the image recognition calibration module comprises a processing image acquisition unit, wherein the processing image acquisition unit is used for acquiring a center point of a processing table top and acquiring a processing image right above the processing table top; and arranging a light reflecting panel on the surface of the processing table surface, carrying out gray scale treatment on the processing image, and extracting the top surface contour, the bottom surface contour and the contour of the reference point of the processing hole position image in the processing image through gray scale value distinction.
The image recognition calibration module further comprises a hole position calibration unit, wherein the hole position calibration unit is used for matching the outline of the reference point with the reference point in the processing reference model and mapping the processing image to the processing reference model; outputting a machining vertical precision signal when the top surface contour and the bottom surface contour of the machining hole site image are coincident, and outputting a machining vertical deviation signal when the top surface contour and the bottom surface contour of the machining hole site image are not fully coincident.
The hole location calibration unit is configured with a hole location calibration strategy comprising: when a machining vertical accurate signal is output, setting the bottom surface contour of a machining hole position image to be a combined contour;
acquiring coordinates of a central point of the coincident profile, and comparing the coordinates of the central point of the coincident profile with the coordinates of the central point of the hole site attaching surface;
outputting a processing hole position accurate signal when the coordinates of the center point of the coincident profile are the same as the coordinates of the center point of the hole position joint surface; outputting a processing hole position deviation signal when the coordinates of the central point of the coincident profile are different from the coordinates of the central point of the hole position joint surface;
calibrating the machining hole site image by corresponding the machining image to the machining reference model further comprises: when a processing hole position deviation signal is output, setting the center point coordinate of the coincident profile as a processing center point, and setting the center point of the hole position joint surface as a hole position reference center point;
the machining center point and the hole site reference center point are connected, the deviation line is set, the direction of the hole site reference center point towards the machining center point is set as the deviation direction, and the length of the deviation line is set as the deviation distance.
The hole location calibration strategy further includes: when a machining vertical deviation signal is output, setting a machining circle through the hole site diameter, and complementing the top surface contour of a machining hole site image by using the machining circle to obtain a top surface complementing contour; vertically corresponding the top surface complement profile to a processing table top to obtain a processing corresponding profile;
acquiring coordinates of a center point of a corresponding contour; comparing the coordinates of the center point of the corresponding contour with the coordinates of the center point of the hole site attaching surface;
outputting a machining hole site inclination signal when the coordinates of the center point of the machining corresponding outline are the same as the coordinates of the center point of the hole site attaching surface; and outputting a machining hole site inclination deviation signal when the coordinates of the center point of the machining corresponding outline are different from the coordinates of the center point of the hole site attaching surface.
The hole location calibration strategy is further configured with a hole location calibration parameter analysis sub-strategy comprising: when a machining hole position inclination signal is output, the bottom surface outline of a machining hole position image is complemented through a machining circle, and a bottom surface complement outline is obtained; acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain a hypotenuse inclined line; connecting the center point of the machined corresponding outline with the center point of the top surface complement outline to obtain a vertical connecting line; the included angle between the vertical connecting line and the inclined line of the hypotenuse is set as an inclined included angle.
The hole site calibration parameter analysis sub-strategy further includes: when a machining hole site inclination deviation signal is output, connecting a center point of a machining corresponding profile with a center point of a hole site attaching surface to obtain an inclination deviation displacement; setting the direction of the central point of the hole site joint surface towards the central point of the corresponding contour to be processed as an inclined deviation direction; the bottom surface outline of the processed hole site image is complemented through the processing circle, and a bottom surface complement outline is obtained; acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain an inclined deviation line; connecting the center point of the machined corresponding profile with the center point of the top surface complement profile to obtain a vertical deviation connecting line; and setting the included angle between the vertical deviation connecting line and the inclined deviation line as an inclined deviation included angle.
Embodiment three the present application provides a storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of any of the methods described above. By the above technical solution, the computer program, when executed by the processor, performs the method in any of the alternative implementations of the above embodiments to implement the following functions: firstly, acquiring a station image and an object image to be processed, establishing a three-dimensional coordinate system, enabling the station image and the object image to be processed to correspond to the three-dimensional coordinate system, setting the object image to be processed above the station image, establishing a processing reference model, setting processing hole site parameters in a structure diagram to be processed in the processing reference model, acquiring a processed processing image, extracting a processing hole site image in the processing image, and enabling the processing image to correspond to the processing reference model for calibrating the processing hole site image.
It will be appreciated by those skilled in the art that embodiments of the present application may be provided as a method, system, or computer program product. Accordingly, the present application may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, the present application may take the form of a computer program product embodied on one or more computer-usable storage media having computer-usable program code embodied therein. The storage medium may be implemented by any type or combination of volatile or nonvolatile Memory devices, such as static random access Memory (Static Random Access Memory, SRAM), electrically erasable Programmable Read-Only Memory (Electrically Erasable Programmable Read-Only Memory, EEPROM), erasable Programmable Read-Only Memory (Erasable Programmable Read Only Memory, EPROM), programmable Read-Only Memory (PROM), read-Only Memory (ROM), magnetic Memory, flash Memory, magnetic disk, or optical disk. These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing apparatus to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
In the embodiments provided in the present application, it should be understood that the disclosed apparatus and method may be implemented in other manners. The above-described apparatus embodiments are merely illustrative, for example, the division of the units is merely a logical function division, and there may be other manners of division in actual implementation, and for example, multiple units or components may be combined or integrated into another system, or some features may be omitted, or not performed. Alternatively, the coupling or direct coupling or communication connection shown or discussed with each other may be through some communication interface, device or unit indirect coupling or communication connection, which may be in electrical, mechanical or other form.
Claims (8)
1. The hole site calibration analysis method based on the image comparison model is characterized by comprising the following steps of: acquiring a station image and an object image to be processed;
establishing a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to establish a processing reference model;
setting machining hole site parameters in a structure diagram to be machined in a machining reference model, wherein the machining hole site parameters comprise hole site depth and hole site diameter;
acquiring a machined machining image, extracting a machining hole position image in the machining image, and aligning the machining image with the machining reference model to calibrate the machining hole position image;
establishing a three-dimensional coordinate system, corresponding the station image and the object image to be processed to the three-dimensional coordinate system, and setting the object image to be processed above the station image to establish a processing reference model further comprises: setting an X axis, a Y axis and a Z axis for the three-dimensional coordinate system, and keeping the upper surface of the station image parallel to the plane where the X axis and the Y axis are located;
setting the upper surface of the station image as a processing table top, acquiring the outline of the processing table top, and setting the outline of the processing table top as the outline of the table top;
setting a first number of reference points at the edge of the table outline, and determining the coordinates of the reference points in a three-dimensional coordinate system;
acquiring a surface to be punched in an image of an object to be processed, setting the surface opposite to the surface to be punched as an anastomotic surface, acquiring the outline of the anastomotic surface, and setting the outline as an anastomotic outline;
correspondingly arranging the coincident outline in the outline of the table top, so that the coincident surface is abutted with the processing table top, and a processing reference model is obtained after the image of the object to be processed is coincident with the station image;
setting the machining hole site parameters in the structure diagram to be machined in the machining reference model further comprises: acquiring the hole site depth and the hole site diameter in the machining hole site parameters, establishing a hole site model according to the hole site depth and the hole site diameter, and corresponding the hole site model to a machining reference model;
acquiring the joint surface of the hole site model and the processing table top, and setting the joint surface as the joint surface of the hole site;
and determining the coordinates of the center point of the hole site joint surface.
2. The hole site calibration analysis method based on the image comparison model according to claim 1, wherein the obtaining of the processed processing image after the processing, and the extracting of the processed hole site image in the processing image comprises: acquiring a center point of a processing table top, and acquiring a processing image right above the processing table top;
and arranging a light reflecting panel on the surface of the processing table surface, carrying out gray scale treatment on the processing image, and extracting the top surface contour, the bottom surface contour and the contour of the reference point of the processing hole position image in the processing image through gray scale value distinction.
3. The hole site calibration analysis method based on the image comparison model according to claim 2, wherein the calibration of the machined hole site image by mapping the machined image to the machined reference model comprises: matching the outline of the reference point with the reference point in the processing reference model, and mapping the processing image into the processing reference model;
outputting a machining vertical precision signal when the top surface contour and the bottom surface contour of the machining hole site image are coincident, and outputting a machining vertical deviation signal when the top surface contour and the bottom surface contour of the machining hole site image are not fully coincident.
4. A hole site calibration analysis method based on an image comparison model as set forth in claim 3, wherein the calibration of the machined hole site image by mapping the machined image to the machined reference model further includes: when a machining vertical accurate signal is output, setting the bottom surface contour of a machining hole position image to be a combined contour;
acquiring coordinates of a central point of the coincident profile, and comparing the coordinates of the central point of the coincident profile with the coordinates of the central point of the hole site attaching surface;
outputting a processing hole position accurate signal when the coordinates of the center point of the coincident profile are the same as the coordinates of the center point of the hole position joint surface; outputting a processing hole position deviation signal when the coordinates of the central point of the coincident profile are different from the coordinates of the central point of the hole position joint surface;
calibrating the machining hole site image by corresponding the machining image to the machining reference model further comprises: when a processing hole position deviation signal is output, setting the center point coordinate of the coincident profile as a processing center point, and setting the center point of the hole position joint surface as a hole position reference center point;
the machining center point and the hole site reference center point are connected, the deviation line is set, the direction of the hole site reference center point towards the machining center point is set as the deviation direction, and the length of the deviation line is set as the deviation distance.
5. The hole site calibration analysis method based on the image comparison model as set forth in claim 4, wherein the calibration of the machined hole site image by mapping the machined image to the machined reference model further includes: when a machining vertical deviation signal is output, setting a machining circle through the hole site diameter, and complementing the top surface contour of a machining hole site image by using the machining circle to obtain a top surface complementing contour;
vertically corresponding the top surface complement profile to a processing table top to obtain a processing corresponding profile;
acquiring coordinates of a center point of a corresponding contour;
comparing the coordinates of the center point of the corresponding contour with the coordinates of the center point of the hole site attaching surface;
outputting a machining hole site inclination signal when the coordinates of the center point of the machining corresponding outline are the same as the coordinates of the center point of the hole site attaching surface; and outputting a machining hole site inclination deviation signal when the coordinates of the center point of the machining corresponding outline are different from the coordinates of the center point of the hole site attaching surface.
6. The hole site calibration analysis method based on the image comparison model as set forth in claim 5, wherein the calibration of the machined hole site image by mapping the machined image to the machined reference model further includes: when a machining hole position inclination signal is output, the bottom surface outline of a machining hole position image is complemented through a machining circle, and a bottom surface complement outline is obtained;
acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain a hypotenuse inclined line;
connecting the center point of the machined corresponding outline with the center point of the top surface complement outline to obtain a vertical connecting line;
the included angle between the vertical connecting line and the inclined line of the hypotenuse is set as an inclined included angle.
7. The hole site calibration analysis method based on the image comparison model as set forth in claim 6, wherein the calibration of the machined hole site image by mapping the machined image to the machined reference model further includes: when a machining hole site inclination deviation signal is output, connecting a center point of a machining corresponding profile with a center point of a hole site attaching surface to obtain an inclination deviation displacement;
setting the direction of the central point of the hole site joint surface towards the central point of the corresponding contour to be processed as an inclined deviation direction;
the bottom surface outline of the processed hole site image is complemented through the processing circle, and a bottom surface complement outline is obtained;
acquiring coordinates of a central point of the bottom surface complement contour, and connecting the central point of the bottom surface complement contour with the central point of the top surface complement contour to obtain an inclined deviation line;
connecting the center point of the machined corresponding profile with the center point of the top surface complement profile to obtain a vertical deviation connecting line;
and setting the included angle between the vertical deviation connecting line and the inclined deviation line as an inclined deviation included angle.
8. A storage medium having stored thereon a computer program which, when executed by a processor, performs the steps of the method according to any of claims 1-7.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310899075.7A CN116612162B (en) | 2023-07-21 | 2023-07-21 | Hole site calibration analysis method, system and storage medium based on image comparison model |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202310899075.7A CN116612162B (en) | 2023-07-21 | 2023-07-21 | Hole site calibration analysis method, system and storage medium based on image comparison model |
Publications (2)
Publication Number | Publication Date |
---|---|
CN116612162A CN116612162A (en) | 2023-08-18 |
CN116612162B true CN116612162B (en) | 2023-11-17 |
Family
ID=87684094
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202310899075.7A Active CN116612162B (en) | 2023-07-21 | 2023-07-21 | Hole site calibration analysis method, system and storage medium based on image comparison model |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN116612162B (en) |
Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111681206A (en) * | 2020-05-08 | 2020-09-18 | 上海工程技术大学 | Method for detecting size of special-shaped hole of spinneret plate |
CN111889989A (en) * | 2020-09-17 | 2020-11-06 | 常州锦瑟医疗信息科技有限公司 | High-precision machining method and system based on mixed reality |
CN112099615A (en) * | 2019-06-17 | 2020-12-18 | 北京七鑫易维科技有限公司 | Gaze information determination method and device, eyeball tracking equipment and storage medium |
CN113554667A (en) * | 2021-07-27 | 2021-10-26 | 上海海瞩智能科技有限公司 | Three-dimensional displacement detection method and device based on image recognition |
CN115131553A (en) * | 2022-08-30 | 2022-09-30 | 季华实验室 | Shielding hole positioning method and device, electronic equipment and storage medium |
CN115239822A (en) * | 2022-07-27 | 2022-10-25 | 北京理工大学 | Real-time visual identification and positioning method and system for multi-module space of split type flying vehicle |
-
2023
- 2023-07-21 CN CN202310899075.7A patent/CN116612162B/en active Active
Patent Citations (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN112099615A (en) * | 2019-06-17 | 2020-12-18 | 北京七鑫易维科技有限公司 | Gaze information determination method and device, eyeball tracking equipment and storage medium |
CN111681206A (en) * | 2020-05-08 | 2020-09-18 | 上海工程技术大学 | Method for detecting size of special-shaped hole of spinneret plate |
CN111889989A (en) * | 2020-09-17 | 2020-11-06 | 常州锦瑟医疗信息科技有限公司 | High-precision machining method and system based on mixed reality |
CN113554667A (en) * | 2021-07-27 | 2021-10-26 | 上海海瞩智能科技有限公司 | Three-dimensional displacement detection method and device based on image recognition |
CN115239822A (en) * | 2022-07-27 | 2022-10-25 | 北京理工大学 | Real-time visual identification and positioning method and system for multi-module space of split type flying vehicle |
CN115131553A (en) * | 2022-08-30 | 2022-09-30 | 季华实验室 | Shielding hole positioning method and device, electronic equipment and storage medium |
Also Published As
Publication number | Publication date |
---|---|
CN116612162A (en) | 2023-08-18 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN100547351C (en) | A kind of machine vision localization method | |
CN102135417B (en) | Full-automatic three-dimension characteristic extracting method | |
CN107133983B (en) | Bundled round steel end face binocular vision system and space orientation and method of counting | |
CN101526484B (en) | Bearing defect detecting technique based on embedded-type machine vision | |
JP2008014940A (en) | Camera calibration method for camera measurement of planar subject and measuring device applying same | |
CN110651686B (en) | Tapping method and system based on tapping mechanical arm | |
CN110132166B (en) | Product image detection method capable of automatically distributing light and comparison device | |
CN107239742A (en) | A kind of gauge pointer scale value calculating method | |
CN104034261B (en) | A kind of curved surface normal direction measurement apparatus and curved surface normal direction measuring method | |
CN105783786A (en) | Part chamfering measuring method and device based on structured light vision | |
CN105606620A (en) | PCBA welding spot detection method and system based on vision | |
CN111531407B (en) | Workpiece attitude rapid measurement method based on image processing | |
KR20130033374A (en) | Surveying method | |
CN110910359A (en) | FPC (flexible printed circuit) line detection method based on feature tracking and skeleton feature matching | |
CN115984512B (en) | Three-dimensional reconstruction device and method for plane scene | |
CN104596412A (en) | Identification base for complex curved surface high-precision measuring and positioning | |
CN116612162B (en) | Hole site calibration analysis method, system and storage medium based on image comparison model | |
CN114549408A (en) | Position size comparison method based on graphic image | |
CN115235375A (en) | Multi-circle characteristic parameter measuring method, detecting method and device for cover plate type workpiece | |
JP2012032341A (en) | Measurement setting data preparation device, measurement setting data preparation method, program for measurement setting data preparation device, and dimension measurement device | |
CN113269729B (en) | Assembly body multi-view detection method and system based on depth image contrast | |
CN110057338A (en) | A kind of adaptive setting method of Workpiece zero point based on duplex measurement | |
CN105431032A (en) | Substrate detection method | |
CN112834505B (en) | Three-dimensional visual detection positioning device and method for pasted welding line of pipeline workpiece | |
JP2004268220A (en) | Electric discharge machine |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |