A method to management or optimize the number of devices and streams (GPUs) and threads (CPU) used based on user specifications and hardware configuration. The method should use a generic device abstraction to allow for multiple types of devices and new devices that may become available in the future.
Details
hardware resources can either be defined by the user or identified at run time
maximum number of threads and streams are tracked by the manager class
memory and host to device transfers are tracked by the DeviceManager
device type is abstracted
node and weight resources are managed by the associated device
HardwareManager Objectives
[ ] Track control flow devices and arithmetic devices
[ ] Discover or assign available hardware resources including num of CPUs/GPUs, number of streams, memory capacity
DeviceManager Objectives
[ ] abstract the device type
[ ] initialize the device
[ ] track memory on the device
[ ] manage streams on the device
[ ] copy host to device and device to host
Other changes
[x] template for DeviceType in IntegrationFunction, LossFunction, and solver
[ ] initNodes and initWeights copies tensors to device
[ ] initModelError, initWeightMatrices, initNodeMatrices copies tensor to device
[ ] syncNodes and syncWeights copies tensors to host
Description
A method to management or optimize the number of devices and streams (GPUs) and threads (CPU) used based on user specifications and hardware configuration. The method should use a generic device abstraction to allow for multiple types of devices and new devices that may become available in the future.
Details
HardwareManager Objectives
DeviceManager Objectives
Other changes