Simulation, Testing and Validation · Test methodology
Scenario Generation
Also known as test case generation, scenario creation, scenario sampling, critical scenario search
Creating concrete driving scenarios, with actors, road layout, behaviours, environmental conditions and parameter values, for testing, by manual authoring, extraction from recorded data, or sampling and searching parameter spaces, often in a standard format such as ASAM OpenSCENARIO.
Explanation
Scenarios come from three broad sources: expert knowledge and regulations (for example the test cases in UN R152 or R157), real-world data such as fleet logs and accident databases, and systematic generation that combines, samples or optimises parameters. ASAM OpenSCENARIO 2.0 structures this through abstraction levels: an abstract scenario captures intent, a logical scenario defines parameter ranges, and a concrete scenario fixes every value.
ISO 34505:2025 defines a method for evaluating scenarios and extending them into test cases with identifiers, objectives, inputs, steps, platforms and expected results. It gives evaluation criteria such as frequency, criticality and complexity, and coverage of requirements and operational domain, plus optimisation of prioritised test-case sets. Tools such as CARLA's ScenarioRunner execute scenarios written in Python or OpenSCENARIO.
Generated scenarios can be physically implausible, behave differently on different simulators, or explode combinatorially as parameters are added. Search methods that hunt for critical cases may concentrate on situations outside the ODD or with negligible real-world likelihood, so plausibility constraints and ODD alignment are needed.
How it works
A logical scenario is defined with parameters, ranges and constraints. A generation strategy is chosen, such as grid sampling, random or importance sampling, or search guided by safety metrics. Concrete scenarios are instantiated, executed and scored; the search can then concentrate around failures or near-misses. The resulting scenarios are exported in a standard format and added to test catalogues.
Automotive applications
- Building regression scenario catalogues
- Searching for critical edge cases
- Converting recorded drives into test scenarios
- Generating variants of regulatory and NCAP tests
Example
A logical pedestrian-crossing scenario has parameters for pedestrian speed (0.5 to 2.5 m/s), ego speed (20 to 60 km/h) and occlusion by a parked van. An optimiser searches for combinations that minimise time-to-collision and outputs a ranked set of concrete OpenSCENARIO files.
An illustrative example: any figures in it are worked numbers, not measurements.
References
- ISO 34505:2025 Road vehicles - Test scenarios for automated driving systems - Scenario evaluation and test case generation (opens in a new tab)
- ASAM OpenSCENARIO 2.0.0: Terms and definitions (opens in a new tab)
- ScenarioRunner documentation (opens in a new tab)
Definitions are original summaries. Standards text is not reproduced; follow the links for the official publications.