NVIDIA DeepStream SDK API Reference

6.4 Release
cvcore::gazenet::GazeNetPreProcessor Class Reference

Detailed Description

Interface for running pre-processing on GazeNet.

Definition at line 67 of file GazeNet.h.

Public Member Functions

 GazeNetPreProcessor ()=delete
 Default constructor is deleted. More...
 
 GazeNetPreProcessor (const ImagePreProcessingParams &preProcessorParams, const ModelInputParams &modelInputParams)
 Constructor of GazeNetPreProcessor. More...
 
 ~GazeNetPreProcessor ()
 Destructor of GazeNetPreProcessor. More...
 
void setLandmarksMeanAndVariance (const Array< Vector2f > &landmarksMean, const Array< Vector2f > &landmarksStd)
 Set the mean and standard deviation of the landmarks for the model. More...
 
void execute (Tensor< NHWC, C1, F32 > &outputFace, Tensor< NHWC, C1, F32 > &outputLeft, Tensor< NHWC, C1, F32 > &outputRight, Tensor< CL, CX, F32 > &outputFeatures, const Tensor< NHWC, C3, U8 > &inputImage, const Array< BBox > &inputBBox, const Array< ArrayN< Vector2f, GazeNetPreProcessor::NUM_LANDMARKS >> &inputLandmarks, FeatureType type=FeatureType::FACEGRID, cudaStream_t stream=0)
 Main interface to run pre-processing. More...
 

Static Public Attributes

static constexpr size_t NUM_LANDMARKS = 68
 Number of landmarks needed for the model. More...
 
static constexpr float BBOX_FACE_SCALE = 1.3f
 Scaling factor for face. More...
 
static constexpr float BBOX_EYE_SCALE = 1.8f
 Scaling factor for eyes. More...
 
static const float DEFAULT_LANDMARKS_MEAN []
 Default landmarks mean values for the model. More...
 
static const float DEFAULT_LANDMARKS_STD []
 Default landmarks standard deviation values for the model. More...
 

Constructor & Destructor Documentation

◆ GazeNetPreProcessor() [1/2]

cvcore::gazenet::GazeNetPreProcessor::GazeNetPreProcessor ( )
delete

Default constructor is deleted.

◆ GazeNetPreProcessor() [2/2]

cvcore::gazenet::GazeNetPreProcessor::GazeNetPreProcessor ( const ImagePreProcessingParams preProcessorParams,
const ModelInputParams modelInputParams 
)

Constructor of GazeNetPreProcessor.

Parameters
preProcessorParamsimage pre-processing parameters.
modelInputParamsmodel paramters for network.

◆ ~GazeNetPreProcessor()

cvcore::gazenet::GazeNetPreProcessor::~GazeNetPreProcessor ( )

Destructor of GazeNetPreProcessor.

Member Function Documentation

◆ execute()

void cvcore::gazenet::GazeNetPreProcessor::execute ( Tensor< NHWC, C1, F32 > &  outputFace,
Tensor< NHWC, C1, F32 > &  outputLeft,
Tensor< NHWC, C1, F32 > &  outputRight,
Tensor< CL, CX, F32 > &  outputFeatures,
const Tensor< NHWC, C3, U8 > &  inputImage,
const Array< BBox > &  inputBBox,
const Array< ArrayN< Vector2f, GazeNetPreProcessor::NUM_LANDMARKS >> &  inputLandmarks,
FeatureType  type = FeatureType::FACEGRID,
cudaStream_t  stream = 0 
)

Main interface to run pre-processing.

Parameters
outputFaceoutput tensor for face region.
outputLeftoutput tensor for left eye.
outputRightoutput tensor for right eye.
outputFeaturesoutput normalized landmarks or facegrid.
inputImageinput image tensor.
inputBBoxinput BBox of the face.
inputLandmarksinput raw facial landmarks.
typewhether to use facegrid model or landmarks model.
streamcuda stream.

◆ setLandmarksMeanAndVariance()

void cvcore::gazenet::GazeNetPreProcessor::setLandmarksMeanAndVariance ( const Array< Vector2f > &  landmarksMean,
const Array< Vector2f > &  landmarksStd 
)

Set the mean and standard deviation of the landmarks for the model.

Parameters
landmarksMeanmean of the landmarks.
landmarksStdstandard deviation of the landmarks.

Field Documentation

◆ BBOX_EYE_SCALE

constexpr float cvcore::gazenet::GazeNetPreProcessor::BBOX_EYE_SCALE = 1.8f
staticconstexpr

Scaling factor for eyes.

Definition at line 83 of file GazeNet.h.

◆ BBOX_FACE_SCALE

constexpr float cvcore::gazenet::GazeNetPreProcessor::BBOX_FACE_SCALE = 1.3f
staticconstexpr

Scaling factor for face.

Definition at line 78 of file GazeNet.h.

◆ DEFAULT_LANDMARKS_MEAN

const float cvcore::gazenet::GazeNetPreProcessor::DEFAULT_LANDMARKS_MEAN[]
static

Default landmarks mean values for the model.

Definition at line 88 of file GazeNet.h.

◆ DEFAULT_LANDMARKS_STD

const float cvcore::gazenet::GazeNetPreProcessor::DEFAULT_LANDMARKS_STD[]
static

Default landmarks standard deviation values for the model.

Definition at line 93 of file GazeNet.h.

◆ NUM_LANDMARKS

constexpr size_t cvcore::gazenet::GazeNetPreProcessor::NUM_LANDMARKS = 68
staticconstexpr

Number of landmarks needed for the model.

Definition at line 73 of file GazeNet.h.


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