Definition at line 578 of file OnnxParser.cpp.
582 ARMNN_ASSERT_MSG(bufferPtr !=
nullptr, fmt::format(
"Buffer for permutation is null").c_str());
586 if (permutationVector.
has_value() && permutationVector.
value().GetSize() > 0)
590 reinterpret_cast<const T*
>(bufferPtr), data.get(),
sizeof(T));
594 ::memcpy(data.get(), bufferPtr, tensorInfo.
GetNumBytes());
597 return std::make_pair(
ConstTensor(tensorInfo, data.get()), std::move(data));
References ARMNN_ASSERT_MSG, TensorInfo::GetNumBytes(), TensorInfo::GetNumElements(), TensorInfo::GetShape(), PermutationVector::GetSize(), OptionalBase::has_value(), armnnUtils::Permute(), armnnUtils::Permuted(), and OptionalReferenceSwitch< std::is_reference< T >::value, T >::value().