NvInfer Plugin¶
-
group
gstreamer_nvinfer_api
Defines an API for the GStreamer NvInfer plugin.
Variables
-
G_BEGIN_DECLS typedef void(* gst_nvinfer_raw_output_generated_callback )(GstBuffer *buf, NvDsInferNetworkInfo *network_info, NvDsInferLayerInfo *layers_info, guint num_layers, guint batch_size, gpointer user_data)
Function definition for the inference raw output generated callback of Gst-NvInfer plugin.
The callback function can be registered by setting “raw-output-generated-callback” property on an “nvinfer” element instance. Additionally, a pointer to user data can be set through the “raw-output-generated-userdata” property. This pointer will be passed to the raw output generated callback function through the userdata parameter.
Refer to the reference deepstream-app sources for a sample implementation of the callback.
- Parameters
[in] buf
: Pointer to the GstBuffer on whose contents inference has been executed. The implementation should assume the buffer to be read-only and should not modify the buffer in any way.[in] network_info
: Network information for the model specified for the nvinfer element instance.[in] layers_info
: Pointer to the array containing information for all bound layers for the inference engine.[in] num_layers
: Number of layers bound for the inference engine i.e. number of elements in the layers_info array.[in] batch_size
: Number of valid input frames in the batch.[in] user_data
: Pointer to the user data set through the “raw-output-generated-userdata” property.
-
struct
NvDsInferTensorMeta
- #include <gstnvdsinfer.h>
Holds the raw tensor output information for one frame / one object.
The “nvinfer” plugins adds this meta when the “output-tensor-meta” property of the element instance is set to TRUE.
This meta data is added as NvDsUserMeta to the frame_user_meta_list of the corresponding frame_meta or object_user_meta_list of the corresponding object with the meta_type set to NVDSINFER_TENSOR_OUTPUT_META.
-
struct
NvDsInferSegmentationMeta
- #include <gstnvdsinfer.h>
Holds the segmentation model output information for one frame / one object.
The “nvinfer” plugins adds this meta for segmentation models.
This meta data is added as NvDsUserMeta to the frame_user_meta_list of the corresponding frame_meta or object_user_meta_list of the corresponding object with the meta_type set to NVDSINFER_SEGMENTATION_META.
-