SaigeVision C/C++  1.4.7
SaigeVision API document for C/C++
Classification's inspection results

Functions

eErrorType SR_GetClsTestResultScore (ClsTestResult clsTestResult, const int numClasses, int *scores, bool includeAddScore=false)
 Get scores for each class. More...
 
eErrorType SR_GetClsTestResultClass (ClsTestResult clsTestResult, int *classIdx)
 Get final class index. More...
 
eErrorType SR_GetClsTestInspectionTime (ClsTestResult clsTestResult, long *inspectionTimeInLong)
 Get the inspection time. More...
 
eErrorType SR_GetClsTestInspectionTimeInDouble (ClsTestResult clsTestResult, double *inspectionTimeInDouble)
 Get the inspection time. More...
 
eErrorType SR_GetClsTestLoadImageTime (ClsTestResult clsTestResult, long *imageLoadingTimeInLong)
 Get the image loading time. More...
 
eErrorType SR_GetClsTestLoadImageTimeInDouble (ClsTestResult clsTestResult, double *imageLoadingTimeInDouble)
 Get the image loading time. More...
 

Detailed Description

Classification's inspection result is a class index and scores for each class.

int numClasses; // needs to be set first.
// Get scores
int* scores = new int[numClasses];
eErrorType error = SR_GetClsTestResultScore(testResult, numClasses, scores, true);
// Get class index
int classIdx = 0;
error = SR_GetClsTestResultClass(testResult, &classIdx);
delete[] scores;

Function Documentation

◆ SR_GetClsTestInspectionTime()

eErrorType SR_GetClsTestInspectionTime ( ClsTestResult  clsTestResult,
long *  inspectionTimeInLong 
)

Get the inspection time.

Parameters
clsTestResult
[out]inspectionTimeInLong
Examples
ExampleClsRuntime.cpp, ExampleClsRuntimeBatchInspection.cpp, ExampleClsRuntimeSimple.cpp, and ExampleSeg+ClsRuntime.cpp.

◆ SR_GetClsTestInspectionTimeInDouble()

eErrorType SR_GetClsTestInspectionTimeInDouble ( ClsTestResult  clsTestResult,
double *  inspectionTimeInDouble 
)

Get the inspection time.

Parameters
clsTestResult
[out]inspectionTimeInDouble

◆ SR_GetClsTestLoadImageTime()

eErrorType SR_GetClsTestLoadImageTime ( ClsTestResult  clsTestResult,
long *  imageLoadingTimeInLong 
)

Get the image loading time.

Parameters
clsTestResult
[out]imageLoadingTimeInLong
Examples
ExampleClsRuntime.cpp, ExampleClsRuntimeBatchInspection.cpp, and ExampleSeg+ClsRuntime.cpp.

◆ SR_GetClsTestLoadImageTimeInDouble()

eErrorType SR_GetClsTestLoadImageTimeInDouble ( ClsTestResult  clsTestResult,
double *  imageLoadingTimeInDouble 
)

Get the image loading time.

Parameters
clsTestResult
[out]imageLoadingTimeInDouble

◆ SR_GetClsTestResultClass()

eErrorType SR_GetClsTestResultClass ( ClsTestResult  clsTestResult,
int *  classIdx 
)

Get final class index.

Parameters
clsTestResult
[out]classIdx
Examples
ExampleClsRuntime.cpp, ExampleClsRuntimeBatchInspection.cpp, ExampleClsRuntimeSimple.cpp, and ExampleSeg+ClsRuntime.cpp.

◆ SR_GetClsTestResultScore()

eErrorType SR_GetClsTestResultScore ( ClsTestResult  clsTestResult,
const int  numClasses,
int *  scores,
bool  includeAddScore = false 
)

Get scores for each class.

Parameters
clsTestResult
numClasses
[out]scoresmemory address receiving scores. The length of memory must be equal to numClasses
includeAddScorewhether get final scores(raw scores + Additional scores) or only raw scores.
Examples
ExampleClsRuntime.cpp, ExampleClsRuntimeBatchInspection.cpp, ExampleClsRuntimeSimple.cpp, and ExampleSeg+ClsRuntime.cpp.
SR_GetClsTestResultScore
eErrorType SR_GetClsTestResultScore(ClsTestResult clsTestResult, const int numClasses, int *scores, bool includeAddScore=false)
Get scores for each class.
SR_GetClsTestResultClass
eErrorType SR_GetClsTestResultClass(ClsTestResult clsTestResult, int *classIdx)
Get final class index.
eErrorType
eErrorType
Enumerator indicating error codes.
Definition: CommonHeaderDLL.h:25