diff options
Diffstat (limited to 'tensorflow/cc/tutorials/example_trainer.cc')
-rw-r--r-- | tensorflow/cc/tutorials/example_trainer.cc | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tensorflow/cc/tutorials/example_trainer.cc b/tensorflow/cc/tutorials/example_trainer.cc index 49d3cca3a4..3675d72ee3 100644 --- a/tensorflow/cc/tutorials/example_trainer.cc +++ b/tensorflow/cc/tutorials/example_trainer.cc @@ -101,7 +101,7 @@ void ConcurrentSteps(const Options* opts, int session_index) { std::unique_ptr<Session> session(NewSession(options)); GraphDef def = CreateGraphDef(); if (options.target.empty()) { - graph::SetDefaultDevice(opts->use_gpu ? "/gpu:0" : "/cpu:0", &def); + graph::SetDefaultDevice(opts->use_gpu ? "/device:GPU:0" : "/cpu:0", &def); } TF_CHECK_OK(session->Create(def)); |