Skip to content

drawtonomy vs scenariogeneration (pyoscx / pyodrx)

scenariogeneration is an open-source Python library for generating linked OpenSCENARIO (.xosc) and OpenDRIVE (.xodr) XML files. It is the successor of the earlier pyoscx and pyodrx libraries and is available on PyPI and documented at pyoscx.github.io/scenariogeneration.

What scenariogeneration covers, per its README:

  • A Python API for constructing OpenSCENARIO and OpenDRIVE files programmatically.
  • Three main components: scenario_generator module, xosc (OpenSCENARIO) subpackage, xodr (OpenDRIVE) subpackage.
  • Full coverage of OpenSCENARIO V1.0.0, and most of V1.1.0, V1.2.0, V1.3.1.
  • Coverage based on OpenDRIVE V1.7.1 — basic roads, junctions, signals, and objects.
  • Parametrization and auto-generation utilities for producing scenario variants.
  • esmini integration for visualization.
  • Licensed under MPL-2.0.
  • Unifies the earlier pyoscx and pyodrx packages.

For programmatic scenario generation — especially scenario fleets, parameter sweeps, and CI-driven test cases — scenariogeneration is one of the established Python options.

drawtonomy is a 2D browser whiteboard. It has no Python API, doesn’t do parametrized generation, and its OpenSCENARIO / OpenDRIVE export is a smaller subset than scenariogeneration’s coverage.

A few things drawtonomy can add alongside scenariogeneration:

  • Visual authoring of a single concrete scenario — actions, triggers, end / fail conditions — with no Python.
  • Running that scenario in the browser on esmini-WASM (transport, seek, PASS / FAIL), separate from the Python pipeline. See the scenario editor.
  • .drawtonomy.svg as a re-editable figure source for documentation.

The two tools are at different layers: scenariogeneration programmatically generates fleets of scenarios from code; drawtonomy visually authors and runs one concrete scenario at a time.

scenariogeneration (and its predecessor projects pyoscx / pyodrx) is one of the most established open-source contributions to the OpenSCENARIO / OpenDRIVE Python ecosystem. drawtonomy emits the same file formats and visualizes against the same downstream player (esmini). Both tools — alongside Scenic, CARLA ScenarioRunner, and direct hand-written XML — are part of the same community building tooling around ASAM’s open standards.