Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash
194 tokens/sec
GPT-4o
7 tokens/sec
Gemini 2.5 Pro Pro
46 tokens/sec
o3 Pro
4 tokens/sec
GPT-4.1 Pro
38 tokens/sec
DeepSeek R1 via Azure Pro
28 tokens/sec
2000 character limit reached

Hierarchical Neural Coding for Controllable CAD Model Generation (2307.00149v1)

Published 30 Jun 2023 in cs.CV and cs.LG

Abstract: This paper presents a novel generative model for Computer Aided Design (CAD) that 1) represents high-level design concepts of a CAD model as a three-level hierarchical tree of neural codes, from global part arrangement down to local curve geometry; and 2) controls the generation or completion of CAD models by specifying the target design using a code tree. Concretely, a novel variant of a vector quantized VAE with "masked skip connection" extracts design variations as neural codebooks at three levels. Two-stage cascaded auto-regressive transformers learn to generate code trees from incomplete CAD models and then complete CAD models following the intended design. Extensive experiments demonstrate superior performance on conventional tasks such as random generation while enabling novel interaction capabilities on conditional generation tasks. The code is available at https://github.com/samxuxiang/hnc-cad.

Definition Search Book Streamline Icon: https://streamlinehq.com
References (52)
  1. Learning representations and generative models for 3d point clouds. In International conference on machine learning, pp.  40–49. PMLR, 2018.
  2. Parametric cad modeling: An analysis of strategies for design reusability. Computer-Aided Design, 74:18–31, 2016.
  3. Bsp-net: Generating compact meshes via binary space partitioning. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp.  45–54, 2020.
  4. Play: Parametrically conditioned layout generation using latent diffusion. arXiv preprint arXiv:2301.11529, 2023.
  5. Jukebox: A generative model for music. arXiv preprint arXiv:2005.00341, 2020.
  6. Inversecsg: Automatic conversion of 3d models to csg trees. Annual Conference on Computer Graphics and Interactive Techniques (SIGGRAPH), 37(6):1–16, 2018.
  7. How do humans sketch objects? ACM Trans. Graph. (Proc. SIGGRAPH), 31(4):44:1–44:10, 2012.
  8. Write, execute, assess: Program synthesis with a repl. In Advances in Neural Information Processing Systems (NeurIPS), pp.  9169–9178, 2019.
  9. Computer-aided design as language. In Advances in Neural Information Processing Systems (NeurIPS), 2021.
  10. Complexgen: Cad reconstruction by b-rep chain complex generation. ACM Trans. Graph. (SIGGRAPH), 41(4), July 2022. doi: 10.1145/3528223.3530078. URL https://doi.org/10.1145/3528223.3530078.
  11. Deep residual learning for image recognition. In Proceedings of the IEEE conference on computer vision and pattern recognition, pp.  770–778, 2016.
  12. Masked autoencoders are scalable vision learners. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp.  16000–16009, 2022.
  13. Gans trained by a two time-scale update rule converge to a local nash equilibrium. Advances in neural information processing systems, 30, 2017.
  14. The curious case of neural text degeneration. In International Conference on Learning Representations (ICLR), 2020.
  15. Squared earth mover’s distance-based loss for training deep neural networks. arXiv preprint arXiv:1611.05916, 2016.
  16. Solidgen: An autoregressive model for direct b-rep synthesis. ”arXiv Preprint”, 2022. doi: 10.48550/ARXIV.2203.13944. URL https://arxiv.org/abs/2203.13944.
  17. Ucsg-net-unsupervised discovering of constructive solid geometry tree. Advances in Neural Information Processing Systems, 33:8776–8786, 2020.
  18. Zero-shot cad program re-parameterization for interactive manipulation. arXiv preprint arXiv:2306.03217, 2023.
  19. Reconstructing editable prismatic cad from rounded voxel models. In SIGGRAPH Asia, December 2022.
  20. Sketch2cad: Sequential cad modeling by sketching in context. ACM Transactions on Graphics (TOG), 39(6):1–14, 2020.
  21. Free2cad: Parsing freehand drawings into cad commands. ACM Trans. Graph. (Proceedings of SIGGRAPH 2022), 41(4):93:1–93:16, 2022.
  22. Secad-net: Self-supervised cad reconstruction by learning sketch-extrude operations. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp.  16816–16826, 2023.
  23. Decoupled weight decay regularization. In International Conference on Learning Representations, 2018.
  24. Martin, D. What is design intent?, 2023. Accessed: Janurary 19, 2023.
  25. Mishra, A. Machine learning in the aws cloud: Add intelligence to applications with amazon sagemaker and amazon rekognition, 2019. URL https://aws.amazon.com/sagemaker/groundtruth/.
  26. Programming language tools and techniques for 3d printing. In 2nd Summit on Advances in Programming Languages (SNAPL 2017). Schloss Dagstuhl-Leibniz-Zentrum fuer Informatik, 2017.
  27. Functional programming for compiling and decompiling computer-aided design. Proceedings of the ACM on Programming Languages, 2(ICFP):1–31, 2018.
  28. Revisiting the design intent concept in the context of mechanical cad education. Computer-Aided Design and Applications, 15(1):47–60, 2018. doi: 10.1080/16864360.2017.1353733. URL https://doi.org/10.1080/16864360.2017.1353733.
  29. Sketchgen: Generating constrained cad sketches. In Advances in Neural Information Processing Systems (NeurIPS), 2021.
  30. Generating diverse high-fidelity images with vq-vae-2. Advances in neural information processing systems, 32, 2019.
  31. Csg-stump: A learning friendly csg-like representation for interpretable shape parsing. In Proceedings of the IEEE/CVF International Conference on Computer Vision, pp.  12478–12487, 2021.
  32. Extrudenet: Unsupervised inverse sketch-and-extrude for shape parsing. In ECCV, 2022.
  33. SketchGraphs: A large-scale dataset for modeling relational geometry in computer-aided design. In ICML 2020 Workshop on Object-Oriented Learning, 2020.
  34. Vitruvion: A generative model of parametric cad sketches. arXiv:2109.14124, 2021.
  35. Shahin, T. Feature-based design – an overview. Computer-aided Design and Applications, 5, 01 2008. doi: 10.3722/cadaps.2008.639-653.
  36. Csgnet: Neural shape parser for constructive solid geometry. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), 2018.
  37. Parsenet: A parametric surface fitting network for 3d point clouds. In European Conference on Computer Vision (ECCV), pp. 261–276. Springer, 2020.
  38. Learning manifold patch-based representations of man-made shapes. In International Conference on Learning Representations (ICLR), 2021.
  39. Learning to infer and execute 3d shape programs. In International Conference on Learning Representations (ICLR), 2019.
  40. Point2cyl: Reverse engineering 3d objects from point clouds to extrusion cylinders. CoRR, abs/2112.09329, 2021. URL https://arxiv.org/abs/2112.09329.
  41. Neural discrete representation learning. Advances in neural information processing systems, 30, 2017.
  42. Neural face identification in a 2d wireframe projection of a manifold object. In 2022 IEEE/CVF Conference on Computer Vision and Pattern Recognition (CVPR), pp.  1612–1621, 2022. doi: 10.1109/CVPR52688.2022.00167.
  43. Pie-net: Parametric inference of point cloud edges. In Advances in Neural Information Processing Systems, volume 33, pp.  20167–20178. Curran Associates, Inc., 2020.
  44. Engineering sketch generation for computer-aided design. In IEEE Conference on Computer Vision and Pattern Recognition Workshops (CVPR Workshop), pp.  2105–2114, 2021a.
  45. Fusion 360 gallery: A dataset and environment for programmatic cad construction from human design sequences. ACM Transactions on Graphics (TOG), 40(4), 2021b.
  46. Deepcad: A deep generative network for computer-aided design models. In IEEE International Conference on Computer Vision (ICCV), pp.  6772–6782, October 2021.
  47. Iconshop: Text-based vector icon synthesis with autoregressive transformers. arXiv preprint arXiv:2304.14400, 2023.
  48. Inferring cad modeling sequences using zone graphs. In IEEE Conference on Computer Vision and Pattern Recognition (CVPR), pp.  6062–6070, June 2021.
  49. Skexgen: Autoregressive generation of cad construction sequences with disentangled codebooks. In International Conference on Machine Learning, pp. 24698–24724. PMLR, 2022.
  50. Yares, E. The failed promise of parametric cad, 2013. Accessed: November 5, 2022.
  51. Capri-net: Learning compact cad shapes with adaptive primitive assembly. In Proceedings of the IEEE/CVF Conference on Computer Vision and Pattern Recognition, pp.  11768–11778, 2022.
  52. Dualcsg: Learning dual csg trees for general and compact cad modeling. arXiv preprint arXiv:2301.11497, 2023.
