Remove constraint of Tensor<>::CopyAsType()

This commit is contained in:
Po-Yen, Chen
2022-08-19 05:31:04 -04:00
parent c34f8411c4
commit 51d0c6794c

View File

@@ -254,7 +254,7 @@ struct Tensor
Tensor(const HostTensorDescriptor& desc) : mDesc(desc), mData(mDesc.GetElementSpaceSize()) {}
template <typename OutT>
std::enable_if_t<std::is_convertible_v<T, OutT>, Tensor<OutT>> CopyAsType() const
Tensor<OutT> CopyAsType() const
{
Tensor<OutT> ret(mDesc);
for(size_t i = 0; i < mData.size(); i++)