Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 9 additions & 0 deletions tests/integration/defs/examples/test_eagle.py
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,15 @@ def test_with_dummy_eagle(hf_model_root,
print("Build engines...")
model_name = "eagle"

# We unset WORLD_SIZE while running tests in specific cluster nodes to
# deal with a bug in transformers library. Trainer initialization in
# get_dummy_spec_decoding_heads() function fails if WORLD_SIZE is unset.
# Preemptively skip tests if WORLD_SIZE is unset.
if os.environ.get("WORLD_SIZE") is None:
pytest.skip(
"[test_with_dummy_eagle] Skipping test due to missing WORLD_SIZE env variable."
)

print("Creating dummy Eagle heads...")
get_dummy_spec_decoding_heads(hf_model_dir=hf_model_root,
save_dir=llm_venv.get_working_directory(),
Expand Down
10 changes: 10 additions & 0 deletions tests/integration/defs/examples/test_medusa.py
Original file line number Diff line number Diff line change
Expand Up @@ -201,6 +201,16 @@ def test_llm_medusa_fp8_modelOpt_ckpt_1gpu(batch_size, medusa_model_roots,
def test_with_dummy_medusa(hf_model_root, medusa_example_root, llm_venv,
cmodel_dir, engine_dir, batch_size, data_type,
num_medusa_heads, use_py_session, model_type):

# We unset WORLD_SIZE while running tests in specific cluster nodes to
# deal with a bug in transformers library. Trainer initialization in
# get_dummy_spec_decoding_heads() function fails if WORLD_SIZE is unset.
# Preemptively skip tests if WORLD_SIZE is unset.
if os.environ.get("WORLD_SIZE") is None:
pytest.skip(
"[test_with_dummy_medusa] Skipping test due to missing WORLD_SIZE env variable."
)

print("Creating dummy Medusa heads...")
get_dummy_spec_decoding_heads(hf_model_dir=hf_model_root,
save_dir=llm_venv.get_working_directory(),
Expand Down