Citations (22)

Summary

  • The paper introduces a hierarchical neural coding scheme using a variant of VQ-VAE with masked skip connections to capture design patterns in CAD models.
  • It employs two-stage cascaded auto-regressive transformers to predict design intent and generate or complete CAD models with user-guided control.
  • Experimental results show superior realism, diversity, and quality compared to state-of-the-art systems such as DeepCAD and SkexGen.

Hierarchical Neural Coding for Controllable CAD Model Generation

The paper introduces a novel approach to the generation of Computer Aided Design (CAD) models through a hierarchical neural coding scheme. The work addresses the need for design intent-aware generation and modification of CAD models, which traditional parametric CAD systems struggle to maintain when models are modified. This is achieved using a multi-level neural representation, which captures CAD design patterns from global part arrangements to local geometries. A variant of vector quantized variational autoencoders (VQ-VAE) with masked skip connections extracts these patterns as discrete neural codebooks at three hierarchical levels: solid, profile, and loop. The system utilizes two-stage cascaded auto-regressive transformers, enabling the generation and auto-completion of CAD shapes while respecting the hierarchical design intent.

Key Contributions

  1. Hierarchical Neural Code Representation: The framework encodes CAD models into a three-level hierarchical tree, leveraging VQ-VAE to create separate codebooks capturing solid, profile, and loop structures. Each level of the hierarchy naturally mirrors the design steps commonly followed in CAD modeling: from macro-level solid part arrangements to micro-level geometric curves.
  2. Masked Skip Connection in VQ-VAE: A modified VQ-VAE architecture incorporates a masked skip connection, mitigating the tendency of the decoder to directly reconstruct input details, thereby fostering a more abstract, design pattern-focused learning in the codebooks.
  3. Two-Stage Cascaded Transformers for Controllable Generation: With the aid of two decoupled auto-regressive transformers, the model first predicts the hierarchical design intent via codebooks and then generates or completes CAD models in alignment with this intended design. This enables user-guided modifications at any level of the design hierarchy, offering direct and intuitive control over both global and local design features.

Numerical and Empirical Evaluation

The experimental results underscore the effective generation of CAD models with enhanced realism, diversity, and quality compared to state-of-the-art systems such as DeepCAD and SkexGen. The model achieves superior scores in quantitative metrics: Coverage (COV), Minimum Matching Distance (MMD), Jensen-Shannon Divergence (JSD), along with higher unique and novelty rates. Human evaluations further affirm the model's competency in generating realistic and complex CAD designs indistinguishable from real, hand-crafted models.

Implications and Future Directions

The research significantly facilitates interactions in CAD design by allowing users not only design creation but also seamless modification and completion of designs. This represents a step towards design systems that incorporate and respect designer intent, thereby offering high-quality interactive design tools. Looking forward, one avenue for development is the integration of additional CAD operations beyond sketch-and-extrude, such as revolve or sweep, to offer even broader coverage of typical CAD design processes. The extension towards enforcing CAD validity via explicit geometric constraints or corrective post-processing methods is another promising direction to enhance the practical applicability of the system.

Overall, this work provides a scalable framework capable of supporting the design and iteration of complex CAD models, addressing both theoretical and practical needs within the engineering and design communities.