BRepA: Graph-Based B-Rep Pretraining for Unified CAD Understanding and Generation
Organizations: Technical University of Munich · Siemens AG · Munich Center for Machine Learning
Abstract
Boundary representation (B-Rep) of CAD models encodes geometric primitives and their relations as a graph structure, enabling efficient shape modeling within CAD software. Learning on B-Reps for downstream tasks, such as segmentation and novel shape generation, requires specialized neural network designs. Moreover, performance improvements and accelerated training can be achieved with effective pretraining strategies, which is particularly important for tasks with limited labeled B-Rep data. In this paper, we introduce BRepA, a unified self-supervised pretraining framework that explicitly reconstructs both the geometry and topology of B-Rep objects via graph-based modeling. By learning from large-scale unlabeled CAD data only once, BRepA produces representations that generalize across tasks and significantly enhance both discriminative and generative learning. On segmentation tasks, BRepA demonstrates remarkable data efficiency. For instance, with only 1% labeled samples, BRepA pretraining improves mIoU by 32.52% compared to models trained from scratch. On generative tasks, aligning diffusion model representations with pretrained BRepA features substantially accelerates convergence, achieving nearly 2 times faster training while improving generation quality under the same computational budget, despite the diffusion model being roughly 20 times larger than BRepA. Overall, our results show that geometry- and topology-aware B-Rep pretraining provides a powerful foundation for both understanding and generating CAD structures, serving as a versatile representation backbone for diverse downstream applications. We will release the code to facilitate future research.
Figures & tables
| Method | 0.10% | 0.20% | 0.50% | 1% | 10% | 20% | 50% | 100% |
|---|---|---|---|---|---|---|---|---|
| UV-Net [ 15 ] | 6.73 | 9.46 | 14.08 | 19.92 | 49.87 | 68.15 | 83.94 | 90.58 |
| UV-Net++ [ 15 ] | 7.89 | 12.17 | 18.43 | 28.06 | 63.85 | 79.24 | 90.91 | 95.88 |
| UV-Net++ [ 15 ] & SDF SSL [ 17 ] | 9.42 | 14.63 | 21.87 | 34.12 | 72.94 | 87.16 | 94.73 | 97.85 |
| BRepA (w/o SSL) | 8.98 | 14.89 | 20.31 | 35.06 | 79.15 | 92.91 | 98.18 | 99.19 |
| BRepA (w/ only geo. MAE) | 14.29 (+5.31) | 20.22 (+5.33) | 36.64 (+16.33) | 63.10 (+28.04) | 88.73 (+9.58) | 95.79 (+2.88) | 98.27 (+0.09) | 99.14 (-0.05) |
| BRepA (ours) | 15.87 (+6.89) | 22.76 (+7.87) | 40.33 (+20.02) | 67.58 (+32.52) | 91.24 (+12.09) | 96.95 (+4.04) | 99.12 (+0.94) | 99.20 (+0.01) |
| Method | 0.10% | 0.20% | 0.50% | 1% | 10% | 20% | 50% | 100% |
|---|---|---|---|---|---|---|---|---|
| UV-Net [ 15 ] | 4.23 | 6.15 | 7.84 | 11.92 | 36.47 | 41.83 | 53.76 | 61.34 |
| UV-Net++ [ 15 ] | 5.87 | 8.24 | 10.93 | 13.68 | 41.12 | 48.35 | 57.64 | 62.85 |
| UV-Net++ [ 15 ] & SDF SSL [ 17 ] | 8.91 | 9.76 | 14.25 | 16.83 | 43.58 | 51.47 | 58.32 | 63.15 |
| BRepA (w/o SSL) | 9.21 | 11.90 | 15.57 | 19.11 | 48.19 | 53.22 | 61.10 | 65.20 |
| BRepA (w/ only geo. MAE) | 14.92 (+5.71) | 18.73 (+6.83) | 23.26 (+7.69) | 25.84 (+6.73) | 52.35 (+4.16) | 55.78 (+2.56) | 61.94 (+0.84) | 66.27 (+1.07) |
| BRepA (ours) | 17.94 (+8.73) | 24.16 (+12.26) | 29.20 (+13.63) | 32.04 (+12.93) | 55.27 (+7.08) | 58.69 (+5.47) | 63.97 (+2.87) | 67.19 (+1.99) |
| Dataset | Model | 1-NNA ( ) | COV ( ) | MMD ( ) |
|---|---|---|---|---|
| MFCAD | BrepDiff | 0.574 | 0.469 | 0.038 |
| BrepDiff † | 0.541 | 0.500 | 0.037 | |
| Fusion 360 | BrepDiff | 0.577 | 0.486 | 0.026 |
| BrepDiff † | 0.542 | 0.510 | 0.025 |
| Model | Params | 0.50% | 1% | 10% |
|---|---|---|---|---|
| BRepA | 13.5M | 40.33 | 67.58 | 91.24 |
| BRepA-L | 27M | 42.81 | 69.63 | 92.70 |
| BRepA-XL | 80M | 44.37 | 71.58 | 93.97 |
| 1-shot | 2-shot | 5-shot | |
|---|---|---|---|
| w/ BRepA | 12.40 | 27.13 | 58.95 |
| w/o BRepA | 11.83 | 17.76 | 38.37 |
| Method | mIoU (%) |
|---|---|
| UV-Net [ 15 ] | 19.85 ± 0.41 |
| UV-Net++ [ 15 ] | 28.12 ± 0.58 |
| UV-Net++ [ 15 ] & SDF SSL [ 17 ] | 34.05 ± 0.87 |
| BRepA (w/o SSL) | 35.18 ± 0.62 |
| BRepA (w/ only geo. MAE) | 63.25 ± 0.68 |
| BRepA | 67.42 ± 0.71 |
3D Representation Learning
3D representation learning builds geometric features for recognizing, reconstructing, generating, and reasoning about objects and scenes.
See all 206 papers