Deepity
Ultra-fast, SIMD-accelerated Predictive Coding
Loading...
Searching...
No Matches
backend Directory Reference

Files

 
Backend.h
 
CPUBackend.h
 
CUDABackend.h
 
DeviceType.h
 
IComputeBackend.h
 
Tensor.h
 A device-aware, RAII-managed buffer. Device is fixed at construction – there is no support for moving a live Tensor between CPU and GPU after creation. Loading weights saved on CPU and running them on GPU doesn't need that: read the saved file into a plain std::vector on the host, then construct a DEVICE_GPU Tensor directly from that vector (see the host-data constructors below) – the one-time host-to-device copy happens inside the constructor, and the temporary host vector falls out of scope immediately after. The Tensor itself is a GPU object from the moment it's born.