displaying data recorded in vehicle
coordinates on a two-dimensional map
around the ego vehicle is an important
part of analyzing sensor coverages and
detections for automated driving
algorithm development in this example
you will learn how to par and plot
recorded sensor data for a scenario on a
bird plot in matlb the data files and
code used in this video can be found in
the matlb example Linked In the
description and can be opened by typing
the following in the command window
I will be talking about plotting lane
information Vision objects and radar
object sections of the example code
today an ego vehicle is defined as the
vehicle that contains the sensors used
for perceiving the environment all
sensors provide information relative to
their positions on the ego vehicle we
will be using one camera and one radar
sensor with long and medium coverage
modes for this video the positions and
orientations of these sensors are as
shown an automated driving system can
contain sensors located anywhere on the
vehicle each sensor contains an origin
in its own sensor coordinate system in
order to use values returned by
individual sensors we transform them
into a unified frame of reference called
the vehicle coordinate system all
vehicles sensors and their related
coordinate systems are placed in the
world coordinate system a world
coordinate system is important in global
path planning localization and
mapping the vehicle coordinate system
used by the automated driving toolbox is
as follows the longitudinal or xaxis
points forward from the vehicle the
lateral or Y axis to the left of the
vehicle and Zed axis points up from the
ground the origin is at the center of
the ego vehicle's rear axle more
information about coordinate systems
used can be found in the
description step one is to redin the
required data from two matat files the
first one contains the sensor
configurations like positions on the ego
vehicle and coverage areas these include
information about the name and type of
the sensors they x y z and and your
positions relative to Ego vehicle origin
sensor field of you and
range the second file consists of
recorded sensor data for 204 time steps
these include object positions reported
by the radar and Camera along with lane
information the radar and lane
information were recorded at 10 updates
per second and the camera at 20 hence
empty arrays are added between every
camera detection in order to show lack
of new
data a single time step worth of data
consists of multiple radar and Camera
points representing the longitude and
lateral object positions along with left
and right lane boundary
information lane information is stored
as a parabolic lane boundary object
which contains information about a
parabolic lane boundary model this model
is of the form y = a x² + b x + C where
a B and C are Lane parameters such as
curvature heading angle distance to left
and right lane lines Etc that can be
obtained from cameras or Lan finding
algorithms step two is creating the bird
ey plot and displaying sensor limits and
coverages a bird ey plot provides a top
down view of a scenario
in this example we will configure and
use a bird's eye plot to visualize
sensor coverages snapshots of all sensor
data in a scenario and a continuous
stream of sensor data a typical bir ey
plot workflow is as follows create a
bird's eye object to store the plots
you're interested in then create a
plotter to configure the display of your
data next plot the data using the
plotter
let's code these steps first create a
bird plot and limit its access to 90 m
in front and 35 M on either side of the
ego vehicle next create the following
plotters a coverage area Potter to plot
the sensor coverages a detection plotter
to plot sensor detections and a lane
boundary plotter to plot Lane
boundaries Loop through the sensor
configurations and plot the sensor
positions ranges and field of use as red
and blue coverage
areas step three is plotting a snapshot
of the data in order to plot all the
data from a single time step extract the
required sensor and Lane data for the
125th time step and store an
appropriately named arrays pass these
arrays along with the previously created
plotters has input to the plot detection
function in order to display this data
on the busza plot the red axis represent
the radar detections the blue triangles
the camera and the black lines the lane
boundaries put step three inside a loop
to continuously plot all the detections
in a
scenario Loop through all the time steps
in the recorded file extract sensor and
Lan information for the current time
step call the plotters use the plot
detection function to plot the data and
finally update the time to the next one
pause for 50 milliseconds for a
realistic display rate if you want to
store the output as a video use get
frame and save each frame in an array
next create a video object and write the
frames to the
object thank you for watching I hope you
enjoyed this video if you are interested
in learning more about birdy plots or
passing and plotting sensor data please
refer to the links in the description
below