Run samples cleanly on GPU with one line addition
See original GitHub issue@gbaydin I’m just wondering what your expectation/desire is here for the programming model
I’m looking at the VAE.fsx sample and trying to run it on GPU. Is the intent that I do this by setting GPU as the default device?
dsharp.config(backend=Backend.Torch, device=Device.GPU)
or is it expected to instruct things via model.move(Device.GPU)
? In which case how do we specify the move of the data and related tensors to the GPU?
When I make the GPU the default then “Saving samples” takes a very long time. Adding this helps:
samples.move(Device.CPU).saveImage(sprintf "samples_%A_%A.png" epoch i)
We should probably always move to the CPU before doing things like saveImage
Issue Analytics
- State:
- Created 3 years ago
- Comments:13 (7 by maintainers)
Top Results From Across the Web
How to set specific gpu in tensorflow?
You can do this in python by having a line os.environ["CUDA_VISIBLE_DEVICES"]="0,1" after importing os package. Using with tf.device('/gpu ...
Read more >Could a GPU alone run a complete system? : r/hardware
If what you're looking for is a single piece of hardware that can "morph" cleanly between GPU and CPU, I think that that...
Read more >MLOps for Batch Processing: Running Airflow on GPUs
From there, the external containers will execute their code on the target GPUs as a single-run script. This requires an external container with ......
Read more >Multi-GPU TensorFlow on Saturn Cloud
We'll train a model serially, on one GPU, and then walk through exactly how ... neatly separated out training, test, and validation samples....
Read more >Vector Processing on CPUs and GPUs Compared
Modern CPUs and GPUs can all process a lot of data in parallel so what exactly makes them different? This question is getting...
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I’m hopeful but it’s not certain. I’m slowly working through these issues, trying to understand what’s going on with the native library loading and package delivery. There are lots of quirky issues here.
I’m closing this as addressed.