The NVIDIA® DriveWorks Intrinsics Constraints tool extracts intrinsics constraints used during calibration for each individual camera. It takes any of the following as input:
It then exports all required constraints in a JSON file, placed in the intrinsics subfolder in the directory structure.
This tool is available on the x86 Host System and NVIDIA DRIVE™ OS Linux.
This tool creates output files that are placed into the current working directory by default. Please ensure the following for your convenience:
The Intrinsics Constraints tool accepts the following parameters. Several of these parameters are required based on the input type.
For more information, please refer to the Examples.
./calibration-intrinsics-constraints --use-checkerboard=11x8
--targetDB=[targetDB_file_path]
--input-video=/[video_path]/camera-0.h264
--input-folder=[folder_path]
--output=/[calib_data_path]/intrinsics/camera-0.json
--camera-model=[ftheta]
--rig=[path/to/rig/file]
[--max-constraints=0]
[--skipFrameCount=0]
--use-checkerboard=[NxN checkerboard grid]
Description: The input NxN checkerboard grid.
Example: --use-checkerboard=12x9
--targetDB=[path to targetDB file, default=]
Description: Path to AprilTag target database. Enables detection of AprilTag targets. Either this or [targetDB] must be supplied.
--input-video=[path to input video]
Description: The file path where the input video is, for checkerboards and AprilTag videos.
--input-folder=[path to input folder]
Description: The file path where the input folder is, for still frames with AprilTag targets.
--output=[path to output file]
Description: The file path where the intrinsics constraints will be saved.
If this parameter is blank, they will automatically be saved to '[input-video].json'.
--camera-model=[camera model, default=ftheta]
Description: Camera model used for calibration. Available options are: [pinhole, ocam, ftheta]. The camera model is not used in any way for extracting the constraints. It is passed directly into the produced json file and may be used by other tools.
--rig=[path to rig file, default=]
Description: Rig file with initial guess of camera intrinsics. Only available for `ftheta` calibration.
--max-constraints=[integer, default=0]
Description: If non-zero, the maximum number of constraints after which stopping the intrinsic constraint extraction process.
--skipFrameCount=[integer, default=0]
Description: Number of frames to skip at the beginning of the video.
./calibration-intrinsics-constraints --use-checkerboard=11x8
--input-video=/[video_path]/camera-0.h264
--output=/[calib_data_path]/intrinsics/camera-0.json
./calibration-intrinsics-constraints --targetDB=/[calib_data_path]/targets.json
--input-video=/[video_path]/camera-0.h264
--output=/[calib_data_path]/intrinsics/camera-0.json
./calibration-intrinsics-constraints --targetDB=/[calib_data_path]/targets.json
--input-folder=[folder_path]
--output=/[calib_data_path]/intrinsics/external.json
The tool will open a window playing back the input video and indicate with a red or green border if a new intrinsic constraint has been collected (i.e. target or checkerboard has been found)