Self-supervised Graph Neural Network for Mechanical CAD Retrieval

Yuhan Quan, Huan Zhao, Jinfeng Yi, Yuqiang ChenarXiv 2024 · DOI

Abstract

GC-CAD is a novel self-supervised framework designed to retrieve similar 3D mechanical parts from massive databases without the need for expensive, manually labeled training data. By representing Computer-Aided Design (CAD) models as graphs and utilizing contrastive learning, the system achieves state-of-the-art accuracy while operating up to 100 times faster than traditional heuristic methods. This approach bridges the gap between computationally heavy geometric descriptors and label-intensive supervised deep learning models.

Introduction

In the mechanical industry, reusing existing CAD parts can save millions of euros in production and storage costs. However, locating specific parts within databases containing millions of files is a significant challenge. Traditional text-based searches are inadequate for describing complex 3D geometries, and existing technical solutions have major drawbacks. Heuristic methods using graph matching are often computationally prohibitive (NP-hard), while supervised deep learning models require thousands of expert-labeled pairs, making data collection expensive and slow.

The authors address these limitations with GC-CAD (Graph Contrastive learning for CAD), a method that learns directly from raw Boundary Representation (BRep) files using self-supervised learning, effectively eliminating the requirement for human-annotated labels.

Methodology

The GC-CAD pipeline consists of three primary stages: graph construction, structure-aware representation, and a contrastive learning framework.

Graph Construction and Representation

The model converts BRep files into graphs where faces are represented as nodes and curves (the intersections of faces) are represented as edges. This dual representation preserves both the local geometry and the global topology of the mechanical part. To extract features, a Graph Neural Network (GNN) backbone processes "UV-grids"—mathematical representations of surfaces—to generate dense embeddings for every node and edge.

Contrastive Learning Framework

To facilitate training without labels, the model employs data augmentation. It generates two "augmented" versions of a single CAD part's graph by randomly masking specific nodes or edges, effectively "deleting" small features.

The GC-CAD framework: from BRep graph construction to contrastive learning with GNNs.

The model is trained using the NT-Xent loss function. This objective forces the embeddings of two augmented versions of the same part (positive pairs) to be similar while pushing the embeddings of different parts (negative pairs) away from each other in the feature space.

Experiments and Results

The researchers evaluated GC-CAD across several datasets, including private industrial collections (~15,000 parts total), the massive public ABC Dataset (360,000 parts for pre-training), and the JoinABLe Dataset for generalization testing.

Performance and Efficiency

GC-CAD demonstrated a 100x speedup over ReebGraph, a standard heuristic method. While traditional methods required 7–14 days to process queries across the datasets, GC-CAD completed the task in 2–3 hours. In terms of accuracy, GC-CAD achieved a Recall@5 of 51.5% on private datasets, significantly outperforming supervised baselines like BRepNet (40.8%).

Qualitative retrieval results across various mechanical part categories, demonstrating the model's ability to identify geometrically similar components.

Zero-Shot Generalization

A key finding was the model's ability to generalize. When pre-trained on the large-scale ABC dataset, GC-CAD performed remarkably well on the unseen JoinABLe dataset without any fine-tuning. This suggests that large-scale self-supervised pre-training can develop a universal "understanding" of mechanical geometry.

Discussion and Key Insights

The study highlights that contrastive learning (distinguishing between parts) is superior to generative methods for CAD retrieval. While generative tasks often focus on reconstructing local surface details, contrastive learning captures the global "essence" of the shape. Furthermore, the authors found that masking faces or edges is a highly effective augmentation strategy, as it mimics how designers create families of parts by adding or removing small features like holes or flanges.

Conclusion and Future Work

GC-CAD provides a scalable, efficient, and accurate solution for single-part retrieval in industrial settings. However, the authors note that assembly retrieval—finding groups of parts that fit together—remains a challenge. Future research will focus on more sophisticated data augmentation techniques tailored to mechanical properties like symmetry and the development of deeper GNN architectures to handle complex multi-part assemblies.

Summary updated

BibTeX
@misc{quan2024self,
  author = {Yuhan Quan and Huan Zhao and Jinfeng Yi and Yuqiang Chen},
  title = {{Self-supervised Graph Neural Network for Mechanical CAD Retrieval}},
  year = {2024},
  eprint = {2406.08863},
  archivePrefix = {arXiv},
  url = {https://arxiv.org/abs/2406.08863},
}
Figure