Imported Upstream version 1.7.0
[platform/core/ml/nnfw.git] / tests / nnapi / specs / V1_2 / reduce_max_float_nnfw.mod.py
1 model = Model()
2 i1 = Input("input", "TENSOR_FLOAT32", "{1, 2, 2, 1}")
3 axis = Parameter("axis", "TENSOR_INT32", "{1}", [2])
4 keepDims = False
5 output = Output("output", "TENSOR_FLOAT32", "{1, 2, 1}")
6
7 model = model.Operation("REDUCE_MAX", i1, axis, keepDims).To(output)
8
9 # Example 1. Input in operand 0,
10 input0 = {i1: # input 0
11           [1.0, 2.0,
12            3.0, 4.0]}
13
14 output0 = {output: # output 0
15           [2.0,
16            4.0]}
17
18 # Instantiate an example
19 Example((input0, output0))