Add the 8-gpu Inkling consistency test (#34009)
This commit is contained in:
@@ -2,6 +2,7 @@ import unittest
|
||||
|
||||
from sglang.srt.environ import envs
|
||||
from sglang.test.accuracy_test_runner import AccuracyTestParams
|
||||
from sglang.test.cache_consistency_jitter import get_jitter_engine, run_jitter_test
|
||||
from sglang.test.ci.ci_register import register_cuda_ci
|
||||
from sglang.test.performance_test_runner import PerformanceTestParams
|
||||
from sglang.test.run_combined_tests import run_combined_tests
|
||||
@@ -12,6 +13,7 @@ from sglang.test.test_utils import ModelLaunchSettings, is_blackwell_system
|
||||
register_cuda_ci(est_time=3600, suite="nightly-8-gpu-common", nightly=True)
|
||||
|
||||
INKLING_NVFP4_MODEL = "thinkingmachines/Inkling-NVFP4"
|
||||
INKLING_SMALL_NVFP4_MODEL = "thinkingmachines/Inkling-Small-NVFP4"
|
||||
|
||||
# Verified Blackwell NVFP4 recipe; see the SGLang cookbook Inkling page.
|
||||
NVFP4_ARGS = [
|
||||
@@ -75,5 +77,35 @@ class TestInklingNVFP4Nightly(unittest.TestCase):
|
||||
)
|
||||
|
||||
|
||||
class TestInklingSmallCacheConsistencyNightly(unittest.TestCase):
|
||||
"""Bitwise version of the per-commit check in
|
||||
``test/registered/models_e2e/test_inkling.py``, on the real checkpoint and
|
||||
at a batch shape the tiny checkpoint never reaches."""
|
||||
|
||||
@unittest.skipIf(not is_blackwell_system(), "NVFP4 requires Blackwell")
|
||||
def test_scored_contexts_are_bitwise_identical(self):
|
||||
with envs.SGLANG_ENABLE_UNIFIED_RADIX_TREE.override(1):
|
||||
with get_jitter_engine(
|
||||
model_path=INKLING_SMALL_NVFP4_MODEL,
|
||||
tp_size=8,
|
||||
trust_remote_code=True,
|
||||
quantization="modelopt_fp4",
|
||||
attention_backend="fa4",
|
||||
page_size=128,
|
||||
fp4_gemm_runner_backend="flashinfer_trtllm",
|
||||
moe_runner_backend="flashinfer_trtllm_routed",
|
||||
enable_torch_symm_mem=True,
|
||||
mamba_radix_cache_strategy="extra_buffer",
|
||||
swa_full_tokens_ratio=0.1,
|
||||
mamba_full_memory_ratio=0.1,
|
||||
mem_fraction_static=0.6,
|
||||
enable_deterministic_inference=True,
|
||||
# The harness pins a tight pool; this checkpoint needs room for
|
||||
# the 2048-4096 token prefixes the default workload draws.
|
||||
max_total_tokens=131_072,
|
||||
) as engine:
|
||||
run_jitter_test(engine)
|
||||
|
||||
|
||||
if __name__ == "__main__":
|
||||
unittest.main()
|
||||
|
||||
Reference in New Issue
Block a user