Skip to content

Commit

Permalink
remove xla_device call
Browse files Browse the repository at this point in the history
  • Loading branch information
lezwon committed Jun 7, 2020
1 parent a9114f8 commit ca33af1
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions tests/models/test_tpu.py
Original file line number Diff line number Diff line change
Expand Up @@ -8,8 +8,7 @@

try:
import torch_xla
device = torch_xla.core.xla_model.xla_device()
device_type = torch_xla.core.xla_model.xla_device_hw(device)
device_type = torch_xla.core.xla_model.xla_device_hw('xla:1')
TPU_AVAILABLE = device_type == 'TPU'
except ImportError:
TPU_AVAILABLE = False
Expand Down

0 comments on commit ca33af1

Please sign in to comment.