Hierarchical B-Rep graph code



This dataset is code/script is for generating hierarchical B-Rep graphs of B-Rep CAD models, and generating batches for inputting into the Hierarchical CADNet neural network; as published in the paper: "Hierarchical CADNet: Learning from B-Reps for Machining Feature Recognition". Note this code also is based on chapter 4 of the connected thesis: "Deep learning for boundary representation CAD models".

To create the hierarchical B-Rep graphs, the geometry of the B-Rep CAD models (stored as STEP files) are described by discretising the surface of the CAD model into a mesh. This mesh can then be treated as a graph and operated on by a graph neural network. The overall topology of the CAD model can be described by the face adjacency matrix. A hierarchical graph structure can be constructed by between the B-Rep adjacency graph and the mesh. A STL mesh was chosen as the tessellation method due to its wide availability in CAD system and offers a concise representation. Each facet in the mesh denotes a vertex in a level of the hierarchical graph. Each of these vertices contain information of the facet’s planar equation, used to describe the surface. A second level of the hierarchical graph denotes the B-Rep adjacency graph. There exists persistent links between each B-Rep face vertex and their corresponding STL facet vertex. A B-Rep face vertex can have more than one STL facets adjacent to it. The goal of the approach is to be able to classify the machining feature of each B-Rep face vertex in the graph.
Date made availableMay 2022
PublisherQueen's University Belfast
Date of data production2020

Cite this