Visual positioning system and method for complex box five-axis numerical control comprehensive processing machine
Through multi-camera visual positioning system and real-time monitoring technology, the positioning accuracy and cavity identification problems in complex box five-axis processing are solved, and high-precision and efficient intelligent processing are achieved, reducing the risks of thin-wall deformation and vibration.
Patent Information
- Application Number
- CN202510270224.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-03-07
- Publication Date
- 2025-07-04
- Estimated Expiration
- 2045-03-07
AI Technical Summary
The prior art has problems in the five-axis processing of complex box bodies, such as insufficient positioning accuracy, limited recognition ability of the cavity structure, inability to monitor processing deformation and cutting status in real time, and lack of dynamic compensation mechanism, resulting in low processing quality and efficiency.
Multi-camera visual positioning system is used to collect and coordinate calibration multi-angle image, combine the splicing and matching of three-dimensional feature point data sets, and determine cutting parameters through thickness measurement and stiffness analysis, generate tool trajectories that avoid internal cavity obstacles, and monitor the processing process in real time to dynamically adjust parameters to form closed-loop control.
It improves the processing accuracy and efficiency of complex boxes, reduces the risk of deformation and vibration in thin-walled areas, and achieves high-precision and efficient intelligent processing.
Smart Images

Figure CN120259422A_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of image processing technology, and particularly to a vision positioning system and method for a five-axis CNC comprehensive machining machine for complex boxes. Background Art
[0002] Complex box structures are key components in high-end equipment manufacturing fields such as aerospace, automotive, and energy. Their machining accuracy and quality directly affect product performance and reliability. Currently, five-axis CNC comprehensive machining machines have become the main equipment for machining complex boxes and can achieve precise machining of complex geometric shapes. Traditional box machining positioning methods mainly rely on manual measurement and mechanical positioning devices, including using special fixtures, tool setting instruments, contact probes, etc. to determine the position and attitude of the workpiece in the machine tool. With the improvement of industrial automation, some advanced factories have begun to try to use a single vision system for auxiliary positioning, but most of these systems are limited to the positioning of workpieces with simple shapes and cannot effectively meet the comprehensive measurement and positioning requirements of the inner and outer surfaces of complex boxes, especially the recognition and parameter optimization capabilities for the inner cavity machining area are limited.
[0003] However, the existing technology still has obvious deficiencies in dealing with five-axis machining of complex boxes. First, a single-view vision system cannot comprehensively capture the complex geometric features of the box, resulting in insufficient positioning accuracy; second, there is a lack of effective means for identifying and analyzing the inner cavity structure of the box, making it difficult to formulate reasonable machining strategies according to the characteristics of different regions; third, traditional methods cannot monitor the workpiece deformation and cutting state during the machining process in real time, resulting in easy excessive deformation and vibration in thin-walled areas; finally, there is a lack of a dynamic compensation mechanism and it is unable to adjust machining parameters according to the real-time machining state, making it difficult to ensure the overall quality and efficiency of complex box machining. These problems are particularly prominent in the machining of high-precision and high-value complex boxes, seriously restricting the improvement of product quality and production efficiency. Summary of the Invention
[0004] This application provides a vision positioning system and method for a five-axis CNC comprehensive machining machine for complex boxes, which is used to achieve high-precision vision positioning and intelligent machining parameter optimization of complex boxes on a five-axis CNC comprehensive machining machine, improving the accuracy, efficiency, and reliability of complex box machining.
[0005] In a first aspect, this application provides a vision positioning system for a five-axis CNC comprehensive machining machine for complex boxes. The vision positioning system for a five-axis CNC comprehensive machining machine for complex boxes includes: A calibration module, which is used to collect multi-angle images of the box workpiece through multiple cameras and use marker points for coordinate calibration to obtain camera parameters and a machine tool space coordinate mapping table; An extraction module, configured to perform edge detection and contour extraction on multi-angle images according to the camera parameters and the machine tool space coordinate mapping table, and merge and transform the features of each view through point cloud stitching to obtain a three-dimensional feature point dataset of the box workpiece; A marking module, configured to determine the actual position of the box in the machine tool through matching degree calculation and error minimization processing according to the three-dimensional feature point dataset, and mark the key machining areas of the inner cavity to obtain the positioning data of the box workpiece and the machining key area table; A recording module, configured to determine the cutting parameters of different areas of the box through thickness measurement and stiffness analysis according to the positioning data and the machining key area table, and record the predicted deformation amount to obtain the cutting depth and feed speed adjustment values for different areas; A processing module, configured to generate a tool path that avoids inner cavity obstacles through path calculation and interference check according to the cutting depth and feed speed adjustment values, and process the thin-walled area to obtain a five-axis machining instruction sequence including the tool approach and retract strategies; A comparison module, configured to compare the difference between the expected machining effect and the actual result by using the machining process monitoring data according to the five-axis machining instruction sequence, and adjust the subsequent machining parameters according to the difference value to obtain real-time compensation data and quality control records.
[0006] In a second aspect, the present application provides a vision positioning method for a five-axis numerical control comprehensive machining machine for complex boxes. The vision positioning method for a five-axis numerical control comprehensive machining machine for complex boxes includes: collecting multi-angle images of the box workpiece through multiple cameras, and performing coordinate calibration by using marker points to obtain camera parameters and a machine tool space coordinate mapping table; performing edge detection and contour extraction on the multi-angle images according to the camera parameters and the machine tool space coordinate mapping table, and merging and transforming the features of each view through point cloud stitching to obtain a three-dimensional feature point dataset of the box workpiece; determining the actual position of the box in the machine tool through matching degree calculation and error minimization processing according to the three-dimensional feature point dataset, and marking the key machining areas of the inner cavity to obtain the positioning data of the box workpiece and the machining key area table; determining the cutting parameters of different areas of the box through thickness measurement and stiffness analysis according to the positioning data and the machining key area table, and recording the predicted deformation amount to obtain the cutting depth and feed speed adjustment values for different areas; generating a tool path that avoids inner cavity obstacles through path calculation and interference check according to the cutting depth and feed speed adjustment values, and processing the thin-walled area to obtain a five-axis machining instruction sequence including the tool approach and retract strategies; comparing the difference between the expected machining effect and the actual result by using the machining process monitoring data according to the five-axis machining instruction sequence, and adjusting the subsequent machining parameters according to the difference value to obtain real-time compensation data and quality control records.
[0007] In a third aspect of the present invention, a computer device is provided, comprising: a memory and at least one processor, wherein instructions are stored in the memory; the at least one processor invokes the instructions in the memory to cause the computer device to execute the above-mentioned vision positioning method for a complex box five-axis numerical control comprehensive machining machine.
[0008] In a fourth aspect of the present invention, a computer-readable storage medium is provided, wherein instructions are stored in the computer-readable storage medium, and when it runs on a computer, it causes the computer to execute the above-mentioned vision positioning method for a complex box five-axis numerical control comprehensive machining machine.
[0009] In the technical solution provided by this application, by collecting multi-angle images of the box workpiece with multiple cameras and using the fiducial points for coordinate calibration, the problem that it is difficult to comprehensively capture the complex geometric features of the box from a single perspective is effectively solved, and the positioning accuracy and reliability are significantly improved; based on the obtained camera parameters and the machine tool space coordinate mapping table, edge detection and contour extraction are performed on the multi-angle images, and the features of each perspective are merged and transformed through point cloud stitching, making the three-dimensional feature point dataset of the complex box more complete and accurate, providing a reliable geometric basis for subsequent processing; by calculating the matching degree and minimizing the error, the actual position of the box in the machine tool is determined, and the key machining areas of the inner cavity are intelligently marked, realizing the efficient conversion from a large amount of three-dimensional data to precise positioning and machining planning, greatly reducing the workload and subjective error of manual analysis; by measuring the thickness and analyzing the stiffness, the cutting parameters of different areas of the box are determined and the predicted deformation amount is recorded, and a differential machining strategy is formulated for the weak stiffness areas such as the thin walls of the box, effectively preventing machining deformation and vibration problems; by calculating the tool path and checking for interference, a tool path that avoids the inner cavity obstacles is generated, and special treatment is carried out for the thin wall areas, solving the tool collision risk in complex inner cavity machining and improving the machining safety; by using the machining process monitoring data to compare the difference between the expected machining effect and the actual result in real time, and dynamically adjusting the subsequent machining parameters according to the difference value, a closed-loop control system is formed, ensuring the quality stability of the entire machining process. At the algorithm level, this solution integrates technologies such as computer vision, spatial analysis, and closed-loop control. In particular, the image processing algorithms applied in feature point extraction, three-dimensional reconstruction, and machine coordinate mapping, as well as the mechanical analysis models applied in thin wall area recognition and machining parameter optimization, jointly construct an intelligent decision-making system for complex box machining, not only improving the machining accuracy, but also enhancing the production efficiency and reducing the scrap risk of high-value complex boxes. Description of the Drawings
[0010] To more clearly illustrate the technical solutions of the embodiments of the present invention, the following will briefly introduce the accompanying drawings required for the description of the embodiments. Obviously, the accompanying drawings in the following description are some embodiments of the present invention. For those of ordinary skill in the art, without creative efforts, other accompanying drawings can also be obtained based on these drawings.
[0011] Figure 1 FIG. is a schematic diagram of an embodiment of a vision positioning system for a complex box five-axis CNC comprehensive machining machine in an embodiment of the present application; Figure 2 FIG. is a schematic diagram of an embodiment of a vision positioning method for a complex box five-axis CNC comprehensive machining machine in an embodiment of the present application. Specific Embodiments
[0012] The embodiments of the present application provide a vision positioning system and method for a complex box five-axis CNC comprehensive machining machine. The terms "first", "second", "third", "fourth", etc. (if any) in the specification, claims and above-mentioned accompanying drawings of the present application are used to distinguish similar objects, and do not have to be used to describe a specific order or sequence. It should be understood that such data can be interchanged under appropriate circumstances so that the embodiments described here can be implemented in an order other than that illustrated or described here. In addition, the terms "comprising" or "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product or device comprising a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or units not clearly listed or inherent to these processes, methods, products or devices.
[0013] For ease of understanding, the following describes the specific process of the embodiments of the present application. Please refer to Figure 1 , an embodiment of the vision positioning system for a complex box five-axis CNC comprehensive machining machine in an embodiment of the present application includes: A calibration module 101, configured to collect multi-angle images of a box workpiece through multiple cameras, and perform coordinate calibration using marker points to obtain camera parameters and a machine tool space coordinate mapping table; An extraction module 102, configured to perform edge detection and contour extraction on the multi-angle images according to the camera parameters and the machine tool space coordinate mapping table, and merge and convert the features of each view through point cloud stitching to obtain a three-dimensional feature point data set of the box workpiece; A marking module 103, configured to determine the actual position of the box in the machine tool according to the three-dimensional feature point data set through matching degree calculation and error minimization processing, and mark the key machining areas of the inner cavity to obtain the positioning data of the box workpiece and a machining key area table; The recording module 104 is configured to determine the cutting parameters of different regions of the box body by using thickness measurement and stiffness analysis according to the positioning data and the machining key area table, record the predicted deformation amount, and obtain the adjusted values of the cutting depth and feed rate for each region. The processing module 105 is configured to generate a tool path that avoids the internal cavity obstacles through path calculation and interference checking according to the adjusted values of the cutting depth and feed rate, and process the thin-walled region to obtain a five-axis machining instruction sequence including the tool approach and retract strategies. The comparison module 106 is configured to compare the difference between the expected machining effect and the actual result by using the machining process monitoring data according to the five-axis machining instruction sequence, and adjust the subsequent machining parameters according to the difference value to obtain real-time compensation data and quality control records.
[0014] It can be understood that the execution subject of this application can be a vision positioning system for a complex box body five-axis CNC comprehensive machining machine, or a terminal or a server. Specifically, it is not limited here. In this embodiment of the application, the server is used as the execution subject for illustration.
[0015] Specifically, the calibration module 101 synchronously acquires multi-view image data of the box body workpiece through an annularly arranged industrial-grade high-definition camera. The original images are preprocessed, such as denoising, grayscale conversion, and contrast enhancement, to improve the image quality. Subsequently, the reflective marking points pre-attached to the surface of the box body are identified to obtain the image coordinate set of the marking points. Based on the actual spatial positions of the known marking points and the image coordinate set, the spatial correspondence relationship is calculated to generate the camera internal parameter matrix. Combining the relative position relationship between different cameras, the conversion equation between the camera coordinate system and the machine tool coordinate system is established to form a complete mapping table of camera parameters and machine tool spatial coordinates. In the machining of box body aerospace aluminum alloy parts, the marking points are usually distributed on the planes and corners of the outer surface of the box body. Images are collected from different angles by at least three high-definition cameras, and the spatial positions of the marking points in the machine tool coordinate system are accurately located after coordinate calibration, thus laying a foundation for subsequent feature extraction.
[0016] The extraction module 102 uses the parameters obtained by the calibration module for edge detection and contour extraction. This module processes multi-angle images through the Canny operator to extract the two-dimensional edge information of the box body workpiece. Geometric analysis is performed on the edge feature map to identify straight lines, arcs, and curved surfaces, and the geometric structure data of the box body contour is generated. According to the camera parameters in the previous step, the two-dimensional image coordinates are converted into three-dimensional space coordinates to obtain single-view three-dimensional feature points. The feature points from different views are unified into the machine tool coordinate system by using the machine tool spatial coordinate mapping table to form a multi-view feature point set. Data cleaning is performed on the feature point set to remove redundant points and noise points, and spatial consistency verification is carried out. Finally, these points are merged and optimized through a three-dimensional space stitching algorithm to construct a complete geometric expression of the box body workpiece and obtain a three-dimensional feature point data set.
[0017] The marking module 103 compares the three-dimensional feature point data set with the theoretical design data of the box workpiece, screens out distinguishable feature point pairs such as planes, edges, and corners through a multi-level feature decomposition and matching strategy, and establishes a hierarchical feature correspondence table. Geometric topological consistency verification is performed on these feature relationships, a spatial constraint network is constructed using the relative position and angular relationships between features, incorrect matches that violate topological logic are excluded, and a highly reliable feature mapping set is obtained. An overdetermined system of equations is constructed based on these mappings, the rigid body transformation parameters of the box workpiece are solved by singular value decomposition, and the influence of measurement noise is reduced by combining a weighted iteration strategy to obtain a rigid pose transformation matrix. Non-uniform thermal expansion correction is performed on this matrix, the spatial deformation field is calculated based on the material properties and temperature distribution data of the box, and accurate pose description data including elastic deformation compensation is generated. Visibility and accessibility analysis of the inner cavity of the box is performed based on this data, special processing areas such as thin-wall areas, deep-hole areas, and narrow-slit areas are identified, and a risk distribution map of inner cavity machining is obtained. Finally, the accurate pose description data and the risk distribution map of inner cavity machining are integrated and sorted to generate the positioning data of the box workpiece and a table of key machining areas.
[0018] The recording module 104 performs virtual slicing on the box workpiece according to the positioning data, divides the box structure into multiple discrete analysis units, and generates a box partition data map. The wall thickness distribution of each analysis unit is measured, the wall thickness value of each point is calculated by surface normal sampling, and the wall thickness distribution data is obtained. The structural stiffness coefficient of each analysis unit is calculated based on the wall thickness distribution data combined with the material property parameters, thin-wall and weak-stiffness areas are identified, and a stiffness distribution table is constructed. The stiffness distribution table is fused with the table of key machining areas, a cutting force safety threshold is established according to the regional importance and stiffness characteristics, and regional cutting force limit conditions are generated. Based on these limit conditions, the maximum allowable cutting depth and the optimal feed rate for each region are derived, and the expected deformation amount under these parameters is calculated simultaneously to form a machining parameter-deformation relationship table. Based on this relationship table, customized machining parameters are assigned to different regions of the box workpiece, and a deformation monitoring threshold is set to obtain the adjusted values of cutting depth and feed rate for each region.
[0019] The processing module 105 divides the box machining task into rough machining layer and finish machining layer according to the cutting depth and feed rate adjustment values, creates an independent tool parameter table, and generates a multi-level machining plan. It generates an initial tool contact point sequence for each machining area, calculates the tool axial vector at each contact point, and obtains a set of tool pose points. Through the tool envelope volume, it conducts interference analysis on the set of tool pose points, detects potential collision areas between the tool and the inner cavity structure of the box, and generates an interference risk map. According to the interference risk map, it re-plans the path of the set of tool pose points, avoids the collision area by restricting the safety distance and adjusting the tool axis tilt angle, and obtains a collision-free tool path. For the path segments passing through the thin-wall area in the collision-free tool path, it adopts a segmented in-and-out strategy and progressive cutting depth control to reduce the influence of cutting force on the thin-wall deformation, and forms an optimized trajectory for the thin-wall area. It merges the collision-free tool path and the optimized trajectory for the thin-wall area, and adds a tool approach and retract safety area and a tool change position to generate a five-axis machining instruction sequence including approach and retract strategies.
[0020] During the execution of the five-axis machining instruction sequence, the comparison module 106 collects real-time machining state information through a multi-sensor array, including cutting force signals, vibration signals, and surface topography data, to obtain the original monitoring data of the machining process. It conducts feature extraction and signal processing on the original monitoring data, filters out noise and identifies key machining state indicators, and obtains machining state feature quantities. It compares and analyzes the machining state feature quantities with the pre-set ideal machining parameters, calculates the deviation degree of each machining index, and generates a machining deviation distribution table. According to this table, it makes real-time corrections to the unexecuted machining path, adjusts the cutting parameters and tool feed trajectory, and obtains dynamically optimized subsequent machining instructions. During the execution of the subsequent machining instructions, it continuously monitors the cutting state and surface quality of the key machining areas, establishes a mapping relationship between machining parameters and machining quality, and obtains machining effect evaluation data. It integrates and records the dynamically optimized subsequent machining instructions and machining effect evaluation data to form real-time compensation data and quality control records for the whole process of workpiece machining.
[0021] In a specific embodiment, the calibration module 101 is specifically used for: Synchronously obtaining multi-view image data of the box workpiece through an annularly arranged industrial-grade high-definition camera to obtain a group of original image data; Performing image preprocessing on the group of original image data, including denoising, grayscale conversion, and contrast enhancement, to obtain enhanced image data; Identifying the reflective marking points pre-attached to the surface of the box workpiece in the enhanced image data to obtain a set of marking point image coordinates; Calculating the spatial correspondence relationship between the actual spatial positions of the known marking points and the set of marking point image coordinates to obtain the camera internal parameter matrix; According to the camera internal parameter matrix and the relative position relationship between different cameras, establish the conversion equation between the camera coordinate system and the machine tool coordinate system, and obtain the coordinate system transformation matrix; Combine the camera internal parameter matrix and the coordinate system transformation matrix to generate a mapping table of camera parameters and machine tool spatial coordinates.
[0022] Specifically, the calibration module 101 synchronously acquires multi-view image data of the box workpiece through ring-arranged industrial-grade high-definition cameras to obtain an original image data set. In the five-axis CNC comprehensive machining of complex boxes, due to the complexity of the box structure, at least 3 - 5 high-definition cameras need to be arranged to form a ring coverage structure in order to obtain comprehensive visual information. These cameras usually use industrial-grade CCD or CMOS sensors with a resolution of 1920×1080 pixels or higher and have a synchronous triggering function to ensure capturing different-view images of the box workpiece at the same moment. The synchronous triggering is achieved through a hardware synchronous signal with an error controlled at the microsecond level to ensure the time consistency of multi-view data. The original images captured by each camera constitute the original image data set, which contains the surface texture, geometric features, and information of pre-attached reflective marker points of the box workpiece. Image preprocessing is performed on the original image data set, including denoising, grayscale conversion, and contrast enhancement, to obtain enhanced image data. The denoising process uses median filtering or Gaussian filtering algorithms to effectively remove random noise introduced by machine vibration and environmental light changes. The grayscale conversion process converts the RGB color image into a single-channel grayscale image to simplify subsequent calculations and improve processing speed. The contrast enhancement is achieved through histogram equalization or adaptive histogram equalization techniques to enhance the contrast between the reflective marker points and the background in the image, facilitating subsequent marker point detection. The preprocessed image data has a higher signal-to-noise ratio and clarity. Reflective marker points pre-attached to the surface of the box workpiece are identified in the enhanced image data to obtain a set of marker point image coordinates. The reflective marker points are usually made of high-reflectivity materials with a diameter in the range of 1 - 5 mm and have regular circular or cross shapes, and are attached to key positions of the box workpiece such as edges, corners, or planes. Marker point recognition uses a method combining threshold segmentation and morphological processing. The high-brightness regions are segmented through an adaptive threshold, and then small holes are filled through morphological closing operations, and small noise is removed through opening operations. Finally, regions that meet the size and shape characteristics of the marker points are selected through connected component analysis. The centroid coordinates are calculated for each marker point region to form a set of marker point image coordinates, which record the two-dimensional pixel coordinates of each marker point on the image plane of each camera. By calculating the spatial correspondence relationship between the actual spatial positions of the known marker points and the set of marker point image coordinates, the camera internal parameter matrix is obtained. The actual spatial positions of the marker points are pre-measured by a high-precision three-coordinate measuring instrument with an accuracy up to the micron level. The camera internal parameter matrix describes the internal geometry and optical characteristics of the camera, including focal length, principal point coordinates, and lens distortion coefficients. The calculation process is based on the pinhole camera model to construct the mapping relationship from the actual spatial coordinates of the marker points to the image coordinates, and the internal parameter matrix is obtained through the least squares method. In practice, the Zhang's calibration method is usually adopted to extract the camera internal parameter through analyzing the projection relationship of the marker points in multiple poses.
[0023] Based on the camera intrinsic matrix and the relative position relationship between different cameras, establish the transformation equation between the camera coordinate system and the machine tool coordinate system to obtain the coordinate system transformation matrix. Determine one camera as the reference camera, establish the camera coordinate system, and then calculate the pose relationship of other cameras relative to the reference camera to obtain the relative transformation matrix between cameras. The correspondence between the camera coordinate system and the machine tool coordinate system is established through marked points with known coordinates, and the rigid body transformation parameters, including the rotation matrix and the translation vector, which are collectively called the coordinate system transformation matrix, are solved. This calculation is usually implemented using the SVD decomposition or the quaternion method to ensure the transformation accuracy. Combine the camera intrinsic matrix and the coordinate system transformation matrix to generate the mapping table of camera parameters and machine tool space coordinates. This mapping table contains the complete transformation relationship from image coordinates to machine tool space coordinates and is the basis for subsequent 3D reconstruction and pose estimation. Specifically, for any point on the image, the ray direction in the camera coordinate system can be obtained by back-projection through the intrinsic matrix, and then it is transformed to the machine tool coordinate system through the coordinate system transformation matrix to determine the position of this point in the machine tool space.
[0024] Taking the machining of a certain aero-engine box part as an example, the box is accurately positioned before machining. The calibration module 101 is circularly arranged with 4 industrial cameras to capture multi-view images of the box, and 12 reflective marked points are pre-attached to the surface of the box. After image preprocessing, the system clearly identifies all the marked points from 4 perspectives and generates the image coordinate set of the marked points. By comparing and calculating with the actual spatial positions of the marked points measured in advance, the intrinsic matrix of each camera is obtained, and the transformation relationship between the camera coordinate system and the machine tool coordinate system is determined. The generated coordinate mapping table enables the system to accurately map any feature point on the image to the machine tool coordinate system.
[0025] In a specific embodiment, the extraction module 102 is specifically used for: Perform edge detection on the multi-angle images through the Canny operator to extract the two-dimensional edge information of the box workpiece and obtain the edge feature map; Perform geometric feature analysis on the edge feature map to identify straight lines, arcs, and curved surfaces and obtain the geometric structure data of the box contour; Convert the geometric structure data of the box contour from two-dimensional image coordinates to three-dimensional space coordinates according to the camera parameters to obtain single-view three-dimensional feature points; Use the machine tool space coordinate mapping table to unify the single-view three-dimensional feature points from different perspectives into the machine tool coordinate system to obtain a multi-view feature point set; Perform data cleaning on the multi-view feature point set, remove redundant points and noise points, and perform spatial consistency verification to obtain a refined feature point set; Merge and optimize the refined feature point set through a three-dimensional space stitching algorithm to construct a geometric representation of the box workpiece and obtain a three-dimensional feature point data set of the box workpiece.
[0026] Specifically, the extraction module 102 performs edge detection on multi-angle images through the Canny operator to extract the two-dimensional edge information of the box workpiece and obtain an edge feature map. As a classic edge detection algorithm, the Canny operator is particularly suitable for extracting the edges of complex box surfaces. In this process, the Canny operator applies Gaussian filtering to the image for smoothing to suppress noise; then calculates the gradient magnitude and direction of the image to determine the intensity and orientation of the edges; then performs non-maximum suppression to retain the local maximum points in the gradient direction; finally, connects the edge points through the double-threshold method to form a complete edge contour. For complex boxes, the high and low thresholds of the Canny operator are usually set as relative values, such as 70% and 30% of the gradient magnitude of the box image, to ensure that both the main structural edges can be effectively captured and excessive noise is not introduced. The edge feature map is a binary image, where the pixel points with a value of 255 represent the edge positions, forming the contour lines on the surface of the box workpiece. Perform geometric feature analysis on the edge feature map to identify geometric elements such as straight lines, arcs, and curved surfaces, and obtain the geometric structure data of the box contour. The geometric feature analysis is realized through algorithms such as the Hough transform and contour fitting. Straight line detection uses the Hough line transform to transform the edge points into the parameter space and identify the parameters of the straight line segment; arc detection uses the Hough circle transform or least squares circular arc fitting to extract the center and radius parameters; for complex curved surfaces, B-spline curve fitting or multi-segment broken line approximation is used. The geometric analysis process also includes the extraction of topological relationships, such as the intersection points of straight lines and the tangent points of straight lines and arcs. The geometric structure data of the box contour is stored in a parameterized form, including the type of geometric elements, position parameters, and their topological relationships, forming a structured description of the two-dimensional contour of the box.
[0027] Convert the geometric structure data of the box body contour from two-dimensional image coordinates to three-dimensional space coordinates according to the camera parameters to obtain single-view three-dimensional feature points. This step uses the inverse projection calculation with the camera internal parameter matrix obtained by the calibration module. For each two-dimensional image point, calculate its corresponding three-dimensional ray direction through the camera internal parameter matrix, and then determine the actual spatial position of the point with the help of the matching points or known depth information in the multi-view images. For structured geometric elements such as straight lines and arcs, the geometric attributes are retained during the inverse projection process, and the parameters are directly converted into the three-dimensional space. The single-view three-dimensional feature points contain the spatial position information of the geometric features on the box body surface observed from a single camera view, but are limited to the surface part visible from this view. Use the machine tool space coordinate mapping table to unify the single-view three-dimensional feature points from different views into the machine tool coordinate system to obtain a multi-view feature point set. The machine tool space coordinate mapping table contains the transformation matrices from each camera coordinate system to the machine tool coordinate system. Through these transformation matrices, the single-view three-dimensional feature points can be converted from their respective camera coordinate systems to the unified machine tool coordinate system. The transformation process includes rotation and translation operations, and the transformed feature points are merged into a set to form a multi-view feature point set, covering the geometric features of multiple visible surfaces of the box body workpiece.
[0028] Perform data cleaning on the multi-view feature point set, remove redundant points and noise points, and conduct spatial consistency verification to obtain a refined feature point set. The data cleaning performs spatial clustering to merge feature points with close distances and reduce redundant data; then identify and remove outliers based on statistical analysis, such as isolated points or points with significantly abnormal distances from surrounding points; then conduct geometric consistency checks to verify whether the spatial relationships between feature points conform to rigid body geometric constraints and remove points that do not meet the constraints. The spatial consistency verification also includes checking the distribution density of feature points to ensure that key areas such as corners and edges are covered by feature points with sufficient density. The refined feature point set significantly reduces the data volume while retaining the key geometric information of the box body, improving the efficiency and accuracy of subsequent processing. Merge and optimize the refined feature point set through a three-dimensional space stitching algorithm to construct a complete geometric representation of the box body workpiece and obtain a three-dimensional feature point data set of the box body workpiece. The three-dimensional space stitching algorithm uses techniques such as the Iterative Closest Point (ICP) to accurately align and fuse feature points from different views. The stitching process establishes the correspondence between feature points, and then optimizes the relative pose between views by minimizing the sum of the squared distances between corresponding point pairs, and iterates repeatedly until convergence. The optimized feature points are globally adjusted to eliminate the inconsistencies between views and form a unified description of the geometric shape of the box body workpiece. The three-dimensional feature point data set is a structured spatial point cloud, containing the key geometric feature points on the surface of the box body workpiece, their spatial positions, normal vectors, and geometric attribute information, providing an accurate geometric model for subsequent pose determination and machining path planning.
[0029] Taking the machining of a compressor housing of an aero-engine as an example, the housing has complex inner and outer contours and multiple precision connecting flanges. The extraction module 102 extracts edge features from high-definition images collected from four different angles through the Canny operator. During the extraction process, the algorithm adjusted the high and low thresholds of Canny to 65% and 25% of the maximum image gradient respectively according to the metallic luster characteristics of the housing surface, effectively extracting the edge contour while suppressing the interference of light spots. In the geometric feature analysis stage, 32 straight edges, 12 circular arc features, and 8 flange planes on the housing were identified. These two-dimensional features were converted into three-dimensional feature points using the camera internal parameter matrix and depth information, and then the feature points from the four perspectives were unified into the machine tool coordinate system through the coordinate mapping table. During the data cleaning process, the system found and merged 357 pairs of redundant points with a distance less than 0.1 mm, and at the same time removed 24 noise points deviating from the main structure by more than 2 mm. The feature points were stitched and optimized through the ICP algorithm to construct a three-dimensional feature point dataset containing 3420 key feature points, accurately describing the geometric structure of the housing.
[0030] In a specific embodiment, the marking module 103 is specifically used for: Comparing the three-dimensional feature point dataset with the theoretical design data of the housing workpiece, screening out key point pairs with significant features to obtain a set of feature point matching pairs; Performing geometric consistency verification on the set of feature point matching pairs, excluding mis-matched points to obtain valid matching point pair data; Calculating the rotation matrix and translation vector of the housing workpiece in the machine tool coordinate system according to the valid matching point pair data to obtain the initial pose parameters; Performing iterative optimization on the initial pose parameters to minimize the Euclidean distance error between the actual position and the theoretical position of the feature points, and obtaining an accurate pose transformation matrix; Performing spatial analysis on the geometric model of the housing workpiece based on the accurate pose transformation matrix, identifying the machining difficult areas in the inner cavity structure to obtain a machining area priority table; Combining and organizing the accurate pose transformation matrix and the machining area priority table to form the positioning data of the housing workpiece and the machining key area table.
[0031] Specifically, the marking module 103 compares the three-dimensional feature point dataset with the theoretical design data of the box workpiece, screens out key point pairs with significant features, and obtains a set of feature point matching pairs. The theoretical design data usually exists in the form of a CAD model. Key feature points are extracted from the CAD model, and these feature points include geometrically significant positions such as edge intersections, corners, and feature hole centers. The comparison process uses the feature descriptor method to calculate descriptors for each point in the three-dimensional feature point dataset, such as descriptors based on curvature, normal vectors, or local geometric shapes. The descriptor captures the geometric characteristics of the spatial region around the point, making it discriminative. Then, the similarity of the descriptors between the three-dimensional feature points and the points extracted from the CAD model is calculated. Usually, the cosine distance or Euclidean distance is used as the similarity metric. According to the similarity ranking, point pairs with a similarity higher than the threshold are selected as candidate matching pairs. To improve the matching accuracy, local geometric consistency constraints are also considered to ensure that the spatial relationship between adjacent feature points remains consistent in the actual data and the theoretical data. The formed set of feature point matching pairs contains the correspondence between the three-dimensional feature point dataset and the theoretical design data.
[0032] Perform geometric consistency verification on the set of feature point matching pairs to exclude incorrect matching points and obtain valid matching point pair data. The geometric consistency verification is based on the principle of invariance under rigid body transformation, that is, the distance between any two points on the same rigid body remains unchanged before and after the transformation. In the verification process, a distance consistency matrix is constructed to calculate the distance difference between points in the matching point pairs. Specifically, for any two pairs of matching points A and B, where point A comes from the three-dimensional feature point dataset and point B comes from the theoretical design data, calculate the distance between the two points. If this value is less than the preset threshold, it is considered that these two pairs of matching points are geometrically consistent. By constructing a consistency graph of the matching point pairs and applying the RANSAC (Random Sample Consensus) algorithm to identify the largest geometrically consistent subset. RANSAC randomly selects a small number of matching point pairs, calculates the transformation matrix, and then verifies the consistency of other point pairs under this transformation. Repeated iterations are performed to find the transformation with the highest support. Exclude the matching points that do not meet the geometric consistency to obtain valid matching point pair data, and these point pairs are reasonably distributed in space and conform to the rigid body transformation relationship.
[0033] Calculate the rotation matrix and translation vector of the box workpiece in the machine tool coordinate system based on the valid matching point pair data to obtain the initial pose parameters. The calculation process can be expressed as solving the following minimization problem: ; where, represents the rotation matrix, which is a 3×3 matrix used to describe the rotational transformation of the box workpiece; represents the translation vector, which is a 3×1 vector used to describe the translational transformation of the box workpiece; is the i-th point in the three-dimensional feature point dataset, which is a 3×1 coordinate vector; is the point in the corresponding theoretical design data and is also a 3×1 coordinate vector; is the weight coefficient of the i-th pair of matching points, which is a scalar and is usually proportional to the matching confidence of the point pair; is the total number of valid matching point pairs and is a positive integer.
[0034] A common method to solve this minimization problem is singular value decomposition (SVD). The specific steps are as follows: Calculate the centroids of the two sets of points: ; ; where, is the weighted centroid of the three-dimensional feature point dataset, is the weighted centroid of the theoretical design data, and both are 3×1 vectors.
[0035] Then subtract the centroids of the two sets of points from each other respectively to construct the covariance matrix: ; where, is a 3×3 covariance matrix that describes the spatial correlation between the two sets of points.
[0036] Perform singular value decomposition on the covariance matrix C: ; where, U and W are both 3×3 orthogonal matrices, is a 3×3 diagonal matrix whose diagonal elements are the singular values.
[0037] Calculate the rotation matrix: ; And judge whether its determinant is 1 to ensure the correct rotation direction. If the determinant is -1, the last column of W needs to be multiplied by -1 and then M is recalculated.
[0038] Finally, calculate the translation vector: ; The M and V calculated in this way constitute the initial attitude parameters of the box workpiece in the machine tool coordinate system.
[0039] Iteratively optimize the initial pose parameters to minimize the Euclidean distance error between the actual and theoretical positions of the feature points, and obtain an accurate pose transformation matrix. The iterative optimization uses a non-linear least squares method, such as the Levenberg-Marquardt algorithm. This algorithm combines the advantages of gradient descent and Gauss-Newton methods and is particularly suitable for solving non-linear least squares problems. During the optimization process, the rotation matrix is usually represented by quaternions or Euler angles to reduce the number of parameters and avoid the orthogonality constraints of the rotation matrix. Calculate the Euclidean distance error from the actual position to the theoretical position of the feature points in each iteration and adjust the pose parameters to reduce the overall error. To improve the optimization stability, robust kernel functions such as Huber loss or Tukey loss are used to reduce the influence of outliers. The iteration termination condition is that the error change is less than the set threshold or the maximum number of iterations is reached. The obtained rotation matrix and translation vector after optimization form an accurate pose transformation matrix, which accurately describes the spatial position and orientation of the box workpiece in the machine tool coordinate system. Based on the accurate pose transformation matrix, perform a spatial analysis on the geometric model of the box workpiece to identify the difficult machining areas and functional surfaces with high precision requirements in the inner cavity structure, and obtain a machining area priority table. The spatial analysis transforms the theoretical CAD model into the machine tool coordinate system through the accurate pose transformation matrix to ensure that the model is consistent with the actual workpiece position. Then perform reachability analysis to evaluate whether the machine tool cutter can reach each area in the box inner cavity, considering the cutter length, diameter, and machine tool movement range limitations. For reachable areas, calculate their difficult machining indices, which comprehensively consider the following factors: area depth index (the deeper, the more difficult to machine), spatial narrowness (measuring the degree of restriction of the cutter operation space), surface tilt angle (the surface perpendicular to the cutter axis direction is easier to machine), and wall thickness (the thin wall area is more difficult to machine). At the same time, combined with functional requirements, areas with high-precision requirements such as mating surfaces and sealing surfaces are given higher priorities. Based on these analysis results, generate a machining area priority table, which includes area division, difficult machining index, precision requirements, and priority ranking information. Combine and organize the accurate pose transformation matrix and the machining area priority table to form the positioning data of the box workpiece and the machining key area table. The positioning data contains the accurate position and orientation information of the box workpiece in the machine tool coordinate system, stored in the form of a rotation matrix and a translation vector, and also includes error estimation and reliability scoring. The machining key area table is stored in a structured data form, and each area entry contains area ID, spatial range description (usually a three-dimensional bounding box or polygon), difficult machining index, precision requirements, machining priority, and recommended machining parameters (such as feed rate, cutting depth range suggestion). The topological relationship between machining areas is also recorded for planning the optimal machining sequence. The positioning data and the machining key area table are combined to form a comprehensive data structure, which serves as the basic data for subsequent cutting parameter planning and tool path generation.
[0040] Taking a complex box part of an aircraft engine as an example, the box has an inner cavity deep groove, a thin-wall structure, and multiple precision mating surfaces. When the marking module 103 processes the three-dimensional feature point data set, it identifies 3,876 key feature points from 25,647 feature points and conducts a comparative analysis with the CAD model. Using curvature and normal vector feature descriptors, 2,764 pairs of initial matching point pairs are screened out. The geometric consistency verification uses the RANSAC algorithm, iterates 200 times, sets the distance tolerance to 0.15 mm, and retains 2,485 pairs of valid matching point pairs. Based on these matching point pairs, the initial pose parameters are calculated using the SVD algorithm, and then optimized through 10 iterations of the Levenberg-Marquardt algorithm. The average Euclidean distance error is reduced from the initial 0.32 mm to 0.08 mm. The analysis of the inner cavity of the box identifies 14 machining areas, including 3 deep groove areas (depth exceeding 150 mm), 4 thin-wall areas (wall thickness less than 5 mm), and 2 high-precision mating surfaces (required precision ±0.02 mm). These areas are sorted according to difficulty and precision requirements to generate a priority table. The positioning data and the machining key area table guide the formulation of the machining strategy for the five-axis CNC machine tool. For the deep groove area, a long tool low-speed cutting strategy is adopted, for the thin-wall area, a multiple light cutting strategy is adopted, and for the mating surface area, a fine machining path is adopted. While meeting the machining accuracy requirements, the risks of thin-wall deformation and tool chatter are effectively avoided.
[0041] In a specific embodiment, the recording module 104 is specifically configured to: Perform virtual slicing on the box workpiece according to the positioning data, divide the box structure into multiple discrete analysis units, and obtain a box partition data map; Measure the wall thickness distribution of each analysis unit in the box partition data map, calculate the wall thickness value of each point through surface normal sampling, and obtain the wall thickness distribution data; Calculate the structural stiffness coefficient of each analysis unit based on the wall thickness distribution data combined with the material characteristic parameters, and identify the thin-wall weak stiffness area to obtain a stiffness distribution table; Fuse the stiffness distribution table with the machining key area table, establish a cutting force safety threshold according to the regional importance and stiffness characteristics, and obtain the regional cutting force limit condition; Derive the maximum allowable cutting depth and the optimal feed rate for each area according to the regional cutting force limit condition, and calculate the expected deformation amount at the same time to obtain a machining parameter - deformation relationship table; Based on the machining parameter - deformation relationship table, allocate customized machining parameters for different areas of the box workpiece, and set a deformation monitoring threshold to obtain the adjusted values of the cutting depth and feed rate for each area.
[0042] Specifically, the recording module 104 performs virtual slicing on the box workpiece according to the positioning data, divides the box structure into multiple discrete analysis units, and obtains a box partition data map. Virtual slicing is a digital partitioning technique that divides a three-dimensional box model along the main coordinate axes or feature directions to form a series of smaller and more easily analyzable sub-regions. There are usually two strategies for the slicing method: uniform grid slicing and feature adaptive slicing. Uniform grid slicing divides the box space into regular grids at fixed intervals and is suitable for regions with relatively uniform structures; feature adaptive slicing dynamically adjusts the grid density according to the complexity of the box's geometric features, using a finer division in regions with drastic geometric changes (such as corners and surface transition regions). Discrete analysis units are the basic computational units formed after slicing, and each unit contains geometric information (three-dimensional coordinates, volume, surface area) and topological information (adjacency relationship between adjacent units). The box partition data map is a collection of these discrete analysis units, stored in a graph structure, where nodes represent analysis units and edges represent the adjacency relationship between units, facilitating subsequent parallel computing and local analysis. Measure the wall thickness distribution of each analysis unit in the box partition data map, calculate the wall thickness value of each point through surface normal sampling, and obtain the wall thickness distribution data. The wall thickness measurement uses the ray projection method. For the outer surface points of each analysis unit, virtual rays are emitted inward along the surface normal direction until the ray intersects the box surface again, and the distance between the two intersection points is the wall thickness value of this point. The selection of surface normal sampling points adopts a uniform distribution strategy to ensure that the sampling points cover the entire surface of the analysis unit, and at the same time increases the sampling density in regions with large curvature changes. For complex internal cavity structures, the situation of multiple ray crossings also needs to be processed, usually using the nearest intersection point strategy, that is, taking the intersection point closest to the starting point to calculate the wall thickness. The wall thickness distribution data includes the three-dimensional coordinates, normal vector direction, and corresponding wall thickness value of each sampling point, stored in the form of a discrete point set, and a continuous wall thickness distribution field is generated through an interpolation algorithm to realize the wall thickness query at any position within the analysis unit.
[0043] Calculate the structural stiffness coefficient of each analysis unit based on the wall thickness distribution data combined with the material property parameters, and identify the thin-wall and weak-stiffness regions to obtain a stiffness distribution table. The calculation of the structural stiffness coefficient considers three key factors: material elastic modulus, wall thickness, and local geometry, and can be expressed by the following formula: ; Where, represents the structural stiffness coefficient of the i-th analysis unit in the j-th material region, with the unit of N / mm; represents the elastic modulus of the j-th material, with the unit of GPa; represents the average wall thickness of the i-th analysis unit, with the unit of mm; is the reference wall thickness value, usually taking the design standard wall thickness, with the unit of mm; is the stiffness proportionality coefficient, which is used to adjust the dimension of stiffness calculation and is dimensionless; is the wall thickness influence index, usually taking values from 2 to 3, which reflects the non-linear influence of wall thickness change on stiffness and is dimensionless; is the geometric shape correction function, which is related to the local curvature of the i-th analysis element and is dimensionless. For a planar region, is close to 1; for a region with a large curvature, is less than 1, indicating a reduction in the stiffness of the curved surface structure. After calculating the structural stiffness coefficients of each analysis element, a stiffness threshold is set. When , this region is marked as a thin-walled and weak-stiffness region. The stiffness distribution table records the position, material type, average wall thickness, local curvature, structural stiffness coefficient and weak-stiffness region mark of each analysis element.
[0044] Fuse the data of the stiffness distribution table with the key machining area table, and establish a cutting force safety threshold based on the regional importance and stiffness characteristics to obtain the regional cutting force limit conditions. The data fusion process is based on spatial position matching, associating the stiffness data and the key machining area information with the same or overlapping spatial positions. The regional importance is a weight factor extracted from the key machining area table, which reflects the functional importance, precision requirements and machining difficulty of the region. The calculation of the cutting force safety threshold takes into account the dual constraints of stiffness characteristics and regional importance. On the one hand, it is necessary to ensure that the workpiece does not undergo excessive deformation during cutting, and on the other hand, it is necessary to meet the precision requirements of important functional regions. For each identified machining region, calculate its cutting force limit conditions, including the maximum allowable cutting force and the cutting force direction constraint. For the thin-walled and weak-stiffness region, the cutting force limit is more stringent, and smaller cutting depths and lower feed rates need to be adopted; for the functionally important region, even if the stiffness is sufficient, conservative cutting parameters should be used to ensure machining accuracy. The regional cutting force limit conditions are stored in the form of structured data, and each region entry contains spatial position, maximum allowable cutting force and direction constraint information.
[0045] Derive the maximum allowable cutting depth and optimal feed rate for each region according to the regional cutting force limit conditions. At the same time, calculate the expected deformation under these parameters to obtain the processing parameter - deformation relationship table. There is an empirical relationship between cutting parameters and cutting force, usually based on a cutting force prediction model, which maps parameters such as cutting depth and feed rate to cutting force. By applying these relationships in reverse, the upper limits of cutting parameters can be derived from the cutting force limit conditions. Specifically, for each machining region, determine the suitable tool type and diameter, and then calculate the expected cutting force under different combinations of cutting depth and feed rate based on the material cutting empirical formula. Compare these expected cutting forces with the regional cutting force limit conditions to screen out the cutting parameter combinations that meet the conditions. At the same time, use finite element analysis or a simplified beam model to estimate the expected deformation of the workpiece under these parameter combinations. By balancing the requirements of machining efficiency and deformation control, select the optimal combination of cutting depth and feed rate. The processing parameter - deformation relationship table records the spatial position of each region, tool information, maximum allowable cutting depth, recommended feed rate range, and the corresponding expected deformation.
[0046] Based on the processing parameter - deformation relationship table, allocate customized processing parameters for different regions of the box workpiece and set the deformation monitoring threshold to obtain the adjusted values of cutting depth and feed rate for each region. The customized parameter allocation process takes into account the smooth transition between regions to avoid machining marks caused by parameter mutations. For adjacent regions, adopt a parameter gradual change strategy to make the cutting depth and feed rate change smoothly along the machining path. The deformation monitoring threshold is set based on the expected deformation plus a safety margin. When the deformation monitored during actual machining exceeds this threshold, trigger the automatic parameter adjustment mechanism. The adjusted values of cutting depth and feed rate include not only the absolute parameter values of each region but also the rules for dynamic adjustment according to real-time monitoring results, such as the deceleration ratio when the deformation exceeds the threshold and the cutting depth reduction strategy. The generated data structure of the cutting parameters for each region clearly defines the optimal machining strategy for each part of the box, supporting the intelligent machining process control of five-axis CNC machine tools.
[0047] Taking the machining of a certain aero-engine casing as an example, the casing is made of high-strength aluminum alloy and has a complex inner cavity and multiple precision mating surfaces. The recording module 104 divides the casing model into 156 analysis units, and uses a finer division in key areas such as thin-wall transition sections. By measuring the wall thickness distribution of each unit using the normal ray method, it is found that the wall thickness of the casing varies from 8 mm to 2.5 mm, and the wall thickness in a certain inner cavity side wall area is only 2.8 mm. For the aluminum alloy material (elastic modulus 70 GPa), combined with the measured wall thickness data, the structural stiffness coefficients of each unit are calculated. The stiffness coefficients in the thin-wall areas (2.5 - 3.0 mm) are significantly lower than those in other areas. In particular, in a curved thin-wall area of the inner cavity, its stiffness coefficient is less than 15% of that in the standard wall thickness area. By integrating this information with the machining key area table, the cutting force safety threshold for this curved thin-wall area is determined to be 180 N. Based on this threshold, the maximum cutting depth for this area is derived as 0.4 mm, the recommended feed rate is 300 - 400 mm / min, and the expected maximum deformation is 0.06 mm. Considering that there is a precision mating surface (tolerance requirement ±0.05 mm) near this area, the system further restricts the deformation monitoring threshold to 0.04 mm. The generated partition parameter table specifies the use of a φ12 mm ball-end milling cutter in this area, with a cutting depth of 0.35 mm and a feed rate of 350 mm / min, and monitors the deformation in real time during machining. Once the deformation exceeds 0.04 mm, the feed rate is immediately reduced to 250 mm / min and the cutting depth is reduced to 0.25 mm. This parameter optimization strategy ensures that the thin-wall area does not undergo excessive deformation while ensuring machining accuracy, and successfully machines complex casing parts that meet the design requirements.
[0048] In a specific embodiment, the processing module 105 is specifically configured to: According to the cutting depth and feed rate adjustment values, divide the casing machining task into a rough machining layer and a finish machining layer, and create an independent tool parameter table for each layer to obtain a multi-level machining plan; Generate a sequence of initial tool contact points for each machining area in the multi-level machining plan, and calculate the tool axial vector at each contact point to obtain a set of tool pose points; Perform interference analysis on the set of tool pose points through the tool envelope volume to detect potential collision areas between the tool and the inner cavity structure of the casing, and obtain an interference risk map; According to the interference risk map, re-plan the path of the set of tool pose points, and avoid the collision area by restricting the safety distance and adjusting the tool axis tilt angle to obtain a collision-free tool trajectory; For the path segments passing through the thin-wall area in the collision-free tool trajectory, adopt a segmented entry and exit strategy and progressive cutting depth control to reduce the impact of cutting force on thin-wall deformation, and obtain an optimized trajectory for the thin-wall area; Merge the non-interference tool path and the optimized path of the thin-walled area, and add a tool approach and retract safety area and a tool change position to generate a five-axis machining instruction sequence including approach and retract strategies.
[0049] Specifically, the processing module 105 divides the box machining task into a rough machining layer and a finish machining layer according to the cutting depth and the feed rate adjustment value, and creates an independent tool parameter table for each layer to obtain a multi-level machining plan. This layer-by-layer machining strategy is the basis for five-axis machining of complex boxes. The main purpose of the rough machining layer is to quickly remove a large amount of material, usually using a larger cutting depth and feed rate, with lower requirements for machining accuracy; while the finish machining layer aims to achieve high-precision surface quality, using a small cutting depth and a moderate feed rate. The layering process starts from the three-dimensional model of the box workpiece, combines the positioning data to determine the material allowance distribution between the initial blank and the target finished product, and then divides the allowance into multiple machining layers according to the preset layer spacing. The tool parameter table for each layer includes the tool type, tool diameter, cutting edge length, recommended spindle speed range, cutting depth, and feed rate. For the rough machining layer, a large-diameter end mill or face mill is usually selected to improve the material removal rate; for the finish machining layer, a ball nose mill is preferred to obtain better surface quality, especially for curved surface areas. The multi-level machining plan is a hierarchical data structure that includes the spatial boundaries, tool parameters, and machining sequence information of each machining layer.
[0050] Generate an initial tool contact point sequence for each machining area in the multi-level machining plan, and calculate the tool axial vector at each contact point to obtain a set of tool pose points. The initial tool contact point sequence is a discrete set of points where the tool contacts the workpiece surface, representing the spatial movement trajectory of the tool. These contact points are usually generated using the isoparametric line method, the contour line method, or the area filling method. The isoparametric line method is suitable for parametric surfaces and generates regularly distributed tool paths along the parametric directions of the surface; the contour line method divides the three-dimensional surface into layers according to equal heights and generates machining paths similar to contour lines on a topographic map; the area filling method is mainly used for planar areas or shallow surfaces and adopts a parallel line or spiral filling strategy. For each contact point, it is also necessary to determine the tool axial vector, that is, the spatial direction of the tool center axis. In three-axis machining, the tool axis is usually fixed in the vertical direction; while in five-axis machining, the tool axis can be adjusted flexibly and usually follows several strategies: the normal strategy (the tool axis is consistent with the normal vector of the workpiece surface), the guide curve strategy (the tool axis changes following a predefined spatial curve), or the fixed angle strategy (the tool axis maintains a fixed angle with a certain direction). The set of tool pose points comprehensively expresses the complete motion information of the tool in space, and each point includes the three-dimensional coordinates of the tool contact point and the corresponding tool axial vector.
[0051] Interference analysis is performed on the tool pose point set through the tool envelope volume to detect potential collision areas between the tool and the inner cavity structure of the box, and an interference risk map is obtained. The tool envelope volume refers to the volume area swept by the tool in space, including the tool body, tool holder, and part of the spindle structure. In the machining of complex inner cavities of boxes, due to limited space, the tool interference problem is particularly prominent. The interference analysis uses a geometric collision detection algorithm to calculate the spatial intersection of the tool envelope volume and the box workpiece model. The specific implementation usually includes two stages: rough detection and fine detection. In the rough detection stage, simplified geometric models (such as bounding boxes, bounding spheres, or bounding cylinders) are used to quickly screen areas where collisions may occur; in the fine detection stage, detailed collision detection is performed on these candidate areas using accurate geometric models. For each tool pose point, it is calculated whether there is an intersection between the tool envelope volume and the box model at this pose. If there is, it is marked as a potential collision point. The interference risk map is a spatial distribution map that records the positions, collision severities, and collision types (such as tool tip collision, tool holder collision, or spindle collision) of all potential collision areas.
[0052] Path replanning is performed on the tool pose point set according to the interference risk map. By restricting the safety distance and adjusting the tool axis tilt angle, the collision areas are avoided, and a collision-free tool path is obtained. Path replanning is an iterative optimization process. For each collision area marked in the interference risk map, corresponding avoidance strategies are taken. The safety distance restriction means maintaining a certain minimum distance between the tool and the inner cavity wall of the box. This distance is usually determined according to the machining accuracy requirements and vibration risks. The adjustment of the tool axis tilt angle is a unique advantage of five-axis machining. By changing the angle between the tool axis vector and the workpiece surface normal vector, the positions of the tool holder and the spindle are moved while keeping the cutting point position unchanged, so as to avoid potential collisions. For collision areas that cannot be solved by simple adjustment, it is necessary to re-plan the tool contact point sequence, which may involve zoning machining or changing to tools with different lengths and shapes. The path replanning process uses a heuristic search algorithm to find the optimal collision-free tool path on the premise of meeting the machining accuracy requirements. The collision-free tool path obtained after replanning ensures that the tool can safely reach all areas to be machined.
[0053] For the path segments passing through the thin-walled area in the interference-free tool path, a segmented approach for entry and exit and progressive cutting depth control are adopted to reduce the impact of cutting force on the deformation of the thin wall, and an optimized trajectory for the thin-walled area is obtained. The thin-walled area is a difficult point in the machining of the box body. Due to its low stiffness, it is prone to deformation during the cutting process, resulting in a decline in machining accuracy or even scrapping of the workpiece. The segmented approach for entry and exit decomposes the continuous cutting process into multiple short segments, and after each segment, the thin-walled area is given time to rebound and dissipate heat, reducing cumulative deformation and thermal deformation. Specifically, the originally continuous tool path is segmented into multiple segments of appropriate length in the thin-walled area, and a micro tool lift action is set between segments. Progressive cutting depth control means that when approaching the thin-walled area, the cutting depth is gradually reduced to make the cutting force change smoothly and avoid vibrations and deformations caused by sudden changes. This depth control usually uses a spline function to define the spatial change rate of the cutting depth to ensure a smooth transition. Combining the stiffness distribution data of the thin-walled area, the cutting parameters are locally optimized, and the cutting depth and feed rate are further reduced at positions with weaker structures. After these optimization processes, the optimized trajectory for the thin-walled area can not only ensure machining efficiency but also effectively control the deformation of the thin wall. The interference-free tool path and the optimized trajectory for the thin-walled area are merged, and the tool approach and retract safety areas and tool change positions are added to generate a five-axis machining instruction sequence including approach and retract strategies. The trajectory merging process organizes the trajectory segments in different areas into a coherent sequence according to spatial positions and machining orders, and then deals with the transition problems between trajectory segments. For the trajectory segments that require rapid movement in the air, the tool lift height and safety plane information are added to ensure that the tool does not collide with the workpiece during non-cutting movement. The tool approach and retract safety areas refer to the buffer areas before the tool enters the cutting state and after it exits the cutting state, usually designed as a gradually changing trajectory approaching or moving away from the workpiece to avoid impacts caused by sudden contact or separation. The tool change positions refer to the specific positions that the machine needs to move to when changing tools, and these positions need to consider the working space of the machine tool and the layout of the tool change device. Finally, the integrated spatial trajectory is converted into a machining instruction format recognizable by the numerical control machine tool, such as G-code, which contains information such as tool coordinates, attitude angles, feed rates, and spindle speeds. These five-axis machining instruction sequences are the direct input for the numerical control machine tool to execute the machining task, and fully describe all the movement details of the tool from the starting point to the ending point.
[0054] Taking the machining of a complex box part of an aircraft engine as an example, the box has an inner cavity deep groove, inclined holes and thin-wall structures. After the processing module 105 receives the cutting depth and feed rate adjustment values, it divides the machining task into 3 layers of rough machining and 2 layers of finish machining. In the rough machining layer, a Φ20mm end mill is used, the cutting depth decreases (5mm → 3mm → 1mm), and the feed rate is 800 - 1200mm / min; in the finish machining layer, a Φ12mm ball-end mill is used, the cutting depths are 0.5mm and 0.2mm, and the feed rate is 500 - 700mm / min. For each machining area layer, an isoparametric tool path is generated, and a total of 12,850 tool contact points are produced. In the inner cavity area, due to space constraints, an inclined angle strategy is adopted for the tool axis, so that the tool always maintains an angle of 10° - 15° with the inner cavity wall surface. Interference analysis found that there are 7 areas at the inner cavity corners with potential collision risks, among which 4 are collisions between the tool shank and the upper wall of the inner cavity, and 3 are collisions between the tool and the inner cavity corners. Through path replanning, the safety distance is increased (from 2mm to 5mm), and the tool axis inclination angle is adjusted (the maximum adjustment is 25°), successfully avoiding all collision areas. For the thin-wall area on the side wall of the box (with a thickness of only 2.5mm), a segmented machining strategy is adopted, dividing the continuous tool path into short segments with a length of no more than 30mm for each segment, and setting a tool lift height of 0.5mm between segments. At the same time, progressive cutting depth control is implemented. In the range of 700mm before approaching the thin-wall area, the cutting depth smoothly transitions from the standard value to the reduced value in the thin-wall area (from 0.5mm to 0.2mm in finish machining). The generated five-axis machining instruction sequence includes a complete tool approach and retract strategy, and a 25mm long progressive approach path is set before each cut into the workpiece to ensure smooth contact. This machining strategy has successfully controlled the thin-wall deformation within 0.03mm in actual application, meeting the machining accuracy requirements of the design.
[0055] In a specific embodiment, the comparison module 106 is specifically used for: During the execution of the five-axis machining instruction sequence, real-time machining state information is collected through a multi-sensor array, including cutting force signals, vibration signals and surface topography data, to obtain the original monitoring data of the machining process; Feature extraction and signal processing are performed on the original monitoring data of the machining process to filter out noise and identify key machining state indicators, obtaining machining state feature quantities; The machining state feature quantities are compared and analyzed with the pre-set ideal machining parameters, the deviation degrees of each machining index are calculated, and a machining deviation distribution table is obtained; According to the machining deviation distribution table, the unexecuted machining paths in the five-axis machining instruction sequence are corrected in real time, the cutting parameters and the tool feed trajectory are adjusted, and subsequent dynamically optimized machining instructions are obtained; During the execution of subsequent machining instructions, continuously monitor the cutting state and surface quality of the key machining area, establish the mapping relationship between machining parameters and machining quality, and obtain the machining effect evaluation data; Integrate and record the dynamically optimized subsequent machining instructions and the machining effect evaluation data to form the real-time compensation data and quality control record of the whole process of workpiece machining.
[0056] Specifically, during the execution of the five-axis machining instruction sequence, the comparison module 106 collects real-time machining state information through a multi-sensor array, including cutting force signals, vibration signals, and surface topography data, to obtain the original monitoring data of the machining process. The multi-sensor array is an integrated monitoring device composed of various types of sensors, strategically arranged at key positions of the five-axis CNC machine tool. The cutting force signal is obtained through a dynamic dynamometer, which is installed on the spindle system or the workbench to collect the cutting force components in the X, Y, and Z directions, and the sampling frequency is usually above 1000 Hz to capture the rapidly changing cutting process. The vibration signal is collected through an acceleration sensor, which is installed on the spindle housing or the workpiece fixture to monitor the mechanical vibration during the machining process, especially focusing on the frequency range related to tool chatter (usually between 100 - 5000 Hz). The surface topography data is obtained in real time through an on-board optical sensor, such as a laser displacement sensor or a structured light scanner, which can measure the surface profile and roughness without contacting the workpiece. All sensor data is synchronously collected through a high-speed data acquisition card and appended with a time stamp and the corresponding machine tool position information to form the original monitoring data stream of the machining process.
[0057] Extract features and process signals from the original monitoring data of the machining process, filter out noise, and identify key machining state indicators to obtain the machining state feature quantities. Signal processing performs preprocessing, including removing DC bias, low-pass filtering to remove high-frequency noise, outlier detection and rejection, etc. For the cutting force signal, calculate the average cutting force, cutting force fluctuation amplitude, and cutting force mutation rate; for the vibration signal, perform time-frequency domain analysis to extract the main frequency component, amplitude feature, and spectral energy distribution; for the surface topography data, calculate the local surface roughness, shape deviation, and surface waviness. Feature extraction uses a variety of data analysis methods, including statistical analysis (mean, standard deviation, peak value, skewness, etc.), time-domain features (rise time, steady-state time, overshoot, etc.), frequency-domain features (main frequency, bandwidth, spectral density, etc.), and time-frequency features (wavelet coefficients, short-time Fourier transform, etc.). Complex signals are reduced in dimension through principal component analysis to extract the main variables and reduce data redundancy. The key machining state indicators include cutting stability indicators, tool wear indicators, surface quality indicators, and machining accuracy indicators, which are calculated through feature combinations and constitute the machining state feature quantities.
[0058] Compare and analyze the machining state characteristic quantities with the pre-set ideal machining parameters, calculate the deviation degrees of each machining index, and obtain the machining deviation distribution table. The ideal machining parameters are derived from historical successful cases, simulation optimization results or expert experience databases, and include the optimal cutting force range, vibration threshold and surface quality standards under different machining conditions. The comparison and analysis adopt normalization processing and weight assignment methods to convert the indexes of different physical quantities and different dimensions into a unified evaluation scale. For each machining state characteristic quantity, calculate its relative deviation from the ideal parameter, and combine with the importance weights of each index to obtain the comprehensive deviation score. Based on the spatial position information, map these deviations onto the workpiece model to form the machining deviation distribution table. This table is stored in the form of structured data, and each record contains spatial position, machining stage, deviation values of each index and comprehensive score. The deviation distribution table visually shows the differences in machining quality of each area of the workpiece, and particularly marks the areas where the deviation exceeds the allowable range, providing a basis for subsequent machining parameter adjustment. According to the machining deviation distribution table, real-time correction is carried out on the unexecuted machining paths in the five-axis machining instruction sequence, adjust the cutting parameters and tool feed trajectories, and obtain the dynamically optimized subsequent machining instructions. The real-time correction mechanism is based on the closed-loop control principle, and different compensation strategies are adopted for different deviation types. When it is detected that the cutting force is too large, reduce the cutting depth or feed speed; when it is found that the vibration tends to be unstable, adjust the spindle speed to avoid the resonance frequency; when the surface quality does not meet the standard, increase the number of finishing passes or reduce the tool step distance. The correction process takes into account the continuity requirements between machining areas and adopts a smooth transition strategy to avoid machining marks caused by parameter mutations. For severely deviated areas, even re-plan the tool feed trajectory, change the contact angle or cutting direction. These correction information are converted into the NC instruction format and updated to the executing machining program to form the dynamically optimized subsequent machining instructions. The correction process is carried out in real time to ensure that the problem can be corrected before it expands.
[0059] During the execution of the subsequent machining instructions, continuously monitor the cutting state and surface quality of the key machining areas, establish the mapping relationship between machining parameters and machining quality, and obtain the machining effect evaluation data. The continuous monitoring uses the same multi-sensor array as described above, but particularly focuses on the key machining areas previously marked as high-risk. The monitoring data is processed in real time and correlated with the corrected parameters to evaluate the influence effect of parameter adjustment on machining quality. The process of establishing the mapping relationship adopts the data regression method to find the functional relationship between machining parameters (independent variables) and machining quality indexes (dependent variables). This process not only records the results, but also saves the dynamic change process, such as the response curve of the quality index after parameter adjustment. The machining effect evaluation data is stored in the form of a multi-dimensional association table, containing information such as parameter combinations, quality indexes and correlation coefficients, providing valuable knowledge accumulation for the machining of future similar workpieces.
[0060] Integrate and record the subsequent processing instructions optimized dynamically and the processing effect evaluation data to form real-time compensation data and quality control records for the entire process of workpiece machining. The integration process correlates the instruction adjustments and effect evaluations in the time series according to the spatial positions and processing sequences to form a complete machining history file. The real-time compensation data part records the triggering conditions, adjustment methods, and adjustment amounts of each adjustment decision, clearly presenting the logical chain of compensation. The quality control record part stores the quality inspection results, key feature dimensions, and surface state evaluations of each processing stage. The integration record adopts a structured data format, supporting rapid retrieval and analysis, facilitating subsequent summary of machining experience and process optimization. These records can be used for quality traceability of the current workpiece and can also be used as input to the experience database to mine machining rules through machine learning methods and continuously improve the machining strategy.
[0061] The above describes the vision positioning method for the complex box five-axis CNC comprehensive machining machine in the embodiments of the present application. Next, the vision positioning system for the complex box five-axis CNC comprehensive machining machine in the embodiments of the present application will be described. Please refer to Figure 2 , an embodiment of the vision positioning system for the complex box five-axis CNC comprehensive machining machine in the embodiments of the present application includes: S201. Collect multi-angle images of the box workpiece through multiple cameras, and use the marked points for coordinate calibration to obtain the camera parameters and the machine tool space coordinate mapping table; S202. According to the camera parameters and the machine tool space coordinate mapping table, perform edge detection and contour extraction on the multi-angle images, and merge and transform the features of each view through point cloud stitching to obtain the three-dimensional feature point data set of the box workpiece; S203. According to the three-dimensional feature point data set, determine the actual position of the box in the machine tool through matching degree calculation and error minimization processing, and mark the key machining areas of the inner cavity to obtain the positioning data of the box workpiece and the machining key area table; S204. According to the positioning data and the machining key area table, determine the cutting parameters of different areas of the box through thickness measurement and stiffness analysis, and record the expected deformation amount to obtain the adjusted values of the cutting depth and feed rate for each area; S205. According to the adjusted values of the cutting depth and feed rate, generate a tool path that avoids the inner cavity obstacles through path calculation and interference check, and process the thin-walled areas to obtain a five-axis machining instruction sequence including the tool approach and retract strategies; S206. According to the five-axis machining instruction sequence, use the machining process monitoring data to compare the difference between the expected machining effect and the actual result, and adjust the subsequent machining parameters according to the difference value to obtain real-time compensation data and quality control records.
[0062] In the embodiments of the present application, multi-cameras are used to collect multi-angle images of the box workpiece and marker points are used for coordinate calibration, effectively solving the problem that it is difficult to comprehensively capture the complex geometric features of the box from a single perspective, and significantly improving the positioning accuracy and reliability; based on the obtained camera parameters and the machine tool space coordinate mapping table, edge detection and contour extraction are performed on the multi-angle images, and the features of each perspective are merged and transformed through point cloud stitching, making the three-dimensional feature point dataset of the complex box more complete and accurate, providing a reliable geometric basis for subsequent processing; the actual position of the box in the machine tool is determined through matching degree calculation and error minimization processing, and the key machining areas of the inner cavity are intelligently marked, realizing an efficient conversion from a large amount of three-dimensional data to precise positioning and machining planning, greatly reducing the workload and subjective error of manual analysis; the cutting parameters of different areas of the box are determined by thickness measurement and stiffness analysis, and the predicted deformation amount is recorded, and a differentiated machining strategy is formulated for the weak stiffness areas such as the thin walls of the box, effectively preventing machining deformation and vibration problems; the tool path for avoiding obstacles in the inner cavity is generated through path calculation and interference check, and special treatment is carried out for the thin wall area, solving the tool collision risk in complex inner cavity machining and improving machining safety; the difference between the expected machining effect and the actual result is compared in real time using the machining process monitoring data, and the subsequent machining parameters are dynamically adjusted according to the difference value, forming a closed-loop control system to ensure the quality stability of the entire machining process. At the algorithm level, this solution integrates technologies such as computer vision, spatial analysis, and closed-loop control. In particular, the image processing algorithms applied in feature point extraction, three-dimensional reconstruction, and machine coordinate mapping, as well as the mechanical analysis models applied in thin wall area recognition and machining parameter optimization, jointly construct an intelligent decision-making system for complex box machining, not only improving the machining accuracy, but also enhancing the production efficiency and reducing the scrapping risk of high-value complex boxes.
[0063] In the embodiments of the present invention, a computer device is further provided. The computer device may be a server. The computer device includes a processor, a memory, a display screen, an input device, a network interface, and a database connected through a system bus. Among them, the processor of the computer design is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program, and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store the corresponding data in this embodiment. The network interface of the computer device is used to communicate with an external terminal through a network connection. The computer program, when executed by the processor, implements the above method.
[0064] An embodiment of the present invention further provides a computer-readable storage medium, on which a computer program is stored. When the computer program is executed by a processor, the above method is implemented. It can be understood that the computer-readable storage medium in this embodiment can be a volatile readable storage medium or a non-volatile readable storage medium.
[0065] Those of ordinary skill in the art can understand that all or part of the processes in the methods of the above embodiments can be completed by instructing relevant hardware through a computer program. The computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the above method embodiments. Among them, any reference to a memory, storage, database, or other medium provided by the present invention and used in the embodiments can include non-volatile and / or volatile memories. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or an external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (SSRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM, etc.
[0066] Those skilled in the art can clearly understand that for the convenience and brevity of description, the specific working processes of the above-described systems, systems, and units can refer to the corresponding processes in the foregoing method embodiments and will not be described herein again.
[0067] When the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present invention, in essence, or the part that contributes to the prior art, or all or part of this technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute all or part of the steps of the methods described in various embodiments of the present invention. The foregoing storage medium includes: various media such as USB flash drives, mobile hard disks, read-only memory (ROM), random access memory (RAM), magnetic disks, or optical discs that can store program codes.
[0068] As described above, the above embodiments are only used to illustrate the technical solutions of the present application and are not intended to limit them; although the present application has been described in detail with reference to the foregoing embodiments, those of ordinary skill in the art should understand that they can still modify the technical solutions described in the foregoing embodiments or perform equivalent replacements for some of the technical features; and these modifications or replacements do not cause the essence of the corresponding technical solutions to deviate from the spirit and scope of the technical solutions of the various embodiments of the present application.
Claims
1. A vision positioning system for a five-axis CNC comprehensive machining machine for complex boxes, characterized in that, The vision positioning system for the five-axis CNC comprehensive machining machine for complex boxes includes: A calibration module, which is used to collect multi-angle images of the box workpiece through multiple cameras, and use the marked points for coordinate calibration to obtain the camera parameters and the machine tool space coordinate mapping table; An extraction module, which is used to perform edge detection and contour extraction on the multi-angle images according to the camera parameters and the machine tool space coordinate mapping table, and merge and transform the features of each view through point cloud stitching to obtain the three-dimensional feature point data set of the box workpiece; A marking module, which is used to determine the actual position of the box in the machine tool through matching degree calculation and error minimization processing according to the three-dimensional feature point data set, and mark the key machining areas of the inner cavity to obtain the positioning data of the box workpiece and the machining key area table; A recording module, which is used to determine the cutting parameters of different areas of the box according to the positioning data and the machining key area table by using thickness measurement and stiffness analysis, and record the predicted deformation amount to obtain the adjusted values of the cutting depth and feed rate for different areas; A processing module, which is used to generate a tool path that avoids the inner cavity obstacles through path calculation and interference checking according to the adjusted values of the cutting depth and feed rate, and process the thin-walled areas to obtain a five-axis machining instruction sequence including the tool entry and exit strategies; A comparison module, which is used to compare the difference between the expected machining effect and the actual result by using the machining process monitoring data according to the five-axis machining instruction sequence, and adjust the subsequent machining parameters according to the difference value to obtain the real-time compensation data and the quality control record.
2. The vision positioning system for the five-axis numerical control comprehensive machining machine for complex boxes according to claim 1, characterized in that, The calibration module is specifically used for: Synchronously obtaining multi-view image data of the box workpiece through industrially-grade high-definition cameras arranged in a ring to obtain an original image data group; Performing image preprocessing on the original image data group, including denoising, grayscale conversion, and contrast enhancement, to obtain enhanced image data; Identifying the reflective marked points pre-attached to the surface of the box workpiece in the enhanced image data to obtain the marked point image coordinate set; Calculating the spatial correspondence relationship between the actual spatial positions of the known marked points and the marked point image coordinate set to obtain the camera internal parameter matrix; Establishing a transformation equation between the camera coordinate system and the machine tool coordinate system according to the camera internal parameter matrix combined with the relative position relationship between different cameras to obtain the coordinate system transformation matrix; Combining the camera internal parameter matrix and the coordinate system transformation matrix to generate the camera parameters and the machine tool space coordinate mapping table.
3. The vision positioning system for a five-axis CNC comprehensive machining machine for complex boxes according to claim 1, wherein, The extraction module is specifically used for: Performing edge detection on the multi-angle images through the Canny operator to extract the two-dimensional edge information of the box workpiece to obtain an edge feature map; Performing geometric feature analysis on the edge feature map to identify straight lines, arcs, and curved surfaces to obtain the geometric structure data of the box contour; Converting the geometric structure data of the box contour from two-dimensional image coordinates to three-dimensional space coordinates according to the camera parameters to obtain single-view three-dimensional feature points; Unifying the single-view three-dimensional feature points under different views into the machine tool coordinate system by using the machine tool space coordinate mapping table to obtain a multi-view feature point set; Performing data cleaning on the multi-view feature point set, removing redundant points and noise points, and performing spatial consistency verification to obtain a refined feature point set; Merge and optimize the refined feature point set through a 3D space stitching algorithm to construct a geometric representation of the box workpiece and obtain a 3D feature point data set of the box workpiece.
4. The vision positioning system for the five-axis numerical control integrated machining machine for complex boxes according to claim 1, wherein, The marking module is specifically used for: Compare the feature points of the 3D feature point data set with the theoretical design data of the box workpiece, screen out key point pairs with significant features, and obtain a set of feature point matching pairs; Perform geometric consistency verification on the set of feature point matching pairs, exclude mis-matched points, and obtain valid matching point pair data; Calculate the rotation matrix and translation vector of the box workpiece in the machine tool coordinate system based on the valid matching point pair data to obtain initial pose parameters; Iteratively optimize the initial pose parameters to minimize the Euclidean distance error between the actual position and the theoretical position of the feature points, and obtain an accurate pose transformation matrix; Perform a spatial analysis on the geometric model of the box workpiece based on the accurate pose transformation matrix, identify the difficult machining areas in the inner cavity structure, and obtain a machining area priority table; Combine and organize the accurate pose transformation matrix and the machining area priority table to form the positioning data of the box workpiece and the machining key area table.
5. The vision positioning system for the five-axis numerical control integrated machining machine for complex boxes according to claim 1, characterized in that, The recording module is specifically used for: Perform virtual slicing on the box workpiece according to the positioning data, divide the box structure into multiple discrete analysis units, and obtain a box partition data map; Measure the wall thickness distribution of each analysis unit in the box partition data map, calculate the wall thickness value of each point through surface normal sampling, and obtain wall thickness distribution data; Calculate the structural stiffness coefficient of each analysis unit based on the wall thickness distribution data combined with material characteristic parameters, and identify thin-walled and weak stiffness areas to obtain a stiffness distribution table; Fuse the stiffness distribution table with the machining key area table, establish a cutting force safety threshold according to the regional importance and stiffness characteristics, and obtain regional cutting force limit conditions; Derive the maximum allowable cutting depth and optimal feed rate for each region according to the regional cutting force limit conditions, and calculate the expected deformation amount at the same time to obtain a machining parameter - deformation relationship table; Based on the machining parameter - deformation relationship table, assign customized machining parameters to different regions of the box workpiece and set a deformation monitoring threshold to obtain adjusted values of cutting depth and feed rate for each region.
6. The vision positioning system for the five-axis CNC comprehensive machining machine for complex boxes according to claim 1, characterized in that The processing module is specifically used for: Divide the box machining task into rough machining layers and finish machining layers according to the adjusted values of cutting depth and feed rate, and create an independent tool parameter table for each layer to obtain a multi-level machining plan; Generate a sequence of initial tool contact points for each machining region in the multi-level machining plan, and calculate the tool axial vector at each contact point to obtain a set of tool pose points; Perform interference analysis on the set of tool pose points through the tool envelope volume, detect potential collision regions between the tool and the inner cavity structure of the box, and obtain an interference risk map; Perform path re-planning on the set of tool pose points according to the interference risk map, and avoid the collision region by restricting the safety distance and adjusting the tool axis tilt angle to obtain a collision-free tool path; For the path segment passing through the thin-walled area in the interference-free tool path, a segmented approach-in approach-out strategy and progressive cutting depth control are adopted to reduce the influence of cutting force on the deformation of the thin wall, and an optimized trajectory for the thin-walled area is obtained. The interference-free tool path and the optimized trajectory of the thin-walled area are merged, and a tool approach-retreat safety area and a tool change position are added to generate a five-axis machining instruction sequence including approach-retreat strategies.
7. The vision positioning system for the five-axis numerical control integrated machining machine for complex boxes according to claim 1, characterized in that, The comparison module is specifically used for: During the execution of the five-axis machining instruction sequence, real-time machining status information including cutting force signals, vibration signals, and surface topography data is collected through a multi-sensor array to obtain the original monitoring data of the machining process. Feature extraction and signal processing are performed on the original monitoring data of the machining process to filter out noise and identify key machining status indicators, obtaining machining status feature quantities. The machining status feature quantities are compared and analyzed with the pre-set ideal machining parameters, and the deviation degrees of each machining index are calculated to obtain a machining deviation distribution table. According to the machining deviation distribution table, the unexecuted machining paths in the five-axis machining instruction sequence are corrected in real time, and the cutting parameters and tool feed trajectories are adjusted to obtain dynamically optimized subsequent machining instructions. During the execution of the subsequent machining instructions, the cutting status and surface quality of the key machining areas are continuously monitored to establish a mapping relationship between machining parameters and machining quality, obtaining machining effect evaluation data. The dynamically optimized subsequent machining instructions and the machining effect evaluation data are integrated and recorded to form real-time compensation data and quality control records for the entire process of workpiece machining.
8. A vision positioning method for a five-axis numerical control integrated machining machine for complex boxes, which is realized by the vision positioning system for a five-axis numerical control integrated machining machine for complex boxes according to any one of claims 1-7, characterized in that, The vision positioning method for the five-axis CNC comprehensive machining machine for complex boxes includes: Multi-angle images of the box workpiece are collected by multiple cameras, and coordinate calibration is performed using marker points to obtain camera parameters and a machine tool space coordinate mapping table. Based on the camera parameters and the machine tool space coordinate mapping table, edge detection and contour extraction are performed on the multi-angle images, and the features of each view are merged and transformed through point cloud stitching to obtain a three-dimensional feature point data set of the box workpiece. Based on the three-dimensional feature point data set, the actual position of the box in the machine tool is determined through matching degree calculation and error minimization processing, and the key machining areas of the inner cavity are marked to obtain the positioning data of the box workpiece and a machining key area table. Based on the positioning data and the machining key area table, the cutting parameters of different areas of the box are determined by thickness measurement and stiffness analysis, and the expected deformation amount is recorded to obtain the adjusted values of the cutting depth and feed rate for different areas. Based on the adjusted values of the cutting depth and feed rate, a tool path that avoids inner cavity obstacles is generated through path calculation and interference checking, and the thin-walled area is processed to obtain a five-axis machining instruction sequence including approach-retreat strategies. Based on the five-axis machining instruction sequence, the differences between the expected machining effect and the actual result are compared using machining process monitoring data, and the subsequent machining parameters are adjusted according to the difference values to obtain real-time compensation data and quality control records.
9. A computer device, characterized in that, It includes a memory and a processor. The memory stores a computer program that can run on the processor. It is characterized in that when the processor executes the computer program, it implements the visual positioning method for the complex box five-axis CNC comprehensive machining machine described in claim 8.
10. A computer-readable storage medium, on which a computer program is stored. When the computer program is run by a processor, the processor is caused to execute the visual positioning method for the complex box five-axis CNC comprehensive machining machine as described in claim 8.
Citation Information
Patent Citations
On-line automatic detection device for detecting wear condition of rotary cutter in the whole processing cycle
CN102528561A
Robot automatic lineation method, system and device based on position error compensation
CN113635281A
Monocular camera and laser radar joint calibration method based on ROS platform
CN117974800A
Control method, device and equipment of five-axis high-precision numerical control machine tool and storage medium
CN119472507A
Image measurement instrument
JP2018081115A
Cited By
Machine tool collision early warning method and system based on data analysis
CN120572391A
1C and 4C comprehensive intelligent inspection trolley for contact network
CN120726056A
Three-coordinate measurement assisted five-axis machining compensation method and system and medium
CN120802836A
Rust removal method, system and equipment for offshore wind power equipment
CN120828365A
Feeding and discharging control method and system for CNC machining
CN121120574A