Reputation: 151
TensorFlow recently introduced tf.contrib.data.prefetch_to_device() which enables pre-fetching to GPU memory but it isn't quite clear how to implement pre-fetching on systems with multiple GPUs. Does each GPU need it's own pipeline with a chunk of the dataset?
Upvotes: 2
Views: 666
Reputation: 63
It appears to me, its capabilities are currently limited to prefetching to one device only. Reason being that I've never seen a tf.device specification for more than one device and I highly doubt you can use a job (distributed TensorFlow) as an argument.
Prefetching to one GPU, though more than one GPU would like to access the Tensor yielded by the Dataset, could still bring performance gains, as multi-GPU-systems usually feature memory sharing over PCIe.
Upvotes: 2