Skip to content
Snippets Groups Projects

New proposal for handling tensor views

Merged Olivier BICHLER requested to merge view into dev
Files
3
@@ -16,7 +16,8 @@
namespace Aidge {
inline void *getCPUPtr(std::shared_ptr<Aidge::Data> const &data) {
return std::static_pointer_cast<Tensor>(data)->getImpl()->rawPtr();
const auto tensor = std::static_pointer_cast<Tensor>(data);
return tensor->getImpl()->hostPtr(tensor->getImplOffset());
}
} // namespace Aidge
Loading