Welcome to Journal of University of Chinese Academy of Sciences,Today is

Journal of University of Chinese Academy of Sciences

Previous Articles     Next Articles

An intelligent analysis method for 2-D CAD shapes based on CSG

FENG Zhuohang, SHEN Liyong   

  1. School of Mathematical Sciences, University of Chinese Academy of Sciences, Beijing 100049, China
  • Received:2024-12-09 Revised:2025-03-03

Abstract: Constructive Solid Geometry (CSG) is a geometric modeling technique that defines complex shapes through Boolean operations between basic geometric primitives. However, reverse modeling to recover the CSG construction sequence from existing geometric shapes has been a challenging research problem. In this paper, we propose a Transformer-based deep network architecture that can parse input geometric shapes and output their corresponding CSG modeling sequences. Using the CSGNET algorithm as a baseline, we first expanded the synthetic dataset used for training, enabling the model to learn and parse a broader range of shapes. Additionally, we adopted an autoregressive learning architecture with a VGG encoder and a Transformer decoder, leveraging the attention mechanism to better correlate the generated sequences. This approach translates 2D shape inputs into CSG sequence outputs in a fixed format, resulting in improved reconstruction quality. We also introduced a validity correction module to ensure that the model does not output invalid reconstruction sequences. Experimental results show that the proposed model achieves better quality on both synthetic and real CAD datasets.

Key words: Constructive Solid Geometry, Attention Mechanism, Deep Learning, Validity Correction

CLC Number: