Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Replace
using_pjrt()
xla runtime device_type()
check with in xla.…
…py for `torch-xla>=2.5` (#20442) * Replace `using_pjrt()` xla runtime `device_type()` check with in xla.py Fixes #20419 `torch_xla.runtime.using_pjrt()` is removed in pytorch/xla#7787 This PR replaces references to that function with a check to [`device_type()`](https://github.com/pytorch/xla/blob/master/torch_xla/runtime.py#L83) to recreate the behavior of that function, minus the manual initialization * Added tests/refactored for version compat * [pre-commit.ci] auto fixes from pre-commit.com hooks for more information, see https://pre-commit.ci * precommit --------- Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
- Loading branch information