Skip to content
Robotics.world

Research

RoadWeaver: Large-Scale Lane-Level HD Map Generation from Scratch for Autonomous Driving Simulation

Long-horizon closed-loop evaluation of autonomous driving systems needs lots of large, geometrically diverse, lane-detailed road maps — but existing maps come either from hand design (slow, limited…

The paper’s first page · arXiv:2608.11580
arXiv
2608.11580 · Preprint · not peer-reviewed
Published
2026-08-12
Authors
Yueyuan Li, Zexi Chen, Weijie Xi, Mingyang Jiang, Songan Zhang, Hanyang Zhuang, Ming Yang

In plain words

Long-horizon closed-loop evaluation of autonomous driving systems needs lots of large, geometrically diverse, lane-detailed road maps — but existing maps come either from hand design (slow, limited variety) or reconstruction of real-world data (limited to places that actually exist, and to their existing topology).

AI summary

Overview

Research area: Robotics / autonomous driving — specifically the automatic generation of lane-level high-definition (HD) road maps for driving simulation.

Technical level: Advanced. The reader needs comfort with generative modeling (VQ-VAE, masked Transformers), graph representations of road networks, and HD map formats such as OpenDRIVE and OSM.

Scope: The paper presents RoadWeaver, a coarse-to-fine pipeline that builds globally connected, lane-level HD maps entirely from scratch and exports them in simulation-ready formats, then validates them by importing 100 generated maps into the Tactics2D simulator.

What This Paper Is About

Long-horizon closed-loop evaluation of autonomous driving systems needs lots of large, geometrically diverse, lane-detailed road maps — but existing maps come either from hand design (slow, limited variety) or reconstruction of real-world data (limited to places that actually exist, and to their existing topology). Automatic generation is the scalable alternative, yet prior methods produce only local patches or incomplete road structures that cannot be dropped straight into a simulator. RoadWeaver's goal is to generate complete, topologically coherent, lane-level HD maps of arbitrary spatial extent from scratch, with user control over how dense the road network is, and to make the output directly importable into a driving simulator.

Key Contributions

  1. A from-scratch HD map generation framework. RoadWeaver produces diverse lane-level HD maps with valid road-network topology and lane geometry, without any source map or sensor data.
  2. A coarse-to-fine, three-stage architecture. Global road skeleton generation, skeleton-guided road-graph expansion, and topology-aware lane-level map construction are decoupled so that global coherence and local detail are handled separately.
  3. Scalable generation through density control. Map scale is controlled by enlarging the spatial extent while holding a target road-node density (nodes per km²), so the number of nodes grows naturally without changing the generation procedure or relying on fixed templates.
  4. Simulation-ready output and an integrated pipeline. Maps export directly to OpenStreetMap and OpenDRIVE formats, and RoadWeaver is integrated into the Tactics2D simulator to provide an out-of-the-box generation and closed-loop evaluation pipeline.

Main Findings

  • Topology affects driving behavior. A t-SNE analysis of trajectories (velocity, acceleration, steering) pooled from multiple autonomous driving datasets shows that trajectories from different road topologies fall into distinct behavioral distributions — the motivation for generating topologically diverse maps.
  • Strong connectivity. RoadWeaver reaches a largest-connected-component (LCC) ratio of 99.9 ± 0.3% and a reachability of 99.8 ± 0.7%. For comparison, HDMapGen reaches 64.3 ± 24.7% LCC and 56.2 ± 28.2% reachability; RoadGen reaches 100.0 ± 0.0% on both; MetaDrive reaches 99.5 ± 2.3% and 99.3 ± 3.3%.
  • Fewest dead ends. The dead-end ratio is 10.7 ± 3.6%, versus 12.8 ± 6.2% for RoadGen, 42.9 ± 29.4% for HDMapGen, and 43.0 ± 10.1% for MetaDrive.
  • Far more closed loops. The cycle ratio is 85.2 ± 6.0%, against 50.5 ± 13.8% for MetaDrive, 46.5 ± 37.2% for HDMapGen, and 0.0 ± 0.0% for RoadGen — meaning more connected blocks and more alternative routes.
  • Much tighter lane endpoint alignment. The endpoint alignment error is 0.24 ± 0.22 m, compared with 4.32 ± 0.41 m (HDMapGen), 4.80 ± 1.29 m (RoadGen), and 8.17 ± 2.43 m (MetaDrive). The abstract reports this as a 94.4% reduction relative to state-of-the-art generation methods.
  • Fast generation. RoadWeaver generates complete HD maps in approximately 1.39–3.50 s. RoadGen's generation time rises from roughly 50 s to 370 s as graphs grow, and RoadGen rarely produces valid maps beyond roughly 60 nodes; MetaDrive's resource consumption rises rapidly as its predefined map configuration grows.
  • Density is controllable but saturates. Under target densities of 10, 15, 20, 25, 30, 35, and 40 road nodes/km², measured densities came out at 8.9, 15.0, 19.6, 25.1, 30.5, 34.5, and 39.0 respectively in one set of runs, and at 12.5, 17.6, 22.4, 25.2, 31.7, 37.1, and 43.3 in a second set using different random seeds. Beyond roughly 40 road nodes/km², further density increases become less significant because of tightening topological constraints.
  • Same density, different maps. Maps generated with different random seeds at the same target density show distinct topological organization, intersection configuration, and local geometry while preserving consistent network-level statistics.
  • Deploys into a simulator without editing. Of 100 randomly generated lane-level HD maps — each with full lane topology including predecessor, successor, and neighboring relations — 100.0% imported successfully into Tactics2D with no manual editing or post-processing. Across 10 sampled routing tasks per map (1,000 total), the built-in route planner succeeded on 98.7%, with an average routing time of 0.82 ± 0.17 s.

Methodology in Plain English

RoadWeaver builds a map the way a cartographer might sketch a city: first the major arteries, then the side streets, then the lane markings.

Stage 1 — Global road skeleton. Rather than drawing every road at once, the system first produces a sparse "skeleton" that captures only the main layout and long-range connectivity, deliberately omitting fine geometry. Because irregular road graphs do not fit on a regular pixel grid, each training graph is rasterized into a road-field tensor with six channels: road probability, two orientation channels, a junction heatmap, an endpoint heatmap, and a distance field. A VQ-VAE compresses this field into a grid of discrete latent tokens and reconstructs it, which converts continuous field prediction into categorical token prediction — keeping dominant topology while suppressing detail. A conditional masked Transformer then learns the distribution of those tokens, conditioned on an 11-dimensional vector: a six-dimensional road-style code plus five structural priors (road density, gridness, radialness, organicness, bearing entropy). The authors chose masked (bidirectional) prediction over autoregressive generation because road layouts have strong long-range dependencies and masked prediction can refine many regions in parallel. At inference, sampled tokens are decoded back into the road field, and centerlines are extracted and vectorized into a skeleton graph.

Stage 2 — Filling in local roads. The skeleton lacks local-road detail, so the system grows additional roads procedurally. It builds a continuous directional tensor field from tangent samples along the skeleton, using a Gaussian-weighted sum of outer products of unit tangents. Growth fronts start from seed points on both sides of the skeleton and step forward, choosing at each step whichever eigen-direction of the local tensor best matches the current heading, blending that with directional inertia, capping the turn angle, and applying a style-dependent random angular perturbation before a first-order Euler step. A front stops at the map boundary, at a length or iteration limit, or when it comes close enough to an existing road to snap onto it. Dangling endpoints are then reconnected by A* search over a cost map derived from the decoded road field — cheaper where predicted road evidence is stronger — and leftover disconnected fragments are removed by largest-connected-component filtering. Large empty regions are later populated with local roads using the same tensor field, keeping direction consistent with the surroundings.

Stage 3 — Lane-level HD map construction. The refined road graph is regularized geometrically, simplified topologically, and processed junction by junction. Each road segment is assigned a lane configuration, from which lane boundaries and directional lane instances are generated. Junction connector lanes are built, lane instances merged, successor links added, and geometric conflicts repaired. The map is then assembled and a final topology repair pass recovers any disconnected lane connections, yielding a directed lane graph exportable to OSM and OpenDRIVE.

Training and evaluation setup. The model is trained on approximately 58,000 OSM road-network samples from 144 cities, each covering about 2 km × 2 km. Baselines are MetaDrive and RoadGen (rule-based) and HDMapGen (data-driven), compared at a comparable scale of roughly 35–40 graph nodes, where intersections, road endpoints, and turning transition points are counted as nodes. Five metrics are used: LCC ratio, reachability, dead-end ratio, cycle ratio, and endpoint alignment error. All experiments run on an NVIDIA GeForce RTX 5090 GPU, an AMD Ryzen 7 9800X3D CPU, and 64 GB of RAM; reported generation time covers the full pipeline and excludes model loading and warm-up.

Why This Matters

Impact on research. Closed-loop benchmarks such as the CARLA Leaderboard and Bench2Drive evaluate driving systems over long routes, where errors like bad lane selection, route deviation, and traffic-rule violations accumulate and only then become visible. That kind of evaluation is bottlenecked by map supply. RoadWeaver turns map supply into a controllable parameter — pick an area and a density, get a valid lane-level map — which makes it possible to systematically vary road topology and measure how it changes driving behavior, rather than evaluating on whatever few maps happen to exist.

Real-world applications:

  • Large-scale regression testing of autonomous driving stacks. Generate many structurally different maps and run the same planner or policy across all of them to find failures that a handful of hand-built maps would never trigger.
  • Scenario and corner-case mining. Because density, style code, and structural priors are controllable, testers can bias generation toward unusual junction configurations or dense networks to stress planning and lane-selection logic.
  • Simulation content for training and reinforcement learning. Rapidly produce (in 1.39–3.50 s per map) fresh environments for agents that would otherwise overfit to a fixed map set.
  • Rapid prototyping of new urban areas. Produce plausible lane-level layouts for regions with no reconstructed HD map available, as a starting point for design or for synthetic data generation.

Industry relevance. Map content is normally the slowest and most expensive input to a simulation program — either licensed, hand-authored, or requiring a mapping fleet. A generator that outputs standard OSM and OpenDRIVE files and imports into an existing simulator with a 100.0% success rate in the reported trial lowers that barrier substantially, and the demonstrated 98.7% routing success rate on 1,000 tasks indicates the outputs are usable for actual route planning, not just visualization. The planned open-source release of the training code and an out-of-the-box implementation further lowers adoption cost.

Future Directions

  • Richer semantics and roadside assets. The authors explicitly list traffic semantics and roadside assets (signs, signals, furniture) as future work; the current output is lane geometry and topology, not a full scene description.
  • Interactive map editing. Also named by the authors: letting a user edit a generated map rather than only sampling a new one, which would matter for scripted scenario design.
  • Higher realism. The conclusion targets improved realism of generated driving environments — the paper evaluates connectivity, geometry, and controllability, but does not report a direct statistical comparison of generated maps against the distribution of real OSM maps beyond the conditioning priors.
  • Pushing past the density ceiling. Measured density tracks the target well up to about 40 road nodes/km² but degrades beyond that because of topological constraints, so very dense urban cores remain an open problem. Related open questions the paper does not resolve include how generated topology translates into measured differences in closed-loop driving outcomes, and how generation behaves at scales far beyond the 2 km × 2 km training samples.

Target Audience

Researchers and engineers working on autonomous driving simulation, HD map construction, and procedural or generative content creation for robotics. It is most useful to readers who already understand road-network graphs and HD map representations and want either a scalable map source for closed-loop evaluation or a reference architecture for coarse-to-fine structured generation. Practitioners building simulation pipelines will find the deployment validation and format compatibility the most immediately actionable parts; students of generative modeling will find the choice of discrete latent tokens plus masked Transformer for globally coherent layout synthesis the most transferable idea.

Authors’ abstract

Autonomous driving simulation requires diverse and scalable lane-level HD maps to support long-horizon evaluation across complex road networks. Existing approaches either rely on handcrafted or reconstructed real-world maps, which limits scalability, or generate only local road structures rather than complete HD maps. We present RoadWeaver, a coarse-to-fine framework for from-scratch generation of diverse, large-scale HD maps. RoadWeaver first synthesizes a global road…

The full abstract on arXiv
Read the original paper

Related papers