From d9eb27597eabe5b7c17520f4f9b3f8a282d72573 Mon Sep 17 00:00:00 2001 From: Georgios Pinitas Date: Tue, 3 Apr 2018 13:44:29 +0100 Subject: COMPMID-797: Switch to new graph. - Cleaned up build system Change-Id: If2faa27ee5b31fa8b972836960ab3ef671059c8d Reviewed-on: https://eu-gerrit-1.euhpc.arm.com/126435 Tested-by: Jenkins Reviewed-by: Pablo Tello --- arm_compute/graph2/nodes/ActivationLayerNode.h | 60 ---------------- .../graph2/nodes/BatchNormalizationLayerNode.h | 72 ------------------- arm_compute/graph2/nodes/ConstNode.h | 55 -------------- arm_compute/graph2/nodes/ConvolutionLayerNode.h | 84 ---------------------- .../graph2/nodes/DepthConcatenateLayerNode.h | 78 -------------------- .../graph2/nodes/DepthwiseConvolutionLayerNode.h | 84 ---------------------- arm_compute/graph2/nodes/EltwiseLayerNode.h | 60 ---------------- arm_compute/graph2/nodes/FlattenLayerNode.h | 49 ------------- arm_compute/graph2/nodes/FullyConnectedLayerNode.h | 75 ------------------- arm_compute/graph2/nodes/InputNode.h | 55 -------------- arm_compute/graph2/nodes/Nodes.h | 44 ------------ arm_compute/graph2/nodes/NodesFwd.h | 51 ------------- arm_compute/graph2/nodes/NormalizationLayerNode.h | 60 ---------------- arm_compute/graph2/nodes/OutputNode.h | 49 ------------- arm_compute/graph2/nodes/PoolingLayerNode.h | 68 ------------------ arm_compute/graph2/nodes/ReshapeLayerNode.h | 55 -------------- arm_compute/graph2/nodes/SoftmaxLayerNode.h | 60 ---------------- arm_compute/graph2/nodes/SplitLayerNode.h | 79 -------------------- 18 files changed, 1138 deletions(-) delete mode 100644 arm_compute/graph2/nodes/ActivationLayerNode.h delete mode 100644 arm_compute/graph2/nodes/BatchNormalizationLayerNode.h delete mode 100644 arm_compute/graph2/nodes/ConstNode.h delete mode 100644 arm_compute/graph2/nodes/ConvolutionLayerNode.h delete mode 100644 arm_compute/graph2/nodes/DepthConcatenateLayerNode.h delete mode 100644 arm_compute/graph2/nodes/DepthwiseConvolutionLayerNode.h delete mode 100644 arm_compute/graph2/nodes/EltwiseLayerNode.h delete mode 100644 arm_compute/graph2/nodes/FlattenLayerNode.h delete mode 100644 arm_compute/graph2/nodes/FullyConnectedLayerNode.h delete mode 100644 arm_compute/graph2/nodes/InputNode.h delete mode 100644 arm_compute/graph2/nodes/Nodes.h delete mode 100644 arm_compute/graph2/nodes/NodesFwd.h delete mode 100644 arm_compute/graph2/nodes/NormalizationLayerNode.h delete mode 100644 arm_compute/graph2/nodes/OutputNode.h delete mode 100644 arm_compute/graph2/nodes/PoolingLayerNode.h delete mode 100644 arm_compute/graph2/nodes/ReshapeLayerNode.h delete mode 100644 arm_compute/graph2/nodes/SoftmaxLayerNode.h delete mode 100644 arm_compute/graph2/nodes/SplitLayerNode.h (limited to 'arm_compute/graph2/nodes') diff --git a/arm_compute/graph2/nodes/ActivationLayerNode.h b/arm_compute/graph2/nodes/ActivationLayerNode.h deleted file mode 100644 index cb19c818c5..0000000000 --- a/arm_compute/graph2/nodes/ActivationLayerNode.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_ACTIVATION_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_ACTIVATION_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Activation Layer node */ -class ActivationLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] info Activation Layer information - */ - ActivationLayerNode(ActivationLayerInfo info); - /** Activation metadata accessor - * - * @return The activation info of the layer - */ - ActivationLayerInfo activation_info() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - ActivationLayerInfo _info; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_ACTIVATION_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/BatchNormalizationLayerNode.h b/arm_compute/graph2/nodes/BatchNormalizationLayerNode.h deleted file mode 100644 index a6e8e2b98e..0000000000 --- a/arm_compute/graph2/nodes/BatchNormalizationLayerNode.h +++ /dev/null @@ -1,72 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_BATCH_NORMALIZATION_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_BATCH_NORMALIZATION_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Batch Normalization Layer node */ -class BatchNormalizationLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] epsilon (Optional) Epsilon parameter. Defaults to 1.f - * @param[in] fused_activation (Optional) Fused activation layer. Disabled if not specified - */ - BatchNormalizationLayerNode(float epsilon = 1.f, ActivationLayerInfo fused_activation = ActivationLayerInfo()); - /** Epsilon parameter accessor - * - * @return Epsilon parameter - */ - float epsilon() const; - /** Returns fused activation - * - * @return Fused activation - */ - ActivationLayerInfo fused_activation() const; - /** Sets fused activation - * - * @param[in] fused_activation Fused activation to set - */ - void set_fused_activation(ActivationLayerInfo fused_activation); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - float _epsilon; - ActivationLayerInfo _fused_activation; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_BATCH_NORMALIZATION_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/ConstNode.h b/arm_compute/graph2/nodes/ConstNode.h deleted file mode 100644 index e1c66176f0..0000000000 --- a/arm_compute/graph2/nodes/ConstNode.h +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_CONST_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_CONST_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Const node */ -class ConstNode final : public INode -{ -public: - /** Constructor - * - * @param[in] desc Tensor descriptor - */ - ConstNode(TensorDescriptor desc); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - TensorDescriptor _desc; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_CONST_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/ConvolutionLayerNode.h b/arm_compute/graph2/nodes/ConvolutionLayerNode.h deleted file mode 100644 index 6e3c9bef32..0000000000 --- a/arm_compute/graph2/nodes/ConvolutionLayerNode.h +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_CONVOLUTION_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_CONVOLUTION_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Convolution Layer node */ -class ConvolutionLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] info Convolution layer attributes - * @param[in] method (Optional) Convolution method to use - */ - ConvolutionLayerNode(PadStrideInfo info, ConvolutionMethod method = ConvolutionMethod::DEFAULT); - /** Sets the convolution layer method to use - * - * @param[in] method Method to use for convolution - */ - void set_convolution_method(ConvolutionMethod method); - /** Convolution layer method accessor - * - * @note This is an indication on which convolution layer implementation to use, - * if it fails to be created the library's heuristic approach will be used - * - * @return Convolution layer method do be used by the node - */ - ConvolutionMethod convolution_method() const; - /** Convolution metadata accessor - * - * @return Convolution information - */ - PadStrideInfo convolution_info() const; - /** Computes convolution output shape - * - * @param[in] input_shape Input shape - * @param[in] weights_shape Weights shape - * @param[in] info Convolution operation attributes - * - * @return Output shape - */ - static TensorShape compute_output_shape(TensorShape input_shape, TensorShape weights_shape, PadStrideInfo info); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - PadStrideInfo _info; - ConvolutionMethod _method; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_CONVOLUTION_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/DepthConcatenateLayerNode.h b/arm_compute/graph2/nodes/DepthConcatenateLayerNode.h deleted file mode 100644 index 23c31048e9..0000000000 --- a/arm_compute/graph2/nodes/DepthConcatenateLayerNode.h +++ /dev/null @@ -1,78 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_DEPTH_CONCATENATE_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_DEPTH_CONCATENATE_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Depth Concatenation Layer node */ -class DepthConcatenateLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] total_nodes Number of nodes that will get concatenated - */ - DepthConcatenateLayerNode(unsigned int total_nodes); - /** Computes depth concatenations output shape - * - * @param input_shapes Shapes of the inputs - * - * @return Expected output shape - */ - static TensorShape compute_output_shape(const std::vector &input_shapes); - /** Disables or not the depth concatenate node - * - * @warning This is used when depth concatenate is performed with sub-tensors, - * where this node is used as a placeholder. - * - * @param[in] is_enabled If true a backend function is created to perform the depth concatenation (involves copying), - * while if false, no function is created and we assume that subtensors are properly set to simulate - * a no copy operation. - */ - void set_enabled(bool is_enabled); - /** Enabled parameter accessor - * - * @return True if a backend function is to be created else false - */ - bool is_enabled() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - unsigned int _total_nodes; - bool _is_enabled; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_DEPTH_CONCATENATE_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/DepthwiseConvolutionLayerNode.h b/arm_compute/graph2/nodes/DepthwiseConvolutionLayerNode.h deleted file mode 100644 index d5b8e34554..0000000000 --- a/arm_compute/graph2/nodes/DepthwiseConvolutionLayerNode.h +++ /dev/null @@ -1,84 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_DEPTHWISE_CONVOLUTION_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_DEPTHWISE_CONVOLUTION_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Depthwise Convolution Layer node */ -class DepthwiseConvolutionLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] info Convolution layer attributes - * @param[in] method Depthwise convolution method to use - */ - DepthwiseConvolutionLayerNode(PadStrideInfo info, DepthwiseConvolutionMethod method = DepthwiseConvolutionMethod::DEFAULT); - /** Sets the depthwise convolution method to use - * - * @param[in] method Depthwise convolution method to use - */ - void set_depthwise_convolution_method(DepthwiseConvolutionMethod method); - /** Depthwise convolution layer method accessor - * - * @note This is an indication on which depthwise implementation to use, - * if it fails to be created the generic approach will be used - * - * @return Depthwise convolution layer method do be used by the node - */ - DepthwiseConvolutionMethod depthwise_convolution_method() const; - /** Convolution metadata accessor - * - * @return Convolution information - */ - PadStrideInfo convolution_info() const; - /** Computes depthwise convolution output shape - * - * @param[in] input_shape Input shape - * @param[in] weights_shape Weights shape - * @param[in] info Convolution operation attributes - * - * @return Output shape - */ - static TensorShape compute_output_shape(TensorShape input_shape, TensorShape weights_shape, PadStrideInfo info); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - PadStrideInfo _info; - DepthwiseConvolutionMethod _method; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_DEPTHWISE_CONVOLUTION_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/EltwiseLayerNode.h b/arm_compute/graph2/nodes/EltwiseLayerNode.h deleted file mode 100644 index 48df2b715d..0000000000 --- a/arm_compute/graph2/nodes/EltwiseLayerNode.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_ELTWISE_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_ELTWISE_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Eltwise Layer node */ -class EltwiseLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] op Element-wise operation to perform - */ - EltwiseLayerNode(EltwiseOperation op); - /** Eltwise operation accessor - * - * @return Eltwise operation that is to be performed by the node - */ - EltwiseOperation eltwise_operation() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - EltwiseOperation _op; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_ELTWISE_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/FlattenLayerNode.h b/arm_compute/graph2/nodes/FlattenLayerNode.h deleted file mode 100644 index 41f6f85045..0000000000 --- a/arm_compute/graph2/nodes/FlattenLayerNode.h +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_FLATTEN_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_FLATTEN_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Flatten Layer node */ -class FlattenLayerNode final : public INode -{ -public: - /** Default Constructor */ - FlattenLayerNode(); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_FLATTEN_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/FullyConnectedLayerNode.h b/arm_compute/graph2/nodes/FullyConnectedLayerNode.h deleted file mode 100644 index 5c71f4ca69..0000000000 --- a/arm_compute/graph2/nodes/FullyConnectedLayerNode.h +++ /dev/null @@ -1,75 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_FULLY_CONNECTED_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_FULLY_CONNECTED_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Fully Connected Layer node */ -class FullyConnectedLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] num_outputs Number of neurons in the layer - */ - FullyConnectedLayerNode(unsigned int num_outputs); - /** Computes weights shape - * - * @warning Works for inputs with 1D batch space - * - * @param[in] input_shape Input shape - * @param[in] num_outputs Number of output neurons - * - * @return Weights shape - */ - static TensorShape compute_weights_shape(TensorShape input_shape, unsigned int num_outputs); - /** Computes fully connected layer output shape - * - * @warning Works for inputs with 1D batch space - * - * @param[in] input_shape Input shape - * @param[in] num_outputs Number of output neurons - * - * @return Output shape - */ - static TensorShape compute_output_shape(TensorShape input_shape, unsigned int num_outputs); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - unsigned int _num_outputs; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_FULLY_CONNECTED_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/InputNode.h b/arm_compute/graph2/nodes/InputNode.h deleted file mode 100644 index 667dcfacf0..0000000000 --- a/arm_compute/graph2/nodes/InputNode.h +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_INPUT_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_INPUT_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Input Layer node */ -class InputNode final : public INode -{ -public: - /** Constructor - * - * @param[in] desc Tensor descriptor - */ - InputNode(TensorDescriptor desc); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - TensorDescriptor _desc; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_INPUT_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/Nodes.h b/arm_compute/graph2/nodes/Nodes.h deleted file mode 100644 index 3786978661..0000000000 --- a/arm_compute/graph2/nodes/Nodes.h +++ /dev/null @@ -1,44 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_NODES_H__ -#define __ARM_COMPUTE_GRAPH2_NODES_H__ - -#include "arm_compute/graph2/nodes/ActivationLayerNode.h" -#include "arm_compute/graph2/nodes/BatchNormalizationLayerNode.h" -#include "arm_compute/graph2/nodes/ConstNode.h" -#include "arm_compute/graph2/nodes/ConvolutionLayerNode.h" -#include "arm_compute/graph2/nodes/DepthConcatenateLayerNode.h" -#include "arm_compute/graph2/nodes/DepthwiseConvolutionLayerNode.h" -#include "arm_compute/graph2/nodes/EltwiseLayerNode.h" -#include "arm_compute/graph2/nodes/FlattenLayerNode.h" -#include "arm_compute/graph2/nodes/FullyConnectedLayerNode.h" -#include "arm_compute/graph2/nodes/InputNode.h" -#include "arm_compute/graph2/nodes/NormalizationLayerNode.h" -#include "arm_compute/graph2/nodes/OutputNode.h" -#include "arm_compute/graph2/nodes/PoolingLayerNode.h" -#include "arm_compute/graph2/nodes/ReshapeLayerNode.h" -#include "arm_compute/graph2/nodes/SoftmaxLayerNode.h" -#include "arm_compute/graph2/nodes/SplitLayerNode.h" - -#endif /* __ARM_COMPUTE_GRAPH2_NODES_H__ */ diff --git a/arm_compute/graph2/nodes/NodesFwd.h b/arm_compute/graph2/nodes/NodesFwd.h deleted file mode 100644 index 08f2454cde..0000000000 --- a/arm_compute/graph2/nodes/NodesFwd.h +++ /dev/null @@ -1,51 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_NODES_FWD_H__ -#define __ARM_COMPUTE_GRAPH2_NODES_FWD_H__ - -namespace arm_compute -{ -namespace graph2 -{ -// Forward declarations -class INode; -class ActivationLayerNode; -class BatchNormalizationLayerNode; -class ConstNode; -class ConvolutionLayerNode; -class DepthConcatenateLayerNode; -class DepthwiseConvolutionLayerNode; -class EltwiseLayerNode; -class FlattenLayerNode; -class FullyConnectedLayerNode; -class InputNode; -class NormalizationLayerNode; -class OutputNode; -class PoolingLayerNode; -class ReshapeLayerNode; -class SoftmaxLayerNode; -class SplitLayerNode; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_NODES_FWD_H__ */ diff --git a/arm_compute/graph2/nodes/NormalizationLayerNode.h b/arm_compute/graph2/nodes/NormalizationLayerNode.h deleted file mode 100644 index 78a843a1e7..0000000000 --- a/arm_compute/graph2/nodes/NormalizationLayerNode.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_NORMALIZATION_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_NORMALIZATION_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Normalization Layer node */ -class NormalizationLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] norm_info Normalization Layer information - */ - NormalizationLayerNode(NormalizationLayerInfo norm_info); - /** Normalization info accessor - * - * @return Normalization layer info - */ - NormalizationLayerInfo normalization_info() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - NormalizationLayerInfo _info; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_NORMALIZATION_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/OutputNode.h b/arm_compute/graph2/nodes/OutputNode.h deleted file mode 100644 index 0c28c84214..0000000000 --- a/arm_compute/graph2/nodes/OutputNode.h +++ /dev/null @@ -1,49 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_OUTPUT_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_OUTPUT_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Output Layer node */ -class OutputNode final : public INode -{ -public: - /** Default Constructor */ - OutputNode(); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_OUTPUT_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/PoolingLayerNode.h b/arm_compute/graph2/nodes/PoolingLayerNode.h deleted file mode 100644 index 09332a9367..0000000000 --- a/arm_compute/graph2/nodes/PoolingLayerNode.h +++ /dev/null @@ -1,68 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_POOLING_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_POOLING_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Pooling Layer node */ -class PoolingLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] pool_info Pooling Layer information - */ - PoolingLayerNode(PoolingLayerInfo pool_info); - /** Pooling metadata accessor - * - * @return Pooling Layer info - */ - PoolingLayerInfo pooling_info() const; - /** Computes pooling output shape - * - * @param[in] input_shape Input shape - * @param[in] info Pooling operation attributes - * - * @return Output shape - */ - static TensorShape compute_output_shape(TensorShape input_shape, PoolingLayerInfo info); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - PoolingLayerInfo _info; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_POOLING_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/ReshapeLayerNode.h b/arm_compute/graph2/nodes/ReshapeLayerNode.h deleted file mode 100644 index 27d52601da..0000000000 --- a/arm_compute/graph2/nodes/ReshapeLayerNode.h +++ /dev/null @@ -1,55 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_RESHAPE_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_RESHAPE_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Reshape Layer node */ -class ReshapeLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] shape Reshaped tensor shape - */ - ReshapeLayerNode(TensorShape shape); - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - TensorShape _shape; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_RESHAPE_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/SoftmaxLayerNode.h b/arm_compute/graph2/nodes/SoftmaxLayerNode.h deleted file mode 100644 index b1091e28fc..0000000000 --- a/arm_compute/graph2/nodes/SoftmaxLayerNode.h +++ /dev/null @@ -1,60 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_SOFTMAX_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_SOFTMAX_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -namespace arm_compute -{ -namespace graph2 -{ -/** Softmax Layer node */ -class SoftmaxLayerNode final : public INode -{ -public: - /** Constructor - * - * @param[in] beta (Optional) Beta parameter. Defaults to 1 - */ - SoftmaxLayerNode(float beta = 1.f); - /** Beta parameter accessor - * - * @return Beta parameter - */ - float beta() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - float _beta; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_SOFTMAX_LAYER_NODE_H__ */ diff --git a/arm_compute/graph2/nodes/SplitLayerNode.h b/arm_compute/graph2/nodes/SplitLayerNode.h deleted file mode 100644 index 90e6134ac0..0000000000 --- a/arm_compute/graph2/nodes/SplitLayerNode.h +++ /dev/null @@ -1,79 +0,0 @@ -/* - * Copyright (c) 2018 ARM Limited. - * - * SPDX-License-Identifier: MIT - * - * Permission is hereby granted, free of charge, to any person obtaining a copy - * of this software and associated documentation files (the "Software"), to - * deal in the Software without restriction, including without limitation the - * rights to use, copy, modify, merge, publish, distribute, sublicense, and/or - * sell copies of the Software, and to permit persons to whom the Software is - * furnished to do so, subject to the following conditions: - * - * The above copyright notice and this permission notice shall be included in all - * copies or substantial portions of the Software. - * - * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR - * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, - * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE - * AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER - * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, - * OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE - * SOFTWARE. - */ -#ifndef __ARM_COMPUTE_GRAPH2_SPLIT_LAYER_NODE_H__ -#define __ARM_COMPUTE_GRAPH2_SPLIT_LAYER_NODE_H__ - -#include "arm_compute/graph2/INode.h" - -#include - -namespace arm_compute -{ -namespace graph2 -{ -/** Split Layer node */ -class SplitLayerNode final : public INode -{ -public: - /** Default Constructor - * - * @param[in] num_splits Number of splits - * @param[in] axis (Optional) Axis to split on. Supported axis >= 2. Defaults to 0 - */ - SplitLayerNode(unsigned int num_splits, unsigned int axis = 0); - /** Computes split layer output shape - * - * @param[in] input_shape Shape of the input - * @param[in] num_splits Number of splits - * @param[in] axis Axis to perform the split on - * @param[in] idx Index of the split - * - * @return A pair with the shape of the split and the starting coordinates - */ - static std::pair compute_output_shape(TensorShape input_shape, unsigned int num_splits, unsigned int axis, unsigned int idx); - /** Number of splits accessor - * - * @return Number of splits - */ - unsigned int num_splits() const; - /** Split axis accessor - * - * @return Split axis - */ - unsigned int axis() const; - - // Inherited overridden methods: - Status validate() override; - NodeType type() const override; - bool forward_descriptors() override; - TensorDescriptor configure_output(size_t idx) const override; - void accept(INodeVisitor &v) override; - -private: - unsigned int _num_splits; - unsigned int _axis; -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_SPLIT_LAYER_NODE_H__ */ -- cgit v1.2.1