NVIDIA DeepStream SDK API Reference

6.4 Release
nvdsinferserver::BasePostprocessor Class Referenceabstract

Detailed Description

Base post-processor class.

Definition at line 162 of file infer_iprocess.h.

Inheritance diagram for nvdsinferserver::BasePostprocessor:
Collaboration diagram for nvdsinferserver::BasePostprocessor:

Public Types

using PostprocessDone = std::function< void(NvDsInferStatus, SharedBatchArray)>
 

Public Member Functions

 BasePostprocessor (InferPostprocessType type, int uid)
 Constructor, save process type and ID. More...
 
 ~BasePostprocessor () override=default
 Destructor default. More...
 
NvDsInferStatus postCudaProcess (SharedBatchArray inBuf, SharedCuStream mainStream, PostprocessDone done) override
 Acquire an output buffer array and call CUDA post processing steps. More...
 
NvDsInferStatus postHostProcess (SharedBatchArray inBuf, SharedCuStream mainStream, PostprocessDone done) override
 Acquire an output buffer array and call host side processing steps. More...
 
virtual NvDsInferStatus allocateResource (const std::vector< int > &devIds)=0
 Allocate resource like output buffer pool. More...
 

Member Typedef Documentation

◆ PostprocessDone

Definition at line 62 of file infer_iprocess.h.

Constructor & Destructor Documentation

◆ BasePostprocessor()

nvdsinferserver::BasePostprocessor::BasePostprocessor ( InferPostprocessType  type,
int  uid 
)
inline

Constructor, save process type and ID.

Definition at line 167 of file infer_iprocess.h.

◆ ~BasePostprocessor()

nvdsinferserver::BasePostprocessor::~BasePostprocessor ( )
overridedefault

Destructor default.

Member Function Documentation

◆ allocateResource()

virtual NvDsInferStatus nvdsinferserver::BasePostprocessor::allocateResource ( const std::vector< int > &  devIds)
pure virtual

Allocate resource like output buffer pool.

Parameters
[in]devIdsList of device IDs.
Returns
Error status.

Implemented in nvdsinferserver::SegmentPostprocessor, nvdsinferserver::ClassifyPostprocessor, nvdsinferserver::DetectPostprocessor, and nvdsinferserver::Postprocessor.

◆ networkType()

InferPostprocessType nvdsinferserver::BasePostprocessor::networkType ( ) const
inline

Definition at line 180 of file infer_iprocess.h.

◆ postCudaProcess()

NvDsInferStatus nvdsinferserver::BasePostprocessor::postCudaProcess ( SharedBatchArray  inBuf,
SharedCuStream  mainStream,
PostprocessDone  done 
)
inlineoverridevirtual

Acquire an output buffer array and call CUDA post processing steps.

Parameters
[in]inBufPointer to the input batch array.
[in]mainStreamThe main CUDA stream to synchronize with.
[in]doneCallback function to be executed.
Returns
Error status.

Implements nvdsinferserver::IPostprocessor.

Definition at line 190 of file infer_iprocess.h.

◆ postHostProcess()

NvDsInferStatus nvdsinferserver::BasePostprocessor::postHostProcess ( SharedBatchArray  inBuf,
SharedCuStream  mainStream,
PostprocessDone  done 
)
inlineoverridevirtual

Acquire an output buffer array and call host side processing steps.

Parameters
[in]inBufPointer to the input batch array.
[in]mainStreamThe main CUDA stream to synchronize with.
[in]doneCallback function to be executed.
Returns
Error status.

Implements nvdsinferserver::IPostprocessor.

Definition at line 204 of file infer_iprocess.h.

◆ setUniqueId()

void nvdsinferserver::BasePostprocessor::setUniqueId ( int  id)
inline

Definition at line 178 of file infer_iprocess.h.

◆ uniqueId()

int nvdsinferserver::BasePostprocessor::uniqueId ( ) const
inline

Definition at line 179 of file infer_iprocess.h.


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