NVIDIA DeepStream SDK API Reference

9.2 Release
ObjectModelProjector Class Reference

Detailed Description

Project and recover target geometry using camera and object models.

Definition at line 184 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Collaboration diagram for ObjectModelProjector:

Public Member Functions

 ObjectModelProjector ()
 Construct an uninitialized object-model projector. More...
 
 ObjectModelProjector (const std::string &configFilePath)
 Construct an object-model projector from configuration. More...
 
 ObjectModelProjector (const std::string &configFilePath, const NvMotDataTypes::Size imgSize, const NvMOTStreamId streamId)
 Construct and initialize a projector for a source stream. More...
 
 ObjectModelProjector (const std::string &configFilePath, const NvMotDataTypes::Size imgSize, const NvMOTStreamId streamId, const std::string &sensorName)
 Construct and initialize a projector for a named source sensor. More...
 
virtual ~ObjectModelProjector ()
 Destroy the object-model projector. More...
 
void queryParams (NvMOTQuery &paramsQuery)
 Populate tracker query capabilities from projector configuration. More...
 
bool isInitialized ()
 Return whether the projector has been initialized. More...
 
const std::string & getSensorName () const
 Return the source sensor name. More...
 
RecoveredObjModel getRecoveredObjectModelFromBbox (const NvMOTObjToTrack *detObj, const NvMOTFrameNum frameNum, const int targetInd, const bool isInitEstimation)
 Recover an object model from a detector bounding box. More...
 
