From 102b0ce919bf5415993cdd6b0e4385b35734d38d Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Thu, 13 Feb 2020 17:59:09 +0000 Subject: COMPMID-3105: Update pad layer to PadV2 Adds the ability to set the padding value in the pad layer node. Change-Id: I2f323146cbdfdfd6cfd617ee4bcafb5ffafedbbb Signed-off-by: Georgios Pinitas Reviewed-on: https://review.mlplatform.org/c/ml/ComputeLibrary/+/2727 Reviewed-by: Michele Di Giorgio Comments-Addressed: Arm Jenkins Tested-by: Arm Jenkins --- arm_compute/graph/backends/FunctionHelpers.h | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'arm_compute/graph/backends/FunctionHelpers.h') diff --git a/arm_compute/graph/backends/FunctionHelpers.h b/arm_compute/graph/backends/FunctionHelpers.h index 9f352edb9a..20c69bfffa 100644 --- a/arm_compute/graph/backends/FunctionHelpers.h +++ b/arm_compute/graph/backends/FunctionHelpers.h @@ -1048,15 +1048,16 @@ std::unique_ptr create_pad_layer(PadLayerNode &node) validate_node(node, 1 /* expected inputs */, 1 /* expected outputs */); // Extract IO and info - typename TargetInfo::TensorType *input = get_backing_tensor(node.input(0)); - typename TargetInfo::TensorType *output = get_backing_tensor(node.output(0)); - const PaddingList &padding = node.padding(); + typename TargetInfo::TensorType *input = get_backing_tensor(node.input(0)); + typename TargetInfo::TensorType *output = get_backing_tensor(node.output(0)); + const PaddingList &padding = node.padding(); + const PixelValue pad_value = node.pad_value(); ARM_COMPUTE_ERROR_ON(input == nullptr); ARM_COMPUTE_ERROR_ON(output == nullptr); // Create and configure function auto func = support::cpp14::make_unique(); - func->configure(input, output, padding); + func->configure(input, output, padding, pad_value); // Log info ARM_COMPUTE_LOG_GRAPH_INFO("Instantiated " -- cgit v1.2.1