get_dl_classifier_resultT_get_dl_classifier_resultGetDlClassifierResultGetDlClassifierResult (Operator)

Name

get_dl_classifier_resultT_get_dl_classifier_resultGetDlClassifierResultGetDlClassifierResult — Retrieve classification results inferred by a deep-learning-based classifier.

Signature

get_dl_classifier_result( : : DLClassifierResultHandle, Index, GenResultName : GenResultValue)

Herror T_get_dl_classifier_result(const Htuple DLClassifierResultHandle, const Htuple Index, const Htuple GenResultName, Htuple* GenResultValue)

void GetDlClassifierResult(const HTuple& DLClassifierResultHandle, const HTuple& Index, const HTuple& GenResultName, HTuple* GenResultValue)

HTuple HDlClassifierResult::GetDlClassifierResult(const HTuple& Index, const HTuple& GenResultName) const

HTuple HDlClassifierResult::GetDlClassifierResult(const HString& Index, const HString& GenResultName) const

HTuple HDlClassifierResult::GetDlClassifierResult(const char* Index, const char* GenResultName) const

HTuple HDlClassifierResult::GetDlClassifierResult(const wchar_t* Index, const wchar_t* GenResultName) const   (Windows only)

static void HOperatorSet.GetDlClassifierResult(HTuple DLClassifierResultHandle, HTuple index, HTuple genResultName, out HTuple genResultValue)

HTuple HDlClassifierResult.GetDlClassifierResult(HTuple index, HTuple genResultName)

HTuple HDlClassifierResult.GetDlClassifierResult(string index, string genResultName)

Description

get_dl_classifier_resultget_dl_classifier_resultGetDlClassifierResultGetDlClassifierResultGetDlClassifierResult allows the user to return classification results. These results are stored in the handle DLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandle and have been obtained from the operator apply_dl_classifierapply_dl_classifierApplyDlClassifierApplyDlClassifierApplyDlClassifier.

The input parameter GenResultNameGenResultNameGenResultNameGenResultNamegenResultName names the sort of result asked and IndexIndexIndexIndexindex identifies for which image the result is to be returned. The respective value is given in GenResultValueGenResultValueGenResultValueGenResultValuegenResultValue.

Concretely, GenResultNameGenResultNameGenResultNameGenResultNamegenResultName can attain the following values:

'confidences'"confidences""confidences""confidences""confidences":

return the confidences values for the selected image IndexIndexIndexIndexindex.

'predicted_classes'"predicted_classes""predicted_classes""predicted_classes""predicted_classes":

return the names of the inferred classes for the selected image IndexIndexIndexIndexindex.

'predicted_class_indices'"predicted_class_indices""predicted_class_indices""predicted_class_indices""predicted_class_indices":

return the indices of the inferred classes for the selected image IndexIndexIndexIndexindex. The class indices correspond to the positions within the array of classes (counting from 0).

The input parameter IndexIndexIndexIndexindex can attain the value 'all'"all""all""all""all", in which case get_dl_classifier_resultget_dl_classifier_resultGetDlClassifierResultGetDlClassifierResultGetDlClassifierResult returns the confidence value, respectively class, for the best candidate (prediction with the highest confidence value) for each image of the input batch.

Otherwise, IndexIndexIndexIndexindex must be an integer selecting one of the input images in the batch, in which case get_dl_classifier_resultget_dl_classifier_resultGetDlClassifierResultGetDlClassifierResultGetDlClassifierResult returns all output classes, respectively, confidences sorted by decreasing confidence value. This is useful in order to retrieve the best K candidates for a given input. As we start indexing at 0, IndexIndexIndexIndexindex must have a value between 0 and the size of the batch of input images minus one.

For an explanation of the concept of deep-learning-based classification see the introduction of chapter Deep Learning / Classification.

Execution Information

Parameters

DLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandleDLClassifierResultHandle (input_control)  dl_classifier_result HDlClassifierResult, HTupleHTupleHtuple (handle) (IntPtr) (HHandle) (handle)

Handle of the deep learning classification results.

IndexIndexIndexIndexindex (input_control)  number HTupleHTupleHtuple (string / integer) (string / int / long) (HString / Hlong) (char* / Hlong)

Index of the image in the batch.

Default value: 'all' "all" "all" "all" "all"

GenResultNameGenResultNameGenResultNameGenResultNamegenResultName (input_control)  attribute.name(-array) HTupleHTupleHtuple (string) (string) (HString) (char*)

Name of the generic parameter.

Default value: 'predicted_classes' "predicted_classes" "predicted_classes" "predicted_classes" "predicted_classes"

List of values: 'confidences'"confidences""confidences""confidences""confidences", 'predicted_class_indices'"predicted_class_indices""predicted_class_indices""predicted_class_indices""predicted_class_indices", 'predicted_classes'"predicted_classes""predicted_classes""predicted_classes""predicted_classes"

GenResultValueGenResultValueGenResultValueGenResultValuegenResultValue (output_control)  attribute.value(-array) HTupleHTupleHtuple (real / string / integer) (double / string / int / long) (double / HString / Hlong) (double / char* / Hlong)

Value of the generic parameter, either the confidence values, the class names or class indices.

Result

If the parameters are valid, the operator get_dl_classifier_resultget_dl_classifier_resultGetDlClassifierResultGetDlClassifierResultGetDlClassifierResult returns the value 2 (H_MSG_TRUE). If necessary, an exception is raised.

Possible Predecessors

apply_dl_classifierapply_dl_classifierApplyDlClassifierApplyDlClassifierApplyDlClassifier

Possible Successors

clear_dl_classifier_resultclear_dl_classifier_resultClearDlClassifierResultClearDlClassifierResultClearDlClassifierResult

Module

Deep Learning Inference