Skip to content

Commit

Permalink
fix error in test_zero_context
Browse files Browse the repository at this point in the history
  • Loading branch information
delock committed Mar 12, 2024
1 parent f4fe02b commit 88567b3
Showing 1 changed file with 3 additions and 0 deletions.
3 changes: 3 additions & 0 deletions tests/unit/runtime/zero/test_zero_context.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
from types import SimpleNamespace

import torch
import pytest
import deepspeed
from deepspeed.runtime.zero.partition_parameters import ZeroParamStatus, partitioned_param_data_shape
import deepspeed.comm as dist
Expand Down Expand Up @@ -126,6 +127,8 @@ def test_scattered_init_dist(self):
assert dist.is_initialized()

def test_scatter_halftype(self):
if not get_accelerator().is_fp16_supported():
pytest.skip("fp16 is not supported")
setup_serial_env()

with deepspeed.zero.Init():
Expand Down

0 comments on commit 88567b3

Please sign in to comment.