| Table of Contents / Calibration / Multi-View | Operators |
get_calib_data — Query data stored or computed in a calibration data model.
get_calib_data( : : CalibDataID, ItemType, ItemIdx, DataName : DataValue)
With the operator get_calib_data, you can query data of the calibration data model CalibDataID. Note that in the following, all 'pose'-related data are given in relation to the coordinate system of the model's reference camera. It can be set or queried by set_calib_data or get_calib_data, respectively.
For ItemType='model', you must pass the value 'general' in ItemIdx. Depending on the selection in DataName, the following model-related data is then returned in DataValue:
Type of the calibration data model. Currently, only models of type 'calibration_object' are supported.
Index of the reference camera for the calibration model. All poses stored in the calibration data model are specified in the coordinate system of this reference camera.
Number of cameras in the calibration data model (see create_calib_data).
Number of calibration objects in the calibration data model (see create_calib_data).
A handle to a camera setup model containing the poses and the internal parameters for the calibrated cameras from the current calibration setup. Note that the returned data handle needs to be cleared by clear_camera_setup_model.
The parameter 'reference_camera' can be set with set_calib_data. The other parameters are set during model creation or are a result of the calibration process and cannot be modified.
With ItemType='camera', you can query data all cameras or for a specific camera.
With ItemIdx='general', the default value of a parameter for all cameras is returned. In contrast, if you pass a valid camera index instead, i.e. a number between 0 and NumCameras-1 (NumCameras is specified during model creation with create_calib_data), only the parameter value of the specified camera is returned.
By selecting the following parameters in DataName, you can query which camera parameters are (or have been) optimized during the calibration performed by calibrate_cameras:
List of the camera parameters that are marked for calibration.
List of camera parameters that are excluded from the calibration.
These parameters can be modified by a corresponding call to set_calib_data.
The following parameters can only be queried for a specific camera, i.e., you must pass a valid camera index in ItemIdx:
Initial internal camera parameters (set with set_calib_data_cam_param).
Optimized internal camera parameters.
Standard deviations of the optimized camera parameters, as estimated at the end of the camera calibration.
Covariance matrix of the optimized camera parameters, as estimated at the end of the camera calibration.
A convenience list of labels for the entries returned by 'params' and 'params_deviations'. This list is camera-type specific.
Initial camera pose , relative to the current reference camera. It is computed internally based on observation poses during the calibration process (see calibrate_cameras).
Optimized camera pose, relative to the current reference camera.
A convenience list of labels for the entries returned by 'pose'.
The calibrated camera parameters ( 'params*' and '*pose*') can be queried only after a successful execution of calibrate_cameras. The initial internal camera parameters 'init_params' can be queried after a successful call to set_calib_data_cam_param.
With ItemType='calib_obj' you can query data for a specific calibration object by passing its index in ItemIdx, i.e. a number between 0 and NumCalibObjects-1 (NumCalibObjects is specified during model creation with create_calib_data).
The following parameters can be queried with DataName and are returned in DataValue:
Number of markers in the calibration object.
Coordinates of the markers relative to the calibration object coordinate system.
These parameters can be modified with set_calib_data_calib_object.
With ItemType='calib_obj_pose' you can query general settings for all calibration object poses, or data for a specific calibration object pose.
With ItemIdx='general', the default value of a parameter for all calibration object poses is returned. In contrast, if you pass a valid calibration object index instead, i.e., a tuple containing a valid index pair [CalibObjIdx, CalibObjPoseIdx], only the parameter value of the specified calibration object pose is returned.
By selecting the following parameters in DataName, you can query which calibration object pose parameters are (or have been) optimized during the calibration performed by calibrate_cameras:
List of calibration object pose parameters marked for calibration.
List of calibration object pose parameters excluded from calibration.
These parameters can be set with set_calib_data.
The following parameters can only be queried for a specific calibration object pose, i.e., you must pass a valid index pair [CalibObjIdx, CalibObjPoseIdx] in ItemIdx:
Initial calibration object pose. It is computed internally based on observation poses during the calibration process (see calibrate_cameras). This pose is relative to the current reference camera.
Optimized calibration object pose, relative to current reference camera.
A convenience list of labels for the entries returned by 'pose'.
These parameters cannot be explicitly modified and can only be queried after calibrate_cameras was executed.
A camera calibration data model CalibDataID cannot be shared between two or more user's threads. Different camera calibration data models can be used independently and safely in different threads.
Handle of a calibration data model.
Type of calibration data item.
Default value: 'camera'
List of values: 'model', 'camera', 'calib_obj', 'calib_obj_pose'
Index of the affected item (depending on the selected ItemType).
Default value: 0
Suggested values: 0, 1, 2, 'general'
The name of the inspected data.
Default value: 'params'
List of values: 'type', 'reference_camera', 'num_cameras', 'num_calib_objs', 'camera_setup_model', 'num_markers', 'x', 'y', 'z', 'params', 'pose', 'init_params', 'init_pose', 'params_deviations', 'params_covariances', 'params_labels', 'pose_labels', 'calib_settings', 'excluded_settings'
Requested data.
* get the camera type of camera 0 get_calib_data (CalibDataID, 'camera', 0, 'type', CameraType) * get the optimized (calibrated) pose of pose 1 of the * calibration object 2 get_calib_data (CalibDataID, 'calib_obj_pose', [2,1], 'pose', CalobjPose)
calibrate_cameras, create_calib_data, read_calib_data
Calibration
| Table of Contents / Calibration / Multi-View | Operators |
| HALCON Reference Manual 10.0.2 | Copyright © 1996-2011 MVTec Software GmbH |