Go to the source code of this file.
Functions | |
| Tensor * | createTensor (const std::string &tensor_name, const std::vector< int > &shape, NvDsDataType data_type=NvDsDataType_FP32, int gpu_id=-1) |
| Creates a tensor with the specified shape, data type, and GPU ID. More... | |
| void | initOrgProjectionMatTensor (TensorCache *tensorCache, int batch_size, int num_sensors, const std::vector< Eigen::Matrix< float, 4, 4 >> &calib_matrices, int gpu_id) |
| Initialize projection matrix tensor and update the TensorCache. More... | |
| void | initProjectionMatTensor (TensorCache *tensorCache, int batch_size, int num_sensors, const std::vector< Eigen::Matrix< float, 4, 4 >> &calib_matrices) |
| Initializes projection matrix tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | initImageWHTensor (TensorCache *tensorCache, int width, int height) |
| Initializes image width/height tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | initInputCachedAnchorTensor (TensorCache *tensorCache) |
| Initializes cached anchor tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | initInputCachedFeatureTensor (TensorCache *tensorCache) |
| Initializes cached feature tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | intiPrevExistsTensor (TensorCache *tensorCache, float value) |
| Initializes prev_exists tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | initIntervalMaskTensor (TensorCache *tensorCache, float value) |
| Initializes interval mask tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | initGroupOriginTensor (TensorCache *tensorCache, const std::vector< float > &group_origin) |
| Initializes group origin tensor using pre-allocated memory and updates the TensorCache. More... | |
| void | updateInputCachedAnchorTensor (TensorCache *tensorCache, torch::Tensor anchor) |
| Updates input cached anchor tensor using pre-allocated memory. More... | |
| void | updateInputCachedFeatureTensor (TensorCache *tensorCache, torch::Tensor feature) |
| Updates input cached feature tensor using pre-allocated memory. More... | |
| void | updateProjectionMatrixForBatch (TensorCache *tensorCache, const std::map< std::string, Eigen::Matrix< float, 4, 4 >> &cameraMatrices, const std::vector< std::string > ¤tBatchCameras, int batch_size, int num_sensors) |
| Updates projection matrix tensor based on the current camera names in the batch. More... | |
| void | updateOrgProjectionMatrixForBatch (TensorCache *tensorCache, const std::map< std::string, Eigen::Matrix< float, 4, 4 >> &cameraMatrices, const std::vector< std::string > ¤tBatchCameras, int batch_size, int num_sensors) |
| Updates the original projection matrix tensor based on the current camera names in the batch. More... | |
| Tensor* createTensor | ( | const std::string & | tensor_name, |
| const std::vector< int > & | shape, | ||
| NvDsDataType | data_type = NvDsDataType_FP32, |
||
| int | gpu_id = -1 |
||
| ) |
Creates a tensor with the specified shape, data type, and GPU ID.
| tensor_name | Name for the tensor |
| shape | Vector of dimensions for the tensor shape |
| data_type | Data type for the tensor (defaults to FP32) |
| gpu_id | GPU ID for memory allocation (-1 for CPU memory, >=0 for GPU) |
| void initGroupOriginTensor | ( | TensorCache * | tensorCache, |
| const std::vector< float > & | group_origin | ||
| ) |
Initializes group origin tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| group_origin | Vector of group origin values |
| void initImageWHTensor | ( | TensorCache * | tensorCache, |
| int | width, | ||
| int | height | ||
| ) |
Initializes image width/height tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| width | Width of the image |
| height | Height of the image |
| void initInputCachedAnchorTensor | ( | TensorCache * | tensorCache | ) |
Initializes cached anchor tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| void initInputCachedFeatureTensor | ( | TensorCache * | tensorCache | ) |
Initializes cached feature tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| void initIntervalMaskTensor | ( | TensorCache * | tensorCache, |
| float | value | ||
| ) |
Initializes interval mask tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| value | Value for the mask (typically 1.0) |
| void initOrgProjectionMatTensor | ( | TensorCache * | tensorCache, |
| int | batch_size, | ||
| int | num_sensors, | ||
| const std::vector< Eigen::Matrix< float, 4, 4 >> & | calib_matrices, | ||
| int | gpu_id | ||
| ) |
Initialize projection matrix tensor and update the TensorCache.
| tensorCache | Pointer to TensorCache object |
| batch_size | Sparse4D model batch size |
| num_sensors | Number of sensors [Deepstream batch size] |
| calib_matrices | Vector of calibration matrices (4x4) to use |
| gpu_id | GPU ID for memory allocation (-1 for CPU memory, >=0 for GPU) |
| void initProjectionMatTensor | ( | TensorCache * | tensorCache, |
| int | batch_size, | ||
| int | num_sensors, | ||
| const std::vector< Eigen::Matrix< float, 4, 4 >> & | calib_matrices | ||
| ) |
Initializes projection matrix tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| batch_size | Sparse4D model batch size |
| num_sensors | Number of sensors [Deepstream batch size] |
| calib_matrices | Vector of calibration matrices (4x4) to use |
| void intiPrevExistsTensor | ( | TensorCache * | tensorCache, |
| float | value | ||
| ) |
Initializes prev_exists tensor using pre-allocated memory and updates the TensorCache.
| tensorCache | Pointer to TensorCache object |
| value | Boolean value (0.0 = false, non-zero = true) |
| void updateInputCachedAnchorTensor | ( | TensorCache * | tensorCache, |
| torch::Tensor | anchor | ||
| ) |
Updates input cached anchor tensor using pre-allocated memory.
| tensorCache | Pointer to TensorCache object |
| anchor | Anchor tensor to update |
| void updateInputCachedFeatureTensor | ( | TensorCache * | tensorCache, |
| torch::Tensor | feature | ||
| ) |
Updates input cached feature tensor using pre-allocated memory.
| tensorCache | Pointer to TensorCache object |
| feature | Feature tensor to update |
| void updateOrgProjectionMatrixForBatch | ( | TensorCache * | tensorCache, |
| const std::map< std::string, Eigen::Matrix< float, 4, 4 >> & | cameraMatrices, | ||
| const std::vector< std::string > & | currentBatchCameras, | ||
| int | batch_size, | ||
| int | num_sensors | ||
| ) |
Updates the original projection matrix tensor based on the current camera names in the batch.
| tensorCache | Pointer to TensorCache object |
| cameraMatrices | Map of camera names to their projection matrices |
| currentBatchCameras | Vector of current camera names in the batch |
| batch_size | Sparse4D model batch size |
| num_sensors | Maximum number of sensors supported by the model |
| void updateProjectionMatrixForBatch | ( | TensorCache * | tensorCache, |
| const std::map< std::string, Eigen::Matrix< float, 4, 4 >> & | cameraMatrices, | ||
| const std::vector< std::string > & | currentBatchCameras, | ||
| int | batch_size, | ||
| int | num_sensors | ||
| ) |
Updates projection matrix tensor based on the current camera names in the batch.
| tensorCache | Pointer to TensorCache object |
| cameraMatrices | Map of camera names to their projection matrices |
| currentBatchCameras | Vector of current camera names in the batch |
| batch_size | Sparse4D model batch size |
| num_sensors | Maximum number of sensors supported by the model |