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/Types.h | 171 --------------------------------------------- 1 file changed, 171 deletions(-) delete mode 100644 arm_compute/graph2/Types.h (limited to 'arm_compute/graph2/Types.h') diff --git a/arm_compute/graph2/Types.h b/arm_compute/graph2/Types.h deleted file mode 100644 index 2625657393..0000000000 --- a/arm_compute/graph2/Types.h +++ /dev/null @@ -1,171 +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_TYPES_H__ -#define __ARM_COMPUTE_GRAPH2_TYPES_H__ - -#include "arm_compute/core/Error.h" -#include "arm_compute/core/Types.h" -#include "arm_compute/core/utils/strong_type/StrongType.h" -#include "arm_compute/core/utils/strong_type/StrongTypeAttributes.h" - -#include -#include - -namespace arm_compute -{ -namespace graph2 -{ -using arm_compute::Status; - -using arm_compute::Coordinates; -using arm_compute::DataType; -using arm_compute::TensorShape; -using arm_compute::Size2D; - -using arm_compute::ActivationLayerInfo; -using arm_compute::NormType; -using arm_compute::NormalizationLayerInfo; -using arm_compute::PadStrideInfo; -using arm_compute::PoolingLayerInfo; -using arm_compute::PoolingType; -using arm_compute::DimensionRoundingType; - -/** TODO (geopin01): Make ids strongly typed */ -using TensorID = unsigned int; -using NodeID = unsigned int; -using EdgeID = unsigned int; -using Activation = arm_compute::ActivationLayerInfo::ActivationFunction; - -/**< GraphID strong type */ -using GraphID = strong_type::StrongType; -/* TODO (geopin01): Strong types for NodeID */ - -/**< Constant TensorID specifying an equivalent of null tensor */ -constexpr TensorID NullTensorID = std::numeric_limits::max(); -/**< Constant NodeID specifying an equivalent of null node */ -constexpr NodeID EmptyNodeID = std::numeric_limits::max(); -/**< Constant EdgeID specifying an equivalent of null edge */ -constexpr EdgeID EmptyEdgeID = std::numeric_limits::max(); - -// Forward declarations -class TensorDescriptor; - -/** Graph configuration structure */ -struct GraphConfig -{ - bool use_function_memory_manager{ false }; /**< Use a memory manager to manage per-funcion auxilary memory */ - bool use_transition_memory_manager{ false }; /**< Use a memory manager to manager transition buffer memory */ - bool use_tuner{ false }; /**< Use a tuner in tunable backends */ - unsigned int num_threads{ 0 }; /**< Number of threads to use (thread capable backends), if 0 the backend will auto-initialize */ -}; - -/**< Data layout format */ -enum class DataLayout -{ - NCHW, /** N(Batches), C(Channels), H(Height), W(Width) from slow to fast moving dimension */ - NHWC /** N(Batches), H(Height), W(Width), C(Channels) from slow to fast moving dimension */ -}; - -/**< Device target types */ -enum class Target -{ - UNSPECIFIED, /**< Unspecified Target */ - NEON, /**< NEON capable target device */ - CL, /**< OpenCL capable target device */ - GC, /**< GLES compute capable target device */ -}; - -/** Supported Element-wise operations */ -enum class EltwiseOperation -{ - ADD, /**< Arithmetic addition */ - SUB, /**< Arithmetic subtraction */ - MUL /**< Arithmetic multiplication */ -}; - -/** Supported Convolution layer methods */ -enum class ConvolutionMethod -{ - DEFAULT, /**< Default approach using internal heuristics */ - GEMM, /**< GEMM based convolution */ - DIRECT, /**< Deep direct convolution */ - WINOGRAD /**< Winograd based convolution */ -}; - -/** Supported Depthwise Convolution layer methods */ -enum class DepthwiseConvolutionMethod -{ - DEFAULT, /**< Default approach using internal heuristics */ - GEMV, /**< Generic GEMV based depthwise convolution */ - OPTIMIZED_3x3, /**< Optimized 3x3 direct depthwise convolution */ -}; - -/** Supported nodes */ -enum class NodeType -{ - ActivationLayer, - BatchNormalizationLayer, - ConvolutionLayer, - DepthConcatenateLayer, - DepthwiseConvolutionLayer, - EltwiseLayer, - FlattenLayer, - FullyConnectedLayer, - NormalizationLayer, - PoolingLayer, - ReshapeLayer, - SoftmaxLayer, - SplitLayer, - - Input, - Output, - Const, -}; - -/** Backend Memory Manager affinity **/ -enum class MemoryManagerAffinity -{ - Buffer, /**< Affinity at buffer level */ - Offset /**< Affinity at offset level */ -}; - -/** NodeID-index struct - * - * Used to describe connections - */ -struct NodeIdxPair -{ - NodeID node_id; /**< Node ID */ - size_t index; /**< Index */ -}; - -/** Common node parameters */ -struct NodeParams -{ - std::string name; /**< Node name */ - Target target; /**< Node target */ -}; -} // namespace graph2 -} // namespace arm_compute -#endif /* __ARM_COMPUTE_GRAPH2_TYPES_H__ */ -- cgit v1.2.1