TL;DR
DeepCAD is the first deep generative model designed to produce 3D shapes as sequences of CAD operations (like sketches and extrusions) rather than static point clouds or meshes. By treating CAD design as a language-like sequence, the model generates clean, sharp-featured, and fully editable 3D models, supported by a massive new dataset of 178,000 CAD construction sequences.
What Problem Does This Paper Address?
Most existing 3D generative models focus on discrete representations: voxels, point clouds, or polygon meshes. While useful for visualization, these formats are "dead" in an engineering context. They lack the design intent, sharp geometric features, and parametric editability required for industrial design.
In contrast, professional designers use Computer-Aided Design (CAD) software to build shapes through a sequence of operations—sketching a 2D profile and then extruding it into 3D space. However, generating these sequences is difficult for standard neural networks because CAD data is irregular, sequential, and contains a mix of discrete command types and continuous geometric parameters. DeepCAD aims to bridge this gap by learning the "drawing process" itself.
Methods
The authors propose a Transformer-based autoencoder that treats CAD commands like words in a sentence.
- Representation: They unify CAD operations into a standard structure. Each command includes a type (e.g., Line, Arc, Circle, Extrude) and a fixed-length vector of 16 parameters.
- Quantization: A key technical contribution is the quantization of continuous parameters (like coordinates and angles) into 8-bit integers. This transforms a difficult regression problem into a classification task, which allows the network to better respect strict geometric relationships like parallelism and perpendicularity.
- Architecture:
- Encoder: A Transformer network that compresses a sequence of up to 60 CAD commands into a single latent vector ($z$).
- Decoder: A Transformer that takes the latent vector and predicts the original command sequence.
- Generation: To generate new shapes, the authors train a Latent-GAN on the learned latent space of the autoencoder. Sampling from this GAN allows the model to produce entirely new, plausible CAD designs.
Datasets
The authors found that existing datasets were either too small (Fusion 360 Gallery) or lacked construction sequences (ABC dataset). To solve this, they created the DeepCAD dataset:
- Scale: 178,238 unique CAD models.
- Source: Parsed from the Onshape repository using their developer API and FeatureScript.
- Content: Each model is represented as a sequence of sketch and extrusion commands. This dataset has been made public to serve as a benchmark for future research.
Key Insights and Ideas
- CAD as Language: The most powerful idea is the analogy between CAD design and natural language. Just as a sentence has a subject and a predicate, a CAD operation has a sketch profile and an extrusion. This makes the Transformer—a powerhouse in NLP—the ideal architecture.
- The Power of Quantization: The authors demonstrate that regressing continuous values often leads to "broken" geometry. By quantizing values to 256 levels, the model learns to "snap" to specific grid points, preserving the clean look of human-made CAD models.
- Editability: Unlike a generated mesh, a DeepCAD output can be imported directly into tools like AutoCAD or SolidWorks. A user can click on a generated face and move it, or change a radius, because the underlying representation is parametric.
Key Results
- Autoencoding Accuracy: The model achieves a command type accuracy of 99.36% and a parameter accuracy of 97.47%.
- Geometric Fidelity: In terms of Chamfer Distance (a measure of how close the generated shape is to the ground truth), DeepCAD significantly outperforms variants that use raw regression instead of quantization.
- Shape Generation: Compared to point-cloud generators like l-GAN, DeepCAD produces shapes with much sharper features and smoother surfaces.
Limitations and Future Work
- Command Scope: The current model only supports lines, arcs, circles, and extrusions. It does not yet handle more complex operations like fillets, chamfers, or revolutions, which often require referencing the model's boundary representation (B-rep).
- Topological Validity: While rare, the model can occasionally generate a sequence that is mathematically "invalid" (e.g., self-intersecting loops), resulting in a failure to render the 3D solid.
- Sequence Length: The model is currently capped at 60 commands. Scaling to more complex, multi-step industrial designs remains a challenge for future iterations.
Summary updated