diff options
author | Michele Di Giorgio <michele.digiorgio@arm.com> | 2019-09-20 14:01:48 +0100 |
---|---|---|
committer | Michele Di Giorgio <michele.digiorgio@arm.com> | 2019-09-20 17:04:24 +0000 |
commit | 4c268b97dff93eae3f71f2a6971f0d3f748b7b38 (patch) | |
tree | 4f3023105369f21a4df540db28f9b2c191a51534 /src/runtime/CL | |
parent | c9564cb3850b6675cef663d7cc0722567b55cc25 (diff) | |
download | ComputeLibrary-4c268b97dff93eae3f71f2a6971f0d3f748b7b38.tar.gz |
COMPMID-2681: Use NE/CL/Pad in NE/CL/GenerateProposalsLayer
Change-Id: Idf1c64224b0ddd4bdac1120cac4437eb2578bb2b
Signed-off-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Reviewed-on: https://review.mlplatform.org/c/1963
Comments-Addressed: Arm Jenkins <bsgcomp@arm.com>
Reviewed-by: Pablo Marquez <pablo.tello@arm.com>
Tested-by: Arm Jenkins <bsgcomp@arm.com>
Diffstat (limited to 'src/runtime/CL')
-rw-r--r-- | src/runtime/CL/functions/CLGenerateProposalsLayer.cpp | 13 |
1 files changed, 4 insertions, 9 deletions
diff --git a/src/runtime/CL/functions/CLGenerateProposalsLayer.cpp b/src/runtime/CL/functions/CLGenerateProposalsLayer.cpp index d712a23325..94aa5e7198 100644 --- a/src/runtime/CL/functions/CLGenerateProposalsLayer.cpp +++ b/src/runtime/CL/functions/CLGenerateProposalsLayer.cpp @@ -37,8 +37,7 @@ CLGenerateProposalsLayer::CLGenerateProposalsLayer(std::shared_ptr<IMemoryManage _flatten_scores_kernel(), _compute_anchors_kernel(), _bounding_box_kernel(), - _memset_kernel(), - _padded_copy_kernel(), + _pad_kernel(), _cpp_nms_kernel(), _is_nhwc(false), _deltas_permuted(), @@ -149,10 +148,8 @@ void CLGenerateProposalsLayer::configure(const ICLTensor *scores, const ICLTenso _scores_flattened.allocator()->allocate(); // Add the first column that represents the batch id. This will be all zeros, as we don't support multiple images - _padded_copy_kernel.configure(&_proposals_4_roi_values, proposals, PaddingList{ { 1, 0 } }); + _pad_kernel.configure(&_proposals_4_roi_values, proposals, PaddingList{ { 1, 0 } }); _proposals_4_roi_values.allocator()->allocate(); - - _memset_kernel.configure(proposals, PixelValue()); } Status CLGenerateProposalsLayer::validate(const ITensorInfo *scores, const ITensorInfo *deltas, const ITensorInfo *anchors, const ITensorInfo *proposals, const ITensorInfo *scores_out, @@ -197,8 +194,7 @@ Status CLGenerateProposalsLayer::validate(const ITensorInfo *scores, const ITens ARM_COMPUTE_RETURN_ON_ERROR(CLBoundingBoxTransformKernel::validate(&all_anchors_info, &proposals_4_roi_values, &deltas_flattened_info, BoundingBoxTransformInfo(info.im_width(), info.im_height(), 1.f))); - ARM_COMPUTE_RETURN_ON_ERROR(CLCopyKernel::validate(&proposals_4_roi_values, proposals, PaddingList{ { 0, 1 } })); - ARM_COMPUTE_RETURN_ON_ERROR(CLMemsetKernel::validate(proposals, PixelValue())); + ARM_COMPUTE_RETURN_ON_ERROR(CLPadLayerKernel::validate(&proposals_4_roi_values, proposals, PaddingList{ { 1, 0 } })); if(num_valid_proposals->total_size() > 0) { @@ -275,7 +271,6 @@ void CLGenerateProposalsLayer::run() // Non maxima suppression run_cpp_nms_kernel(); // Add dummy batch indexes - CLScheduler::get().enqueue(_memset_kernel, true); - CLScheduler::get().enqueue(_padded_copy_kernel, true); + CLScheduler::get().enqueue(_pad_kernel, true); } } // namespace arm_compute |