aboutsummaryrefslogtreecommitdiff
path: root/arm_compute/runtime/CL/functions/CLSplit.h
diff options
context:
space:
mode:
authorKurtis Charnock <kurtis.charnock@arm.com>2019-11-29 11:42:30 +0000
committerGeorgios Pinitas <georgios.pinitas@arm.com>2020-01-13 17:43:02 +0000
commitec00da149b7884114cd6c43cc9c1cff62ddaa710 (patch)
treeef02ea4d3c5b45178606f40cbea6af6b33005d6f /arm_compute/runtime/CL/functions/CLSplit.h
parent6f314db14f0fd242d53f3a9f780158169259b31b (diff)
downloadComputeLibrary-ec00da149b7884114cd6c43cc9c1cff62ddaa710.tar.gz
COMPMID-2728: Add support for split sizes in CLSplit
Signed-off-by: Kurtis Charnock <kurtis.charnock@arm.com> Change-Id: I69ea9e812478904c3e10379bb5943d534c45f942 Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/c/VisualCompute/ComputeLibrary/+/214132 Tested-by: bsgcomp <bsgcomp@arm.com> Reviewed-by: Georgios Pinitas <georgios.pinitas@arm.com> Reviewed-on: https://review.mlplatform.org/c/2432 Tested-by: Arm Jenkins <bsgcomp@arm.com> Comments-Addressed: Arm Jenkins <bsgcomp@arm.com> Reviewed-by: Michele Di Giorgio <michele.digiorgio@arm.com>
Diffstat (limited to 'arm_compute/runtime/CL/functions/CLSplit.h')
-rw-r--r--arm_compute/runtime/CL/functions/CLSplit.h35
1 files changed, 3 insertions, 32 deletions
diff --git a/arm_compute/runtime/CL/functions/CLSplit.h b/arm_compute/runtime/CL/functions/CLSplit.h
index 7e22f52022..87265a4c00 100644
--- a/arm_compute/runtime/CL/functions/CLSplit.h
+++ b/arm_compute/runtime/CL/functions/CLSplit.h
@@ -24,9 +24,11 @@
#ifndef ARM_COMPUTE_CLSPLIT_H
#define ARM_COMPUTE_CLSPLIT_H
+#include "arm_compute/core/CL/ICLTensor.h"
#include "arm_compute/core/Types.h"
#include "arm_compute/runtime/CL/functions/CLSlice.h"
+#include "arm_compute/runtime/CPP/functions/CPPSplit.h"
#include "arm_compute/runtime/IFunction.h"
#include <memory>
@@ -34,43 +36,12 @@
namespace arm_compute
{
-// Forward declarations
-class ICLTensor;
-
/** Basic function to split a tensor along a given axis */
-class CLSplit : public IFunction
+class CLSplit : public CPPSplit<CLSlice, ICLTensor>
{
public:
- /** Default constructor */
- CLSplit();
- /** Initialise the kernel's input and outputs.
- *
- * @param[in] input The input tensor. Data types supported: All.
- * @param[out] outputs A vector containing the output tensors. Data types supported: Same as @p input.
- * The output tensors should match the input tensor dimensions for all shape dimensions apart
- * from the split dimension.
- * @param[in] axis Axis on which to split the input.
- */
- void configure(const ICLTensor *input, const std::vector<ICLTensor *> &outputs, unsigned int axis);
- /** Static function to check if given info will lead to a valid configuration of @ref CLSplit
- *
- * @param[in] input The input tensor info. Data types supported: All.
- * @param[in] outputs A vector containing the output tensors' info. Data types supported: Same as @p input.
- * The output tensors should match the input tensor dimensions for all shape dimensions apart
- * from the split dimension
- * @param[in] axis Axis on which to split the input.
- *
- * @return a status
- */
- static Status validate(const ITensorInfo *input, const std::vector<ITensorInfo *> &outputs, unsigned int axis);
-
// Inherited methods overridden:
void run() override;
-
-private:
- std::vector<ICLTensor *> _outputs_vector;
- std::vector<CLSlice> _slice_functions;
- unsigned int _num_outputs;
};
} // namespace arm_compute
#endif /* ARM_COMPUTE_CLSPLIT_H */