diff options
author | Anthony Barbier <anthony.barbier@arm.com> | 2017-10-23 18:55:17 +0100 |
---|---|---|
committer | Anthony Barbier <anthony.barbier@arm.com> | 2017-10-23 18:58:11 +0100 |
commit | 8a3da6f91f90c566b844d568f4ec43b946915af8 (patch) | |
tree | d8265ab6b77cdabaa856b623fc8c1ade64867c03 /arm_compute | |
parent | 2aab3165ae3104c8f3018157b62d4febdc94f2b7 (diff) | |
download | armcl-8a3da6f91f90c566b844d568f4ec43b946915af8.tar.gz armcl-8a3da6f91f90c566b844d568f4ec43b946915af8.tar.bz2 armcl-8a3da6f91f90c566b844d568f4ec43b946915af8.zip |
Update AlexNet example with accessors
Diffstat (limited to 'arm_compute')
-rw-r--r-- | arm_compute/graph/Tensor.h | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/arm_compute/graph/Tensor.h b/arm_compute/graph/Tensor.h index 9fdd56db6..dbe2ba595 100644 --- a/arm_compute/graph/Tensor.h +++ b/arm_compute/graph/Tensor.h @@ -67,6 +67,16 @@ public: * @param[in] accessor Tensor accessor */ template <typename AccessorType> + Tensor(TensorInfo &&info, std::unique_ptr<AccessorType> &&accessor) + : _target(TargetHint::DONT_CARE), _info(info), _accessor(std::move(accessor)), _tensor(nullptr) + { + } + /** Constructor + * + * @param[in] info Tensor info to use + * @param[in] accessor Tensor accessor + */ + template <typename AccessorType> Tensor(TensorInfo &&info, AccessorType &&accessor) : _target(TargetHint::DONT_CARE), _info(info), _accessor(arm_compute::support::cpp14::make_unique<AccessorType>(std::forward<AccessorType>(accessor))), _tensor(nullptr) { |