Store the tensor's metadata */
| 43 | { |
| 44 | /** Store the tensor's metadata */ |
| 45 | class TensorInfo final : public ITensorInfo |
| 46 | { |
| 47 | public: |
| 48 | /** Default constructor */ |
| 49 | TensorInfo(); |
| 50 | /** Default destructor */ |
| 51 | ~TensorInfo() = default; |
| 52 | /** Allow instances of this class to be copy constructed */ |
| 53 | TensorInfo(const ITensorInfo &info); |
| 54 | /** Allow instances of this class to be copy constructed */ |
| 55 | TensorInfo(const TensorInfo &); |
| 56 | /** Allow instances of this class to be copied */ |
| 57 | TensorInfo &operator=(const TensorInfo &) = default; |
| 58 | /** Allow instances of this class to be move constructed */ |
| 59 | TensorInfo(TensorInfo &&) = default; |
| 60 | /** Allow instances of this class to be moved */ |
| 61 | TensorInfo &operator=(TensorInfo &&) = default; |
| 62 | |
| 63 | /** Construct a tensor info with a format. |
| 64 | * |
| 65 | * Can be used for automatic derivation of the shape by the function. |
| 66 | * |
| 67 | * @param[in] format Format of the tensor. |
| 68 | */ |
| 69 | TensorInfo(Format format); |
| 70 | |
| 71 | /** 2D tensor constructor |
| 72 | * |
| 73 | * @param[in] width Width of the 2D tensor |
| 74 | * @param[in] height Height of the 2D tensor |
| 75 | * @param[in] format Single plane format of the tensor. |
| 76 | */ |
| 77 | TensorInfo(unsigned int width, unsigned int height, Format format); |
| 78 | /** Constructor |
| 79 | * |
| 80 | * @param[in] tensor_shape It specifies the size for each dimension of the tensor in number of elements. |
| 81 | * @param[in] format Single plane format of the tensor. |
| 82 | */ |
| 83 | TensorInfo(const TensorShape &tensor_shape, Format format); |
| 84 | |
| 85 | /** Construct a tensor info with a data type and number of channels. |
| 86 | * |
| 87 | * Can be used for automatic derivation of the shape by the function. |
| 88 | * |
| 89 | * @param[in] num_channels It indicates the number of channels for each tensor element |
| 90 | * @param[in] data_type Data type to use for each tensor element |
| 91 | */ |
| 92 | TensorInfo(size_t num_channels, DataType data_type); |
| 93 | |
| 94 | /** Constructor |
| 95 | * |
| 96 | * @param[in] tensor_shape It specifies the size for each dimension of the tensor in number of elements. |
| 97 | * @param[in] num_channels It indicates the number of channels for each tensor element |
| 98 | * @param[in] data_type Data type to use for each tensor element |
| 99 | */ |
| 100 | TensorInfo(const TensorShape &tensor_shape, size_t num_channels, DataType data_type); |
| 101 | |
| 102 | /** Constructor |
no test coverage detected