Skip to content

CLI Application

The CLI trainer application allows you to train CAD targets via a terminal application.

Train CAD

  1. Starting the trainer application with no argument, or -h, or -help displays usage instructions.

  2. To run CAD training you need to set the

    • output directory,
    • input configuration (e.g. defaultCADTargetTrainingConfig.json),
    • CAD file,
    • camera calibration

Detail Camera Calibration:

The target data files must be generated with the camera intrinsics of the target device (Device used for tracking). To get a suitable calibration file for the trainer application, please follow the instructions on Camera Calibration

Limitation: CAD Target Tracking currently only supports 640 x 480 input resolution (landscape mode).

When the target should be tracked with a different camera (different FOV / different focal length) the target data needs to be retrained accordingly!

Detail Input Configuration:

The input configuration is a JSON file containing the following content:

{
"Config.Target.Type": "CAD",
"Config.Target.Name": "targetname",
"CAD.UprightVector": [ 0.0, 1.0, 0.0 ],
"CAD.Detection.DistanceRange": [ 0.3, 0.6 ],
"CAD.Detection.NumTrainingViews": 1000,
"CAD.Detection.ElevationAngleRange": [10.0, 70.0]
}

Configuration parameter explanation:

Config.Target.Type
Always use "CAD" for CAD Training.

Config.Target.Name
The name of the Target. Allowed characters: 'a-z' 'A-Z' '0-9' '_'.

CAD.UprightVector
A vector that defines the upright axis of the object. By default, the upright axis is defined as the Y-axis of the model, and therefore [0.0, 1.0, 0.0].

CAD.Detection.DistanceRange
Defines the distance range in meter from which the object should be detectable. A larger range can lead to more false positive detections and slower runtime.

CAD.Detection.NumTrainingViews
Defines the number of viewpoints used for training. More viewpoints mean a higher chance of detecting the correct object pose within the defined viewpoint space, but also increase the runtime.

CAD.Detection.ElevationAngleRange
The minimum and maximum elevation angle in degrees from which the object should be detectable.

Angle Description
90° Top-down view
Horizontal view
-90° Bottom-up view

It is recommended to use a range similar to [10.0°, 70.0°]. In this case, the object cannot be detected when viewed from top-down or bottom-up. Note that a larger range can lead to more false positive detections and slower runtime.

Info

Batch training of CAD targets is not possible.

Back to top