aboutsummaryrefslogtreecommitdiff
path: root/src/graph
diff options
context:
space:
mode:
authorSang-Hoon Park <sang-hoon.park@arm.com>2020-03-06 16:32:01 +0000
committerGeorgios Pinitas <georgios.pinitas@arm.com>2020-03-11 18:34:03 +0000
commit6800117df3be825f0ec5c6cc71c4377322f51b99 (patch)
tree0e579a271f2676dc2d6aa947df29a5cf0ab8bd1c /src/graph
parent9204646e091ffc25eda61768537357916a4f7df4 (diff)
downloadComputeLibrary-6800117df3be825f0ec5c6cc71c4377322f51b99.tar.gz
COMPMID-3221: (DATA_UPDATE) add graph example for EDSR
Change-Id: Id74190e2af444da8dab4813fd65016104f3882a9 Signed-off-by: Sang-Hoon Park <sang-hoon.park@arm.com> Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/2862 Tested-by: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/graph')
-rw-r--r--src/graph/nodes/DeconvolutionLayerNode.cpp12
-rw-r--r--src/graph/nodes/EltwiseLayerNode.cpp15
2 files changed, 20 insertions, 7 deletions
diff --git a/src/graph/nodes/DeconvolutionLayerNode.cpp b/src/graph/nodes/DeconvolutionLayerNode.cpp
index d4a5b769e7..a2e4e2b056 100644
--- a/src/graph/nodes/DeconvolutionLayerNode.cpp
+++ b/src/graph/nodes/DeconvolutionLayerNode.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2018-2019 ARM Limited.
+ * Copyright (c) 2018-2020 ARM Limited.
*
* SPDX-License-Identifier: MIT
*
@@ -32,8 +32,8 @@ namespace arm_compute
{
namespace graph
{
-DeconvolutionLayerNode::DeconvolutionLayerNode(PadStrideInfo info)
- : _info(std::move(info))
+DeconvolutionLayerNode::DeconvolutionLayerNode(PadStrideInfo info, QuantizationInfo out_quant_info)
+ : _info(std::move(info)), _out_quant_info(std::move(out_quant_info))
{
_input_edges.resize(3, EmptyEdgeID);
_outputs.resize(1, NullTensorID);
@@ -88,6 +88,12 @@ TensorDescriptor DeconvolutionLayerNode::configure_output(size_t idx) const
ARM_COMPUTE_ERROR_ON(src == nullptr || weights == nullptr);
TensorDescriptor output_info = compute_output_descriptor(src->desc(), weights->desc(), _info);
+
+ if(!_out_quant_info.empty())
+ {
+ output_info.set_quantization_info(_out_quant_info);
+ }
+
return output_info;
}
diff --git a/src/graph/nodes/EltwiseLayerNode.cpp b/src/graph/nodes/EltwiseLayerNode.cpp
index 568b882425..7970bad5f7 100644
--- a/src/graph/nodes/EltwiseLayerNode.cpp
+++ b/src/graph/nodes/EltwiseLayerNode.cpp
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2018 ARM Limited.
+ * Copyright (c) 2018-2020 ARM Limited.
*
* SPDX-License-Identifier: MIT
*
@@ -30,8 +30,8 @@ namespace arm_compute
{
namespace graph
{
-EltwiseLayerNode::EltwiseLayerNode(EltwiseOperation op, ConvertPolicy c_policy, RoundingPolicy r_policy)
- : _op(op), _convert_policy(c_policy), _rounding_policy(r_policy)
+EltwiseLayerNode::EltwiseLayerNode(EltwiseOperation op, QuantizationInfo out_quant_info, ConvertPolicy c_policy, RoundingPolicy r_policy)
+ : _op(op), _out_quant_info(out_quant_info), _convert_policy(c_policy), _rounding_policy(r_policy)
{
_input_edges.resize(2, EmptyEdgeID);
_outputs.resize(1, NullTensorID);
@@ -71,7 +71,14 @@ TensorDescriptor EltwiseLayerNode::configure_output(size_t idx) const
const Tensor *src = input(0);
ARM_COMPUTE_ERROR_ON(src == nullptr);
- return src->desc();
+ auto output_info = src->desc();
+
+ if(!_out_quant_info.empty())
+ {
+ output_info.set_quantization_info(_out_quant_info);
+ }
+
+ return output_info;
}
NodeType EltwiseLayerNode::type() const