title: Tensorflow, restore variables in a specific device
body: <p>Maybe my question is a bit naive, but I really didn't find anything in the tensorflow documentation.</p>
  
  <p>I have a trained tensorflow model where the variables of it was placed in the GPU. Now I would like to restore this model and test it using the CPU.</p>
  
  <p>If I do this via 'tf.train.Saver.restore` as in the example:
  <code>
   saver = tf.train.import_meta_graph("/tmp/graph.meta")
   saver.restore(session, "/tmp/model.ckp")
  </code></p>
  
  <p>I have the following excpetion:</p>
  
  <p><code>
  InvalidArgumentError: Cannot assign a device to node 'b_fc8/b_fc8/Adam_1': Could not satisfy explicit device specification '/device:GPU:0' because no devices matching that specification are registered in this process; available devices: /job:localhost/replica:0/task:0/cpu:0
  </code></p>
  
  <p>How can I make restore these variables in the <code>CPU</code>?</p>
  
  <p>Thanks</p>