[TPU] Deprecate xm.mark_step in favor of `torch_xla.sync (#25254)
Signed-off-by: NickLucche <nlucches@redhat.com> Co-authored-by: Ye (Charlotte) Qi <yeq@meta.com>
This commit is contained in:
@@ -6,6 +6,7 @@ Run `pytest tests/kernels/moe/test_moe_pallas.py`.
|
||||
"""
|
||||
import pytest
|
||||
import torch
|
||||
import torch_xla
|
||||
|
||||
# yapf conflicts with isort for this block
|
||||
# yapf: disable
|
||||
@@ -77,7 +78,7 @@ def test_pallas_moe(
|
||||
expert_map=e_map,
|
||||
renormalize=False,
|
||||
)
|
||||
xm.mark_step()
|
||||
torch_xla.sync(wait=False)
|
||||
|
||||
# Compare outputs
|
||||
torch.testing.assert_close(
|
||||
|
||||
Reference in New Issue
Block a user