Source-linked AI summary
Learning to Ground Before Reading: Unified PCB Engineering Drawing Parsing with Compact Vision-Language Models
Jinghao Liu, Xingrun Liu, Gengchen Sun, Han Xiao, Xingyu Chen, Yuhui Deng
TL;DR
PCB engineering-drawing parsers commonly depend on localization followed by crop recognition, leaving missed regions unrecoverable. This paper trains a compact VLM to generate full-page region classes, normalized boxes, and content, using Localization-First training to address content-token imbalance. On the fixed ED split, Localization-First improves strict localization F1 by 0.0955 over joint training, while G-Unified achieves the strongest reported end-to-end content metrics among the unmodified runs.
Problem
PCB drawings combine sparse graphics, dense tables, and position-dependent text, while cascaded localization and crop recognition make downstream parsing depend on finding each region.
Method
G-Unified generates region classes, normalized boxes, and textual or HTML content directly from full pages, with Localization-First training before complete targets.
Results
Localization-First improves strict localization F1 from 0.3942 to 0.4897, while G-Unified achieves the best content metrics among unmodified end-to-end runs.
Takeaways & Limitations
G-Unified provides a detector-free baseline for full-page PCB drawing parsing, but content recall remains the main bottleneck.
Takeaways & Limitations
The comparison uses a short 10/10-epoch Hybrid-VL reproduction that does not establish convergence to the original 400/30-epoch setting.
Abstract
from arXiv · showhide
PCB engineering drawings mix sparse graphics, dense tables, and text whose meaning depends on page position. Localizing the regions and sending crops to specialized recognizers are determined as the methods for most parsers, so missed regions cannot be recovered downstream. We train a compact VLM to read the full page and get a sequence of region classes, normalized boxes, and text or HTML content. Bounding boxes are converted to coordinate tokens for supervision. Inference uses no detector or crop parser. The joint target is difficult to optimize because class and box tokens are sparse relative to the much longer content sequences. Our localization-first curriculum learns the class-box format before adding content targets with content-aware resampling. On the fixed validation split of the Engineering Drawing Dataset (ED dataset), Localization-First improves strict localization F1 by 0.0955 over joint training (paired image-bootstrap 95% interval: [0.0350, 0.1572]). G-Unified has the lowest NED, highest cell F1, and only nonzero exact-match score. It provides a detector-free baseline for full-page PCB drawing parsing.
1 Introduction
PCB engineering drawings require joint understanding of content, spatial context, and semantic role, but cascaded parsers make recognition depend on successful localization. The paper proposes G-Unified, which generates region classes, boxes, and content directly from full pages, with Localization-First training to address optimization imbalance.
- Problem: PCB drawings combine graphical views, fabrication notes, stackups, drill schedules, and heterogeneous tables whose meaning depends on spatial context.A complete parser must identify regions, determine their roles, recover textual or tabular content, and retain page locations.
- Problem: Cascaded systems localize regions first and route crops to OCR engines or VLMs, so missed regions cannot be recovered by downstream recognition.This decomposition creates a hard dependency between localization and recognition.
- Approach: G-Unified replaces the cascade with a compact VLM that predicts each region's semantic class, bounding box, and textual or HTML content from the full page.The unified call eliminates detector inference, crop routing, and a second recognizer.
- Approach: Localization-First training first establishes region classes and locations before introducing the complete class-box-content target.The schedule prioritizes sparse localization supervision before longer content targets.
2 Related Work
Document understanding has progressed from explicit layout analysis and OCR-linked multimodal models toward OCR-free generative page modeling. Engineering drawings remain difficult because their sparse graphics, rotated annotations, dense tables, and domain-specific layouts motivate specialized cascaded systems.
- General document understanding: DocLayNet and LayoutParser support large-scale layout annotation, detection, and segmentation, while LayoutLM-family models combine textual, spatial, and visual features.These approaches typically rely on OCR tokens or task-specific prediction heads.
- Generative document modeling: OCR-free models such as Donut, Pix2Struct, and Florence-2 generate structured outputs directly from page pixels, while table-focused work targets textual and structural recovery.Generative VLMs also extend document modeling toward localization and grounding.
- Engineering drawings: Engineering drawings combine sparse line graphics, rotated annotations, dense tables, and domain-specific layouts that make them especially challenging.Prior work includes VLM-based extraction, blueprint symbol recognition, and multimodal reasoning over engineering documents.
- Engineering drawings: Specialized engineering-drawing systems commonly use cascaded pipelines, such as geometric heuristics or rotation-aware detection followed by dedicated recognition.eDOCr2 and Hybrid-VL exemplify this localization-then-parsing pattern.
3 Methodology
The methodology represents each page as an ordered sequence of region classes, normalized boxes, and content, then compares grounding-only, cascaded, and unified parsing modes. Its training objective addresses content-token dominance by masking localization fields first and restoring full targets in a second phase.
- Unified output representation: The unified representation serializes page regions in reading-compatible order, with each record containing a class, four normalized box coordinates, and content.Content is plain text, an HTML table, or an empty string for graphical figures.
- Unified output representation: Fixed-grid coordinates make geometry independent of raster resolution and permit deterministic parsing.The ontology contains text, figure, title block, drill, stackup, and other table classes.
- Parsing modes: The study contrasts grounding-only prediction, cascaded crop parsing, and unified full-page generation of classes, boxes, and content.The primary experiments use the unified mode implemented by G-Unified.
- Detector-free parsing: In a two-stage pipeline, content recovery requires both matched localization and correct crop parsing, so a localization miss forces a content miss.Unified generation instead conditions output tokens on the full-page representation and preceding page context.
- Joint objective: Joint teacher-forced likelihood is dominated by long content fields because class and box fields contribute comparatively few tokens.Long HTML targets can also postpone later regions in the sequence.
- Localization-First training: Localization-First training masks content during Phase 1, then restores the complete grammar while retaining class and box supervision in Phase 2.This trains region counting, class vocabulary, coordinate syntax, and stopping behavior before adding content fields without manually tuned loss coefficients.
4 Experiments
Experiments evaluate unified training variants and compare detector-free parsing with established cascaded systems on the fixed ED validation split. Evaluation uses shared localization and end-to-end content metrics, with implementation details specified for reproducibility.
- Dataset: The ED dataset contains 267 drawings and 2,209 annotated regions, with 241 training drawings and 26 validation drawings.The validation split contains 272 regions, including 78 nonempty content targets across 20 drawings.
- Training Variants: Localization-First training uses a box-only phase before restoring full targets and oversamples content-bearing pages during the later phase.Phase 1 uses 241 box-only targets for two epochs; Phase 2 repeats each content-bearing page twice in addition to its regular occurrence.
- Implementation: The principal unified model is Qwen3.5-4B with 4-bit quantization and LoRA adaptation, while the 2B counterpart uses the same grammar and preprocessing.The configuration uses LoRA rank 32, scaling 64, dropout 0.05, and an 8,192-token maximum sequence length.
- Baselines: Comparisons include reproduced eDOCr2 and Hybrid-VL pipelines, with frozen validation detections for eDOCr2 and oriented-box localization for Hybrid-VL.The common protocol converts each Hybrid-VL predicted oriented box to its enclosing axis-aligned box.
- Evaluation: Localization matches predictions to references one-to-one within the same canonical class at IoU ≥0.5, then reports micro precision, recall, F1, and mean IoU.Uncertainty is estimated with 5,000 paired bootstrap replicates over the 26 validation drawings.
- Evaluation: Content extraction uses only strict class-aware localization matches, with normalized edit distance, structured HTML cell F1, and exact-match scoring.Unmatched references receive NED 1 and zero cell or exact-match credit; malformed outputs are treated as empty.
5 Results
On the fixed ED validation split, Localization-First improved unified-model localization while content recall and cross-system trade-offs remained central limitations. Strict diagnostics show stronger localization and content metrics for G-Unified than other unmodified end-to-end runs, but unmatched regions still dominate content loss.
- Controlled Unified-Model Comparison: 0.0955 F1 improvement over the 4B baseline raised Local-First localization F1 to 0.4897, with matched IoU 0.8907.Local-First also reached precision 0.6485 and NED 0.8143; NED decreased by 0.0682 versus the 4B baseline.
- Paired Uncertainty and Class Behavior: 95% paired-bootstrap intervals excluded zero for Local-First minus the 4B baseline, while intervals for Local-First versus stable included zero.The bootstrap used 5,000 replicates; 99.86% of paired replicates favored Local-First over the 4B baseline.
- Paired Uncertainty and Class Behavior: Per-class F1 improved from baseline to Local-First for text, figure, title block, and stackup, while drill remained 0.8889.The corresponding Local-First scores were 0.4551, 0.5306, 0.5405, and 0.7692; several classes contain few references.
- Content Recall and Output Grammar: Local-First matched 27 of 78 content-bearing references, with full-denominator content loss driven primarily by unmatched regions.On matched regions, Local-First obtained NED 0.4634, cell F1 0.3169, and exact match 0.1250; 51 references were unmatched.
- Same-Split Cross-System Localization: Hybrid-VL achieved the highest localization F1, whereas Local-First had the highest mean IoU among matched boxes without detector inference or crop routing.Local-First was 0.1807 F1 below Hybrid-VL on the same validation split.
- Cross-System Content Extraction: Decoder repair raised format rate to 1.0 in diagnostics, but content accuracy remained low; G-Unified remained strongest among unmodified runs.Repair-only produced mean NED 0.515 and cell F1 0.1646, while exact match remained zero for both diagnostics.
6 Conclusion
G-Unified is a detector-free compact VLM for jointly predicting region classes, boxes, and content from full PCB drawings. Localization-First improved strict localization, while content recall remained the main bottleneck on the ED validation split.
- 0.6704: Reproduced Hybrid-VL achieved higher localization F1 than G-Unified.
- G-Unified achieved the best content metrics among the unmodified end-to-end runs.
- 27 of 78 content references were localized, yielding 23 usable outputs for G-Unified.
- The results are limited to one run per variant on 26 validation pages, motivating broader evaluation and improved content recall and structured decoding.