Train PointPillars object detector
Train a Detector
Resume Training a Detector
trainingData — Input training data
valid datastore object | table
Training data, specified as a valid datastore object or table.
If you use a datastore object, your data must be set up such that using the
readfunction on the datastore object returns a cell array or table with three columns. Each row corresponds to a point cloud, and the columns must follow this format.
First column — Organized or unorganized point cloud data, specified as a
Second column — Bounding boxes, specified as a cell array containing an M-by-9 matrix. Each row of the matrix is of the form [x y z length width height roll pitch yaw], representing the location and dimension of a bounding box. M is the number of bounding boxes.
Third column — Labels, specified as a cell array containing an M-by-1 categorical vector with object class names. All categorical data returned by the datastore must use the same pool of categories.
If you use a table, the table must have two or more columns. The first column must contain point cloud file names. The point cloud files can be in any format supported by
pcreadfunction. Each of the remaining columns represent a single object class such as Car, or Truck containing cell vectors. Each cell contains an M-by-9 matrix, M is the number of bounding boxes. The columns of the each matrix are of the form [x y z length width height roll pitch yaw], specifying the location and dimensions of the bounding box in the corresponding point cloud.
You can generate the input training data from labeled ground truth samples by using
detector — PointPillars object detector
PointPillars object detector, specified as a
You can train an untrained object detector using the training options.
You can continue training a pretrained detector with additional training data, or perform more training iterations to improve detector accuracy.
options — Training options
TrainingOptionsSGDM object |
TrainingOptionsRMSProp object |
Training options, specified as a
object returned by the
trainingOptions (Deep Learning Toolbox) function. To specify the
solver name and other options for network training, use the
trainingOptions (Deep Learning Toolbox) function.
trainPointPillarsObjectDetector function supports these
|Name-Value Arguments||Supported Options|
checkpoint — Saved detector checkpoint
Saved detector checkpoint, specified as a
pointPillarsObjectDetector object. To periodically save a detector
checkpoint during training, specify
CheckpointPath. To control how
frequently check points are saved see the
CheckPointFrequencyUnit training options.
To load a checkpoint for a previously trained detector, first load the corresponding
MAT file from the checkpoint path. Then extract the object detector from the loaded
data. For example, if the
CheckpointPath property of your
options object is
'/checkpath', you can load a
checkpoint MAT file by using this code.
data = load("/checkpath/pointpillars_checkpoint__216__2018_11_16__13_34_30.mat"); checkpoint = data.detector;
The name of the MAT file includes the iteration number and timestamp of when the
detector checkpoint was saved. The MAT file saves the detector in the
detector variable. Use the
trainPointPillarsObjectDetector function to train the
pointPillarsDetector = trainPointPillarsObjectDetector(trainingData,checkpoint,options);
detector — Trained PointPillars object detector
Trained PointPillars object detector, returned as
info — Training progress information
Training progress information, returned as a structure array with these fields. Each field corresponds to a stage of training.
TrainingLoss— Training loss at each iteration. The training loss is the mean squared error (MSE), calculated as the sum of the localization error, confidence loss, and classification loss.
ValidationLoss— Validation loss at each iteration.
Each field is a numeric vector with one element per training iteration. If the
function does not calculate a value at a specific iteration, it returns a value of
NaN for that iteration. The structure contains
ValidationLoss only when
trainingOptions(Deep Learning Toolbox) |
- Lidar 3-D Object Detection Using PointPillars Deep Learning
- Code Generation For Lidar Object Detection Using PointPillars Deep Learning
- Unorganized to Organized Conversion of Point Clouds Using Spherical Projection
- Getting Started with PointPillars
- Getting Started with Point Clouds Using Deep Learning
- Datastores for Deep Learning (Deep Learning Toolbox)