RecoveredObjModel getRecoveredObjectModelFromProj3DBbox (const NvMOTObjToTrack *detObj, const NvMOTFrameNum frameNum)
 Recover an object model from externally projected three-dimensional bounding-box data. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgFeet (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space feet point. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgWaist (const Eigen::Vector2d pt_img_waist, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space waist point. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgHead (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space head point. More...
 
RecoveredObjModel getRecoveredObjectModelWithAdaptiveHeight (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_waist, const Eigen::Vector2d pt_img_foot, const NvMotDataTypes::Rect2f &bbox, const TrackerIndex &targetInd, const NvMOTClassId classId, float conf_head, float conf_waist, float conf_foot)
 Get recovered 3D cylinder model with dynamic height from pose keypoints. More...
 
Eigen::Vector2d computeHeightAndWorldFeetFromHeadAndWaist (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_waist, const TrackerIndex &targetInd, const NvMOTClassId classId)
 Estimate target height and world feet position from image head and waist points. More...
 
Eigen::Vector2d computeHeightAndWorldFeetFromHeadAndFoot (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_foot, const TrackerIndex &targetInd, const NvMOTClassId classId)
 Estimate target height and world feet position from image head and foot points. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from world-space feet coordinates. More...
 
const std::vector< Eigen::Vector2d > getProjectedWorldGroundPts (const std::vector< Eigen::Vector2d > &pt_world_feet_list)
 Project world-ground points into image coordinates. More...
 
const Eigen::Vector2d getCamHeadPtFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image waist point to the corresponding image head point. More...
 
const Eigen::Vector2d getCamWaistPtFromCamHeadPt (const Eigen::Vector2d imgHeadPt, const NvMOTClassId classId, const int targetInd)
 Map an image head point to the corresponding image waist point. More...
 
const Eigen::Vector2d getCamWaistPtFromCamFeetPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image feet point to the corresponding image waist point. More...
 
const Eigen::Vector2d getCamFeetPtFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image waist point to the corresponding image feet point. More...
 
const Eigen::Vector2d getWorldFeetPtOnGroundFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Recover world-ground feet coordinates from an image waist point. More...
 
const Eigen::Vector2d getWorldFeetPtOnGroundFromCamFeetPt (const Eigen::Vector2d imgFeetPt, const NvMOTClassId classId, const int targetInd)
 Recover world-ground feet coordinates from an image feet point. More...
 
const NvDsObj3DBbox getWorld3DBboxFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Build a world-space three-dimensional bounding box from feet coordinates. More...
 
std::vector< Eigen::Vector2d > calculateProjCornersOf3DBboxFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project the eight corners of a world-space three-dimensional bounding box. More...
 
const Eigen::Vector2d projectWorldPt2ImgPt (const Eigen::Vector3d pt_world)
 Project a world-space point into image coordinates. More...
 
bool isTargetVisibleInImage (const Eigen::Vector2d &pt_world_feet, float targetHeight)
 Check if any point of a vertical target (from feet to head) projects into the camera FOV. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCircleFromWorldFeet (const Eigen::Vector2d pt_world_feet, const float radius)
 Project a horizontal circle centered at world-space feet coordinates. More...
 
const bool getOutputFootLocation ()
 Return whether foot-location output is enabled. More...
 
const bool getOutputConvexHull ()
 Return whether convex-hull output is enabled. More...
 
float getMinPoseConfidence () const
 Return the minimum pose-keypoint confidence. More...
 
Eigen::Matrix2d computeGroundCovariance (const Eigen::Vector2d &pixel_pt, float pixel_sigma)
 Compute ground plane position covariance from pixel uncertainty using Jacobian. More...
 
float getTargetHeight () const
 Return the current target-model height. More...
 
float getHeightConfidence () const
 Return the current height-estimation confidence. More...
 
void setTargetHeight (float height, float confidence, bool force=false)
 Update target-model height when confidence permits. More...
 
void setTargetModelForClass (NvMOTClassId classId)
 Select the target model for a class ID. More...
 
NvMOTClassId getTargetClassId () const
 Return the current target-model class ID. More...
 
 ObjectModelProjector ()
 Construct an uninitialized object-model projector. More...
 
 ObjectModelProjector (const std::string &configFilePath)
 Construct an object-model projector from configuration. More...
 
 ObjectModelProjector (const std::string &configFilePath, const NvMotDataTypes::Size imgSize, const NvMOTStreamId streamId)
 Construct and initialize a projector for a source stream. More...
 
 ObjectModelProjector (const std::string &configFilePath, const NvMotDataTypes::Size imgSize, const NvMOTStreamId streamId, const std::string &sensorName)
 Construct and initialize a projector for a named source sensor. More...
 
virtual ~ObjectModelProjector ()
 Destroy the object-model projector. More...
 
void queryParams (NvMOTQuery &paramsQuery)
 Populate tracker query capabilities from projector configuration. More...
 
bool isInitialized ()
 Return whether the projector has been initialized. More...
 
const std::string & getSensorName () const
 Return the source sensor name. More...
 
RecoveredObjModel getRecoveredObjectModelFromBbox (const NvMOTObjToTrack *detObj, const NvMOTFrameNum frameNum, const int targetInd, const bool isInitEstimation)
 Recover an object model from a detector bounding box. More...
 
RecoveredObjModel getRecoveredObjectModelFromProj3DBbox (const NvMOTObjToTrack *detObj, const NvMOTFrameNum frameNum)
 Recover an object model from externally projected three-dimensional bounding-box data. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgFeet (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space feet point. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgWaist (const Eigen::Vector2d pt_img_waist, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space waist point. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromImgHead (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from an image-space head point. More...
 
RecoveredObjModel getRecoveredObjectModelWithAdaptiveHeight (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_waist, const Eigen::Vector2d pt_img_foot, const NvMotDataTypes::Rect2f &bbox, const TrackerIndex &targetInd, const NvMOTClassId classId, float conf_head, float conf_waist, float conf_foot)
 Get recovered 3D cylinder model with dynamic height from pose keypoints. More...
 
Eigen::Vector2d computeHeightAndWorldFeetFromHeadAndWaist (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_waist, const TrackerIndex &targetInd, const NvMOTClassId classId)
 Estimate target height and world feet position from image head and waist points. More...
 
Eigen::Vector2d computeHeightAndWorldFeetFromHeadAndFoot (const Eigen::Vector2d pt_img_head, const Eigen::Vector2d pt_img_foot, const TrackerIndex &targetInd, const NvMOTClassId classId)
 Estimate target height and world feet position from image head and foot points. More...
 
const NvMotDataTypes::Rect2f getBboxOfProjectedCylinderFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder bounding box from world-space feet coordinates. More...
 
const std::vector< Eigen::Vector2d > getProjectedWorldGroundPts (const std::vector< Eigen::Vector2d > &pt_world_feet_list)
 Project world-ground points into image coordinates. More...
 
const Eigen::Vector2d getCamHeadPtFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image waist point to the corresponding image head point. More...
 
const Eigen::Vector2d getCamWaistPtFromCamHeadPt (const Eigen::Vector2d imgHeadPt, const NvMOTClassId classId, const int targetInd)
 Map an image head point to the corresponding image waist point. More...
 
const Eigen::Vector2d getCamWaistPtFromCamFeetPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image feet point to the corresponding image waist point. More...
 
const Eigen::Vector2d getCamFeetPtFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Map an image waist point to the corresponding image feet point. More...
 
const Eigen::Vector2d getWorldFeetPtOnGroundFromCamWaistPt (const Eigen::Vector2d imgWaistPt, const NvMOTClassId classId, const int targetInd)
 Recover world-ground feet coordinates from an image waist point. More...
 
const Eigen::Vector2d getWorldFeetPtOnGroundFromCamFeetPt (const Eigen::Vector2d imgFeetPt, const NvMOTClassId classId, const int targetInd)
 Recover world-ground feet coordinates from an image feet point. More...
 
const NvDsObj3DBbox getWorld3DBboxFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Build a world-space three-dimensional bounding box from feet coordinates. More...
 
std::vector< Eigen::Vector2d > calculateProjCornersOf3DBboxFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project the eight corners of a world-space three-dimensional bounding box. More...
 
const Eigen::Vector2d projectWorldPt2ImgPt (const Eigen::Vector3d pt_world)
 Project a world-space point into image coordinates. More...
 
bool isTargetVisibleInImage (const Eigen::Vector2d &pt_world_feet, float targetHeight)
 Check if any point of a vertical target (from feet to head) projects into the camera FOV. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCircleFromWorldFeet (const Eigen::Vector2d pt_world_feet, const float radius)
 Project a horizontal circle centered at world-space feet coordinates. More...
 
const bool getOutputFootLocation ()
 Return whether foot-location output is enabled. More...
 
const bool getOutputConvexHull ()
 Return whether convex-hull output is enabled. More...
 
float getMinPoseConfidence () const
 Return the minimum pose-keypoint confidence. More...
 
Eigen::Matrix2d computeGroundCovariance (const Eigen::Vector2d &pixel_pt, float pixel_sigma)
 Compute ground plane position covariance from pixel uncertainty using Jacobian. More...
 
float getTargetHeight () const
 Return the current target-model height. More...
 
float getHeightConfidence () const
 Return the current height-estimation confidence. More...
 
void setTargetHeight (float height, float confidence, bool force=false)
 Update target-model height when confidence permits. More...
 
void setTargetModelForClass (NvMOTClassId classId)
 Select the target model for a class ID. More...
 
NvMOTClassId getTargetClassId () const
 Return the current target-model class ID. More...
 

Protected Member Functions

const Eigen::MatrixXd convertYamlVec2EigenMatrixXd (YAML::Node yamlVec, const int rows, const int cols)
 Convert a nested YAML sequence to an Eigen matrix. More...
 
bool importCameraModelInfo (const std::string filename)
 Import camera-model calibration from a YAML file. More...
 
bool importExternalProj3DBboxInfo (const std::string filename)
 Import externally projected three-dimensional bounding boxes. More...
 
const Model3DInfo & getDefaultModelByClass (const NvMOTClassId classId)
 Return the default three-dimensional model for a class. More...
 
const TargetHomography & getDefaultHomographyMatByClass (const NvMOTClassId classId)
 Return the default homographies for a class. More...
 
void deriveDataFromCameraProjMatrix (TargetHomography &homographyMat, const Model3DInfo &humanModel)
 Derive target-plane homographies from the camera projection matrix. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgWaist (const Eigen::Vector2d pt_img_waist, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space waist point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgHead (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space head point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgFeet (const Eigen::Vector2d pt_img_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space feet point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from world-space feet coordinates. More...
 
bool isTargetModelValid (TrackerIndex targetInd, NvMOTClassId classId)
 Return whether the current target model is valid for a target. More...
 
const Eigen::MatrixXd convertYamlVec2EigenMatrixXd (YAML::Node yamlVec, const int rows, const int cols)
 Convert a nested YAML sequence to an Eigen matrix. More...
 
bool importCameraModelInfo (const std::string filename)
 Import camera-model calibration from a YAML file. More...
 
bool importExternalProj3DBboxInfo (const std::string filename)
 Import externally projected three-dimensional bounding boxes. More...
 
const Model3DInfo & getDefaultModelByClass (const NvMOTClassId classId)
 Return the default three-dimensional model for a class. More...
 
const TargetHomography & getDefaultHomographyMatByClass (const NvMOTClassId classId)
 Return the default homographies for a class. More...
 
void deriveDataFromCameraProjMatrix (TargetHomography &homographyMat, const Model3DInfo &humanModel)
 Derive target-plane homographies from the camera projection matrix. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgWaist (const Eigen::Vector2d pt_img_waist, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space waist point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgHead (const Eigen::Vector2d pt_img_head, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space head point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromImgFeet (const Eigen::Vector2d pt_img_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from an image-space feet point. More...
 
std::vector< Eigen::Vector2d > calculateProjectedCylinderFromWorldFeet (const Eigen::Vector2d pt_world_feet, const NvMOTClassId classId, const int targetInd)
 Project a cylinder from world-space feet coordinates. More...
 
bool isTargetModelValid (TrackerIndex targetInd, NvMOTClassId classId)
 Return whether the current target model is valid for a target. More...
 

Protected Attributes

bool m_isInit
 Indicates whether the projector has been initialized. More...
 
uint m_streamInd
 Index of the corresponding source stream. More...
 
std::string m_sensorName
 Sensor name of the corresponding source stream. More...
 
const std::string m_configFilePath
 Path of the module config file. More...
 
std::string m_resolvedCameraModelFilepath
 Resolved camera model filepath for this stream. More...
 
NvTrackerParamsObjectModelProjector m_params
 Config params for target management. More...
 
NvMotDataTypes::Size m_srcFrameSize
 Source video frame size where the bbox info is based on. More...
 
CameraInfo m_cameraInfo
 Set camera parameters. More...
 
std::vector< std::vector< Proj3DBboxInfo > > m_externalProj3DBboxInfo
 Store projected 3D bounding box info for all frames in the stream. More...
 
Model3DInfo m_targetModel
 Each target's object model can be different in size. More...
 
NvMOTClassId m_targetClassId
 Projector's current target model class ID. More...
 
std::map< NvMOTClassId, Model3DInfo > m_defaultModelByClass
 Each class's object model. More...
 
float m_groundPlaneHeight
 Specifies the world-space ground-plane height. More...
 
CameraMatrix m_ProjMat_World2Cam
 Stores the world-to-camera projection matrix. More...
 
IntrinsicMatrix m_K
 Intrinsic matrix. More...
 
IntrinsicMatrix m_K_inv
 Inverse of intrinsic matrix. More...
 
RotationMatrix m_R
 Rotation matrix (world to camera). More...
 
RotationMatrix m_R_T
 Transpose of rotation matrix. More...
 
TranslationMatrix m_t
 Translation vector. More...
 
Eigen::Vector2d m_pix2cam_offset
 Shifts corner-origin pixels to the optical center for projectionMatrix_3x4. More...
 
HomographyMatrix m_H_ground
 Ground-plane homography, independent of target height. More...
 
HomographyMatrix m_H_ground_inv
 Inverse of ground plane homography. More...
 
Eigen::Vector3d m_r3
 Third row of R^T (for ground plane intersection). More...
 
Eigen::Vector3d m_P_z_col
 P[:,2] - projection matrix Z column (height update direction). More...
 
Eigen::Vector3d m_H_inv_Pz
 H_ground_inv * P_z_col (precomputed for Sherman-Morrison). More...
 
TranslationMatrix m_camLocation_World
 Camera position in world coordinate system. More...
 
TargetHomography m_targetHomographyMat
 Homography matrices for head, waist, and feet planes composed from the projection matrix. More...
 
std::map< NvMOTClassId, TargetHomography > m_defaultHomographyMatByClass
 Stores default target homographies by class. More...
 

Constructor & Destructor Documentation

◆ ObjectModelProjector() [1/8]

ObjectModelProjector::ObjectModelProjector ( )

Construct an uninitialized object-model projector.

◆ ObjectModelProjector() [2/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath)

Construct an object-model projector from configuration.

Parameters
[in]configFilePathPath to the configuration file.

◆ ObjectModelProjector() [3/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath,
const NvMotDataTypes::Size  imgSize,
const NvMOTStreamId  streamId 
)

Construct and initialize a projector for a source stream.

Parameters
[in]configFilePathPath to the configuration file.
[in]imgSizeSource image size.
[in]streamIdSource stream identifier.

◆ ObjectModelProjector() [4/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath,
const NvMotDataTypes::Size  imgSize,
const NvMOTStreamId  streamId,
const std::string &  sensorName 
)

Construct and initialize a projector for a named source sensor.

Parameters
[in]configFilePathPath to the configuration file.
[in]imgSizeSource image size.
[in]streamIdSource stream identifier.
[in]sensorNameSource sensor name.

◆ ~ObjectModelProjector() [1/2]

virtual ObjectModelProjector::~ObjectModelProjector ( )
virtual

Destroy the object-model projector.

◆ ObjectModelProjector() [5/8]

ObjectModelProjector::ObjectModelProjector ( )

Construct an uninitialized object-model projector.

◆ ObjectModelProjector() [6/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath)

Construct an object-model projector from configuration.

Parameters
[in]configFilePathPath to the configuration file.

◆ ObjectModelProjector() [7/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath,
const NvMotDataTypes::Size  imgSize,
const NvMOTStreamId  streamId 
)

Construct and initialize a projector for a source stream.

Parameters
[in]configFilePathPath to the configuration file.
[in]imgSizeSource image size.
[in]streamIdSource stream identifier.

◆ ObjectModelProjector() [8/8]

ObjectModelProjector::ObjectModelProjector ( const std::string &  configFilePath,
const NvMotDataTypes::Size  imgSize,
const NvMOTStreamId  streamId,
const std::string &  sensorName 
)

Construct and initialize a projector for a named source sensor.

Parameters
[in]configFilePathPath to the configuration file.
[in]imgSizeSource image size.
[in]streamIdSource stream identifier.
[in]sensorNameSource sensor name.

◆ ~ObjectModelProjector() [2/2]

virtual ObjectModelProjector::~ObjectModelProjector ( )
virtual

Destroy the object-model projector.

Member Function Documentation

◆ calculateProjCornersOf3DBboxFromWorldFeet() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjCornersOf3DBboxFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Project the eight corners of a world-space three-dimensional bounding box.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjCornersOf3DBboxFromWorldFeet() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjCornersOf3DBboxFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Project the eight corners of a world-space three-dimensional bounding box.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCircleFromWorldFeet() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCircleFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const float  radius 
)

Project a horizontal circle centered at world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]radiusCircle radius.

◆ calculateProjectedCircleFromWorldFeet() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCircleFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const float  radius 
)

Project a horizontal circle centered at world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]radiusCircle radius.

◆ calculateProjectedCylinderFromImgFeet() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgFeet ( const Eigen::Vector2d  pt_img_feet,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space feet point.

Parameters
[in]pt_img_feetImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromImgFeet() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgFeet ( const Eigen::Vector2d  pt_img_feet,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space feet point.

Parameters
[in]pt_img_feetImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromImgHead() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgHead ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space head point.

Parameters
[in]pt_img_headImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromImgHead() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgHead ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space head point.

Parameters
[in]pt_img_headImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromImgWaist() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgWaist ( const Eigen::Vector2d  pt_img_waist,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space waist point.

Parameters
[in]pt_img_waistImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromImgWaist() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromImgWaist ( const Eigen::Vector2d  pt_img_waist,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from an image-space waist point.

Parameters
[in]pt_img_waistImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromWorldFeet() [1/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ calculateProjectedCylinderFromWorldFeet() [2/2]

std::vector<Eigen::Vector2d> ObjectModelProjector::calculateProjectedCylinderFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)
protected

Project a cylinder from world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ computeGroundCovariance() [1/2]

Eigen::Matrix2d ObjectModelProjector::computeGroundCovariance ( const Eigen::Vector2d &  pixel_pt,
float  pixel_sigma 
)

Compute ground plane position covariance from pixel uncertainty using Jacobian.

Parameters
[in]pixel_ptThe pixel coordinates (u, v).
[in]pixel_sigmaStandard deviation of pixel noise.

◆ computeGroundCovariance() [2/2]

Eigen::Matrix2d ObjectModelProjector::computeGroundCovariance ( const Eigen::Vector2d &  pixel_pt,
float  pixel_sigma 
)

Compute ground plane position covariance from pixel uncertainty using Jacobian.

Parameters
[in]pixel_ptThe pixel coordinates (u, v).
[in]pixel_sigmaStandard deviation of pixel noise.

◆ computeHeightAndWorldFeetFromHeadAndFoot() [1/2]

Eigen::Vector2d ObjectModelProjector::computeHeightAndWorldFeetFromHeadAndFoot ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_foot,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId 
)

Estimate target height and world feet position from image head and foot points.

Parameters
[in]pt_img_headImage-space head point.
[in]pt_img_footImage-space foot point.
[in]targetIndTarget index.
[in]classIdTarget class ID.

◆ computeHeightAndWorldFeetFromHeadAndFoot() [2/2]

Eigen::Vector2d ObjectModelProjector::computeHeightAndWorldFeetFromHeadAndFoot ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_foot,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId 
)

Estimate target height and world feet position from image head and foot points.

Parameters
[in]pt_img_headImage-space head point.
[in]pt_img_footImage-space foot point.
[in]targetIndTarget index.
[in]classIdTarget class ID.

◆ computeHeightAndWorldFeetFromHeadAndWaist() [1/2]

Eigen::Vector2d ObjectModelProjector::computeHeightAndWorldFeetFromHeadAndWaist ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_waist,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId 
)

Estimate target height and world feet position from image head and waist points.

Parameters
[in]pt_img_headImage-space head point.
[in]pt_img_waistImage-space waist point.
[in]targetIndTarget index.
[in]classIdTarget class ID.

◆ computeHeightAndWorldFeetFromHeadAndWaist() [2/2]

Eigen::Vector2d ObjectModelProjector::computeHeightAndWorldFeetFromHeadAndWaist ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_waist,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId 
)

Estimate target height and world feet position from image head and waist points.

Parameters
[in]pt_img_headImage-space head point.
[in]pt_img_waistImage-space waist point.
[in]targetIndTarget index.
[in]classIdTarget class ID.

◆ convertYamlVec2EigenMatrixXd() [1/2]

const Eigen::MatrixXd ObjectModelProjector::convertYamlVec2EigenMatrixXd ( YAML::Node  yamlVec,
const int  rows,
const int  cols 
)
protected

Convert a nested YAML sequence to an Eigen matrix.

Parameters
[in]yamlVecYAML matrix values.
[in]rowsMatrix row count.
[in]colsMatrix column count.

◆ convertYamlVec2EigenMatrixXd() [2/2]

const Eigen::MatrixXd ObjectModelProjector::convertYamlVec2EigenMatrixXd ( YAML::Node  yamlVec,
const int  rows,
const int  cols 
)
protected

Convert a nested YAML sequence to an Eigen matrix.

Parameters
[in]yamlVecYAML matrix values.
[in]rowsMatrix row count.
[in]colsMatrix column count.

◆ deriveDataFromCameraProjMatrix() [1/2]

void ObjectModelProjector::deriveDataFromCameraProjMatrix ( TargetHomography &  homographyMat,
const Model3DInfo &  humanModel 
)
protected

Derive target-plane homographies from the camera projection matrix.

Parameters
[out]homographyMatTarget homographies to populate.
[in]humanModelTarget model dimensions.

Referenced by setTargetHeight().

◆ deriveDataFromCameraProjMatrix() [2/2]

void ObjectModelProjector::deriveDataFromCameraProjMatrix ( TargetHomography &  homographyMat,
const Model3DInfo &  humanModel 
)
protected

Derive target-plane homographies from the camera projection matrix.

Parameters
[out]homographyMatTarget homographies to populate.
[in]humanModelTarget model dimensions.

◆ getBboxOfProjectedCylinderFromImgFeet() [1/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgFeet ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space feet point.

Parameters
[in]pt_img_headImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromImgFeet() [2/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgFeet ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space feet point.

Parameters
[in]pt_img_headImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromImgHead() [1/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgHead ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space head point.

Parameters
[in]pt_img_headImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromImgHead() [2/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgHead ( const Eigen::Vector2d  pt_img_head,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space head point.

Parameters
[in]pt_img_headImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromImgWaist() [1/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgWaist ( const Eigen::Vector2d  pt_img_waist,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space waist point.

Parameters
[in]pt_img_waistImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromImgWaist() [2/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromImgWaist ( const Eigen::Vector2d  pt_img_waist,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from an image-space waist point.

Parameters
[in]pt_img_waistImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromWorldFeet() [1/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getBboxOfProjectedCylinderFromWorldFeet() [2/2]

const NvMotDataTypes::Rect2f ObjectModelProjector::getBboxOfProjectedCylinderFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Project a cylinder bounding box from world-space feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamFeetPtFromCamWaistPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getCamFeetPtFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image waist point to the corresponding image feet point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamFeetPtFromCamWaistPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getCamFeetPtFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image waist point to the corresponding image feet point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamHeadPtFromCamWaistPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getCamHeadPtFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image waist point to the corresponding image head point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamHeadPtFromCamWaistPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getCamHeadPtFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image waist point to the corresponding image head point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamWaistPtFromCamFeetPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getCamWaistPtFromCamFeetPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image feet point to the corresponding image waist point.

Parameters
[in]imgWaistPtImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamWaistPtFromCamFeetPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getCamWaistPtFromCamFeetPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image feet point to the corresponding image waist point.

Parameters
[in]imgWaistPtImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamWaistPtFromCamHeadPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getCamWaistPtFromCamHeadPt ( const Eigen::Vector2d  imgHeadPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image head point to the corresponding image waist point.

Parameters
[in]imgHeadPtImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getCamWaistPtFromCamHeadPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getCamWaistPtFromCamHeadPt ( const Eigen::Vector2d  imgHeadPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Map an image head point to the corresponding image waist point.

Parameters
[in]imgHeadPtImage-space head point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getDefaultHomographyMatByClass() [1/2]

const TargetHomography& ObjectModelProjector::getDefaultHomographyMatByClass ( const NvMOTClassId  classId)
inlineprotected

Return the default homographies for a class.

Parameters
[in]classIdTarget class ID.

Fallback to first available homography matrix if no homography matrix is defined for the given class ID and print a warning.

Definition at line 593 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References NvTrackerParamsObjectModelProjector::m_debugVerboseLevel, m_defaultHomographyMatByClass, and m_params.

Referenced by setTargetModelForClass().

◆ getDefaultHomographyMatByClass() [2/2]

const TargetHomography& ObjectModelProjector::getDefaultHomographyMatByClass ( const NvMOTClassId  classId)
inlineprotected

Return the default homographies for a class.

Parameters
[in]classIdTarget class ID.

Fallback to first available homography matrix if no homography matrix is defined for the given class ID and print a warning.

Definition at line 593 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References NvTrackerParamsObjectModelProjector::m_debugVerboseLevel.

◆ getDefaultModelByClass() [1/2]

const Model3DInfo& ObjectModelProjector::getDefaultModelByClass ( const NvMOTClassId  classId)
inlineprotected

Return the default three-dimensional model for a class.

Parameters
[in]classIdTarget class ID.

Fallback to first available model if no model is defined for the given class ID and print a warning.

Definition at line 571 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References NvTrackerParamsObjectModelProjector::m_debugVerboseLevel, m_defaultModelByClass, and m_params.

Referenced by setTargetModelForClass().

◆ getDefaultModelByClass() [2/2]

const Model3DInfo& ObjectModelProjector::getDefaultModelByClass ( const NvMOTClassId  classId)
inlineprotected

Return the default three-dimensional model for a class.

Parameters
[in]classIdTarget class ID.

Fallback to first available model if no model is defined for the given class ID and print a warning.

Definition at line 571 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References NvTrackerParamsObjectModelProjector::m_debugVerboseLevel.

◆ getHeightConfidence() [1/2]

float ObjectModelProjector::getHeightConfidence ( ) const
inline

Return the current height-estimation confidence.

Definition at line 467 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getHeightConfidence() [2/2]

float ObjectModelProjector::getHeightConfidence ( ) const
inline

Return the current height-estimation confidence.

Definition at line 467 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References Model3DInfo::heightConfidence, and m_targetModel.

◆ getMinPoseConfidence() [1/2]

float ObjectModelProjector::getMinPoseConfidence ( ) const
inline

Return the minimum pose-keypoint confidence.

Definition at line 454 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getMinPoseConfidence() [2/2]

float ObjectModelProjector::getMinPoseConfidence ( ) const
inline

◆ getOutputConvexHull() [1/2]

const bool ObjectModelProjector::getOutputConvexHull ( )
inline

Return whether convex-hull output is enabled.

Definition at line 451 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getOutputConvexHull() [2/2]

const bool ObjectModelProjector::getOutputConvexHull ( )
inline

◆ getOutputFootLocation() [1/2]

const bool ObjectModelProjector::getOutputFootLocation ( )
inline

Return whether foot-location output is enabled.

Definition at line 448 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getOutputFootLocation() [2/2]

const bool ObjectModelProjector::getOutputFootLocation ( )
inline

◆ getProjectedWorldGroundPts() [1/2]

const std::vector<Eigen::Vector2d> ObjectModelProjector::getProjectedWorldGroundPts ( const std::vector< Eigen::Vector2d > &  pt_world_feet_list)

Project world-ground points into image coordinates.

Parameters
[in]pt_world_feet_listWorld-ground points to project.

◆ getProjectedWorldGroundPts() [2/2]

const std::vector<Eigen::Vector2d> ObjectModelProjector::getProjectedWorldGroundPts ( const std::vector< Eigen::Vector2d > &  pt_world_feet_list)

Project world-ground points into image coordinates.

Parameters
[in]pt_world_feet_listWorld-ground points to project.

◆ getRecoveredObjectModelFromBbox() [1/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelFromBbox ( const NvMOTObjToTrack *  detObj,
const NvMOTFrameNum  frameNum,
const int  targetInd,
const bool  isInitEstimation 
)

Recover an object model from a detector bounding box.

Parameters
[in]detObjDetected object to project.
[in]frameNumCurrent frame number.
[in]targetIndTarget index, or a negative value when unavailable.
[in]isInitEstimationWhether this is the target's initial estimate.

◆ getRecoveredObjectModelFromBbox() [2/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelFromBbox ( const NvMOTObjToTrack *  detObj,
const NvMOTFrameNum  frameNum,
const int  targetInd,
const bool  isInitEstimation 
)

Recover an object model from a detector bounding box.

Parameters
[in]detObjDetected object to project.
[in]frameNumCurrent frame number.
[in]targetIndTarget index, or a negative value when unavailable.
[in]isInitEstimationWhether this is the target's initial estimate.

◆ getRecoveredObjectModelFromProj3DBbox() [1/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelFromProj3DBbox ( const NvMOTObjToTrack *  detObj,
const NvMOTFrameNum  frameNum 
)

Recover an object model from externally projected three-dimensional bounding-box data.

Parameters
[in]detObjDetected object to match.
[in]frameNumCurrent frame number.

◆ getRecoveredObjectModelFromProj3DBbox() [2/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelFromProj3DBbox ( const NvMOTObjToTrack *  detObj,
const NvMOTFrameNum  frameNum 
)

Recover an object model from externally projected three-dimensional bounding-box data.

Parameters
[in]detObjDetected object to match.
[in]frameNumCurrent frame number.

◆ getRecoveredObjectModelWithAdaptiveHeight() [1/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelWithAdaptiveHeight ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_waist,
const Eigen::Vector2d  pt_img_foot,
const NvMotDataTypes::Rect2f &  bbox,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId,
float  conf_head,
float  conf_waist,
float  conf_foot 
)

Get recovered 3D cylinder model with dynamic height from pose keypoints.

Parameters
[in]pt_img_headThe head location on the image.
[in]pt_img_waistThe waist location on the image.
[in]pt_img_footThe foot location on the image.
[in]bboxThe bounding box.
[in]targetIndThe target index.
[in]classIdThe class ID.
[in]conf_headConfidence of the head keypoint.
[in]conf_waistConfidence of the waist keypoint.
[in]conf_footConfidence of the foot keypoint.
Returns
Recovered 3D cylinder model with dynamic height.

◆ getRecoveredObjectModelWithAdaptiveHeight() [2/2]

RecoveredObjModel ObjectModelProjector::getRecoveredObjectModelWithAdaptiveHeight ( const Eigen::Vector2d  pt_img_head,
const Eigen::Vector2d  pt_img_waist,
const Eigen::Vector2d  pt_img_foot,
const NvMotDataTypes::Rect2f &  bbox,
const TrackerIndex &  targetInd,
const NvMOTClassId  classId,
float  conf_head,
float  conf_waist,
float  conf_foot 
)

Get recovered 3D cylinder model with dynamic height from pose keypoints.

Parameters
[in]pt_img_headThe head location on the image.
[in]pt_img_waistThe waist location on the image.
[in]pt_img_footThe foot location on the image.
[in]bboxThe bounding box.
[in]targetIndThe target index.
[in]classIdThe class ID.
[in]conf_headConfidence of the head keypoint.
[in]conf_waistConfidence of the waist keypoint.
[in]conf_footConfidence of the foot keypoint.
Returns
Recovered 3D cylinder model with dynamic height.

◆ getSensorName() [1/2]

const std::string& ObjectModelProjector::getSensorName ( ) const
inline

Return the source sensor name.

Definition at line 231 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References m_sensorName.

◆ getSensorName() [2/2]

const std::string& ObjectModelProjector::getSensorName ( ) const
inline

◆ getTargetClassId() [1/2]

NvMOTClassId ObjectModelProjector::getTargetClassId ( ) const
inline

Return the current target-model class ID.

Definition at line 505 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References m_targetClassId.

◆ getTargetClassId() [2/2]

NvMOTClassId ObjectModelProjector::getTargetClassId ( ) const
inline

Return the current target-model class ID.

Definition at line 505 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getTargetHeight() [1/2]

float ObjectModelProjector::getTargetHeight ( ) const
inline

Return the current target-model height.

Definition at line 464 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ getTargetHeight() [2/2]

float ObjectModelProjector::getTargetHeight ( ) const
inline

Return the current target-model height.

Definition at line 464 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References Model3DInfo::height, and m_targetModel.

◆ getWorld3DBboxFromWorldFeet() [1/2]

const NvDsObj3DBbox ObjectModelProjector::getWorld3DBboxFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Build a world-space three-dimensional bounding box from feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getWorld3DBboxFromWorldFeet() [2/2]

const NvDsObj3DBbox ObjectModelProjector::getWorld3DBboxFromWorldFeet ( const Eigen::Vector2d  pt_world_feet,
const NvMOTClassId  classId,
const int  targetInd 
)

Build a world-space three-dimensional bounding box from feet coordinates.

Parameters
[in]pt_world_feetWorld-space feet position.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getWorldFeetPtOnGroundFromCamFeetPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getWorldFeetPtOnGroundFromCamFeetPt ( const Eigen::Vector2d  imgFeetPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Recover world-ground feet coordinates from an image feet point.

Parameters
[in]imgFeetPtImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getWorldFeetPtOnGroundFromCamFeetPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getWorldFeetPtOnGroundFromCamFeetPt ( const Eigen::Vector2d  imgFeetPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Recover world-ground feet coordinates from an image feet point.

Parameters
[in]imgFeetPtImage-space feet point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getWorldFeetPtOnGroundFromCamWaistPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::getWorldFeetPtOnGroundFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Recover world-ground feet coordinates from an image waist point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ getWorldFeetPtOnGroundFromCamWaistPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::getWorldFeetPtOnGroundFromCamWaistPt ( const Eigen::Vector2d  imgWaistPt,
const NvMOTClassId  classId,
const int  targetInd 
)

Recover world-ground feet coordinates from an image waist point.

Parameters
[in]imgWaistPtImage-space waist point.
[in]classIdTarget class ID.
[in]targetIndTarget index.

◆ importCameraModelInfo() [1/2]

bool ObjectModelProjector::importCameraModelInfo ( const std::string  filename)
protected

Import camera-model calibration from a YAML file.

Parameters
[in]filenameCamera-model file path.
Returns
True when the camera model is imported successfully.

◆ importCameraModelInfo() [2/2]

bool ObjectModelProjector::importCameraModelInfo ( const std::string  filename)
protected

Import camera-model calibration from a YAML file.

Parameters
[in]filenameCamera-model file path.
Returns
True when the camera model is imported successfully.

◆ importExternalProj3DBboxInfo() [1/2]

bool ObjectModelProjector::importExternalProj3DBboxInfo ( const std::string  filename)
protected

Import externally projected three-dimensional bounding boxes.

Parameters
[in]filenameProjected bounding-box file path.
Returns
True when the bounding boxes are imported successfully.

◆ importExternalProj3DBboxInfo() [2/2]

bool ObjectModelProjector::importExternalProj3DBboxInfo ( const std::string  filename)
protected

Import externally projected three-dimensional bounding boxes.

Parameters
[in]filenameProjected bounding-box file path.
Returns
True when the bounding boxes are imported successfully.

◆ isInitialized() [1/2]

bool ObjectModelProjector::isInitialized ( )
inline

Return whether the projector has been initialized.

Definition at line 228 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References m_isInit.

◆ isInitialized() [2/2]

bool ObjectModelProjector::isInitialized ( )
inline

Return whether the projector has been initialized.

Definition at line 228 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ isTargetModelValid() [1/2]

bool ObjectModelProjector::isTargetModelValid ( TrackerIndex  targetInd,
NvMOTClassId  classId 
)
inlineprotected

Return whether the current target model is valid for a target.

Parameters
[in]targetIndTarget index.
[in]classIdTarget class ID.

Definition at line 663 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References Model3DInfo::height, and Model3DInfo::radius.

◆ isTargetModelValid() [2/2]

bool ObjectModelProjector::isTargetModelValid ( TrackerIndex  targetInd,
NvMOTClassId  classId 
)
inlineprotected

Return whether the current target model is valid for a target.

Parameters
[in]targetIndTarget index.
[in]classIdTarget class ID.

Definition at line 663 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References Model3DInfo::height, m_targetClassId, m_targetModel, and Model3DInfo::radius.

◆ isTargetVisibleInImage() [1/2]

bool ObjectModelProjector::isTargetVisibleInImage ( const Eigen::Vector2d &  pt_world_feet,
float  targetHeight 
)

Check if any point of a vertical target (from feet to head) projects into the camera FOV.

Parameters
[in]pt_world_feetWorld coordinates of feet (X, Y on ground plane).
[in]targetHeightActual height of the target (uses adaptive height if available).
Returns
True if any part of the target's vertical extent is visible in the image.

◆ isTargetVisibleInImage() [2/2]

bool ObjectModelProjector::isTargetVisibleInImage ( const Eigen::Vector2d &  pt_world_feet,
float  targetHeight 
)

Check if any point of a vertical target (from feet to head) projects into the camera FOV.

Parameters
[in]pt_world_feetWorld coordinates of feet (X, Y on ground plane).
[in]targetHeightActual height of the target (uses adaptive height if available).
Returns
True if any part of the target's vertical extent is visible in the image.

◆ projectWorldPt2ImgPt() [1/2]

const Eigen::Vector2d ObjectModelProjector::projectWorldPt2ImgPt ( const Eigen::Vector3d  pt_world)

Project a world-space point into image coordinates.

Parameters
[in]pt_worldWorld-space point.

◆ projectWorldPt2ImgPt() [2/2]

const Eigen::Vector2d ObjectModelProjector::projectWorldPt2ImgPt ( const Eigen::Vector3d  pt_world)

Project a world-space point into image coordinates.

Parameters
[in]pt_worldWorld-space point.

◆ queryParams() [1/2]

void ObjectModelProjector::queryParams ( NvMOTQuery &  paramsQuery)

Populate tracker query capabilities from projector configuration.

Parameters
[out]paramsQueryTracker query structure to update.

◆ queryParams() [2/2]

void ObjectModelProjector::queryParams ( NvMOTQuery &  paramsQuery)

Populate tracker query capabilities from projector configuration.

Parameters
[out]paramsQueryTracker query structure to update.

◆ setTargetHeight() [1/2]

void ObjectModelProjector::setTargetHeight ( float  height,
float  confidence,
bool  force = false 
)
inline

Update target-model height when confidence permits.

Parameters
[in]heightNew target height.
[in]confidenceConfidence of the new height.
[in]forceWhether to update regardless of confidence.

Only update if new confidence >= current (or force is true).

Definition at line 475 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ setTargetHeight() [2/2]

void ObjectModelProjector::setTargetHeight ( float  height,
float  confidence,
bool  force = false 
)
inline

Update target-model height when confidence permits.

Parameters
[in]heightNew target height.
[in]confidenceConfidence of the new height.
[in]forceWhether to update regardless of confidence.

Only update if new confidence >= current (or force is true).

Definition at line 475 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

References deriveDataFromCameraProjMatrix(), Model3DInfo::height, Model3DInfo::heightConfidence, m_targetHomographyMat, and m_targetModel.

◆ setTargetModelForClass() [1/2]

void ObjectModelProjector::setTargetModelForClass ( NvMOTClassId  classId)
inline

◆ setTargetModelForClass() [2/2]

void ObjectModelProjector::setTargetModelForClass ( NvMOTClassId  classId)
inline

Select the target model for a class ID.

Parameters
[in]classIdTarget class ID.

Early return if current class matches the new class.

Definition at line 489 of file 9.2/sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Field Documentation

◆ m_cameraInfo

CameraInfo ObjectModelProjector::m_cameraInfo
protected

◆ m_camLocation_World

TranslationMatrix ObjectModelProjector::m_camLocation_World
protected

Camera position in world coordinate system.

Definition at line 541 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_configFilePath

const std::string ObjectModelProjector::m_configFilePath
protected

◆ m_defaultHomographyMatByClass

std::map< NvMOTClassId, TargetHomography > ObjectModelProjector::m_defaultHomographyMatByClass
protected

Stores default target homographies by class.

Definition at line 543 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Referenced by getDefaultHomographyMatByClass().

◆ m_defaultModelByClass

std::map< NvMOTClassId, Model3DInfo > ObjectModelProjector::m_defaultModelByClass
protected

◆ m_externalProj3DBboxInfo

std::vector< std::vector< Proj3DBboxInfo > > ObjectModelProjector::m_externalProj3DBboxInfo
protected

Store projected 3D bounding box info for all frames in the stream.

Definition at line 519 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_groundPlaneHeight

float ObjectModelProjector::m_groundPlaneHeight
protected

Specifies the world-space ground-plane height.

Definition at line 523 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_H_ground

HomographyMatrix ObjectModelProjector::m_H_ground
protected

Ground-plane homography, independent of target height.

Definition at line 536 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_H_ground_inv

HomographyMatrix ObjectModelProjector::m_H_ground_inv
protected

Inverse of ground plane homography.

Definition at line 537 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_H_inv_Pz

Eigen::Vector3d ObjectModelProjector::m_H_inv_Pz
protected

H_ground_inv * P_z_col (precomputed for Sherman-Morrison).

Definition at line 540 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_isInit

bool ObjectModelProjector::m_isInit
protected

Indicates whether the projector has been initialized.

Definition at line 509 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Referenced by isInitialized().

◆ m_K

IntrinsicMatrix ObjectModelProjector::m_K
protected

◆ m_K_inv

IntrinsicMatrix ObjectModelProjector::m_K_inv
protected

◆ m_P_z_col

Eigen::Vector3d ObjectModelProjector::m_P_z_col
protected

P[:,2] - projection matrix Z column (height update direction).

Definition at line 539 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_params

◆ m_pix2cam_offset

Eigen::Vector2d ObjectModelProjector::m_pix2cam_offset
protected

Shifts corner-origin pixels to the optical center for projectionMatrix_3x4.

Zero when projectionMatrix_3x4_w2p already maps into pixel coordinates.

Definition at line 532 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_ProjMat_World2Cam

CameraMatrix ObjectModelProjector::m_ProjMat_World2Cam
protected

Stores the world-to-camera projection matrix.

Definition at line 524 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_R

RotationMatrix ObjectModelProjector::m_R
protected

Rotation matrix (world to camera).

Definition at line 529 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_r3

Eigen::Vector3d ObjectModelProjector::m_r3
protected

Third row of R^T (for ground plane intersection).

Definition at line 538 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_R_T

RotationMatrix ObjectModelProjector::m_R_T
protected

◆ m_resolvedCameraModelFilepath

std::string ObjectModelProjector::m_resolvedCameraModelFilepath
protected

Resolved camera model filepath for this stream.

Definition at line 515 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_sensorName

std::string ObjectModelProjector::m_sensorName
protected

Sensor name of the corresponding source stream.

Definition at line 511 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Referenced by getSensorName().

◆ m_srcFrameSize

NvMotDataTypes::Size ObjectModelProjector::m_srcFrameSize
protected

Source video frame size where the bbox info is based on.

Definition at line 517 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_streamInd

uint ObjectModelProjector::m_streamInd
protected

Index of the corresponding source stream.

Definition at line 510 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

◆ m_t

TranslationMatrix ObjectModelProjector::m_t
protected

◆ m_targetClassId

NvMOTClassId ObjectModelProjector::m_targetClassId
protected

◆ m_targetHomographyMat

TargetHomography ObjectModelProjector::m_targetHomographyMat
protected

Homography matrices for head, waist, and feet planes composed from the projection matrix.

Definition at line 542 of file sources/libs/nvmultiobjecttracker/include/modules/ObjectModelProjector/ObjectModelProjector.hpp.

Referenced by setTargetHeight(), and setTargetModelForClass().

◆ m_targetModel

Model3DInfo ObjectModelProjector::m_targetModel
protected

The documentation for this class was generated from the following file: