Main Content

Lidar Labeler

Label ground truth data in lidar point clouds

Description

The Lidar Labeler app enables you to label objects in a point cloud or a point cloud sequence. The app reads point cloud data from PLY, PCAP, LAS, LAZ, ROS and PCD files. Using the app, you can:

  • Define cuboid region of interest (ROI) labels and scene labels. Use them to interactively label your ground truth data.

  • Define attributes for the labels and use them to provide further detail about the labels.

  • Use built-in algorithms for clustering, ground plane segmentation, automated labeling, and tracking.

  • Save label definitions, point cloud data, and ground truth data to a session file for future use.

  • Use the Projected View option to view the labels in top, front and side views simultaneously.

  • Use the Camera View option to create and reuse custom views of the point cloud data.

  • Use the Auto Align option to rotate and best fit the cuboid to the cluster.

  • Use the lidar.syncImageViewer.SyncImageViewer class to sync the app to an external visualization or analysis tool.

  • Write, import, and use a custom automation algorithm for automated labeling.

  • Evaluate the performance of your label automation algorithms with a visual summary.

  • Export the labeled ground truth as a groundTruthLidar object. This object can be used for system verification and training an object detector.

To learn more about this app, see Get Started with the Lidar Labeler.

Lidar Labeler App

Open the Lidar Labeler App

  • MATLAB® Toolstrip: On the Apps tab, under Image Processing and Computer Vision, click the app icon.

  • MATLAB command prompt: Enter lidarLabeler.

Programmatic Use

expand all

lidarLabeler opens a new session of the app, enabling you to label ground truth data in point clouds.

lidarLabeler(velodyneLidarFileName,deviceModel,calibrationFile) opens the app and loads the velodyneLidarFileName.

lidarLabeler(ptCloudSeqFolder) opens the app and loads the point cloud sequence from the folder ptCloudSeqFolder, where ptCloudSeqFolder is a string scalar or character vector specifying a folder that contains point cloud files. The point cloud files must have extensions supported by pcformats, and are loaded in the order returned by the dir function.

lidarLabeler(lasSeqFolder) opens the app and loads the LAS sequence from the folder lasSeqFolder, where lasSeqFolder is a string scalar or character vector specifying a folder contains LAS files. LAS files must have extensions supported by lasformats, and are loaded in the order returned by the dir function.

lidarLabeler(___,'SyncImageViewerTargetHandle',syncImageViewer) opens the app and loads both of these components:

  • A point cloud signal, specified using any of the input argument combinations from previous syntaxes.

  • An external video or image sequence display tool that is time-synchronized with the specified point cloud signal.

The syncImageViewer input is a handle to a lidar.syncImageViewer.SyncImageViewer class that implements the external tool.

For example, this code opens the app with a point cloud signal and synchronized video visualization tool.

sourceName = fullfile(toolboxdir('lidar'),'lidardata','lcc', ...
                      'HDL64','pointCloud');
lidarLabeler(sourceName,'SyncImageViewerTargetHandle',@SyncImageDisplay)

lidarLabeler(sessionFile) opens the app and loads a saved app session sessionFile. The sessionFile input contains the path and file name of a MAT-file. The MAT-file that sessionFile points to contains the saved session.

Limitations

  • The labels do not support sublabels.

  • The Label Summary window does not support sublabels.

More About

expand all

Tips

  • Use the lidar.syncImageViewer.SyncImageViewer class to create a tool for viewing the image corresponding to the point cloud data.

  • Remove the ground plane to clearly view the created object labels.

  • Use the rotate, translate, expand, and shrink options to edit the cuboids after drawing them.

  • Use the Camera View option to save the a view of the data from the current angle and direction.

  • To avoid having to relabel ground truth with new labels, organize the labeling scheme you want to use before you begin marking your ground truth.

  • You can copy and paste the labels between signals that are of the same type.

Algorithms

expand all

You can use label automation algorithms to speed up labeling within the app. To create your own label automation algorithm to use within the app, see Create Automation Algorithm for Labeling. You can also use one of the provided built-in algorithms. Follow these steps:

  1. Load the data you want to label, and create at least one label definition.

  2. On the app toolstrip, click Select Algorithm, and select one of the built-in automation algorithms.

  3. Click Automate, and then follow the automation instructions in the right pane of the automation window.

Introduced in R2020b