diff --git a/tests/unit/runtime/rollout/test_hybrid_engine_rollout.py b/tests/unit/runtime/rollout/test_hybrid_engine_rollout.py index 046ab8189f2b..c557dbbc2857 100644 --- a/tests/unit/runtime/rollout/test_hybrid_engine_rollout.py +++ b/tests/unit/runtime/rollout/test_hybrid_engine_rollout.py @@ -1218,7 +1218,7 @@ def test(self): from transformers import Qwen2Config, Qwen2ForCausalLM rank = dist.get_rank() - device = torch.device(f"cuda:{rank}") + device = torch.device(get_accelerator().current_device_name()) model = Qwen2ForCausalLM( Qwen2Config( vocab_size=32,