Papers
Topics
Authors
Recent
Gemini 2.5 Flash
Gemini 2.5 Flash 99 tok/s
Gemini 2.5 Pro 43 tok/s Pro
GPT-5 Medium 28 tok/s
GPT-5 High 35 tok/s Pro
GPT-4o 94 tok/s
GPT OSS 120B 476 tok/s Pro
Kimi K2 190 tok/s Pro
2000 character limit reached

Drawing2CAD: 2D to Parametric CAD

Updated 5 September 2025
  • Drawing2CAD is a sequence-to-sequence framework that translates 2D vectorized engineering drawings into structured, parametric CAD command sequences, preserving design intent and geometric precision.
  • It employs a dual-decoder transformer architecture that decouples high-level CAD operation inference from precise parameter regression, thereby ensuring accurate and consistent model construction.
  • The framework utilizes a unified vector primitive representation and introduces a soft target distribution loss to robustly handle ambiguous and noisy drawing inputs in industrial settings.

Drawing2CAD (CAD-VGDrawing) is a sequence-to-sequence learning framework designed to convert vectorized engineering drawings directly into parametric CAD (Computer-Aided Design) models. The framework prescribes a principled strategy for bridging the gap between traditional 2D vector graphics, which are the entry point for much of engineering design, and modern parametric CAD systems that demand structured command sequences and geometric precision. Drawing2CAD is enabled by a unified vector primitive representation, a specialized dual-decoder transformer architecture, and an engineered dataset (CAD-VGDrawing) pairing vectorized drawings with parametric model sequences. This approach directly targets the underexplored but industrially critical problem of 2D drawing-to-parametric CAD conversion, with a focus on preserving both geometric accuracy and the underlying design intent (Qin et al., 26 Aug 2025).

1. Problem Formulation and Framework Overview

Drawing2CAD reframes the CAD generation task as a sequence-to-sequence (seq2seq) problem: mapping input sequences of vector drawing primitives to structured output sequences representing parametric CAD operations. The input is a network-friendly representation of geometric primitives—lines, arcs, splines—parsed from vector drawings (for example, SVG files). The output is a CAD command sequence encoding construction parameters and operations required to programmatically instantiate the depicted geometry in a CAD environment.

The mapping is formulated probabilistically as: y=argmaxy  p(yx;θ)=t=1Np(yty<t,x;θ)y^* = \arg\max_{y} \; p(y \mid x; \theta) = \prod_{t=1}^{N} p\bigl(y_t \mid y_{<t},x;\theta\bigr) where xx denotes the drawing primitive sequence, yy is the CAD command sequence, and θ\theta the model parameters.

An encoder processes the input vector primitives and context; a dual-decoder transformer concurrently generates both high-level command types and low-level numeric parameters, thereby maintaining fidelity and correspondence across drawing and model domains.

2. Network-Friendly Vector Primitive Representation

A canonical innovation in Drawing2CAD is the construction of a standardized, information-dense representation for vector drawing primitives. Each geometric entity (e.g., line, arc, spline) is converted into a tokenized command format that unambiguously captures its type and continuous parameters such as endpoints, radii, orientation, and curvature. This representation enables the encoder to robustly extract both spatial and structural features, facilitating downstream learning of complex design relationships and topologies.

Such abstraction preserves geometric precision and ensures that key relationships (e.g., connectivity, intersection, collinearity) among primitives are delivered to the downstream transformer architecture. This representation also generalizes to a wide variety of engineering drawing styles present in industrial practice.

3. Dual-Decoder Transformer Architecture

The core of Drawing2CAD is a dual-decoder transformer architecture engineered specifically to address two essential facets of drawing-to-CAD translation:

  • Command Branch: Infers a sequence of high-level CAD operations, such as extrusions, revolutions, boolean combinations, and related procedural steps. This branch captures design intent and the logical structure of the part's construction.
  • Parameter Branch: Regresses the precise continuous parameters (e.g., dimensions, angles, coordinates) associated with each operation. This ensures accurate instantiation of the geometry.

The dual-decoder paradigm facilitates explicit decoupling between “what is done” (operation sequence) and “how it is done” (geometry specification), allowing the model to maintain strict parametric and logical correspondence. During training and inference, alignment between these two branches is enforced, so that generated operations are always parameterized with contextually consistent values derived from the input drawing.

4. Soft Target Distribution Loss

A critical challenge in parameter learning is the inherent ambiguity and minor variations that exist in design drawings, especially those derived from freehand or legacy sources. To address over-penalization and instability from hard one-hot loss functions, Drawing2CAD introduces a soft target distribution loss. This loss formulation provides the model with probabilistic—rather than absolute—feedback for each predicted token or parameter.

This softening enables the network to tolerate small discrepancies in input interpretation, supports more gradual convergence, and is particularly well-suited to disambiguating geometric features that may admit multiple near-equivalent parametrizations in realistic design settings.

5. CAD-VGDrawing Dataset Construction

Training and evaluation of Drawing2CAD are supported by the CAD-VGDrawing dataset. This corpus is distinguished by:

  • Paired samples: Each instance contains a vectorized engineering drawing and a corresponding parametric CAD model described as a command sequence.
  • Coverage: The dataset incorporates a diverse set of industrial scenarios, reflecting a range of drafting conventions, geometric complexities, and design domains.
  • Explicit annotations: Each drawing is comprehensively annotated with construction steps, enabling fine-grained evaluation and interpretability.

The dataset serves both as a benchmark for future research on 2D-to-CAD translation—and as a foundation for robust, end-to-end model training.

6. Experimental Results and Ablation Studies

Empirical evaluations demonstrate that Drawing2CAD achieves leading performance on reconstruction accuracy, geometric precision, and fidelity to design intent. Experimental components include:

  • Quantitative metrics: Assessment of sequence-level reconstruction accuracy, geometric error metrics (e.g., Chamfer distance, parametric error), and structural correctness of the command sequence.
  • Ablations: Isolating the impact of each technical innovation (vector representation, dual-decoder, soft loss) to clarify contributions and diagnose architectural tradeoffs.
  • Qualitative analysis: Visual comparison of output CAD models with input drawings highlights the method's ability to preserve both geometric and procedural design elements even in the presence of drawing ambiguity.

Key findings indicate robust handling of schematic, noisy, or stylistically variable inputs.

7. Applications, Access, and Broader Impact

Drawing2CAD directly supports automation and digitization of industrial workflows reliant on 2D engineering drawings. Applications include:

  • Digitization of legacy or hand-drawn documents: Automating conversion to parametric CAD reduces manual transcription effort and error.
  • Accelerating design iteration: Rapid translation of early-phase vector sketches into detailed CAD assemblies enhances engineer productivity.
  • Workflow integration: The unified command-based format enables seamless introduction into existing CAD software ecosystems or collaborative platforms.

The codebase and CAD-VGDrawing dataset are openly accessible for replication and extension. Researchers are instructed to clone the repository, follow the provided installation and data download steps, and utilize included scripts for model training and evaluation.


Drawing2CAD exemplifies an engineered approach for the automatic, parametric synthesis of CAD models from vectorized drawings, coupling end-to-end joint learning with structured domain representations. Its technical innovations—networked primitive representation, dual-decoder architecture, and soft loss—address long-standing challenges in geometric fidelity and design intent preservation, and offer a publicly available platform for furthered research in drawing-to-CAD automation (Qin et al., 26 Aug 2025).

Definition Search Book Streamline Icon: https://streamlinehq.com
References (1)