Use canonical CPU device name in TensorHandle::Resolve.

PiperOrigin-RevId: 305124817
Change-Id: I2e51fa917503d4deab90ed57b1407f77a89c280f
This commit is contained in:
Cesar Crusius 2020-04-06 14:58:59 -07:00 committed by TensorFlower Gardener
parent 444d8d7cf4
commit 2f0ac02d72

View File

@ -41,7 +41,7 @@ AbstractTensorInterface* TensorHandle::Resolve(Status* status) {
auto* custom_device = absl::get<CustomDevice*>(device());
TensorHandle* copy;
*status = custom_device->CopyTensorFromDevice(
this, "/job:localhost/task:0/replica:0/device:CPU:0", &copy);
this, "/job:localhost/replica:0/task:0/device:CPU:0", &copy);
if (status->ok()) {
return copy->Resolve(status);
} else {