From 3864c8e5c79c1d04c18b1b99ee85cd0b9ddb4f55 Mon Sep 17 00:00:00 2001 From: =?utf8?q?Shubham=20Gupta/System=20SW=20/SRI-Bangalore/Engineer/?= =?utf8?q?=EC=82=BC=EC=84=B1=EC=A0=84=EC=9E=90?= Date: Tue, 6 Nov 2018 06:11:03 +0530 Subject: [PATCH] Defining CAST_EX in NeuralNetworksEx.h (#3424) This patch defines CAST_EX in NeuralNetworksEx.h Signed-off-by: shubham --- include/NeuralNetworksEx.h | 26 ++++++++++++++++++++++++++ 1 file changed, 26 insertions(+) diff --git a/include/NeuralNetworksEx.h b/include/NeuralNetworksEx.h index 3fe9ec8..b34db9e 100644 --- a/include/NeuralNetworksEx.h +++ b/include/NeuralNetworksEx.h @@ -32,6 +32,32 @@ __BEGIN_DECLS */ typedef enum { /** extends operation. */ + + /** + * Casts a tensor/tensor-values to a new type + * + * The output value is calucated as: + * + * output = new_type(input) + * + * Ex: + * X = {1.8,2.2}, dtype of X = float32 + * Y = Cast(X), dtype of Y = int32 + * then Y = {1,2} + * + * Supported tensor {@link OperandCode}: + * * {@link ANEURALNETWORKS_TENSOR_FLOAT32} + * * {@link ANEURALNETWORKS_TENSOR_INT32} + * * {@link ANEURALNETWORKS_TENSOR_QUANT8_ASYMM} + * + * Supported tensor rank: up to 4 + * + * Inputs: + * * 0: An n-D tensor, specifying the first input. + * + * Outputs: + * * 0: The output tensor, of the same {@link OperandCode} and shape as input0. + */ ANEURALNETWORKS_CAST_EX = 50000, /**< Casts a tensor to a new type */ ANEURALNETWORKS_GATHER_EX = 50001, /**< Gather slices according to indexes and axis */ ANEURALNETWORKS_TOPK_V2_EX = 50002, /**< Find values and indices of the k largest elements */ -- 2.7.4