Retrieval of local topological similarity in b-rep model
The method addresses inefficiencies in B-rep model similarity retrieval by using topological signatures to automatically identify and select similar parts within CAD models, enhancing design and manufacturing processes.
Patent Information
- Application Number
- JP2025066784
- Authority / Receiving Office
- JP · JP
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-04-15
- Filing Date
- 2025-04-15
- Publication Date
- 2025-10-27
AI Technical Summary
Existing systems lack an efficient method for local topological similarity retrieval in B-rep models, which are crucial for CAD applications, leading to inefficiencies in design and manufacturing processes.
A computer-implemented method for searching local topological similarities in B-rep models by representing B-rep elements with topological signatures, determining isomorphic subgraphs, and filtering based on signature closeness, allowing for automatic identification of similar parts within a B-rep model.
The method enhances ergonomics and efficiency in CAD design by automatically identifying and selecting topologically similar parts, reducing user interaction and improving response time while maintaining CPU efficiency.
Smart Images

Figure 2025162547000001_ABST
Abstract
Description
[Technical Field]
[0001] The present disclosure relates to the field of computer programs and systems, and more particularly to methods, systems, and programs relating to local topological similarity searching in B-rep models. [Background technology]
[0002] Several systems and programs are on the market for designing, engineering, and manufacturing objects. CAD is an acronym for Computer-Aided Design, which refers, for example, to software solutions for designing objects. CAE is an acronym for Computer-Aided Engineering, which refers, for example, to software solutions for simulating the physical behavior of future products. CAM is an acronym for Computer-Aided Manufacturing, which refers, for example, to software solutions for defining manufacturing processes and operations. In the above computer-aided design systems, the graphical user interface plays a key role in the efficiency of the techniques. The techniques just mentioned can be embedded within product lifecycle management (PLM) systems. PLM refers to a business strategy that helps companies share product data, apply common processes, and leverage enterprise knowledge for product development from conception to the end of product life, across the extended enterprise concept. PLM solutions offered by Dassault Systèmes (under the trademarks CATIA, ENOVIA, and DELMIA) provide an "Engineering Hub" that organizes product engineering knowledge, a "Manufacturing Hub" that manages manufacturing engineering knowledge, and an "Enterprise Hub" that enables enterprise integration and connectivity to both the Engineering Hub and the Manufacturing Hub. Together, the systems provide an open object model that connects products, processes, and resources to enable dynamic, knowledge-based product creation and decision support that drives optimized product definition, manufacturing preparation, production, and service.
[0003] Within the context just described, there is a need for an improved solution for local topological similarity retrieval in B-rep models. Summary of the Invention
[0004] Therefore, a computer-implemented method is provided for searching for local topological similarities in a B-rep model. The B-rep model is represented by a given B-rep graph. Each node of the given B-rep graph represents a B-rep element and is associated with the element's topological signature. The method includes obtaining a query B-rep graph. Each node of the query B-rep graph represents a B-rep element and is associated with the element's topological signature. The method further includes determining one or more subgraphs of the given B-rep graph. Each determined subgraph is isomorphic to the query B-rep graph. Determining the one or more subgraphs includes searching for subgraphs isomorphic to the query B-rep graph. Determining the one or more subgraphs further includes filtering the subgraph isomorphisms to the query B-rep graph. The filtering is based on the closeness of the topological signature with respect to the query B-rep graph.
[0005] The method may include one or more of the following: determining the one or more subgraphs includes iterating: Given a subgraph of a query B-rep graph, where the subgraph results from a previous iteration, adding the nodes of the query B-rep graph to the subgraph; and determining all subgraphs of a given B-rep graph that have already been determined as isomorphic and similar, according to the closeness of their topological signatures with the subgraph of the query B-rep graph that remains isomorphic to the subgraph of the query B-rep graph due to the previous iteration, when adding a node corresponding to a node added to the subgraph of the query B-rep graph, and such that the determined subgraph remains similar to the subgraph of the query graph according to the closeness of their topological signatures when adding the node; determining for all said subgraphs includes selecting a subgraph in which the added node has a topological signature closeness to the corresponding node added to the query, relative to the subgraph determined to remain isomorphic to the subgraph of the query B-rep graph when adding the node; Two nodes have topological signature closeness if the similarity score between the two topological signatures is greater than a predefined threshold; - topological signatures are vectors and similarity scores are similarity scores between vectors, - The similarity score is the cosine similarity or other distance between the vectors. the method further includes, for each subgraph of the one or more subgraphs resulting from determining: Computing a graph similarity score that quantifies the similarity between the subgraph and the query B-rep graph based on the topological signatures of the elements; the method further comprises: ranking one or more subgraphs according to the computed graph similarity scores; clustering one or more subgraphs according to the computed graph similarity scores; o Discarding one or more subgraphs whose graph similarity score is below a predefined threshold, and / or Selecting one or more subgraphs whose graph similarity score is greater than a predefined threshold, and / or -The graph similarity score between two B-rep graphs is the average of the respective vector similarities between the topological signatures of two corresponding nodes in the two graphs, or ○ The smallest vector similarity among the vector similarities between the topological signatures of two corresponding nodes in the two graphs.
[0006] There is further provided a computer program comprising instructions for carrying out the method.
[0007] There is also provided a computer readable recording medium having a computer program recorded thereon.
[0008] A computer system is further provided that includes a processor coupled to a memory, the memory storing a computer program.
[0009] Non-limiting examples will now be described with reference to the accompanying drawings. [Brief explanation of the drawings]
[0010] [Figure 1] FIG. [Figure 2] FIG. [Figure 3] FIG. [Figure 4] FIG. [Figure 5] FIG. [Figure 6] FIG. [Figure 7] FIG. [Figure 8] FIG. [Figure 9] FIG. [Figure 10] FIG. [Figure 11] An example of a system is shown. DETAILED DESCRIPTION OF THE INVENTION
[0011] A computer-implemented method for searching for local topological similarities in a B-rep model is proposed. The B-rep model is represented by a given B-rep graph. Each node of the given B-rep graph represents a B-rep element and is associated with the element's topological signature. The method includes obtaining a query B-rep graph. Each node of the query B-rep graph represents a B-rep element and is associated with the element's topological signature. The method further includes determining one or more subgraphs of the given B-rep graph. Each determined subgraph is isomorphic to the query B-rep graph. Determining the one or more subgraphs includes searching for subgraphs isomorphic to the query B-rep graph. Determining the one or more subgraphs further includes filtering the subgraph isomorphisms to the query B-rep graph. The filtering is based on the closeness of the topological signature with respect to the query B-rep graph.
[0012] The method constitutes an improved solution for the search of local topological similarities in B-rep models.
[0013] In fact, the query B-rep graph is a B-rep graph of B-reps (which can be called "query B-reps") and thus represents a set of B-rep elements, or in other words, a set of connected B-rep faces separated by B-rep edges, forming a machine part, or only a portion of a machine part, e.g., a given mechanical feature. The method searches for a subgraph of the B-rep graph that is isomorphic to the just-mentioned query B-rep graph. This means that the method finds a subgraph representing a portion of a B-rep (specifically, a portion of a B-rep represented by a given B-rep graph that represents a portion of the machine part represented by the B-rep) that has the same face and edge configuration as the query B-rep graph. Hence, the just-mentioned subgraph already has topological similarity with the query B-rep graph. However, the method further filters the just-mentioned subgraph based on the closeness of their topological signatures. Each B-rep element, whether one of the query B-rep graphs or one of the given B-rep graphs, is actually associated with a topological signature (e.g., a vector) that describes its topology and geometry. Hence, filtering based on topological signature closeness means that subgraphs found to be isomorphic with respect to the query B-rep graph are filtered based on the closeness of their topological signatures in the query B-rep graph. Filtering can be based on the topological signatures of the received elements one by one, i.e., filtering is based on an element-by-element comparison between the topological signatures of the elements of the subgraphs and the topological signatures of the corresponding elements in the query B-rep graph. Alternatively, filtering can be based on a comparison of the overall scores or averages of the topological signatures between the subgraphs and the query B-rep graph. In any case, the comparison and filtering just described makes it possible to filter out (discard) subgraphs that are not sufficiently topologically similar to the query B-rep graph due to a lack of closeness in their topological signatures.What has just been described makes it possible to determine subgraphs of a given B-rep graph that have sufficient topological similarity with the query B-rep graph, and thus to find parts in a given B-rep that represent parts of the machine component represented by the given B-rep that are topologically similar to the parts represented by the input query B-rep graph. Moreover, the level of topological signature closeness in filtering can be controlled (automatically or by a user) to receive more or fewer subgraphs in filtering, for example through the use of topological signature closeness threshold(s).
[0014] A query B-rep graph may be a subgraph of a given B-rep graph and thus represent a subpart of the machine part represented by the given B-rep graph. A user may graphically select a corresponding portion of a given B-rep, which may then be displayed and provided as input to the method. Thus, the method allows a user to graphically select a portion of a B-rep and return to the user other portions of the B-rep that are topologically similar to the selected portion. The other portions and the selected portion represent the same or topologically similar portions of the machine part represented by the B-rep. The currently mentioned portions may be, for example, the same or topologically similar cylinders in a B-rep representing a wheel (an example of which is provided later in this specification). Thus, the method allows a user to graphically select a portion of a B-rep and automatically provide the user with topologically similar or identical portions. This saves user interaction for the task of selecting these parts, since only one part, corresponding to the part or, for example, a single click / touch or a few clicks / touches on the face, needs to be selected by the user, and other parts are automatically searched for and selected by the computer system. Thus, the method improves ergonomics for selecting similar parts of a (e.g., displayed) B-rep model. The method also provides interactivity, since the user may control the similarity threshold used for evaluating local topological similarity (as described later in this specification). Furthermore, the method is CPU-efficient, building on neighbor-aware topological signatures that allow the problem to be significantly alleviated by performing pairwise node comparisons between the query graph and the search graph and simplifying the latter by removing nodes that are not likely to be candidates (i.e., dissimilar to any of the query nodes). Thus, the system is responsive and provides the user with prompt (e.g., immediate) feedback.Moreover, the method may return the determined subgraphs along with bijections between them and the query, allowing interpretability for the solution.
[0015] The method may be included in the design and / or manufacturing process of a mechanical part represented by a given B-rep. The process may include: - Providing a given B-rep, for example as a result of an initial design process; - A user graphically selects a portion of a given B-rep to be displayed, the portion being represented by the input query B-rep graph; - automatically searching for parts of the B-rep that are topologically similar or identical to the selected part (for example, all cylinders of the same / similar size, positioning, proximity and diameter in a B-rep representing a wheel) by implementing a method; - optionally displaying all (searched and selected) parts to the user, for example by displaying the B-rep model and graphically highlighting the searched parts; - Defining design operations that will be applied by the user to all parts, for example, in the case of a wheel, defining a new diameter for a cylinder, representing the location of a screw or bolt, allowing the use of a larger thread / bolt for improved robustness; - the system automatically applies design operations to all parts in a uniform manner (e.g. automatically setting the diameter of all cylinders according to the new diameter defined); Optionally, using a modified B-rep to manufacture the part represented by the just-mentioned B-rep may include: o Converting the B-rep or its B-rep graph or its corresponding feature tree into manufacturing instructions that set up and / or control the manufacturing process, for example by converting the B-rep into a CAM (Computer Aided Manufacturing) file; and / or o storing the manufacturing instructions (e.g. as CAM files) and / or transmitting them to the manufacturing plant and / or to the appropriate manufacturing machines; and / or o Manufacturing machine parts (e.g., based on a manufacturing order).
[0016] The method is for searching for local topological similarities in a B-rep model. What has just been said means that the method, given an input B-rep, identifies one or more B-rep portions of another B-rep that are topologically similar to the input B-rep. Specifically, the input B-rep, also called a query B-rep, is the B-rep represented by the query B-rep graph, and the identified B-rep portions are the portions of the B-rep represented by the given B-rep graph that are represented by the determined subgraph(s).
[0017] "B-rep," also known as "B-Rep," stands for "Boundary Representation." B-rep is the most common type of modeling in CAD applications. It is a mathematically precise representation of a 3D object. This representation defines a solid as a collection of connected surface elements that define the boundary between interior and exterior points. B-rep contains two types of information: topological components and the geometric definition of those components. Topological components include the vertices, edges, and faces that define the surface of the 3D object, as well as the connectivity between them. In addition to connectivity, topological information also includes the orientation of edges and faces, while geometric information typically consists of mathematical equations that describe the vertices, edges, and faces (points, curves, and surfaces, respectively).
[0018] As used herein, any B-rep (i.e., boundary representation) is a 3D representation of a mechanical part. Specifically, a B-rep is a persistent data representation that describes a 3D modeled object that represents the mechanical part. A B-rep can be the result of a calculation and / or a series of operations performed during the design phase of a 3D modeled object that represents the mechanical part. The shape of the mechanical part that is displayed on a computer screen when representing the modeled object is (e.g., a tessellation of the B-rep). In an example, a B-rep represents a portion of a model object.
[0019] B-Rep contains topological and geometric entities. Topological entities are faces, edges, and vertices. Geometric entities are 3D objects such as surfaces, planes, curves, lines, and points. By definition, a face is the boundary of a surface, called a supporting surface. An edge is the boundary of a curve, called a supporting curve. A vertex is a point in 3D space. They are related to each other as follows: The boundary of a curve is defined by two points (vertices) on the curve. The boundary of a surface is defined by its boundary, which is the set of edges on the surface. The boundaries of edges of a face are connected by sharing a vertex. Faces are connected by sharing an edge. Two faces are adjacent if they share an edge. Similarly, two edges are adjacent if they share a vertex. In a CAD system, B-Rep collects the "bounded by" relationship, the relationship between topological entities and supporting geometry, and the mathematical description of the supporting geometry in an appropriate data structure. An interior edge of a B-Rep is exactly an edge shared by two faces. By definition, boundary edges are not shared and touch only one face. By definition, a boundary face is bounded by at least one boundary edge. A B-Rep is said to be closed if all of its edges are interior edges. A B-Rep is said to be open if it contains at least one boundary edge. Closed B-Reps are used to model 3D volumes with thickness, since they define the interior portion of a material that (virtually) encloses a space. Open B-Reps are used to model 3D skins, which represent 3D objects that are small enough that their thickness can be ignored.
[0020] A key advantage of B-rep over other representation types used in CAD modeling is its ability to accurately represent any shape. All other representations used—for example, point clouds, distance fields, and meshes—approximate the shape they represent through discretization. B-rep, on the other hand, contains surface equations that represent the exact design and therefore constitute a true “master model” for further manufacturing, whether that be generating toolpaths for CNC or discretizing to the correct sample density for a given 3D printer technology. In other words, by using B-rep, the 3D model can be an accurate representation of the object to be manufactured. Furthermore, B-rep is advantageous for simulating the behavior of the 3D model. It supports local refinement of the simulation mesh to capture physical phenomena for stress, thermal, electromagnetic, or other analyses, and can support true contact modeling between curved surfaces in kinematics. Finally, B-Rep allows for a small memory and / or file footprint. First, the representation contains surfaces based solely on parameters. In other representations, such as meshes, the equivalent surface contains up to several thousand triangles. Second, B-rep does not contain any historical information.
[0021] In this specification, in addition to vertices, faces, and edges, each B-rep also contains co-edges. Co-edges are directed edges, i.e., edges of a B-rep that have additional direction information. Co-edges thereby define the ordering around the faces of a B-Rep and the adjacency of the faces, i.e., the topology of a B-rep. Co-edges fully link B-rep entities. Each co-edge has one parent face (i.e., the face that defines the boundary), one parent edge (i.e., by definition, a co-edge is an directed edge and therefore has a parent edge), one co-edge that is a co-edge with the same parent edge, one next co-edge corresponding to the next co-edge in the loop to which the co-edge belongs, and one previous co-edge corresponding to the previous co-edge in the loop to which the co-edge belongs. Each co-edge maintains adjacency relationships with the next and previous co-edges around the parent face, the paired co-edges of adjacent faces, the parent face, and the parent edge.
[0022] Every B-rep is represented herein by a B-rep graph. A B-rep graph herein is a graph representation of each B-rep, including graph nodes and graph edges. Each graph node represents each edge, each face, or each co-edge of each B-rep. This means that there is a graph node for each edge of the B-rep, a graph node for each face of the B-rep, and a graph node for each co-edge of the B-rep. Each graph node further includes a topological signature associated with (i.e., attached to) the graph node. The topological signature of a B-rep element can be any data, e.g., a vector, that captures the topology of the B-rep element. Furthermore, the signature may capture the geometry of the B-rep element and / or data about its neighborhood (i.e., neighboring elements). Thus, the topological signature captures the local topology corresponding to the B-rep element and is sometimes referred to as the element's "local topological signature." The local topological signature may be a local topological signature output by a local Deep CAD neural network trained according to claim 1 of European patent application EP23306709.9 filed by DASSAULT SYSTEMES, or according to any dependent claim of claim 1 of European patent application EP23306709.9, or according to any embodiment or implementation of the training method disclosed in European patent application EP23306709.9, the contents of which are incorporated herein by reference.For any B-rep graph herein, e.g., a query B-rep graph or a given B-rep graph, the method may optionally include an initial step of applying to each node of the B-rep graph the just-described local Deep CAD neural network trained according to the training method of European Patent Application EP23306709.9, thereby outputting for each node a local topological signature that forms a topological signature associated with the node.
[0023] The B-rep graph also includes graph edges. Each respective graph edge connects two respective graph nodes, a respective first node and a respective second node. The first graph nodes represent respective co-edges. The second graph nodes represent one of the following: - the face associated with each co-edge (i.e. the parent face of the co-edge, i.e. the face that defines the boundary), - edges (i.e., co-edge parent edges), - adjacent coedges (i.e., the next or previous coedge, i.e., the next or previous coedge in the loop to which the coedge belongs), or - Pairs of co-edges (i.e., co-edges with the same parent edge).
[0024] A given B-rep graph is an input for the method. It represents a given B-rep model, which represents a machine part. Each node of the given B-rep graph represents an element of the just mentioned B-rep and is associated with the element's topological signature. The method may include an initial step of providing the given B-rep and / or -rep graph, for example by retrieval (e.g., downloading) from a (e.g., distant) memory, server, database, or cloud, or by designing the B-rep and B-rep graph.
[0025] The method includes obtaining a query B-rep graph. The query B-rep graph may be a subgraph of a given B-rep graph and therefore may represent a portion of a given B-rep. Alternatively, the query B-rep graph may be a B-rep graph of another B-rep, or a B-rep graph of a portion of another B-rep. As for any B-rep graph herein, each node of the query B-rep graph represents a B-rep element and is associated with the element's topological signature.
[0026] Providing a query B-rep graph may be performed as follows: First, displaying a B-rep, either the given B-rep or another B-rep. Next, a user selects a set of B-rep elements, e.g., a set of faces, in the displayed B-rep. This may be performed by graphical user interaction. For example, a user may select graphical elements one by one by clicking or touching each element. A computer system performing the method may then automatically infer a B-rep graph corresponding to the user selection by extracting it from the B-rep graph of the displayed B-rep. For example, the computer may infer as the query graph a subgraph including the nodes of all faces selected by the user and the nodes of all other B-rep elements (e.g., edges) belonging to at least one of the faces.
[0027] In addition to providing a query B-rep graph, the method further includes determining one or more subgraphs (subgraphs) of the given B-rep graph. Each determined subgraph is isomorphic to the query B-rep graph. In this disclosure, two graphs are isomorphic if there is a bijection between the nodes, and if the bijection satisfies the following: for every pair of nodes in the first graph connected by an edge, the image (by the bijection) of the two nodes in the second graph is also connected by an edge, and vice versa. A first node in the first graph corresponds to a second node in the second graph if it is the image of the second node by the above bijection.
[0028] Determining one or more subgraphs includes searching for subgraph isomorphisms (i.e., of a given B-rep graph) to the query B-rep graph. This may be done in any suitable manner, for example, by using breadth first search. Furthermore, determining also includes filtering subgraph isomorphisms to the query B-rep graph. Filtering is based on the closeness of the topological signature with respect to the query B-rep graph. Filtering subgraphs means discarding / filtering at least some of the subgraphs found to be isomorphic to the query B-rep. Specifically, the just-mentioned subgraph is discarded based on the closeness of its topological signature with the query B-rep graph, i.e., either because one or more nodes in the query B-rep graph and the topological signatures of the corresponding node(s) each have inconsistent / insufficiently similar topological signatures, or because the signatures of the nodes in the subgraph and the signatures of the nodes in the query graph, as a whole, have too significant inconsistencies / and insufficient similarity.
[0029] Determining one or more subgraphs of a given B-rep graph may involve iteration.
[0030] Each iteration is given a subgraph of the query B-rep graph, where the subgraph resulted from the previous iteration, and involves adding a node of the query B-rep graph to the subgraph. In the first iteration, the subgraph resulting from the previous iteration is the initial subgraph (i.e., it does not itself result from the previous iteration, but results from initialization). The initial subgraph may be an empty set, in which case adding a node of the query B-rep graph consists of adding (e.g., randomly) every node of the query B-rep graph to the empty set, and the single node may form a subgraph of the B-rep query graph resulting from the first iteration. In each iteration, as of the second iteration, the subgraph of the query B-rep graph resulting from the previous iteration contains at least one node, and adding a node of the query B-rep graph may consist of adding (e.g., randomly) every node of the query B-rep graph that is not already included in the subgraph resulting from the previous iteration.
[0031] Each iteration then involves determining all subgraphs of the given B-rep graph that have already been determined as isomorphic and similar, according to the closeness of their topological signatures with the subgraph of the query B-rep graph that resulted from the previous iteration and that remain isomorphic to the subgraph of the query B-rep graph when adding a node corresponding to the node added to the subgraph of the query B-rep graph, and such that the determined subgraph remains similar to the subgraph of the query graph according to the closeness of their topological signatures when adding the node. In other words, at each iteration, as of the second iteration, there is a subgraph of the given B-rep graph that resulted from the previous iteration and that 1) is isomorphic to the subgraph of the query B-rep graph that resulted from the previous iteration, and 2) is similar to the just-mentioned subgraph according to the closeness of their topological signatures. The determination consists in determining each subgraph from among the just-mentioned subgraphs that, when adding a node corresponding to a node added to the query graph, 1) remains isomorphic to the subgraph of the query B-rep graph resulting from the previous iteration and remains isomorphic to the subgraph of the query B-rep graph to which the node was added, and 2) remains similar to this subgraph according to the closeness of their topological signatures.What we just said consists in determining, for each subgraph that was isomorphic and topologically similar to the query subgraph in the previous iteration, whether there exists a node(s) of the given B-rep graph to add to the subgraph such that the isomorphism and the closeness of the topological signatures are maintained with the subgraph of the query graph resulting from the previous iteration.
[0032] Determining all such subgraphs may include selecting subgraphs in which the added node and the corresponding node added to the query have topological signature closeness for subgraphs determined to remain isomorphic to the subgraph of the query B-rep graph when adding a node. The topological closeness between two nodes may be defined as follows: two nodes have topological signature closeness if the similarity score between the two topological signatures is greater than a predefined threshold: The predefined threshold just mentioned may be 0.5 or greater, for example 0.6 or greater, for example 0.7 or greater, for example 0.8 or greater, for example equal to 1, where 0 means minimal similarity and 1 means maximal similarity. The threshold may be set and unchangeable. Alternatively, the threshold may be changeable, for example set by a user (e.g., in an early stage of the method). The topological signatures may be vectors, as mentioned above, and the similarity score in this case may be a similarity score between the vectors, for example cosine similarity.
[0033] The method may further include calculating a graph similarity score for each of the one or more subgraphs resulting from determining (i.e., determining subgraphs of the given B-rep graph that are isomorphic and topologically similar to the query). The graph similarity score quantifies the similarity (i.e., topological similarity) between the subgraph and the query B-rep graph based on the topological signatures of their elements. The graph similarity score between two B-rep graphs may be the average (e.g., L1 mean, L2 mean, geometric mean) of the vector similarities (e.g., cosine similarities) between the topological signatures of corresponding nodes in the two graphs, respectively. Alternatively, the graph similarity score between two B-rep graphs may be the minimum vector similarity among the vector similarities between the topological signatures of corresponding nodes in the two graphs, respectively.
[0034] The method may further include one or more of the following: - ranking one or more subgraphs according to the calculated graph similarity scores, e.g., in descending order of scores; - clustering the one or more subgraphs according to the computed graph similarity scores; - discarding one or more subgraphs whose graph similarity score is below a predefined threshold (which may, for example, be set at an early stage of the method); and / or - Select one or more subgraphs whose graph similarity score is greater than a predefined threshold (which may be set, for example, at an early stage of the method).
[0035] The implementation of this method will now be described.
[0036] In the implementation just described, the inputs to the method are: - given a Face-B-rep graph (i.e., a B-rep graph in which every node represents a face) of a 3D CAD object (B-rep), where each node of the graph has a topological signature such that two nodes have similar signatures if and only if two associated faces are topologically similar; and A query that is a subgraph of a given B-rep graph (or of another B-rep graph). Furthermore, the faces of a query also have a topological signature.
[0037] Figure 1 illustrates the input where the query graph (captioned "query" in the figure) is a subgraph of the given B-rep graph (illustrated by the caption "Full 3D model").
[0038] The goal is to find a list of graphs that are isomorphic to the query. Figure 2 illustrates the output (the detected isomorphic graphs).
[0039] It is worth noting that the implementation uses only the faces of B-rep objects, i.e., it focuses on the B-rep graph of faces. However, everything works equally well if more feature types are taken into account, such as face and edge features, or loops.
[0040] definition Let G be the graph of the CAD model. V(G) is a list of nodes from G ●E(G) is the list of edges from G ●For all demonstrations, V(G) n ={p∈P(V(G)),|p|=n}, where P is the power set operator ●f,G∈V(G) 2 for which e(f,g) is the edge between f and g ●G and H are the same type
[0041]
number
[0042] and satisfy the following ∀(f,g)∈G,e(f,g)∈E(G)⇔e(φ(f),φ(g))∈E(H) ●G' is a subgraph of G if and only if ○∃n∈N,∃q∈V(G) n |q=V(G'), we write G'=G[q].
[0043] ○∀(f1,f2)∈G' 2 ,e(f1,f2)∈E(G)⇔e(f1,f2)∈E(G') (The usual definition of a subgraph is: (f1,f2)∈G' 2 ,e(f1,f2)∈G⇒e(f1,f2)∈G' But this projection is not useful.) • The number of nodes in a graph is called its length.
[0044] q=(f1,f2, ,f n )∈V(G) n Let be the list of faces from the query in G. G[q] is the query graph.
[0045] Candidate graph: Let G[q'] satisfy the following. G[q']=(f'1,f'2, )⊂V(G) n G subgraph.
[0046]
number
[0047] is a candidate for q if: ●G[q'] and G[q] are isomorphic ●φ is bijective ●∀(f'1,f'2)∈q' 2 ,e(f'1,f'2)∈E(G[q'])⇔e(φ(f'1),φ(f'2))∈E(G[q]) remarks: There can be multiple isomorphisms for the same subgraph G[q'], hence there are different candidates (G[q'],φ1) ≠ (G[q'],φ2) ⇔ φ1 ≠ φ2.
[0048] Semicandidate graph: Let G[q'] satisfy the following. q'=(f'1,f'2, )∈V(G) m A subgraph of G
[0049]
number
[0050] is a semi-candidate graph of q if: G[q'] is an isomorphism to a subgraph of G[q] named H ●
[0051]
number
[0052] is bijective ●∀(f'1,f'2)∈q' 2 ,e(f'1,f'2)∈E(G[q'])⇔e(φ(f'1),φ(f'2))∈E(H) remarks:
[0053]
number
[0054] φ=φ' is injective.
[0055] Theorem 1: G[q'] is q'=(f'1,f'2, )∈V(G) m a subgraph of G, and
[0056]
number
[0057] If (G[q'],φ) satisfies the above, then (G[q'],φ) is a semi-candidate graph of q. When m=n, (G[q'],φ) is the semi-candidate graph of q.
[0058] Proof: Let H⊆G[q] be an isomorphism to G[q'] by φ such that
[0059]
number
[0060] ●n=m ●φ is an injective function of G[q] ⇒|q'|=|q|=|V(H)| and V(H)⊂q ⇒So, V(H)=q and H=G[q] ⇒Therefore, Im(φ)=V(H)=q=V(G[q]) ⇒
[0061]
number
[0062] is bijective because φ is injective ⇒∀(f'1,f'2)∈q' 2 ,e(f'1,f'2)∈E(G[q'])⇔e(φ(f'1),φ(f'2))∈E(H)=V(G[q]) Therefore, (G[q'],φ) is a candidate graph for q.
[0063] Note : ●The candidate is clearly a semi-candidate. A semicandidate of length i≠n is not a semicandidate because φ satisfies the following:
[0064]
number
[0065] It is not possible for ∂x∂y to be bijective. ●The candidates for a query are exactly semi-candidates of length n.
[0066] Next, implementation algorithms are immediately described that implement the step of determining subgraphs of a given B-rep graph that are isomorphic and topologically similar to the query B-rep graph. First, an algorithm is provided that finds subgraph isomorphisms to a query B-rep graph, and then a modified algorithm is provided that implements the step of determining subgraphs of a given B-rep graph that are isomorphic and topologically similar to the query B-rep graph.
[0067] input G: BRep graph of CAD object q: Query q ⊂ V(G) Initialization
[0068]
number
[0069] root∈q (randomly sampled) algorithm For each unsearched face f∈q, a searched face G[q] with breath first search (BFS) starting from the root, new_semicandidates ←[] For each (path, φ)∈semicandidates,
[0070]
number
[0071] When (G|[V(path)∪{f'}],φ') is a semi-candidate graph, new_semicandidates ← new_semicandidates+(G[V(path)∪{f'}],φ') semicandidates ← new_semicandidates output A list of all candidate graphs The algorithm gives all candidate graphs that are isomorphic to the query.
[0072] Proof completion The algorithm terminates because each loop has looped over a finite set. success G[q] is q=(f1,f2, )∈V(G). n Let the query satisfy Let's go as follows. H i : "In loop turn i, the semicandidates contain exactly all the semicandidates of G, (G',φ) is
[0073]
number
[0074] is loop invariant. We are H i Prove that is true for ∀i∈[[0,n]]. i=0 A semi-candidate is one empty semi-candidate
[0075]
number
[0076] Includes. An empty semicandidate is just a semicandidate of length 0. Therefore, H0 is true. Let i∈[[0,n-1]], and H i Assume that is true. We are H i+1 Prove that. f j Let be called the face from q that is handled during the j-th loop. q i ={f1, ,f i )∈V(G) i and q i+1 ={f1, ,f fi+1} ∈V(G) i+1 Further afield, q i+1 =q i ∪{φ -1 (f i+1 )}∀(G',φ)∈semicandidates After one loop, new_semicandidates is
[0077]
number
[0078] It contains only (G',φ) that satisfies ●Let (P,φ) be a semi-candidate of length i+1,
[0079]
number
[0080] Far away. ●∃q' i+1 ∈V[G] i+1 |P=G[q' i+1 ]
[0081]
number
[0082] ●
[0083]
number
[0084] is the associated bijection |∀e(f,g)∈G,e(f,g)∈E(G[q' i+1 ])⇔e(φ(f),φ(g))∈E(G[q i+1 ]) ●q' i =q' i+1 -{φ -1 (f i+1 )} Far away.
[0085]
number
[0086] remains bijective, and {f,g}∈G[q' i ]⇔e(φ| q’i (f),φ| q’i (g))∈G[q i ]. (q i ⊂q i+1 and q' i ⊂q' i+1 ) ⇒
[0087]
number
[0088] ⇒By assumption (G[q' i ],φ|q' i ) is among the candidates in loop i. During loop i+1, The algorithm is (G[q' i ],φ| q’i ) and surface φ -1 (f i+1 ) and Detect the next G[q' i+1 ]=G[q' i ∪{φ -1 (f' i+1 )}]
[0089]
number
[0090] So, (G[q' i+1 ]=P,φ), is added to new_semicandidates. So new_semicandidates contains all isomorphisms of G' and semicandidates. So, the semi-candidate has a G at the end of the loop. r Includes all isomorphisms of and semi-candidates. So, H i+1 is true. By regression, for ∀i∈[[0,n]], H i is true Therefore, H n is true. At the end of the algorithm, the semi-candidate
[0091]
number
[0092] Contains all semicandidates(P,φ) with By Theorem 1, we obtain all candidates (P,φ) for the query.
[0093] Note : It is entirely possible that the same graph has several possible bijections, in which case they will all be computed.
[0094] Once all candidates are obtained, this may involve filtering to extract the most similar ones. To do so, the following scores are used:
[0095] Scoring Let (G[q'],φ) be a candidate graph for G[q].
[0096]
number
[0097] R d Let be a function that maps each face of G to a similar signature. Sim:(R d ) 2
[0098]
number
[0099] Let be the similarity function. We define two scores as follows:
[0100]
number
[0101] The method is as follows: ∞ If ((G[q'],φ))≧threshold is satisfied, a filter may be applied to the results.
[0102] To do so, the implementation includes the just-described filter for the construction algorithm, which is compiled as follows (the just-described compilation is an algorithm that performs the determination of subgraphs that are isomorphic and topologically similar to the query B-rep graph):
[0103] input G: BRep graph of CAD object q: Query q ⊂ V(G) threshold: the minimum allowed similarity score Initialization
[0104]
number
[0105] root ∈ q (sampled randomly) algorithm For each unexplored face f ∈ q, for the explored G[q] having a BFS (breath first search) starting from root new_semicandidates ← [] For each (path, φ) ∈ semicandidates
[0106] [Number]
[0107] When (G|[V(path) ∪ {f’}], φ’) is a semicandicate graph When sim(φ(f), φ(f')) ≥ threshold new_semicandidates ← new_semicandidates + (G[V(path)] ∪ {f’}), φ r ) semicandidates ← new_semicandidates output List of all candidate graphs ∀(G[q ‘ , φ) ∈ semicandidates, S ∞ ((G[q’], φ)) ≥ threshold.
[0108] Note ● The proof containing the candidate remains the same ● To prove that the conditions described above are equivalent to filtering by score, if the candidate (P, φ) does not exist in the second algorithm. It is equivalent to the existence of the face f. It is equivalent to the existence of a face f satisfying Sim(f', φ(f')) < threshold, and thus ∞
[0109] [Number]
[0110] • The modifications just mentioned will significantly speed up the computation time by choosing a threshold higher than 0.5.
[0111] The method may include ranking the obtained candidates, for example using the S1 score to obtain the most similar ones.
[0112] Examples of results obtained by the method will now be given.
[0113] In a first example, a user selects a two-sided cylinder in a B-rep model of a wheel. Figure 3 is an example B-rep where a two-sided cylinder 30 is selected. The query B-rep graph is therefore a subgraph of the wheel B-rep graph corresponding to these two sides. Figure 4 shows all two-sided cylinders (some exemplified by 40) for which the B-rep graph was identified as a topologically similar subgraph of the wheel B-rep graph that is isomorphic to the query B-rep graph of the input cylinder 30. Figure 4 also shows the similarity score S ∞ Only cylinders in the subgraph with ≥ 0.995 are displayed.
[0114] In a second example, as illustrated in Figure 5, a four-sided vein 50 is selected by the user in the same wheel B-rep. The query B-rep graph is therefore a subgraph of the wheel B-rep graph corresponding to these four veins. Figure 6 shows all four-sided veins (some illustrated by numeral 60) for the B-rep whose B-rep graph has been identified as a topologically similar subgraph of the wheel B-rep graph that is isomorphic to the query B-rep graph of input vein 50. Small and large veins are identified as illustrated in Figure 6. The table below shows the S of queries for these different veins. ∞ Score and S1 score are shown.
[0115] [Table 1]
[0116] In a third example, the fin surface in the heat B-rep model is selected by the user (the fin is indicated by reference numeral 70), as shown in Figure 7. Figure 8 shows the results depending on the similarity score threshold selected in the algorithm (the filtering step of the method).
[0117] In the fourth example, a face of B-rep subpart 90 is selected, as shown in Figure 9. Subpart 100 has a similarity score S of 0.924, as shown in Figure 10. ∞ and a similarity score S1 of 0.971. Subpart 102 has a similarity score S1 of 0.528. ∞ and a similarity score S1 of 0.883, and therefore may not be identified by the method since it has a similarity score that is too small.
[0118] The method is computer-implemented. What is meant by this is that the steps (or substantially all steps) of the method are performed by at least one computer, or any similar system. Thus, the method steps are performed by a computer, possibly fully automatically or semi-automatically. In an example, triggering of at least some of the method steps may occur through user-computer interaction. The level of user-computer interaction required depends on the expected level of automation and may be balanced against the need to implement the user's wishes. In an example, the level just mentioned may be user-defined and / or pre-defined.
[0119] A typical example of a computer implementation of the method is performing the method by a system adapted for the purposes just described. The system may include a processor coupled to a memory and a graphical user interface (GUI), the memory having stored thereon a computer program including instructions for performing the method. Additionally, the memory may store a database. The memory is any hardware adapted for such storage, possibly including several physically distinct parts (e.g., one for the program and possibly one for the database).
[0120] FIG. 11 shows an example of a system in which the system is a client computer system, eg, a user's workstation.
[0121] The example client computer includes a central processing unit (CPU) 1010 coupled to an internal communication bus 1000, and a random access memory (RAM) 1070 further coupled to the bus. Moreover, the client computer is provided with a graphical processing unit (GPU) 1110 associated with a video random access memory 1100 coupled to the bus. The video RAM 1100 is also known to those skilled in the art as a frame buffer. A mass storage device controller 1020 manages access to mass memory devices, such as a hard drive 1030. Mass memory devices suitable for tangibly embodying computer program instructions and data include, by way of example, all forms of non-volatile memory, including, by way of example, semiconductor memory devices such as EPROM, EEPROM, and flash memory devices, magnetic disks, such as internal hard disks and removable disks, and magneto-optical disks. Any of the foregoing may be supplemented by, or incorporated in, specially designed application-specific integrated circuits (ASICs). A network adapter 1050 manages access to a network 1060. Additionally, the client computer may include a haptic device 1090, such as a cursor control device, keyboard, or the like. The cursor control device is used with the client computer to allow a user to selectively place a cursor at any desired location on the display 1080. In addition, the cursor control device allows a user to select various commands and input control signals. The cursor control device includes some signal generating device to input control signals into the system. Typically, the cursor control device is a mouse, and the mouse buttons may be used to generate signals. Alternatively or additionally, the client computer system may include a sensitive pad and / or a sensitive screen.
[0122] A computer program includes computer-executable instructions, and the instructions may include means for causing the system to perform a method. The program may be recordable on any data storage medium, including the system's memory. The program may be implemented, for example, in digital electronic circuitry, or in computer hardware, firmware, software, or a combination thereof. The program may be implemented as an apparatus, for example, as an article of manufacture tangibly embodied in a machine-readable storage device for execution by a programmable processor. The method steps may be performed by a programmable processor by executing a program of instructions that perform the functions of the method by operating on input data and generating output. Thus, the processor may be programmable and coupled to receive data and instructions from, and transmit data and instructions to, a data storage system, at least one input device, and at least one output device. The application program may be implemented in a high-level procedural or object-oriented programming language, or in assembly or machine language, if desired. In any case, the language may be a compiled or interpreted language. The program may be a full installation or update program. The application of a program to a system in any case results in instructions for performing a method. The computer program may alternatively be stored and executed on a server in a cloud computing environment, the server being in communication with one or more clients via a network, in which case the method is performed in the cloud computing environment by a processing unit executing the instructions contained in the program. [Explanation of symbols]
[0123] 30 cylinders 40 cylinders 50 Bane 60 Bane 70 Fin 90 B-rep sub parts 100 subparts 102 Subparts
Claims
1. 1. A computer-implemented method for local topological similarity search in a B-rep model represented by a given B-rep graph, wherein each node of the given B-rep graph represents a B-rep element and is associated with a topological signature of the element, the method comprising: providing a query B-rep graph, each node of said query B-rep graph representing a B-rep element and associated with a topological signature of said element; determining one or more subgraphs of the given B-rep graph, each determined subgraph being isomorphic to the query B-rep graph, and determining the one or more subgraphs includes: searching for subgraphs isomorphic to the query B-rep graph; and filtering the subgraphs that are isomorphic to the query B-rep graph based on the closeness of their topological signatures to the query B-rep graph; Including A method comprising:
2. Determining the one or more subgraphs includes: Given a subgraph of the query B-rep graph, adding the nodes of the query B-rep graph to the subgraph, where the subgraph originates from a previous iteration; and determining all subgraphs of the given B-rep graph that have already been determined as isomorphic and similar, according to the closeness of their topological signatures with the subgraph of the query B-rep graph that remains isomorphic to the subgraph of the query B-rep graph due to the previous iteration, when adding the node corresponding to the node being added to the subgraph of the query B-rep graph, and such that the determined subgraph remains similar to the subgraph of the query graph according to the closeness of their topological signatures when adding the node; 2. The method of claim 1, wherein the iteration of
3. 3. The method of claim 2, wherein determining all subgraphs includes selecting subgraphs for which the added node has a topological signature closeness to the corresponding node added to the query, relative to the subgraphs determined to remain isomorphic to the subgraphs of the query B-rep graph when adding the node.
4. 4. The method of claim 3, wherein two nodes have topological signature closeness if the similarity score between the two topological signatures is greater than a predefined threshold.
5. 5. The method of claim 4, wherein the topological signatures are vectors and the similarity scores are similarity scores between vectors.
6. The method of claim 5 , wherein the similarity score is a cosine similarity.
7. for each subgraph of the one or more subgraphs resulting from said determining: - computing a graph similarity score that quantifies the similarity between the subgraph and the query B-rep graph based on the topological signatures of the elements; 7. The method of claim 1, further comprising:
8. - ranking said one or more subgraphs according to the calculated graph similarity scores; clustering said one or more subgraphs according to the computed graph similarity scores; discarding one or more subgraphs whose graph similarity score is below a predefined threshold; and / or selecting one or more subgraphs whose graph similarity score is greater than a predefined threshold; The method of claim 7 further comprising:
9. The graph similarity score between two B-rep graphs is: the average of the similarities of each of said vectors between the topological signatures of two corresponding nodes in said two graphs, or the smallest vector similarity among the vector similarities between the topological signatures for two corresponding nodes in the two graphs; The method according to claim 7 or 8, wherein
10. A computer program comprising instructions which, when executed by a computer system, cause the computer to perform the method of any one of claims 1 to 9.
11. A computer-readable data recording medium having the computer program according to claim 10 recorded thereon.
12. 11. A computer comprising a processor coupled to a memory, the memory having the computer program of claim 10 stored thereon.