Skip to content

Commit

Permalink
fix
Browse files Browse the repository at this point in the history
  • Loading branch information
dakinggg committed Apr 12, 2024
1 parent 8981209 commit 4fe928c
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion tests/models/layers/test_dmoe.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,8 @@
from torch.distributed.tensor.parallel.ddp import _pre_dp_module_transform
from torch.nn.parallel import DistributedDataParallel as DDP

from composer.utils import dist as cdist

from llmfoundry.models.layers.dmoe import dMoE
from llmfoundry.models.layers.ffn import dtensorify_param
from llmfoundry.models.mpt.configuration_mpt import MPTConfig
Expand Down Expand Up @@ -192,7 +194,7 @@ def test_dmoe(moe_num_experts: int, mlp_type: str, moe_world_size: int,
# TODO(GRT-2435): Change to fixture
def delete_transformers_cache():
# Only delete the files on local rank 0, otherwise race conditions are created
if not dist.get_local_rank() == 0:
if not cdist.get_local_rank() == 0:
return

hf_cache_home = os.path.expanduser(
Expand Down

0 comments on commit 4fe928c

Please sign in to comment.