Complex feature layered recognition method for blank model based on feature matrix
Through the method based on feature matrix, the blank model features of large complex components are extracted and layered, and the problem of difficult to identify complex cavity characteristics in the existing technology is solved, and high-precision and rapid identification is achieved, which is suitable for key zeros for aerospace vehicles. part.
Patent Information
- Application Number
- CN202010303644.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-04-17
- Publication Date
- 2024-12-31
- Estimated Expiration
- 2040-04-17
AI Technical Summary
The prior art is difficult to achieve efficient and accurate identification of complex cavity features of blank models or workpiece models of large complex cabin components, especially the lack of design feature tree information, making it difficult to directly identify by obtaining geometric topology information of feature tree.
A hierarchical recognition method for complex feature of the blank model based on feature matrix is used to identify complex intersecting features by obtaining geometric topology data, optimizing the model, establishing attribute adjacency graphs, extracting and hierarchizing features, and constructing feature matrix libraries for matching.
It realizes high-precision and rapid identification of large and complex components blank models, improves the accuracy and efficiency of identification of complex intersection features, and is suitable for key components of aerospace vehicles such as large aircraft and rockets.
Smart Images

Figure CN111582053B_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of digital design and manufacturing, and in particular relates to a large-scale complex blank model recognition method. Background Art
[0002] Large cabin parts are key components of aerospace vehicles such as large commercial aircraft, fighter jets, and launch vehicles. For example, the interstage cabin, as a connecting component of the rocket body, has a significant impact on the overall dynamic characteristics, flight resistance, and flight speed. The importance and specificity of the role of this type of parts make them usually complete integrated components. With the gradual improvement of the requirements for the service performance of aircraft, the structural design features of this type of large and complex component parts have many complex internal intersection features such as bosses and cavities, and they are becoming more and more complex. The surface of the blank model also has randomly distributed forming errors, which poses great challenges to the accurate identification of its internal features.
[0003] Feature-based processing planning of cabin blank parts is crucial to ensure the manufacturing accuracy and quality of such large and complex feature parts. Feature recognition is a key technology for realizing three-dimensional computer-aided process planning (CAPP) and computer-aided manufacturing (CAM). Such parts have a large number of processing features, large feature sizes, significant differences between features, and high feature geometric complexity, which makes feature recognition difficult and the recognition efficiency and accuracy need to be improved. Therefore, feature recognition of complex parts has become a research hotspot for many researchers and institutions at home and abroad.
[0004] Domestic and foreign scholars have conducted a lot of research on the problem of design feature recognition. There are three main methods for part feature recognition: graph-based, rule-based, and trace-based. In practical applications, scholars have optimized and combined these methods and proposed a part feature recognition method that integrates multiple methods. MAREFAT et al. used the method of adding virtual chains to the graph-based method to identify intersecting features. Shen Mei et al. proposed a method of using concave and convex features in the model as intermediate features for feature recognition. Woo proposed a feature recognition method of interactive volume sum to decompose the feature tree structure. Zubair conducted an in-depth study on the symmetric features in the feature tree structure and proposed a method of splitting the interactive volume sum to identify intersecting features. Liu Changqing et al. proposed a method for defining complex processing features to realize CNC processing of complex features. Zhang Congcong et al. proposed a method for identifying defective structures in CAD models of aircraft structural parts, which promoted the development of feature recognition in the aerospace field.
[0005] The continuous and in-depth research of the above-mentioned scholars has promoted feature recognition methods such as complex feature definition and adding constraint surfaces, and preliminarily realized the recognition of design features and processing features in CAD models, which has promoted the targeted application of feature recognition technology in engineering. However, since such methods use personalized feature definition methods for the recognition of simple intersecting features, their promotion and application in complex feature recognition is limited.
[0006] In recent years, many scholars have also devoted themselves to methods of obtaining part information from STEP to realize feature recognition. Zhang et al. obtained the geometric data of features and related information of machining feature surface boundaries from STEP files. Based on this study, Sridharan proposed a method for identifying contour features and end face features based on the feature boundary expression rules. Zubair et al. used surface boundary rules to identify hole features in parts, exploring the advantages of STEP format in the field of feature recognition. Wang Jun et al. took advantage of the STEP file's accurate recording of design feature information and integrated graph-based and trace-based methods to identify intersecting features. Zhang Yu et al. proposed to input the geometric topological information of the feature-extracting STEP file into the improved BP neural network for intelligent feature recognition, so that the versatility of feature recognition is further improved.
[0007] These studies are based on popular theories such as STEP-NC system and neural network, and have achieved many results in realizing accurate recognition of design model features, promoting the development of automatic recognition methods of design features, but are not suitable for the recognition of non-design model features such as blank models or workpiece geometric models.
[0008] In summary, scholars have made a lot of research progress in the field of part feature recognition. Existing methods recognize planar structure features based on the boundary information and boundary rules of the part geometric model, which improves the search, extraction and storage level of the geometric and topological data of the part design model. It can achieve high accuracy in single feature recognition, and has also achieved exploratory results in the recognition of a few types of simple feature combinations. There has also been a lot of progress in the recognition of complex intersecting features of the design model. Different from the design model, the blank model is obtained by means of post-scanning reconstruction, lacks design feature tree information, and is difficult to directly identify by obtaining the geometric topological information of the feature tree. Therefore, it is difficult for existing methods to achieve efficient and accurate recognition of blank models or workpiece models, especially large cabin-type component blank models with a large number of bosses and mouth frames or complex cavity features of workpiece models. Summary of the invention
[0009] The technical problem to be solved by the present invention is that, in view of the fact that existing methods are difficult to achieve efficient and accurate recognition of complex cavity features of blank models or workpiece models, especially blank models or workpiece models of large cabin-type components with a large number of bosses and frame combinations, a method for hierarchical recognition of complex features of blank models based on a feature matrix is provided to achieve high-precision and rapid recognition of complex intersecting features.
[0010] In order to solve the above technical problems, the present invention adopts the following technical solutions:
[0011] A complex feature layered recognition method for a blank model based on a feature matrix, characterized by comprising the following steps:
[0012] S1: First, the geometric topological data of all faces on the part blank model are obtained, and the pixel information of the face is output, wherein the pixel information includes the features showing the contour and the pseudo features caused by the blank forming defects; then, grayscale information is generated by a global binarization processing method; the geometric topological information of the pseudo features located on the contour surface is extracted and deleted, and the data of each face of the model is optimized in turn, and finally an optimized part blank model is obtained;
[0013] S2: Then, an attribute adjacency graph is established with the optimized part blank model as the object to achieve a detailed description of the spatial position relationship between the associated surfaces in the model; the concavity and convexity of the associated surfaces are calculated through the normal vectors of the intersecting edges and adjacent surfaces, and features are extracted based on the concavity and convexity of all associated surfaces. The extracted features include indivisible single features and complex combined features;
[0014] S3: Apply the feature stratification algorithm to stratify the extracted features until all the extracted features are converted into a combination of single features; calculate the feature matrices of all the extracted single features and the single features obtained by stratification in turn; build a general feature matrix library, and match the calculated feature matrix with the feature matrix library by comparing the feature matrix elements; when the feature matrix is matched successfully, the identified feature attributes and their geometric topological data are output. When a feature matrix that cannot be matched successfully appears, the general feature matrix library is expanded, and the features are matched again until the identified feature attributes and their geometric topological data are output.
[0015] In the above technical scheme, in step S1, a threshold segmentation method suitable for random surface forming errors and defects is adopted, pixel information of these surfaces is output based on the acquired data, bilateral filtering preprocessing is performed on the pixel information, and then grayscale information is generated through a global binarization processing method; wherein, the optimal segmentation threshold is calculated by an iterative method, and the obtained optimal threshold is used to segment pixel information, so that the segmented image can distinguish between display contours and pseudo-features; the geometric topological information of pseudo-features located on the contour surface is extracted and deleted, and the data of each surface of the model is optimized in turn, and finally an optimized part blank model is obtained.
[0016] In the above technical solution, in step S1, a threshold segmentation method for pseudo feature recognition is used to extract pseudo features of the contour surface, which specifically includes the following steps:
[0017] S11. Input blank model S R , traverse and search the blank model, extract the geometric topological data of the surface s and the surface {s1, s2…s n};
[0018] S12, input the ith face, and calculate the pixel value g of the face = {g1, g2…g m};
[0019] S13, using bilateral filtering method to process the geometric topological data of each surface i Perform smoothing and protect the image edges, and determine the spatial domain value through calculation;
[0020] S14, using the global threshold segmentation method to segment the surface i The threshold is iteratively calculated, the initial threshold x0 is determined according to the image histogram, the termination parameter ε is set, the pixels are judged one by one, and the average pixels m1 above the initial threshold and the average pixels m2 below the initial threshold are calculated respectively;
[0021] S15, calculate the current image threshold x=(g min +g max ) / 2, this value is used to adjust and optimize the initial threshold;
[0022] S16, determine the position difference between the current image threshold x and the initial threshold x0. If the difference is less than ε, output the binary image of the i-th surface, determine and identify the pseudo features on the surface, remove the geometric information feature data of the pseudo features on the surface, and optimize the data of the model; if the difference is greater than ε, assign the current image threshold x to the initial threshold x0, and execute step d;
[0023] S17, determine whether all the faces have been processed. If there are unprocessed faces, continue to execute step d. If all the faces have been processed, output all the faces and their optimized data information, and the model optimization is completed.
[0024] In the above technical solution, in step S2, the attribute adjacency graph of the part is established based on the position and adjacency relationship between the face units contained in the model; the tag information of all edges and faces is queried through the part blank model optimized in step S1, and then the two adjacent faces associated with each edge are obtained, and the direction vector of each edge and the normal vector of its adjacent face are calculated. The spatial geometric relationship of the face is obtained through vector calculation, and the convexity and concavity of the spatial position composed of the edge and the adjacent face are judged, thereby completing the feature extraction.
[0025] In the above technical solution, in step S2, no matter what type of face on the model is, the spatial position relationship between the two faces is determined by the angle θ between the two faces, and the direction vector V of the common edge is determined by n Cross-product with the normal vector V1 of face F1 to get V e (V e =V1×V n ), through V e Calculate the angle θ (θ = arccos ((V e ×V2) / (||V e ||×||V2||)); when 0<θ<π, the common edge of two adjacent faces is determined to be a convex edge type; when π<θ<2π, the common edge of two adjacent faces is determined to be a concave edge type.
[0026] In the above technical solution, in step S2, the faces constituting the model are divided into two categories: curved surfaces and flat surfaces by the curvature of the faces, and the combination type of the faces is further determined by combining the curvature of the intersecting edges;
[0027] For plane-plane intersection, the normal vectors V1, V2 and the common edge direction vector V of planes F1 and F2 are calculated directly based on the geometric data of the model surface. n , and then determine the concavity and convexity of the intersecting surface;
[0028] When there are both planes and curved surfaces in the intersecting surface and the intersection line is a straight line, calculate the tangent plane F of the curved surface F2 at the intersection line. t The normal vector V2 and the common edge direction vector V n , and then determine the concavity and convexity of the intersecting surface;
[0029] When the intersection line is a curve, make a tangent plane F of surface F2 through any point p on the intersection line. t , calculate the point p parallel to the tangent plane F t The direction vector V n and point p perpendicular to the tangent plane F t The normal vector V2 of the intersection surface is then used to determine the concavity and convexity of the intersection surface;
[0030] When the intersecting surfaces are all curved surfaces, the tangent planes F1 and F2 at the intersection of the curved surfaces t1 and F t1 And calculate the normal vectors V1, V2 of each tangent plane and the common edge direction vector V n , and finally determine the concavity and convexity of the intersecting surface.
[0031] In the above technical solution, a ring-based feature stratification method is adopted in step S3. First, all features on the model are extracted by judging the concavity and convexity, and then the ring information of complex features is collected by feature traversal. The ring information is analyzed to obtain the rings that meet the conditions and serve as the basis for feature stratification.
[0032] In the above technical solution, the basis for stratifying the extracted features in step S3 is: setting a feature ring to be associated with multiple faces, and a face to be associated with multiple groups of adjacent faces; judging whether the common edges of each face contained in a certain ring satisfy the condition that only concave structures or only convex structures exist, and the ring that meets this condition is the stratified ring; based on this, all stratified rings are judged, and the entire model is stratified to convert all complex features into single features; for island-type features in the model, there is no complex intersection relationship between them and other features, and they can be directly identified without stratification processing.
[0033] In the above technical solution, in step S3, the feature matrix construction method based on the relationship between faces is used to construct feature matrices of different features by designing the description rules of matrix elements and their values for faces, and to form a feature matrix library: for complex features composed of n faces, a feature matrix A is constructed. i×j , where i and j represent face F i With F j The serial number of the i-th row and j-th column corresponds to the value a i×j Indicates face F i With F j The structure attributes composed of the matrix elements are different in position w i and its value describe the type of face and the relationship between faces; by traversing the entire blank model and the relationship between faces, query the model's geometric topological data, calculate and establish the feature matrix of the entire model.
[0034] In the above technical solution, the feature matrix matching process in step S3 is: matching the feature matrix of a single feature with the feature matrix of a feature library to achieve recognition of a single feature:
[0035] When the feature sub-matrix corresponds to the arc-shaped cavity feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as the arc-shaped cavity feature;
[0036] When the feature sub-matrix corresponds to the square cavity type feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as the square cavity type feature;
[0037] When the feature sub-matrix corresponds to a cylindrical boss-like feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as a cylindrical boss-like feature.
[0038] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0039] Large cabin components are important parts of large aircraft, rockets and other aerospace vehicles. They have many complex internal intersecting features, which poses a great challenge to the accurate identification of their internal features. The effective identification of the internal features of the blank model is an important basis for determining the machining allowance, optimizing cutting parameters and planning tool paths. However, various methods in the prior art cannot guarantee the accuracy and efficiency of the identification of complex components.
[0040] The present invention proposes a hierarchical identification method for intersection features of large-scale complex component blank models based on feature matrix, and realizes multi-level complex intersection feature identification based on blank model topological information. First, the threshold segmentation method is used to identify and eliminate pseudo features and data of large-scale complex component blank models, and the blank model is optimized. Then, the attribute adjacency graph of the optimized blank model is constructed, and the hierarchical identification method is used to hierarchically process the intersection features of the optimized blank model of the component to obtain a single feature and calculate its feature matrix. Multiple types of single features are converted into feature matrices, and a feature matching library is established. Finally, the feature matrix is matched with the feature library to accurately identify the intersection features of the model. An example verification is carried out on a blank model with multiple features of cabin parts, and the feasibility and effectiveness of the algorithm are verified by accurately identifying multiple types of features. The general feature recognition research object is the design feature model, and its model has complete geometric topological data, which provides great advantages for feature recognition and extraction. However, this technology takes the blank as the research object, which is more practical for processing and production planning. The blank does not have complete geometric topological data. This technology establishes a mapping relationship between the blank and the processing model, obtains the three-dimensional model of the blank through three-dimensional scanning, and uses a global threshold segmentation method to identify and eliminate the geometric topological data information of pseudo features in the three-dimensional model of the blank, so as to avoid the influence of defects on the recognition rate of processing features. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 The figure is a flowchart of the identification method implemented according to the present invention.
[0042] Figure 2 A comparison between the actual image and schematic diagram of pseudo features caused by the material forming process involved in the method of the present invention.
[0043] Figure 3 The present invention is a flowchart of the threshold segmentation method for pseudo feature recognition involved in the present invention.
[0044] Figure 4 It is a schematic diagram of the adjacency graph construction process of the blank optimization model of the present invention.
[0045] Figure 5 It is a schematic diagram of the calculation principle of the concavity and convexity of the intersecting surface of the present invention.
[0046] Figure 6Schematic diagram of the layering of complex features of the present invention.
[0047] Figure 7 This is an example of the geometric model feature matrix of the present invention. DETAILED DESCRIPTION
[0048] The complex feature layered recognition method of the blank model based on the feature matrix implemented in the present invention is as follows Figure 1-6 As shown. From the automatic recognition of the intersection feature combination of the blank model or workpiece model of large and complex components, a model hierarchical algorithm based on the feature matrix is proposed to achieve high-precision and rapid recognition of complex intersection features. A blank model optimization method considering pseudo-feature recognition is designed, based on which its attribute adjacency graph is established and feature extraction is performed. The extracted features are hierarchically processed until they are unified, and the matrix description of the unified features is extracted and matched with the feature matrix library to achieve high-precision and rapid recognition of the feature matrix. The accurate recognition of complex intersection features in the example is achieved through feature matrix matching, which verifies the effectiveness of the hierarchical algorithm in the complex feature recognition process.
[0049] By designing the feature recognition process of the blank model, the blank model of the input part is processed to realize the recognition and output of all the features of the model. The feature recognition process flowchart of the designed blank model is shown in the figure. Figure 1 As shown, pseudo-feature recognition and processing based on threshold segmentation method, feature search and extraction, and feature matching and recognition were carried out respectively.
[0050] The blank model usually has forming errors and surface defects, which makes it difficult to avoid pseudo features when performing feature recognition on its scanned parts. Therefore, a feature recognition method considering pseudo feature recognition and processing is proposed. First, the geometric topological data of all faces on the blank model of the part are obtained, and a threshold segmentation method suitable for random forming errors and defects on the surface is adopted. Based on the acquired data, the pixel information of these faces is output, and the pixel information is preprocessed by bilateral filtering, and then the grayscale information is generated by the global binarization processing method. Among them, the optimal segmentation threshold is calculated by an iterative method, and the optimal threshold is used to segment the pixel information, so that the segmented image can distinguish between the display contour and pseudo features. The geometric topological information of the pseudo features located on the contour surface is extracted and deleted, and the data of each face of the model is optimized in turn, and finally the optimized blank model of the part is obtained.
[0051] The optimized blank model is analyzed, its attribute adjacency graph is established, and the spatial position relationship between the numerous associated faces in the model is described in detail. The concavity and convexity of the associated faces are calculated through the normal vectors of the intersecting edges and adjacent faces, and features are extracted based on the concavity and convexity of all associated faces. The extracted features include multiple types of features such as indivisible single features and complex combination features.
[0052] The extracted features are layered using a feature layering algorithm until all extracted features are converted into a combination of single features. The feature matrices of all extracted single features and layered single features are calculated in sequence. A general feature matrix library is constructed, and the calculated feature matrix is matched with the feature matrix library by comparing the feature matrix elements. When the match is successful, the corresponding feature recognition is realized, and the identified feature attributes and their geometric topological information are output to provide data support for process planning. When a feature matrix that cannot be matched successfully appears, the general feature matrix library is expanded according to the feature requirements in combination with case analysis, and then the feature matching and recognition are performed.
[0053] The designed feature recognition includes the design and implementation of pseudo-feature recognition, attribute adjacency graph construction, feature hierarchical processing and feature matrix matching, as follows.
[0054] Pseudo-feature recognition in feature layering recognition:
[0055] Due to mold errors, warping deformation, cold plastic deformation and other reasons, the blanks of large cabin components usually have forming defects such as unevenness and nozzle nodules. These defects make the blank model surface have randomly distributed forming errors, forming pseudo features, which interfere with the accurate recognition of real features. It is necessary to identify pseudo features and eliminate their data information before real feature recognition to eliminate their interference with the accurate recognition of real features.
[0056] Figure 2 The figure shows a partial image of the blank surface and a binary image of the blank. In the figure, the forming error caused by the mold causes pseudo features. In order to segment and remove pseudo features from real features, the image processing method is used to achieve accurate recognition of pseudo features on the contour surface through algorithm design.
[0057] In order to extract pseudo-features of the surface contour of the blank, a threshold segmentation method for pseudo-feature recognition is designed for processing. Figure 3 The following Figure 3 The main process is described in.
[0058] a. Input the blank model S R , traverse the model and extract the geometric topological data of the surface s and the surface, which are recorded as {s1, s2…s n}.
[0059] b. Input the ith face and calculate the pixel value g = {g1, g2…g m}.
[0060] c. Use bilateral filtering method to filter s iSmoothing is performed and the image edges are protected. The spatial domain value is determined by calculation to be 100 (the larger the value, the smoother the image) and the value range is 0.01 (the smaller the value, the clearer the image edges).
[0061] d. Use global threshold segmentation method to segment the surface s i The threshold is iteratively calculated, the initial threshold x0 is determined according to the image histogram, the termination parameter ε is set, the pixels are judged one by one, and the average pixels m1 above the initial threshold and the average pixels m2 below the initial threshold are calculated respectively.
[0062] e. Calculate the current image threshold x = (g min +g max ) / 2, which is used to adjust and optimize the initial threshold.
[0063] f. Determine the position difference between the current image threshold x and the initial threshold x0. If the difference is less than ε, output the binary image of the i-th surface, determine and identify the pseudo features on the surface, remove the geometric information feature data of the pseudo features on the surface, and optimize the data of the model. If the difference is greater than ε, assign the current image threshold x to the initial threshold x0 and execute step d.
[0064] g. Determine whether all faces have been processed. If there are unprocessed faces, continue to execute step d. If all faces have been processed, output all faces and their optimized data information, and the model optimization is completed.
[0065] Attribute adjacency graph construction:
[0066] Through the processing technology, path planning and feature analysis of the structure of a certain type of cabin part, it can be seen that its structural features mainly include cavities, grooves, holes, depressions and bosses. A more complex and diverse equivalent part model with all the above features is designed to replace the original cabin part model, such as Figure 4 –a design model. The blank point cloud model is obtained by scanning with a laser scanner, as shown in Figure 4 -b. Pseudo features caused by forming defects on the blank point cloud model, such as Figure 4 -c shows that the obvious columnar traces in the blank are mold opening traces and are not processing features. The pseudo-feature recognition threshold segmentation method is used to process the blank model and optimize its geometric topology data. The optimized blank model is shown in Figure 4 -d as shown.
[0067] Figure 4The numbers in -d represent the face units of the equivalent part model, where number 1 represents the set of all faces that do not participate in the machining contour. 2 and 14 are surface units, and 3-13 and 15 are plane units. The property adjacency graph of the part is established based on the position and adjacency relationship between the face units contained in the model, such as Figure 4 -e. Through the above optimization model, the tag information of all edges and faces is queried, and then the two adjacent faces associated with each edge are obtained, and the direction vector of each edge and the normal vector of its adjacent face are calculated. The spatial geometric relationship of the face is obtained through vector calculation, and the concavity and convexity of the spatial position composed of the edge and adjacent face are judged, thereby completing the feature extraction.
[0068] Determining the spatial relationship between faces is an important process in feature recognition. Figure 5 As shown in the figure, no matter what type of face on the model, the spatial position relationship between two faces is determined by the angle θ between the two faces, which is determined by the direction vector V of the common edge. n Cross-product with the normal vector V1 of face F1 to get V e (V e =V1×V n ), through V e Calculate the angle θ (θ = arccos ((V e ×V2) / (||V e ||×||V2||)). When 0<θ<π, the common edge of two adjacent faces can be determined as a convex edge type; when π<θ<2π, the common edge of two adjacent faces can be determined as a concave edge type.
[0069] The faces that make up the model are divided into two categories: curved surfaces and flat surfaces based on the curvature of the faces, and the combination type of the faces is further determined based on the curvature of the intersecting edges. Figure 5 Four intersection relationships between planes and curved surfaces are shown. The concavity and convexity determination methods corresponding to these four relationships are given below.
[0070] Plane-plane intersection type (see Figure 5 a plane-plane intersection type):
[0071] For this type, the normal vectors V1, V2 and the common edge direction vector V of planes F1 and F2 can be directly calculated based on the geometric data of the model surface. n , the concavity and convexity of the intersecting surface can be determined according to the above method.
[0072] Plane-surface intersection type with straight line intersection (see Figure 5 The plane-surface intersection type where the b intersection line is a straight line):
[0073] When there are both planes and curved surfaces in the intersecting surface and the intersection line is a straight line, calculate the tangent plane F of the curved surface F2 at the intersection line. tThe normal vector V2 and the common edge direction vector V n , and then determine the concavity and convexity of the intersecting surface according to the above method.
[0074] The intersection line is a plane-surface intersection type (see Figure 5 The c intersection line is the plane-surface intersection type of the curve):
[0075] When the intersection line is a curve, make a tangent plane F of surface F2 through any point p on the intersection line. t , calculate the point p parallel to the tangent plane F t The direction vector V n and point p perpendicular to the tangent plane F t The normal vector V2 is obtained, and then the concavity and convexity of the intersecting surface are determined according to the above method.
[0076] Surface-surface intersection type (see Figure 5 d surface-surface intersection type):
[0077] When the intersecting surfaces are all curved surfaces, the tangent planes F1 and F2 at the intersection of the curved surfaces t1 and F t1 And calculate the normal vectors V1, V2 of each tangent plane and the common edge direction vector V n , and finally determine the concavity and convexity of the intersecting surface according to the above method.
[0078] Feature layering processing:
[0079] Complex parts have the structural characteristics of multiple features intersecting and combining. In order to identify these complex intersecting features, the complex parts are decomposed by layering to achieve accurate feature identification. In this regard, the present invention designs a feature layering method based on rings. First, all features on the model are extracted by judging the concavity and convexity, and then the ring information of the complex features is collected by feature traversal. The ring information is analyzed to obtain the rings that meet the conditions and serve as the basis for feature layering. Specifically, for a feature, one ring is associated with multiple faces, and one face is associated with multiple groups of adjacent faces. It is judged whether the common edges of each face contained in a certain ring meet the conditions of only concave structures or only convex structures. The ring that meets this condition is the layered ring, which serves as the basis for feature layering. Based on this, all the layered rings are judged, and the entire model is layered to convert all complex features into single features. For island-type features in the model, there is no complex intersection relationship with other features, and they can be directly identified without layering.
[0080] by Figure 4 The model is taken as an example, and the designed ring-based feature hierarchical method is used for processing, such as Figure 6As shown. According to the above method, this example contains four layered rings that meet the conditions, and the entire model is divided into 4 layers (excluding the island feature), namely f1, f2, f3 and f4. Among them, f1 and f2 form a groove with a curved surface, f2 and f3, f3 and f4 respectively form a rectangular square groove.
[0081] Construction and matching of feature matrix:
[0082] The present invention proposes a feature matrix construction method based on face relationships. By designing the description rules of matrix elements and their values for faces, feature matrices of different features are constructed to form a feature matrix library. The feature matrices of different features have unique certainty, making the precise matching of features in the instance model fully feasible in theory.
[0083] For complex features consisting of n faces, construct the feature matrix A i×j , where i and j represent face F i With F j The serial number of the i-th row and j-th column corresponds to the value a i×j Indicates face F i With F j The structure properties of the composition.
[0084] The different positions of the matrix element values w i Its values describe the types of faces and the relationships between faces, as shown in Table 1. The matrix framework is as follows:
[0085] w1 and w2 are defined as the type of the surface. Specifically, w1w2 = 11 means F i With F j All are planes; w1w2=12 or 21 indicates F i With F j There is a curved surface and a plane in each; when w1w2=22, it means F i With F j All are curved surfaces.
[0086] Describing F with w3 i With F j Whether adjacent or not, the element values are set to 3 and 4 respectively, where w3=3 represents adjacent, and w3=4 represents non-adjacent.
[0087] Define w4 as F i With F j When w3=3, F i With F j Adjacent, common edges have concave-convex properties. Therefore, w4=5 is used to describe F i With F j The structure is concave, w4=6 describes F i With F jThe structure is a convex structure. When w3=4, F i With F j Not adjacent, no common edges, parallel or anisotropic, w4=7 to describe F i With F j Parallel to each other, w4=8 to describe F i With F j An anisotropic relationship that is neither adjacent nor parallel.
[0088] Table 1 Definition of feature matrix element values
[0089]
[0090] The construction of feature library is open and expandable. It is usually based on the existing feature library and continuously expands the feature library in combination with specific case analysis. Using the above method, a feature library for cabin parts was constructed. Table 2 shows some typical features in the constructed feature library and its feature matrix.
[0091] Table 2 Feature matrix construction of feature library elements
[0092]
[0093] Applying the above-mentioned feature matrix construction method based on face relationships, by traversing the entire blank model and the face relationships, querying the model's geometric topological data, calculating and establishing the feature matrix of the entire model. Figure 4 -d model and its faces as an example for description.
[0094] Depend on Figure 4 -d model and its face number, you can create A 15×15 Obtain the 15 types of faces in the model and the adjacent, parallel or anisotropic relationships between faces, analyze the concave and convex structures of the faces, and obtain the feature matrix of the entire model according to the designed feature matrix construction method, such as Figure 7 shown.
[0095] From the feature matrix of the blank model, we can see that the faces composed of the features f1 and f2 are numbered 1, 2, 3, 4, 5, and 6, respectively. Figure 7 The feature submatrix A1 in the figure. The features formed by f2 and f3 contain face numbers 3, 4, 5, 7, and 8, that is, Figure 7 The feature submatrix A2 in the figure. The features formed by f3 and f4 contain face numbers 8, 9, 10, 11, 12, and 13, that is, Figure 7 The feature submatrix A3 in the middle. In this blank model, the cylindrical surface in the middle is isolated and does not need to be layered. The surface numbers of its constituent features are 14 and 15, that is, Figure 7 The characteristic sub-matrix A4 in the middle.
[0096] Feature matrix matching: Match the feature matrix of a single feature with the feature matrix of the feature library to achieve single feature recognition. By matching with the feature components in the feature library shown in Table 2, we can obtain:
[0097] The matrix corresponding to the feature submatrix A1 matches the matrix B8 in the feature library, which is an arc cavity feature;
[0098] The matrices corresponding to the feature submatrices A2 and A3 match the B7 matrix in the feature library, which is a square cavity type feature;
[0099] The matrix corresponding to the feature submatrix A4 matches the matrix B1 in the feature library and is a cylindrical boss feature.
Claims
1. A complex feature layered recognition method for blank models based on feature matrix, characterized in that The steps include: S1: firstly, the geometric topological data of all faces on the part blank model are obtained, and the pixel information of the faces is output, wherein the pixel information includes the features showing the contour and the pseudo features caused by the blank forming defects; Then, grayscale information is generated through a global binarization method; the geometric topology information of pseudo features located on the contour surface is extracted and deleted, and the data of each face of the model is optimized in turn, and finally an optimized part blank model is obtained; S2: Then, an attribute adjacency graph is established with the optimized part blank model as the object to achieve a detailed description of the spatial position relationship between the associated surfaces in the model; the concavity and convexity of the associated surfaces are calculated through the normal vectors of the intersecting edges and adjacent surfaces, and features are extracted based on the concavity and convexity of all associated surfaces. The extracted features include indivisible single features and complex combined features; S3: Applying a feature stratification algorithm to stratify the extracted features until all the extracted features are converted into a combination of single features; calculating the feature matrices of all the extracted single features and the single features obtained by stratification in turn; constructing a general feature matrix library, and matching the calculated feature matrix with the feature matrix library by comparing the feature matrix elements; When the feature matrix is matched successfully, the identified feature attributes and their geometric topological data are output. When a feature matrix cannot be matched successfully, the general feature matrix library is expanded and the features are matched again until the identified feature attributes and their geometric topological data are output.
2. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1, characterized in that: In step S1, a threshold segmentation method suitable for random surface forming errors and defects is adopted, pixel information of these surfaces is output based on the acquired data, bilateral filtering preprocessing is performed on the pixel information, and then grayscale information is generated through a global binarization processing method; wherein, the optimal segmentation threshold is calculated by an iterative method, and the obtained optimal threshold is used to segment pixel information, so that the segmented image can distinguish between display contours and pseudo features; the geometric topological information of pseudo features located on the contour surface is extracted and deleted, and the data of each surface of the model is optimized in turn, and finally an optimized part blank model is obtained.
3. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 2, characterized in that: In step S1, a threshold segmentation method for pseudo feature recognition is used to extract pseudo features of the contour surface, which specifically includes the following steps: S11. Input blank model S R , traverse and search the blank model, extract the geometric topological data of the surface s and the surface {s1, s2…s n }; S12, input the ith face, and calculate the pixel value g of the face = {g1, g2…g m }; S13, using bilateral filtering method to process the geometric topological data of each surface i Perform smoothing and protect the image edge, and determine the spatial domain value through calculation; S14, using the global threshold segmentation method to segment the surface i The threshold is iteratively calculated, the initial threshold x0 is determined according to the image histogram, the termination parameter ε is set, the pixels are judged one by one, and the average pixels m1 above the initial threshold and the average pixels m2 below the initial threshold are calculated respectively; S15, calculate the current image threshold x=(g min +g max ) / 2, this value is used to adjust and optimize the initial threshold; S16, determine the position difference between the current image threshold x and the initial threshold x0. If the difference is less than ε, output the binary image of the i-th surface, determine and identify the pseudo features on the surface, remove the geometric information feature data of the pseudo features on the surface, and optimize the data of the model; if the difference is greater than ε, assign the current image threshold x to the initial threshold x0, and execute step d; S17, determine whether all the faces have been processed. If there are unprocessed faces, continue to execute step d. If all the faces have been processed, output all the faces and their optimized data information, and the model optimization is completed.
4. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1, characterized in that: In step S2, the position and adjacency relationship between the face units contained in the model are used to establish the attribute adjacency graph of the part; the tag information of all edges and faces is queried through the part blank model optimized in step S1, and then the two adjacent faces associated with each edge are obtained, and the direction vector of each edge and the normal vector of its adjacent face are calculated. The spatial geometric relationship of the face is obtained through vector calculation, and the convexity and concavity of the spatial position composed of the edge and the adjacent face are judged, thereby completing the feature extraction.
5. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 4, characterized in that: In step S2, no matter what type of face on the model is, the spatial position relationship between the two faces is determined by the angle θ between the two faces, and the direction vector V of the common edge is n Cross-product with the normal vector V1 of face F1 to get V e (V e =V1×V n ), through V e Calculate the angle θ (θ = arccos ((V e ×V2) / (||V e ||×||V2||)); when 0<θ<π, the common edge of two adjacent faces is determined to be a convex edge type; when π<θ<2π, the common edge of two adjacent faces is determined to be a concave edge type.
6. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 4, characterized in that: In step S2, the faces constituting the model are divided into two categories: curved surfaces and flat surfaces according to the curvature of the faces, and the combination type of the faces is further determined in combination with the curvature of the intersecting edges; For plane-plane intersection, the normal vectors V1, V2 and the common edge direction vector V of planes F1 and F2 are calculated directly based on the geometric data of the model surface. n , and then determine the concavity and convexity of the intersecting surface; When there are both planes and curved surfaces in the intersecting surface and the intersection line is a straight line, calculate the tangent plane F of the curved surface F2 at the intersection line. t The normal vector V2 and the common edge direction vector V n , and then determine the concavity and convexity of the intersecting surface; When the intersection line is a curve, make a tangent plane F through any point p on the intersection line. t , calculate the point p parallel to the tangent plane F t The direction vector V n and point p perpendicular to the tangent plane F t The normal vector V2 of the intersection surface is then used to determine the concavity and convexity of the intersection surface; When the intersecting surfaces are all curved surfaces, the tangent planes F1 and F2 at the intersection of the curved surfaces t1 and F t1 And calculate the normal vectors V1, V2 of each tangent plane and the common edge direction vector V n , and finally determine the concavity and convexity of the intersecting surface.
7. The complex feature layered identification method of a blank model based on a feature matrix according to claim 1 is characterized in that: In step S3, a ring-based feature stratification method is adopted. First, all features on the model are extracted by judging the concavity and convexity. Then, the ring information of complex features is collected by feature traversal. The ring information is analyzed to obtain the rings that meet the conditions and serve as the basis for feature stratification.
8. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 7, characterized in that: The basis for stratifying the extracted features in step S3 is: setting a feature ring to be associated with multiple faces, and a face to be associated with multiple groups of adjacent faces; judging whether the common edges of each face contained in a certain ring satisfy the condition that only concave structures or only convex structures exist, and the ring that meets this condition is the stratified ring; based on this, all stratified rings are judged, and the entire model is stratified to convert all complex features into single features; for island-type features in the model, there is no complex intersection relationship between them and other features, and they can be directly identified without stratification processing.
9. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 7, characterized in that: In step S3, a feature matrix construction method based on face relationships is used to construct feature matrices of different features by designing the description rules of matrix elements and their values for faces. Composition feature matrix library: For complex features composed of n faces, construct feature matrix A i×j , where i and j represent face F i With F j The serial number of the i-th row and j-th column corresponds to the value a i×j Indicates face F i With F j The structure attributes composed of the matrix elements are different in position w i and its value describe the type of face and the relationship between faces; by traversing the entire blank model and the relationship between faces, query the model's geometric topological data, calculate and establish the feature matrix of the entire model.
10. The complex feature hierarchical identification method of a blank model based on a feature matrix according to claim 1 or 7, characterized in that: The feature matrix matching process in step S3 is: matching the feature matrix of a single feature with the feature matrix of a feature library to achieve recognition of a single feature: When the feature sub-matrix corresponds to the arc-shaped cavity feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as the arc-shaped cavity feature; When the feature sub-matrix corresponds to the square cavity type feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as the square cavity type feature; When the feature sub-matrix corresponds to a cylindrical boss-like feature in the matrix matching feature library, the feature sub-matrix of the single feature is matched and identified as a cylindrical boss-like feature.
