/**
* @file NeuralNetworksEx.h
* @brief This file contains ANeuralNetworksModel_addOperationEx function definition
- * @ingroup COM_AI_RUNTIME
+ * @note This header describes experimental feature,
+ * so specification here can be changed or/and removed
*/
#ifndef NN_RUNTIME_NEURAL_NETWORKS_EX_H
#define NN_RUNTIME_NEURAL_NETWORKS_EX_H
* Outputs:
* * 0: A tensor of the same {@link OperandCode} as input0.
*/
- ANEURALNETWORKS_TENSORFLOW_MAX_EX = 50003,
+ ANEURALNETWORKS_REDUCE_MAX_EX = 50003,
/**
* Splits a tensor along a given axis into num_splits subtensors.
continue;
case tflite::BuiltinOperator_REDUCE_MAX:
CHECK_NN(ANeuralNetworksModel_addOperationEx(
- nn_model, ANEURALNETWORKS_TENSORFLOW_MAX_EX,
+ nn_model, ANEURALNETWORKS_REDUCE_MAX_EX,
static_cast<uint32_t>(augmented_inputs.size()),
augmented_inputs.data(),
static_cast<uint32_t>(node.outputs->size),
std::string custom_name(registration.custom_name);
if (custom_name.compare("TensorFlowMax") == 0) {
CHECK_NN(ANeuralNetworksModel_addOperationEx(
- nn_model, ANEURALNETWORKS_TENSORFLOW_MAX_EX,
+ nn_model, ANEURALNETWORKS_REDUCE_MAX_EX,
static_cast<uint32_t>(augmented_inputs.size()),
augmented_inputs.data(),
static_cast<uint32_t>(node.outputs->size),
return new operation::ExpNode{inputs, outputs};
};
- _map[ANEURALNETWORKS_TENSORFLOW_MAX_EX] = [](const OperationFactory::Param &init_param) {
+ _map[ANEURALNETWORKS_REDUCE_MAX_EX] = [](const OperationFactory::Param &init_param) {
assert(init_param.input_count == 2 && init_param.output_count == 1);
operand::IndexSet outputs{init_param.outputs[0]};
break;
}
- case ANEURALNETWORKS_TENSORFLOW_MAX_EX:
+ case ANEURALNETWORKS_REDUCE_MAX_EX:
{
using internal::tflite::op::ReduceMax::Param;
using internal::tflite::op::ReduceMax::Node;
GeneratedTests.cast_ex*
GeneratedTests.gather_ex*
GeneratedTests.strided_slice_ex*
-GeneratedTests.tensorflowmax_ex*
+GeneratedTests.reduce_max_ex*
GeneratedTests.reduce_sum_ex*
GeneratedTests.topk_v2*
# Unexpected result
GeneratedTests.cast_ex*
GeneratedTests.gather_ex*
GeneratedTests.strided_slice_ex*
-GeneratedTests.tensorflowmax_ex*
+GeneratedTests.reduce_max_ex*
GeneratedTests.reduce_sum_ex*
GeneratedTests.topk_v2*
# Unhandled exception
i1 = Input("input", "TENSOR_FLOAT32", "{3, 4}")
axis = Int32Scalar("axis", 1)
out1 = Output("output", "TENSOR_FLOAT32", "{3}")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(out1)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(out1)
# Example 1. Input in operand 0, 1
input0 = {i1: # input 0
i1 = Input("input", "TENSOR_INT32", "{3, 4}")
axis = Int32Scalar("axis", 1)
out1 = Output("output", "TENSOR_INT32", "{3}")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(out1)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(out1)
# Example 1. Input in operand 0, 1
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{2}", [3, -1])
output = Output("output", "TENSOR_FLOAT32", "{%d, %d, %d}" % (batch, rows, cols))
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 2, -3, -2])
output = Output("output", "TENSOR_FLOAT32", "{%d, %d}" % (batch, depth))
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{1}", [2])
output = Output("output", "TENSOR_FLOAT32", "{1, 2, 1}")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 0, -3, -3])
output = Output("output", "TENSOR_FLOAT32", "{2}")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{2}", [0, 2])
output = Output("output", "TENSOR_FLOAT32", "{1, 3, 1}")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{4}", [1, 0, -3, -3])
output = Output("output", "TENSOR_QUANT8_ASYMM", "{2}, 0.8, 5")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0
axis = Parameter("axis", "TENSOR_INT32", "{2}", [0, 2])
output = Output("output", "TENSOR_QUANT8_ASYMM", "{1, 3, 1}, 0.8, 5")
-model = model.Operation("TENSORFLOW_MAX_EX", i1, axis).To(output)
+model = model.Operation("REDUCE_MAX_EX", i1, axis).To(output)
# Example 1. Input in operand 0,
input0 = {i1: # input 0