FastDeploy  latest
Fast & Easy to Deploy!
Public Member Functions | List of all members
fastdeploy::vision::classification::PaddleClasPostprocessor Class Reference

Postprocessor object for PaddleClas serials model. More...

#include <postprocessor.h>

Public Member Functions

 PaddleClasPostprocessor (int topk=1)
 Create a postprocessor instance for PaddleClas serials model. More...
 
bool Run (const std::vector< FDTensor > &tensors, std::vector< ClassifyResult > *result)
 Process the result of runtime and fill to ClassifyResult structure. More...
 
void SetTopk (int topk)
 Set topk value.
 
int GetTopk () const
 Get topk value.
 

Detailed Description

Postprocessor object for PaddleClas serials model.

Constructor & Destructor Documentation

◆ PaddleClasPostprocessor()

fastdeploy::vision::classification::PaddleClasPostprocessor::PaddleClasPostprocessor ( int  topk = 1)
explicit

Create a postprocessor instance for PaddleClas serials model.

Parameters
[in]topkThe topk result filtered by the classify confidence score, default 1

Member Function Documentation

◆ Run()

bool fastdeploy::vision::classification::PaddleClasPostprocessor::Run ( const std::vector< FDTensor > &  tensors,
std::vector< ClassifyResult > *  result 
)

Process the result of runtime and fill to ClassifyResult structure.

Parameters
[in]tensorsThe inference result from runtime
[in]resultThe output result of classification
Returns
true if the postprocess successed, otherwise false

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