summaryrefslogtreecommitdiff
path: root/tests/nnapi/specs/V1_2/abs_2D_float_nnfw.mod.py
blob: 901127b8da08b7e8268a30e036b09920e502c28b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
# model
model = Model()

i1 = Input("input", "TENSOR_FLOAT32", "{5, 2}")
i2 = Output("output", "TENSOR_FLOAT32", "{5, 2}")
model = model.Operation("ABS", i1).To(i2)

# Example 1. Input in operand 0,
input0 = {i1: # input 0
          [0.735078,	-0.46738, -241,	0.9118, -0.46686,	
          -3150.219, -0.495291,	-0.42874460, 0.5005046655,
          0.1131106620]}

output0 = {i2: # output 0
           [0.735078,	0.46738, 241,	0.9118, 0.46686,	
          3150.219, 0.495291,	0.42874460, 0.5005046655,
          0.1131106620]}

# Instantiate an example
Example((input0, output0))