diff options
Diffstat (limited to 'res/TensorFlowTests/UNIT_Mean_002')
-rw-r--r-- | res/TensorFlowTests/UNIT_Mean_002/test.info | 2 | ||||
-rw-r--r-- | res/TensorFlowTests/UNIT_Mean_002/test.pbtxt | 68 |
2 files changed, 70 insertions, 0 deletions
diff --git a/res/TensorFlowTests/UNIT_Mean_002/test.info b/res/TensorFlowTests/UNIT_Mean_002/test.info new file mode 100644 index 000000000..682e7cb20 --- /dev/null +++ b/res/TensorFlowTests/UNIT_Mean_002/test.info @@ -0,0 +1,2 @@ +input, Placeholder:0, TF_FLOAT, [1, 3, 3, 2] +output, Mean:0, TF_FLOAT, [1, 2] diff --git a/res/TensorFlowTests/UNIT_Mean_002/test.pbtxt b/res/TensorFlowTests/UNIT_Mean_002/test.pbtxt new file mode 100644 index 000000000..1d129f9a2 --- /dev/null +++ b/res/TensorFlowTests/UNIT_Mean_002/test.pbtxt @@ -0,0 +1,68 @@ +# Reference Python code: +# +# import tensorflow as tf +# +# inp = tf.placeholder(tf.float32, [1,3,3,2]) +# mean = tf.math.reduce_mean(inp, keepdims=False, axis=[-2,-3]) +# +# print(tf.get_default_graph().as_graph_def()) +# +# WARNING! Below GraphDef is modified to make it easy to read +node { + name: "Placeholder" + op: "Placeholder" + attr { + key: "dtype" + value { type: DT_FLOAT } + } + attr { + key: "shape" + value { + shape { + dim { size: 1 } + dim { size: 3 } + dim { size: 3 } + dim { size: 2 } + } + } + } +} +node { + name: "Mean/reduction_indices" + op: "Const" + attr { + key: "dtype" + value { type: DT_INT32 } + } + attr { + key: "value" + value { + tensor { + dtype: DT_INT32 + tensor_shape { + dim { size: 2 } + } + int_val: -2 + int_val: -3 + } + } + } +} +node { + name: "Mean" + op: "Mean" + input: "Placeholder" + input: "Mean/reduction_indices" + attr { + key: "T" + value { type: DT_FLOAT } + } + attr { + key: "Tidx" + value { type: DT_INT32 } + } + attr { + key: "keep_dims" + value { b: false } + } +} |