Introduction to Scenario Editor

Scenario Editor is a tool for the creation, modification and storage of scenarios for use in rFpro and Dymola. Scenario Editor allows users to view an OpenDRIVE map (.xodr file) and then plot a route around the road network while adding events such as stops and lane changes. For Dymola, this defines the behaviour of a single vehicle whereas for rFpro we can define and synchronise the movement of multiple vehicles. It’s also possible to define routes that don’t follow the road network but rather are defined as a series of waypoints anywhere around the map. This is primarily used to define trajectories for things like pedestrians or drones.

User Interface

When you first open the Scenario Editor you will see an empty space into which you load the OpenDRIVE map, a route list showing you the lanes selected or waypoints created and a dropdown list of all the routes in the current scenario, along with a number of buttons that allow for modification of the scenario. In the screenshot below one of the OpenDRIVE sample roads has been loaded.

Scenario editor with one of the OpenDRIVE sample roads loaded
Figure 1: Scenario editor with one of the OpenDRIVE sample roads loaded

Plotting a route

Once a file has been opened and displayed, you can then use the plot to plan a route along the drawn lines by simply clicking on the lane where you wish the route to begin. After that, every lane that is connected to the one you have selected is highlighted so you can pick the next appropriate lane to drive in. As you select lanes, nodes will be added to the route list shown as IDs of the lanes. Some nodes will have child nodes that represent events (lane change, turning on the lights) that occur on this lane. Double clicking these child nodes will allow you to edit or delete these events. While plotting a route you may undo the last lane selection and enable an auto select feature which will automatically select the next lane if there is only one option.

Waypoint route

The Scenario Editor also allows you to create routes using waypoints by a simple toggle to switch between the waypoint system or the lane system. In the waypoint system you can select any point to create a waypoint. A smooth curve will be fitted through the waypoints to show the actual trajectory that will be followed. The route list allows you to go back and modify the waypoints.

Adding events

Various events can be added to the scenario through the UI buttons. Each event has a new dialog box that allows for customisation of the event. Each event occurs within a particular lane in the route and will be added to the route list as a child of the lane where the event will happen. This also allows for later editing or deleting of the event.

All events, except for a few that occur at the start of the scenario, such as the initial speed/acceleration profile, allow you to choose a point within the lane where the event will occur. For example, when creating a stopping point, you will be able to select where the stop occurs and for how long the vehicle should stop.

Multiple routes

For use with rFpro and the Claytex Simulation Manager, we use the Scenario Editor to define the routes for multiple traffic vehicles. Each route gets a name to make it easy to identify later as can be seen in the screenshot below. You can synchronise the time at which the vehicles will reach specific points on their route allowing you to setup near-miss or accident scenarios as well as defining routine driving tasks.

Scenario Editor with multiple routes defined
Figure 2: Scenario Editor with multiple routes defined

Exporting scenario

There are three ways of exporting information from the Scenario Editor which are by creating a route file, a trajectory file or an MRoute file.

  1. A route file contains all the needed information to add a single route to a scenario.
  2. A trajectory file contains a series of tables inside of a .mat file. This is the format required by Dymola to define the road and driver actions for use with a VeSyMA vehicle model. The same trajectory file is also with rFpro to define what the ego vehicle driver models should do or the trajectory of an individual traffic vehicle.
  3. The MRoute file is currently the only method of exporting a complete scenario rather than a single route. The MRoute file is then read by Simulation Manager to configure the ego and traffic that will then be simulated in rFpro.

Written by Adam Smedley – Software Developer

Please get in touch if you have any questions or have got a topic in mind that you would like us to write about. You can submit your questions / topics via: Tech Blog Questions / Topic Suggestion

Swiss Replica Watches

CONTACT US

Got a question? Just fill in this form and send it to us and we'll get back to you shortly.

Sending

© Copyright 2010-2021 Claytex Services Ltd All Rights Reserved

Rolex Replica Watches Rolex Daytona Replica Watches Rolex GMT-Master II Replica Watches Rolex Submariner Replica Watches Rolex Yacht-Master Replica Watches

Log in with your credentials

Forgot your details?