|
| eErrorType | SR_GetDetTestResultNumberOfBoxes (DetTestResult detTestResult, int *numDetectedBoxes) |
| | Get the number of detected boxes. More...
|
| |
| eErrorType | SR_GetDetTestResultDetectedBoxes (DetTestResult detTestResult, const int numDetectedBoxes, SR_DetectedBox *detectedBoxes) |
| | Get SR_DetectedBox. More...
|
| |
| eErrorType | SR_GetDetTestResultAllBoxesInfo (DetTestResult detTestResult, const int numDetectedBoxes, int *classIndices, float *scores, int *coordinatesXYXY) |
| | Get all the detected boxes. More...
|
| |
| eErrorType | SR_GetDetTestResultOneBoxInfo (DetTestResult detTestResult, const int boxIndex, int *classIndex, float *score, int *coordinateXYXY) |
| | Get a single detected box. More...
|
| |
| eErrorType | SR_GetDetTestResultNumberOfBoxesBeforeFiltered (DetTestResult detTestResult, int numClasses, int *numRawBoxes) |
| | Get the number of raw detected boxes before filtered by Max number of boxes for each class. More...
|
| |
| eErrorType | SR_GetDetTestInspectionTime (DetTestResult detTestResult, long *inspectionTimeInLong) |
| | Get the inspection time. More...
|
| |
| eErrorType | SR_GetDetTestInspectionTimeInDouble (DetTestResult detTestResult, double *inspectionTimeInDouble) |
| | Get the inspection time. More...
|
| |
| eErrorType | SR_GetDetTestLoadImageTime (DetTestResult detTestResult, long *imageLoadingTimeInLong) |
| | Get the image loading time. More...
|
| |
| eErrorType | SR_GetDetTestLoadImageTimeInDouble (DetTestResult detTestResult, double *imageLoadingTimeInDouble) |
| | Get the image loading time. More...
|
| |
Detection's inspection result is a list of detected boxes. Information contained in detected boxes are as follows:
- class index: class index of a detected box
- score: normalized probability (0-100) that the detected box is correct(class & geometrical info)
- coordinates: x, y coordinate of top left and bottom right corners (x_tl, y_tl, x_br, y_br)
width = x_br - x_tl, height = y_br - y_tl
int numBoxes = 0;
int* classIndices = new int[numBoxes];
float* scores = new float[numBoxes];
int* coordinateXYXY = new int[numBoxes*4];
for (int i = 0; i < numBoxes; i++){
int classIndex = classIndices[i];
float score = scores[i];
int x_tl = coordinateXYXY[4 * i];
int y_tl = coordinateXYXY[4 * i + 1];
int x_br = coordinateXYXY[4 * i + 2];
int y_br = coordinateXYXY[4 * i + 3];
int width = x_br - x_tl;
int height = y_br - y_tl;
}
delete[] classIndices;
delete[] scores;
delete[] coordinateXYXY;
◆ SR_GetDetTestInspectionTime()
◆ SR_GetDetTestInspectionTimeInDouble()
Get the inspection time.
- Parameters
-
| detTestResult | |
| [out] | inspectionTimeInDouble | |
◆ SR_GetDetTestLoadImageTime()
Get the image loading time.
- Parameters
-
| detTestResult | |
| [out] | imageLoadingTimeInLong | |
- Examples
- ExampleDetRuntime.cpp.
◆ SR_GetDetTestLoadImageTimeInDouble()
Get the image loading time.
- Parameters
-
| detTestResult | |
| [out] | imageLoadingTimeInDouble | |
◆ SR_GetDetTestResultAllBoxesInfo()
| eErrorType SR_GetDetTestResultAllBoxesInfo |
( |
DetTestResult |
detTestResult, |
|
|
const int |
numDetectedBoxes, |
|
|
int * |
classIndices, |
|
|
float * |
scores, |
|
|
int * |
coordinatesXYXY |
|
) |
| |
Get all the detected boxes.
It is recommended to use SR_GetDetTestResultDetectedBoxes instead.
- Parameters
-
| detTestResult | |
| numDetectedBoxes | |
| [out] | classIndices | memory address receiving class indices. The length of memory must be equal to numDetectedBoxes |
| [out] | scores | memory address receiving scores. The length of memory must be equal to numDetectedBoxes |
| [out] | coordinatesXYXY | memory address receiving coordinates. The length of memory must be equal to 4 x numDetectedBoxes |
◆ SR_GetDetTestResultDetectedBoxes()
◆ SR_GetDetTestResultNumberOfBoxes()
◆ SR_GetDetTestResultNumberOfBoxesBeforeFiltered()
| eErrorType SR_GetDetTestResultNumberOfBoxesBeforeFiltered |
( |
DetTestResult |
detTestResult, |
|
|
int |
numClasses, |
|
|
int * |
numRawBoxes |
|
) |
| |
Get the number of raw detected boxes before filtered by Max number of boxes for each class.
- Parameters
-
| detTestResult | |
| numClasses | |
| [out] | numRawBoxes | memory address receiving number of raw detected boxes. The length of memory must be equal to numClasses. |
- Examples
- ExampleDetRuntime.cpp.
◆ SR_GetDetTestResultOneBoxInfo()
| eErrorType SR_GetDetTestResultOneBoxInfo |
( |
DetTestResult |
detTestResult, |
|
|
const int |
boxIndex, |
|
|
int * |
classIndex, |
|
|
float * |
score, |
|
|
int * |
coordinateXYXY |
|
) |
| |
Get a single detected box.
It is recommended to use SR_GetDetTestResultDetectedBoxes instead.
- Parameters
-
| detTestResult | |
| boxIndex | |
| [out] | classIndex | memory address receiving a class index. |
| [out] | score | memory address receiving a score. |
| [out] | coordinateXYXY | memory address receiving coordinates. The length of memory must be equal to 4. |