A machining feature recognition method and system based on start face classification preference
By analyzing the topological relationship between the surfaces and edges of solid parts and verifying the feature types, the low efficiency problem caused by improper selection of the starting surface in existing feature recognition methods is solved, and efficient feature recognition and automatic extraction of groove circumferential array features are achieved.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-04-20
- Publication Date
- 2026-03-24
AI Technical Summary
Existing feature recognition methods are inefficient when retrieving the starting face of a subgraph, and their reliance on predefined feature subgraphs increases the number of isomorphic comparisons, thus affecting feature recognition efficiency.
By analyzing the topological relationship of the face edges of the solid part, calculating the included angle and concavity/convexity attributes of two faces at the common edge, constructing the adjacency graph of the part attributes, deleting convex attribute edges, selecting the face with the most adjacent faces as the starting face, performing feature type verification, and extracting feature faces.
It improves feature recognition efficiency, reduces the number of subgraph isomorphic comparisons, enhances the conformity of the starting face to different feature types, avoids redefining the starting face, and supports direct extraction of slot circumferential array features.
Smart Images

Figure CN116469124B_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of product digital design and manufacturing technology, and in particular relates to a processing feature recognition method and system based on initial surface classification and optimization. Background Technology
[0002] The statements in this section are merely background information related to the present invention and do not necessarily constitute prior art.
[0003] Machining feature recognition extracts information related to the manufacturing process from a 3D part model and is a key technology in the CAM / CAPP field. Currently, the most widely used feature recognition methods in industrial software are pattern matching based on feature subgraph retrieval. Chen Zhuoning's method uses part geometric information and process semantic information from an MBD (Model-Based Definition) model to search for the starting face and minimum condition subgraph in the part attribute adjacency graph, achieving hierarchical recognition of various features according to predefined priorities. Huang Rui et al. use the feasible tool axial space of the machining surface as a constraint, integrate manufacturing semantics to cluster machining surfaces, construct machining region subgraphs, and use these subgraphs as intersecting manufacturing feature traces. Combined with dimension information, they optimize and merge machining region subgraphs to achieve feature recognition. Liu Xuemei et al. construct an adjacency matrix of the part attribute adjacency graph, extract the minimum adjacency graph of the part by retrieving submatrices that meet the conditions, achieve single feature recognition by comparing the minimum adjacency graph with predefined feature elements, and extract composite features by clustering single features with the same feature factors. Peng Fangyu et al. determined the pseudo-feature region of the blank based on two-dimensional image recognition, mapped the recognition results onto the three-dimensional model to realize pseudo-feature identification and deletion, and then decomposed the intersecting features and combined features of complex parts into single features through feature hierarchical sorting. The adjacency matrix of the single feature was extracted and matched with the predefined feature matrix to realize feature recognition.
[0004] Subgraph retrieval is the core of feature recognition methods. Subgraph retrieval typically selects a starting face from the adjacency graph of part attributes as the starting point for the retrieval. The quality of the starting face selection significantly impacts the completeness and efficiency of the retrieval results. Usually, a face with more adjacent faces is chosen as the starting face based on prior knowledge. However, simply relying on the number of adjacent faces fails to reflect the structural differences in starting faces between different feature types. When retrieving feature subgraphs, it may still be necessary to backtrack to the starting face and redefine it, leading to a decrease in retrieval efficiency. Furthermore, the determination of the current feature type mainly depends on predefined feature subgraphs; only after completing the subgraph isomorphic retrieval can the feature type be finally confirmed, thus limiting feature recognition efficiency. Current feature recognition methods pay little attention to the optimal selection of the starting face for subgraph retrieval and reducing the number of isomorphic comparisons. This paper proposes a feature recognition method that optimizes the starting face for subgraph retrieval, reducing backtracking in the feature retrieval process due to poor starting face selection and utilizing prior information to reduce the number of subgraph isomorphic comparisons, thereby improving feature recognition efficiency. This is a technical problem that urgently needs to be solved by those skilled in the art. Summary of the Invention
[0005] To address the technical problems mentioned above, this invention provides a processing feature recognition method and system based on starting face classification and optimization. By verifying the starting face according to the adjacency topology, the feature type can be directly determined, reducing the process of retrieving subgraphs from the attribute adjacency graph for subgraph isomorphism and effectively improving the efficiency of feature recognition.
[0006] To achieve the above objectives, the present invention adopts the following technical solution:
[0007] The first aspect of the present invention provides a processing feature recognition method based on starting face classification, comprising:
[0008] Analyze the topological relationships of the faces and edges of solid parts;
[0009] For any two faces sharing a common edge, calculate the angle between the two faces at the common edge based on the tangent direction vector of the common edge and the normal vectors of the two faces at the common edge, and determine the concavity or convexity of the edge based on the angle.
[0010] Based on the topological relationship between the face and edge of the part and the concave and convex properties of the edge, an adjacency graph of the part attributes is constructed with the face as the node and the edge as the connecting arc.
[0011] Remove all edges with convex attributes from the adjacency graph of the part attributes to obtain a set of concave subgraphs;
[0012] For each concave subgraph in the set of concave subgraphs, the face with the most adjacent faces is selected as the starting face, and the starting face is subjected to feature starting face optimization and verification to determine the feature type of each starting face;
[0013] For the starting face that passes the verification, extract the feature face according to the feature type.
[0014] Furthermore, the specific method for calculating the included angle between the two faces at the common edge is as follows:
[0015] Calculate the normal plane of the first and second faces at the midpoint of the common edge, the tangent direction vector of the common edge, and the normal vectors of the two faces at the common edge;
[0016] Calculate the intersection lines of the first and second faces with the normal plane, respectively;
[0017] Take the quarter points of the two intersecting lines that are close to the midpoint of the common edge as reference points for calculating the normals of the first and second faces;
[0018] At the two quarter points, calculate the normal vectors of the first and second faces respectively;
[0019] Based on the positional relationship between the first face and the common edge, the cross product vectors on the first and second faces are obtained;
[0020] Based on the cross product vectors of the first and second faces, the angle between the two faces at the common edge is calculated. Furthermore, it also includes traversing the feature faces and creating feature nodes on the feature tree.
[0021] Furthermore, it also includes: for the starting face that fails the verification, performing isomorphic comparison between its corresponding concave subgraph and the predefined feature subgraph to determine the feature type, and creating feature nodes on the feature tree.
[0022] Furthermore, the steps for optimizing and verifying the starting surface of the groove feature are as follows:
[0023] Step 60101: Obtain the set of adjacent edges of the outer ring of the starting face;
[0024] Step 60102: Initialize the concave edge counter;
[0025] Step 60103: Traverse the set of adjacent edges starting from the first concave edge;
[0026] Step 60104: Take one edge from the adjacent edge set in order and query the concavity / convexity property of the taken edge;
[0027] Step 60105: If the side that is taken out is a concave side, then increment the concave side counter by 1;
[0028] Step 60106: Repeat steps 60103 to 60105 until all edges in the adjacent edge set have been traversed. Based on the concave edge counter and the total number of edges in the adjacent edge set, determine whether the starting face is the starting face of a through slot, a semi-open through slot, a crescent-shaped slot, or a closed slot. If so, return that the verification passed; otherwise, return that the verification failed.
[0029] Furthermore, the steps for optimizing and verifying the starting surface of the hole feature are as follows:
[0030] Step 60201: If the starting surface is not a cylinder or cone, return to the verification failure; otherwise, proceed to step 60202.
[0031] Step 60202: If the normal vector of the starting face is in the same direction as the base face, return that the verification failed; otherwise, proceed to step 60203.
[0032] Step 60203: Obtain the set of adjacent edges of the starting face;
[0033] Step 60204: Take any edge from the set of adjacent edges and query the concavity / convexity properties of the edge;
[0034] Step 60205: If the edge is concave, proceed to step 60206;
[0035] Step 60206: If the edge is located on the outer ring of the starting face, proceed to step 60208; otherwise, proceed to step 60207.
[0036] Step 60207: Repeat steps 60204 to 60206 until all edges in the adjacent edge set have been traversed;
[0037] Step 60208: Obtain the opposite side of the starting face relative to the edge;
[0038] Step 60209: If the type of the opposite face is not the same as the starting face, return that the validation failed; otherwise, proceed to step 60210.
[0039] Step 60210: If the radius of the opposite face is the same as that of the starting face, return "Verification failed"; otherwise, determine whether the hole is a round hole or a conical hole, and return "Verification passed".
[0040] Furthermore, the steps for optimizing and verifying the starting surface of the outer circle feature are as follows:
[0041] Step 60301: If the starting surface is not a cylinder or cone, return to the verification failure; otherwise, proceed to step 60302.
[0042] Step 60302: If the normal vector of the starting face is opposite to that of the base face, return that the verification failed; otherwise, proceed to step 60303.
[0043] Step 60303: Obtain the set of adjacent edges of the starting face;
[0044] Step 60304: Take any edge from the set of adjacent edges and query the concavity / convexity properties of the edge;
[0045] Step 60305: If the edge is concave, proceed to step 60306;
[0046] Step 60306: If the edge is located on the outer ring of the starting face, proceed to step 60308; otherwise, proceed to step 60307.
[0047] Step 60307: Repeat steps 60304 to 60306 until all edges in the adjacent edge set have been traversed;
[0048] Step 60308: Obtain the opposite side of the starting face relative to the edge;
[0049] Step 60309: If the type of the opposite face is not the same as the starting face, return that the verification failed; otherwise, proceed to step 60310.
[0050] Step 60310: If the radius of the opposite face is the same as that of the starting face, determine whether the starting face is a cylindrical face or an external conical face, and return that the verification passed; otherwise, return that the verification failed.
[0051] Furthermore, the steps for performing the initial face selection verification of planar features are as follows: if the initial face is a plane, the verification is returned as passed; otherwise, the verification is returned as failed.
[0052] A second aspect of the present invention provides a processing feature recognition system based on starting face classification, comprising:
[0053] The parsing module is configured to parse the topological relationships of the face edges of solid parts;
[0054] The concavity / convexity attribute determination module is configured to: for any two faces sharing a common edge, calculate the angle between the two faces at the common edge based on the tangent direction vector of the common edge and the normal vectors of the two faces at the common edge, and determine the concavity / convexity attribute of the edge based on the angle.
[0055] The adjacency graph construction module is configured to: construct a part attribute adjacency graph based on the face-edge topology relationship and the concavity / convexity attribute of the edge, with faces as nodes and edges as connecting arcs;
[0056] The concave subgraph construction module is configured to: remove all edges with convex attributes from the part attribute adjacency graph to obtain a set of concave subgraphs;
[0057] The verification module is configured to: for each concave subgraph in the set of concave subgraphs, select the face with the most adjacent faces as the starting face, and perform feature starting face optimization verification on the starting face to determine the feature type of each starting face;
[0058] The feature surface extraction module is configured to extract feature surfaces from the validated starting surfaces based on the feature type.
[0059] A third aspect of the present invention provides a computer-readable storage medium having a computer program stored thereon, which, when executed by a processor, implements the steps of the processing feature recognition method based on starting face classification as described above.
[0060] A fourth aspect of the present invention provides a computer device including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor executes the program to implement the steps of a processing feature recognition method based on starting face classification as described above.
[0061] Compared with the prior art, the beneficial effects of the present invention are:
[0062] This invention provides a processing feature recognition method based on starting face classification. For most predefined feature types, the feature type can be directly determined by verifying the starting face according to the adjacency topology relationship. This reduces the process of retrieving subgraphs from the attribute adjacency graph and performing subgraph isomorphism, effectively improving the efficiency of feature recognition.
[0063] This invention provides a processing feature recognition method based on the classification and optimization of the starting face. It classifies and optimizes the starting face according to the feature type, which improves the degree of conformity of the starting face to the geometric features of different feature types and avoids the redefinition of the starting face due to improper selection of the starting face.
[0064] This invention provides a processing feature recognition method based on the classification and selection of starting faces. Since it adopts the starting face selected according to feature type, for the starting face of the groove type sub-graph, a semi-automatic groove circumferential array recognition method based on the starting face can be applied in the automatic feature recognition process to directly extract the groove circumferential array features.
[0065] This invention provides a processing feature recognition method based on the classification and optimization of the starting face. The method used to calculate the concavity and convexity of the common edge of the two sides of the part optimizes the reference point on which the normal calculation of the two sides near the common edge depends, improves the accuracy of the normal calculation near the common edge, has universality, and can be used to calculate the concavity and convexity of the common edge of the surface of common types of parts. Attached Figure Description
[0066] The accompanying drawings, which form part of this invention, are used to provide a further understanding of the invention. The illustrative embodiments of the invention and their descriptions are used to explain the invention and do not constitute an improper limitation of the invention.
[0067] Figure 1 This is a flowchart of a processing feature recognition method based on starting face classification optimization according to Embodiment 1 of the present invention;
[0068] Figure 2This is an illustration of the hole system feature recognition effect of a transmission groove wheel part according to Embodiment 1 of the present invention;
[0069] Figure 3 This is a diagram illustrating the effect of groove system feature recognition for a transmission grooved wheel part according to Embodiment 1 of the present invention.
[0070] Figure 4 This is a diagram illustrating the effect of feature recognition on the outer diameter of a transmission grooved wheel part according to Embodiment 1 of the present invention.
[0071] Figure 5(a) is a schematic diagram of the starting face of a three-dimensional part according to Embodiment 1 of the present invention;
[0072] Figure 5(b) is an attribute adjacency diagram of a three-dimensional part according to Embodiment 1 of the present invention and a concave diagram of a groove feature;
[0073] Figure 6 This is a schematic diagram of the four division points M1 and M2 near the midpoint M of the common edge e of two faces F1 and F2 in Embodiment 1 of the present invention;
[0074] Figure 7 This is a schematic diagram of the surface normal when the two surfaces F1 and F2 of Embodiment 1 of the present invention are in a convex relationship and a convex edge is formed at the common edge e of the two surfaces;
[0075] Figure 8 This is a schematic diagram of the normal direction of the concave side surface formed at the common edge e of the two sides in Embodiment 1 of the present invention. Detailed Implementation
[0076] The present invention will be further described below with reference to the accompanying drawings and embodiments.
[0077] It should be noted that the following detailed description is illustrative and intended to provide further explanation of the invention. Unless otherwise specified, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention pertains.
[0078] Example 1
[0079] This embodiment provides a processing feature recognition method based on the initial face classification optimization.
[0080] This embodiment provides a processing feature recognition method based on starting face classification, which can be implemented on a computer using the C / C++ programming language.
[0081] This embodiment provides a processing feature recognition method based on start-face classification and optimization. According to predefined feature adjacency topology relationships, the method classifies, verifies, and optimizes the start faces of initially selected subgraphs. For start faces that meet the classification verification conditions, the minimum adjacent subgraph (concave subgraph) retrieved from the start face or the associated set of minimum adjacent subgraphs is directly extracted as the feature face of the corresponding category. While identifying features, it also merges features with the same feature factors, such as circular array features. For subgraphs that do not meet the feature start-face optimization conditions, they are initially classified as unidentified features. Subsequently, the minimum feature subgraph can be extracted from the untyped start face, and its feature type is determined through subgraph isomorphism. Because this technical solution classifies and optimizes start faces according to feature type, it improves the degree of conformity of start faces to geometric features of different feature types, avoids the redefinition of start faces due to improper selection, and for most predefined feature types, the feature type can be directly determined by verifying the start face according to the adjacency topology relationship. This reduces the process of retrieving subgraphs from the attribute adjacency graph and performing subgraph isomorphism, effectively improving the efficiency of feature recognition. In particular, since this scheme adopts the starting face selected according to feature type, for the starting face of the slot type sub-graph, the slot circumferential array semi-automatic recognition method based on the starting face can be applied in the automatic feature recognition process to directly extract the slot circumferential array features.
[0082] This embodiment provides a machining feature recognition method based on start face classification and optimization. It obtains a part attribute adjacency graph based on the part's face-edge relationship and the concavity / convexity calculation results of the common edge of two faces. By deleting edges with convex attributes, it obtains a series of concave subgraph sets (MAAG). Then, it performs start face classification and optimization on the concave subgraphs. For start faces that pass the classification and optimization, the concave subgraph or associated array subgraph (presenting a linear array or circular array of concave subgraphs) is directly extracted as feature faces. For concave subgraphs that fail to pass the classification and optimization and cannot be optimized to identify a specific type of start face, feature recognition can continue through subgraph isomorphic matching.
[0083] This embodiment provides a processing feature recognition method based on starting face classification and optimization, such as... Figure 1 As shown, it includes:
[0084] Step 1: For solid part S, use SVMAN-M to parse the topological relationship of the Brep face and edge of part S to obtain the set of faces and edges of part S; for example, Figure 5(a) shows the 10 faces of a part.
[0085] Step 2: For any two faces with a common edge, based on the direction vector of the common edge and the normal information of the two adjacent faces in the local area near the common edge (i.e., the normal vectors of the two faces at the common edge), calculate the angle between the two faces at the common edge and the concavity and convexity information of the edge in turn.
[0086] Step 3: Based on the topological relationship between the face and edge of the part and the concavity and convexity properties of the edge, construct the attribute adjacency graph AAG of the part with the face as the node and the edge as the connecting arc; for example, the left side of Figure 5(b) shows the attribute adjacency graph of a part.
[0087] Step 4: Remove all edges with convex attributes from the AAG to obtain the concave subgraph set MAAG = {MAAG} i}, i = 1, 2, ..., m, MAAG i Let m represent the i-th concave subgraph, and m be the number of concave subgraphs; for example, the right side of Figure 5(b) is a concave subgraph.
[0088] Step 5: Extract a concave subgraph from MAAG. i Iterate through its constituent faces in turn, and take the face with the most adjacent faces as the initial value CGF of the starting face. i (If there are multiple faces with the most adjacent faces, then any one of them is chosen as the initial value of the starting face); for example, the right side of Figure 5(a) is a starting face;
[0089] Step 6: In the minimum attribute adjacency graph MAAG of the part i In the middle, for the initial value CGF of the starting surface i The starting surfaces of features such as grooves (systems), holes (systems), outer circles, and planes are optimized and verified, and the CGF is determined. i The feature type, and CGF i The corresponding feature type record, and CGF i Add the set of all start faces that have been determined to be of the same type to MAAG_A; for example, the start face on the right side of Figure 5(a) can be determined to be a groove feature through verification, that is, the start face of the groove (system) feature;
[0090] Step 7: If the starting face cannot be selected (or CGF) i If the feature type cannot be determined, then the subgraph MAAG will be used. i Add to the remaining subgraph set MAAG_B;
[0091] Step 8: Repeat steps 5 to 6 until all subgraphs in MAAG have been traversed, then proceed to step 9;
[0092] Step 9: Using the existing single feature recognition method of SVMAN-M, for all starting surfaces (starting surfaces recorded in MAAG_A) whose feature types have been determined, perform single feature retrieval such as slot, hole, outer circle, and plane in sequence, extract the feature surface set corresponding to each starting surface, add it to the identified feature surface set FeatureSrf, and mark the identified surfaces.
[0093] Taking Figures 5(a) and 5(b) as examples, surface 2 is the starting surface of a groove feature, and surfaces 1, 2, and 3 are the feature surfaces of the groove feature, with the starting surface also being a feature surface of the groove. In this embodiment, the term "feature surface" usually refers to a single surface, while a set of feature surfaces is a collection of multiple feature surfaces. For example, the set consisting of surfaces 1, 2, and 3 is called a groove feature, which is the feature corresponding to surface 2 as the starting surface.
[0094] Step 10: Traverse the feature surface set corresponding to each element (features identified based on the starting face) in FeatureSrf, and create feature nodes sequentially on the feature tree;
[0095] Step 11: For the concave subgraphs in the remaining subgraph set MAAG_B, they can be temporarily listed as feature nodes of unidentified features on the feature tree. Later, the feature type can be determined by isomorphic comparison between the concave subgraphs in MAAG_B and the user-predefined feature subgraphs, and then specific feature class nodes (nodes of the corresponding feature type) can be created.
[0096] Step 12: Output the final feature tree (feature node tree) based on the interface of the SVMAN-M process management class, and the algorithm ends.
[0097] In step 2, for any two faces sharing a common edge, based on the local normal information of the two faces at the common edge (i.e., the normal vectors of the two faces at the common edge), the included angle and concavity / convexity information of the two faces at the common edge are calculated sequentially, such as... Figure 6 , Figure 7 and Figure 8 As shown, the specific algorithm steps are as follows:
[0098] Step 201: Calculate the normal plane F of the first face F1 and the second face F2 at the midpoint M of the common edge e. N And the common edge tangent direction vector is V n The normal vectors of the two faces at the common edge are N1 and N2;
[0099] Step 202: Calculate the relationship between surface F1 and surface F2 and the normal plane F1. N The intersection lines e1 and e2;
[0100] Step 203: Take the midpoints M1 and M2 of the two intersecting lines e1 and e2, which are close to the midpoint M of the common edge e, as reference points for calculating the normals of surfaces F1 and F2.
[0101] Step 204: Calculate the normal vector N of surfaces F1 and F2 at points M1 and M2 respectively. s1 and N s2 ;
[0102] Step 205: If face F1 is to the left of the common edge e, then there is a cross product vector V on face F1. s1 =Ns1 ×V n There is a V on face F2 s2 =N s2 ×(-V n );
[0103] Step 206: If face F1 is to the right of the common edge e, then there is a cross product vector V on face F1. s1 =N s1 ×(-V n ), there is a V on face F2 s2 =N s2 ×V n ;
[0104] Step 207: Calculate the vector angle, that is, the angle formed by the two faces at the common edge:
[0105]
[0106] Step 208: Determine the type of the two surfaces. If at least one of the two surfaces is a plane, proceed to steps 209 to 211; otherwise, if both surfaces are curved, proceed to steps 212 to 214.
[0107] Step 209, if V s1 If N²≥0, then θ=α, 0<θ<180°, and the side is concave.
[0108] Step 210, if V s1 If N² < 0, then θ = 360° - α, 180° < θ < 360°, and the edge is convex.
[0109] Step 211, Proceed to step 215;
[0110] Step 212, if V s1 ·N2>0 and V s2 If N2>0, meaning both sides are concave, then θ=α, 0<θ<180°, and the edge is concave.
[0111] Step 213, if V s1 ·N2<0 and V s2 If N2 < 0, meaning both sides are convex, then θ = 360° - α, and 180° < θ < 360°, so the edge is convex.
[0112] Step 214, if V s1 ·N2<0 and V s2 ·N2>0, or if V s1 ·N2>0 and V s2 If N2 < 0, meaning one of the two surfaces is convex and the other is concave, then we define θ = α, where 180° < θ < 360°, and the edge is concave.
[0113] Step 215, Algorithm ends.
[0114] In step 6, in the minimum attribute adjacency graph MAAG of the part... i In the middle, for the initial value CGF of the starting surface i The algorithm steps for performing the initial surface optimization and verification of slot (system) features are as follows:
[0115] Step 60101: Obtain CGF i The set of all adjacent edges of the outer ring is CGEd = {Ed} j}, j = 1, 2, ..., k;
[0116] Step 60102: Initialize the concave edge counter Num = 0;
[0117] Step 60103: Take out the first concave edge, and start traversing CGEd from the first concave edge, keeping the rest in the same order;
[0118] Step 60104: Take one side of Ed from CGEd in sequence. j And query Ed j The raised / recessed attribute flag;
[0119] Step 60105: If Flag == 1, i.e., Ed j When the edge is concave, Num = Num + 1;
[0120] Step 60106: Repeat steps 60103 to 60105 until all edges in CGEd have been traversed, then proceed to step 60107.
[0121] Step 60107: If Num equals 2, the total number of edges in the adjacent edge set is 4, and the concave edges are on the 1st and 3rd edges, then the starting face is the starting face of the through groove, proceed to step 60112; if not satisfied, proceed to step 60108.
[0122] Step 60108: If Num equals 3 and the total number of edges in the adjacent edge set is 4, it indicates that the starting face is a semi-open slot starting face, and proceed to step 60112; otherwise, proceed to step 60109.
[0123] Step 60109: If Num+2 = the total number of edges k in CGEd, and the total number of edges in the adjacent edge set is 4 or 6, and the convex edge is in the cycle (CGF) i If the sequence number in the outer ring (or set CGEd) differs by 1 or 2, it indicates that the starting face is a crescent-shaped groove starting face, and proceed to step 60112; otherwise, proceed to step 60110.
[0124] Step 60110: If Num equals the total number of edges k in CGEd, then the starting face is the starting face of the closed slot, proceed to step 60112; otherwise, proceed to step 60111.
[0125] Step 60111: If the judgment conditions in steps 60107 to 60110 are all false, then proceed to step 60113.
[0126] Step 60112: Return the verification pass information and return the feature type of the starting face as slot, then the algorithm ends;
[0127] Step 60113: Return the verification failure message, and the algorithm ends.
[0128] In step 6, in the minimum attribute adjacency graph MAAG of the part... i In the middle, for the initial value CGF of the candidate starting surface i The algorithm steps for verifying the starting surface of the hole feature are as follows:
[0129] Step 60201, if CGF i If it is not a cylinder or cone, skip directly to step 60211; otherwise, proceed to step 60202.
[0130] Step 60202, if CGF i If the normal vector is in the same direction as the base surface (i.e., the outer cylindrical cone surface), skip directly to step 60211; otherwise, proceed to step 60203.
[0131] Step 60203: Obtain CGF i The set of all adjacent edges CGEd = {Ed j}, j = 1, 2, ..., k;
[0132] Step 60204: Take any side Ed from CGEd. j And query edge Ed j The raised / recessed attribute flag;
[0133] Step 60205: If Flag == 1, that is, edge Ed j If the edge is concave, proceed to step 60206;
[0134] Step 60206, if edge Ed j Located in CGF i If it is on the outer ring, proceed to step 60208; otherwise, proceed to step 60207.
[0135] Step 60207: Repeat steps 60204 to 60206 until all edges in CGEd have been traversed, then proceed to step 60211;
[0136] Step 60208: Obtain surface CGFi Relative to edge Ed j F opposite nb ;
[0137] Step 60209, if face F nb The type is not the same as CGF i Same, that is, does not satisfy the condition of surface CGF i If the surface is either a cylinder or a cone, proceed directly to step 60211; otherwise, proceed to step 60210.
[0138] Step 60210, if F nb With CGF i If the radii are the same, proceed to step 60212; otherwise, proceed to step 60211.
[0139] Step 60211: Verification failed, algorithm ends;
[0140] Step 60212, if CGF i If the surface is cylindrical, the hole is a circular hole; otherwise, the hole is a conical hole. The algorithm returns a successful check and ends.
[0141] In step 6, in the minimum attribute adjacency graph MAAG of the part... i In the middle, for the initial value CGF of the starting surface i The algorithm steps for verifying the starting surface of the outer circle feature are as follows:
[0142] Step 60301, if CGF i If it is not a cylinder or cone, skip directly to step 60311; otherwise, proceed to step 60302.
[0143] Step 60302, if CGF i If the normal vector is opposite to the base surface (i.e., the inner cylindrical surface), skip directly to step 60311; otherwise, proceed to step 60303.
[0144] Step 60303: Obtain CGF i The set of all adjacent edges CGEd = {Ed j}, j = 1, 2, ..., k;
[0145] Step 60304: Take any side Ed from CGEd. j And query edge Ed j The raised / recessed attribute flag;
[0146] Step 60305: If Flag == 1, that is, edge Ed j If the edge is concave, proceed to step 60306;
[0147] Step 60306, if edge Ed j Located in CGFi If it is on the outer ring, proceed to step 60308; otherwise, proceed to step 60307.
[0148] Step 60307: Repeat steps 60304 to 60306 until all edges in CGEd have been traversed, then proceed to step 60311;
[0149] Step 60308: Obtain surface CGF i Relative to edge Ed j F opposite nb ;
[0150] Step 60309, if face F nb The type is not the same as CGF i Same, that is, does not satisfy the condition of surface CGF i If the surface is either a cylinder or a cone, proceed directly to step 60311; otherwise, proceed to step 60310.
[0151] Step 60310, if F nb With CGF i If the radii are the same, proceed to step 60312; otherwise, proceed to step 60311.
[0152] Step 60311: Verification failed, algorithm ends;
[0153] Step 60312, if CGF i If it is a cylindrical surface, then it is an outer cylindrical surface; otherwise, it is an outer conical surface.
[0154] Step 60313: Verification passed, algorithm ends.
[0155] In step 6, in the minimum attribute adjacency graph MAAG of the part... i In the middle, for the initial value CGF of the starting surface i The method for performing planar feature start surface verification is as follows: If CGF i If the type is planar, then it can be considered CGF. i This is the starting face of the plane.
[0156] In step 9, when identifying the slot based on the SVMAN-M single feature recognition mechanism, the specific steps are as follows:
[0157] Step 90101: Prepare for slot identification by retrieving a slot start surface (slot (system) feature start surface) SCF from the set of start surfaces whose types have been determined (SlotC). ii ;
[0158] Step 90102, if SCF ii If the surface is already identified and marked, skip to step 90106.
[0159] Step 90103, if SCF ii If it is an unidentified surface, then apply SCF. ii The SVMAN-M single-slot feature recognition algorithm is used to obtain the feature surface set Feature1 for SCF. ii The groove system feature surface set Feature2 is obtained by using the groove circumferential array feature recognition algorithm; where groove system refers to multiple groove features of the same shape that satisfy the circumferential array condition.
[0160] Step 90104: If sizeof(Feature2) = k * sizeof(Feature1), k ≥ 3, then the feature is a groove system, and the feature surface set is CGFeature. ii =Feature2; conversely, the feature set CGFeature ii =Feature1; where sizeof() is a memory capacity measurement function;
[0161] Step 90105: Collect CGfeatures ii The faces in the feature set are marked as identified and added to the identified feature face set FeatureSrf←CGFeature ii ;
[0162] Step 90106: Repeat steps 90101 to 90105 until all starting faces in Slot C have been marked;
[0163] Step 90107: Return the current FeatureSrf, and the algorithm ends.
[0164] In step 9, when identifying features such as holes (systems), outer circles, and planes based on the SVMAN-M single feature recognition mechanism, the specific steps are as follows:
[0165] Step 90201: For the set of starting faces C whose types have been determined, prepare for feature recognition by extracting a starting face CF whose features have been determined. jj ;
[0166] Step 90202, if CF jj If it is an unidentified surface, then for CF jj By directly applying features such as SVMAN-M holes (systems), outer circles, and planes, the feature surface set CGFeature is extracted. ii ;
[0167] Step 90203: Collect CGFeature ii The faces in the feature set are marked as identified and added to the identified feature face set FeatureSrf←CGFeature ii;
[0168] Step 90204: Repeat steps 90201 to 90203 until all starting faces in C have been marked;
[0169] Step 90205: Return the current FeatureSrf, and the algorithm ends.
[0170] Feature recognition results are as follows Figure 2 , Figure 3 , Figure 4 As shown, in each image, the left side is the feature tree, and the right side is the highlight effect after clicking on the corresponding feature node in the feature tree. Figure 2 , Figure 3 , Figure 4 These are highlighted effects for hole systems, groove systems, and outer circle features, respectively.
[0171] This embodiment provides a machining feature recognition method based on the initial surface classification and optimization, and provides a method for automatic recognition of part machining features based on the domestically developed and controllable three-dimensional machining process planning and design software system SVMAN-M.
[0172] This embodiment provides a processing feature recognition method based on the classification and optimization of the starting face. By classifying and optimizing the starting face according to the feature type, the degree of conformity of the starting face to the geometric features of different feature types is improved, and the redefinition of the starting face due to improper selection of the starting face is avoided.
[0173] This embodiment provides a processing feature recognition method based on the classification and optimization of the starting face. For most predefined feature types, the feature type can be directly determined by verifying the starting face according to the adjacency topology relationship. This reduces the process of retrieving subgraphs from the attribute adjacency graph and performing subgraph isomorphism, effectively improving the efficiency of feature recognition.
[0174] This embodiment provides a processing feature recognition method based on the classification and selection of the starting face. Since the starting face is selected according to the feature type, for the starting face of the groove type sub-graph, the semi-automatic recognition method of groove circumferential array based on the starting face can be applied in the automatic feature recognition process to directly extract the groove circumferential array features.
[0175] This embodiment provides a processing feature recognition method based on the classification and optimization of the starting face. The method used is a method for calculating the concavity and convexity of the common edge of two sides of a part. It optimizes the reference point on which the normal calculation of the two sides near the common edge depends, improves the accuracy of the normal calculation near the common edge, and has universality. It can be used to calculate the concavity and convexity of the common edge of the surface of common types of parts.
[0176] Example 2
[0177] This embodiment provides a processing feature recognition system based on starting face classification and optimization, which specifically includes:
[0178] The parsing module is configured to parse the topological relationships of the face edges of solid parts;
[0179] The concavity / convexity attribute determination module is configured to: for any two faces sharing a common edge, calculate the angle between the two faces at the common edge based on the tangent direction vector of the common edge and the normal vectors of the two faces at the common edge, and determine the concavity / convexity attribute of the edge based on the angle.
[0180] The adjacency graph construction module is configured to: construct a part attribute adjacency graph based on the face-edge topology relationship and the concavity / convexity attribute of the edge, with faces as nodes and edges as connecting arcs;
[0181] The concave subgraph construction module is configured to: remove all edges with convex attributes from the part attribute adjacency graph to obtain a set of concave subgraphs;
[0182] The verification module is configured to: for each concave subgraph in the set of concave subgraphs, select the face with the most adjacent faces as the starting face, and perform feature starting face optimization verification on the starting face to determine the feature type of each starting face;
[0183] The feature surface extraction module is configured to extract feature surfaces from the validated starting surfaces based on the feature type.
[0184] It should be noted that each module in this embodiment corresponds one-to-one with each step in Embodiment 1, and their specific implementation processes are the same, so they will not be repeated here.
[0185] Example 3
[0186] This embodiment provides a computer-readable storage medium storing a computer program that, when executed by a processor, implements the steps in the processing feature recognition method based on start face classification optimization as described in Embodiment 1 above.
[0187] Example 4
[0188] This embodiment provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the program, it implements the steps in the processing feature recognition method based on starting face classification as described in Embodiment 1 above.
[0189] Those skilled in the art will understand that embodiments of the present invention can be provided as methods, systems, or computer program products. Therefore, the present invention can take the form of hardware embodiments, software embodiments, or embodiments combining software and hardware aspects. Furthermore, the present invention can take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage and optical storage) containing computer-usable program code.
[0190] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, generate instructions for implementing the flowchart illustrations and / or block diagrams. Figure 1 One or more processes and / or boxes Figure 1 A device that provides the functions specified in one or more boxes.
[0191] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means, which are implemented in a process Figure 1 One or more processes and / or boxes Figure 1 The function specified in one or more boxes.
[0192] These computer program instructions may also be loaded onto a computer or other programmable data processing equipment to cause a series of operational steps to be performed on the computer or other programmable equipment to produce a computer-implemented process, thereby providing instructions that execute on the computer or other programmable equipment for implementing the process. Figure 1 One or more processes and / or boxes Figure 1 The steps of the function specified in one or more boxes.
[0193] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. The storage medium can be a magnetic disk, optical disk, read-only memory (ROM), or random access memory (RAM), etc.
[0194] The above description is merely a preferred embodiment of the present invention and is not intended to limit the invention. Various modifications and variations can be made to the present invention by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of the present invention should be included within the scope of protection of the present invention.
Claims
1. A processing feature recognition method based on starting face classification and optimization, characterized in that, include: The topological relationships of the face and edge of a solid part are analyzed, with the analysis of the Brep face and edge topological relationships based on SVMAN-M. For any two faces sharing a common edge, calculate the angle between the two faces at the common edge based on the tangent direction vector of the common edge and the normal vectors of the two faces at the common edge, and determine the concavity or convexity of the edge based on the angle. Based on the topological relationship between the face and edge of the part and the concave and convex properties of the edge, an adjacency graph of the part attributes is constructed with the face as the node and the edge as the connecting arc. Remove all edges with convex attributes from the adjacency graph of the part attributes to obtain a set of concave subgraphs; For each concave subgraph in the set of concave subgraphs, the face with the most adjacent faces is selected as the starting face. In the concave subgraph, the starting face is selected and verified according to the adjacency topology relationship to determine the feature type of each starting face. Feature types include slots, holes, outer circles, and planes; For the starting face that passes the verification, extract the feature face according to the feature type; For a starting face that meets the classification verification conditions, directly extract the concave subgraph or the associated set of concave subgraphs retrieved from the starting face as the feature face of the corresponding category; It also includes: traversing the feature surface and creating feature nodes on the feature tree; Alternatively, it may also include: for a starting face that fails the verification, performing an isomorphic comparison between its corresponding concave subgraph and a predefined feature subgraph to determine the feature type, and creating a feature node on the feature tree.
2. The processing feature recognition method based on starting face classification as described in claim 1, characterized in that, The specific method for calculating the included angle between two faces at their common edge is as follows: Calculate the first face The normal plane of the second face at the midpoint of the common edge, the tangent direction vector of the common edge, and the normal vectors of the two faces at the common edge; Calculate the intersection lines of the first and second faces with the normal plane, respectively; Take the quarter points of the two intersecting lines that are close to the midpoint of the common edge as reference points for calculating the normals of the first and second faces; At the two quarter points, calculate the normal vectors of the first and second faces respectively; Based on the positional relationship between the first face and the common edge, the cross product vectors on the first and second faces are obtained; Based on the cross product vectors on the first and second faces, the angle between the two faces at the common edge is calculated.
3. The processing feature recognition method based on starting face classification as described in claim 1, characterized in that, The steps for performing the initial surface optimization and verification of the slot feature are as follows: Step 60101: Obtain the set of adjacent edges of the outer ring of the starting face; Step 60102: Initialize the concave edge counter; Step 60103: Traverse the set of adjacent edges starting from the first concave edge; Step 60104: Take one edge from the adjacent edge set in order and query the concavity / convexity property of the taken edge; Step 60105: If the side that is taken out is a concave side, then increment the concave side counter by 1; Step 60106: Repeat steps 60103 to 60105 until all edges in the adjacent edge set have been traversed. Based on the concave edge counter and the total number of edges in the adjacent edge set, determine whether the starting face is the starting face of a through slot, a semi-open through slot, a crescent-shaped slot, or a closed slot. If so, return that the verification passed; otherwise, return that the verification failed.
4. The processing feature recognition method based on starting face classification as described in claim 1, characterized in that, The steps for performing the optimal selection and verification of the hole feature starting surface are as follows: Step 60201: If the starting surface is not a cylinder or cone, return to the verification failure; otherwise, proceed to step 60202. Step 60202: If the normal vector of the starting face is in the same direction as the base face, return that the verification failed; otherwise, proceed to step 60203. Step 60203: Obtain the set of adjacent edges of the starting face; Step 60204: Take any edge from the set of adjacent edges and query the concavity / convexity properties of the edge; Step 60205: If the edge is concave, proceed to step 60206; Step 60206: If the edge is located on the outer ring of the starting face, proceed to step 60208; otherwise, proceed to step 60207. Step 60207: Repeat steps 60204 to 60206 until all edges in the adjacent edge set have been traversed; Step 60208: Obtain the opposite side of the starting face relative to the edge; Step 60209: If the type of the opposite face is not the same as the starting face, return that the validation failed; otherwise, proceed to step 60210. Step 60210: If the radius of the opposite face is the same as that of the starting face, return "Verification failed"; otherwise, determine whether the hole is a round hole or a conical hole, and return "Verification passed".
5. The processing feature recognition method based on starting face classification as described in claim 1, characterized in that, The steps for optimizing and verifying the starting surface of the outer circle feature are as follows: Step 60301: If the starting surface is not a cylinder or cone, return to the verification failure; otherwise, proceed to step 60302. Step 60302: If the normal vector of the starting face is opposite to that of the base face, return that the verification failed; otherwise, proceed to step 60303. Step 60303: Obtain the set of adjacent edges of the starting face; Step 60304: Take any edge from the set of adjacent edges and query the concavity / convexity properties of the edge; Step 60305: If the edge is concave, proceed to step 60306; Step 60306: If the edge is located on the outer ring of the starting face, proceed to step 60308; otherwise, proceed to step 60307. Step 60307: Repeat steps 60304 to 60306 until all edges in the adjacent edge set have been traversed; Step 60308: Obtain the opposite side of the starting face relative to the edge; Step 60309: If the type of the opposite face is not the same as the starting face, return that the verification failed; otherwise, proceed to step 60310. Step 60310: If the radius of the opposite face is the same as that of the starting face, determine whether the starting face is a cylindrical face or an external conical face, and return that the verification passed; otherwise, return that the verification failed.
6. The processing feature recognition method based on starting face classification as described in claim 1, characterized in that, The steps for performing the initial face selection verification of planar features are as follows: if the initial face is a plane, the verification is returned as passed; otherwise, the verification is returned as failed.
7. A processing feature recognition system based on starting face classification and selection, characterized in that, include: The parsing module is configured to parse the topological relationships of the face edges of solid parts, wherein the parsing of the topological relationships of the Brep face edges of the parts is based on SVMAN-M. The concavity / convexity attribute determination module is configured to: for any two faces sharing a common edge, calculate the angle between the two faces at the common edge based on the tangent direction vector of the common edge and the normal vectors of the two faces at the common edge, and determine the concavity / convexity attribute of the edge based on the angle. The adjacency graph construction module is configured to: construct a part attribute adjacency graph based on the face-edge topology relationship and the concavity / convexity attribute of the edge, with faces as nodes and edges as connecting arcs; The concave subgraph construction module is configured to: remove all edges with convex attributes from the part attribute adjacency graph to obtain a set of concave subgraphs; The verification module is configured to: for each concave subgraph in the set of concave subgraphs, select the face with the most adjacent faces as the starting face, and perform feature starting face optimization verification on the starting face according to the adjacency topology relationship in the concave subgraph to determine the feature type of each starting face; Feature types include slots, holes, outer circles, and planes; The feature surface extraction module is configured to: extract feature surfaces based on feature type for the start surface that has passed the verification; and directly extract the concave subgraphs or associated concave subgraph sets retrieved from the start surface as the feature surface of the corresponding category for the start surface that meets the classification verification conditions. The system also performs the following steps: Traverse the feature surfaces and create feature nodes on the feature tree; Alternatively, for a starting face that fails the verification, its corresponding concave subgraph is isomorphically compared with a predefined feature subgraph to determine the feature type, and feature nodes are created on the feature tree.
8. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the program is executed by the processor, it implements the steps in the preferred processing feature recognition method based on starting face classification as described in any one of claims 1-6.
9. A computer device, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the program, it implements the steps in the processing feature recognition method based on starting face classification as described in any one of claims 1-6.
Citation Information
Patent Citations
Processing feature recognition and information extraction method for MBD model
CN110795797A
Semi-automatic identification method and system for groove circumference array features
CN115049617A