get_dl_classifier_result
— Retrieve classification results inferred by a deep-learning-based
classifier.
get_dl_classifier_result
is obsolete and is only provided for
reasons of backward compatibility.
get_dl_classifier_result( : : DLClassifierResultHandle, Index, GenResultName : GenResultValue)
get_dl_classifier_result
allows the user to return
classification results. These results are stored in the handle
DLClassifierResultHandle
and have been obtained from
the operator apply_dl_classifier
.
The input parameter GenResultName
names the sort of result asked
and Index
identifies for which image the result is to be returned.
The respective value is given in GenResultValue
.
Concretely, GenResultName
can attain the following values:
return the confidences values for the
selected image Index
.
return the names of the inferred
classes for the selected image Index
.
return the indices of
the inferred classes for the selected image Index
.
The class indices correspond to the positions within the array of
classes (counting from 0).
The input parameter Index
can attain the value 'all' , in
which case get_dl_classifier_result
returns the confidence value,
respectively class, for the best candidate (prediction with the
highest confidence value) for each image of the input batch.
Otherwise, Index
must be an integer selecting one of the input
images in the batch, in which case get_dl_classifier_result
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, Index
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. The workflow involving this legacy operator is described in the chapter Legacy / DL Classification.
DLClassifierResultHandle
(input_control) dl_classifier_result →
(handle)
Handle of the deep learning classification results.
Index
(input_control) number →
(string / integer)
Index of the image in the batch.
Default value: 'all'
GenResultName
(input_control) attribute.name(-array) →
(string)
Name of the generic parameter.
Default value: 'predicted_classes'
List of values: 'confidences' , 'predicted_class_indices' , 'predicted_classes'
GenResultValue
(output_control) attribute.value(-array) →
(real / string / integer)
Value of the generic parameter, either the confidence values, the class names or class indices.
If the parameters are valid, the operator
get_dl_classifier_result
returns the value 2 (H_MSG_TRUE). If
necessary, an exception is raised.
Deep Learning Inference