11
$\begingroup$

I'v trained a deep network (e.g. LeNet) using NetTrain with TargetDevice -> "GPU". Everything works well and it is really fast. But now I have a trained network and tens of thousands of samples to classify. The GPU based training was evaluating ~ 1200 samples/second but seems like I can only use CPU based ParallelMap to evaluate trained network with samples (i.e. slow).

Is there a way to apply the trained network using the GPU as target device?

$\endgroup$
4
  • $\begingroup$ Not yet, but I hear gpu inference is coming in 11.1 $\endgroup$
    – M.R.
    Oct 7, 2016 at 16:14
  • 3
    $\begingroup$ Yes, we're trying to get it into 11.1, and will be available by writing net[input, TargetDevice -> "GPU"] instead of net[input]. $\endgroup$ Oct 9, 2016 at 10:33
  • $\begingroup$ I cannot test the GPU at the moment, as I'm having issues with TargetDevice->"GPU" on my Quadro K2100M (compute capability 3.0, latest drivers) for some reason, but would love to know if this was added, as I was hoping to use it. It shouldn't be that difficult in theory, as this is done every single time a loss is computed for training data as well as for validation data. $\endgroup$ Apr 3, 2017 at 23:35
  • $\begingroup$ Nevermind, just confirmed! It works in 11.1. trained[data,TargetDevice->"GPU"] $\endgroup$ Apr 5, 2017 at 5:54

1 Answer 1

9
$\begingroup$

Works in 11.1.

trained[data,TargetDevice->"GPU"]
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.