Tiny adjust CI testcases (#14362)

This commit is contained in:
Liangsheng Yin
2025-12-03 21:19:51 +08:00
committed by GitHub
parent 443d7bcd83
commit 24903b88ba
+12 -8
View File
@@ -36,7 +36,7 @@ class TestDeepseekV3FP4(CustomTestCase):
"--kv-cache-dtype", "--kv-cache-dtype",
"fp8_e4m3", "fp8_e4m3",
"--model-loader-extra-config", "--model-loader-extra-config",
'{"enable_multithread_load": true}', '{"enable_multithread_load": true,"num_threads": 64}',
] ]
cls.process = popen_launch_server( cls.process = popen_launch_server(
cls.model, cls.model,
@@ -68,7 +68,8 @@ class TestDeepseekV3FP4(CustomTestCase):
write_github_step_summary( write_github_step_summary(
f"### test_gsm8k (deepseek-v3-fp4)\n" f'{metrics["accuracy"]=:.3f}\n' f"### test_gsm8k (deepseek-v3-fp4)\n" f'{metrics["accuracy"]=:.3f}\n'
) )
self.assertGreater(metrics["accuracy"], 0.935)
self.assertGreater(metrics["accuracy"], 0.935)
def test_bs_1_speed(self): def test_bs_1_speed(self):
args = BenchArgs(port=int(self.base_url.split(":")[-1]), max_new_tokens=2048) args = BenchArgs(port=int(self.base_url.split(":")[-1]), max_new_tokens=2048)
@@ -80,7 +81,8 @@ class TestDeepseekV3FP4(CustomTestCase):
write_github_step_summary( write_github_step_summary(
f"### test_bs_1_speed (deepseek-v3-fp4)\n" f"{speed=:.2f} token/s\n" f"### test_bs_1_speed (deepseek-v3-fp4)\n" f"{speed=:.2f} token/s\n"
) )
self.assertGreater(speed, 75)
self.assertGreater(speed, 75)
class TestDeepseekV3FP4MTP(CustomTestCase): class TestDeepseekV3FP4MTP(CustomTestCase):
@@ -109,7 +111,7 @@ class TestDeepseekV3FP4MTP(CustomTestCase):
"--kv-cache-dtype", "--kv-cache-dtype",
"fp8_e4m3", "fp8_e4m3",
"--model-loader-extra-config", "--model-loader-extra-config",
'{"enable_multithread_load": true}', '{"enable_multithread_load": true,"num_threads": 64}',
] ]
cls.process = popen_launch_server( cls.process = popen_launch_server(
cls.model, cls.model,
@@ -153,8 +155,9 @@ class TestDeepseekV3FP4MTP(CustomTestCase):
f'{metrics["accuracy"]=:.3f}\n' f'{metrics["accuracy"]=:.3f}\n'
f"{avg_spec_accept_length=:.2f}\n" f"{avg_spec_accept_length=:.2f}\n"
) )
self.assertGreater(metrics["accuracy"], 0.94)
self.assertGreater(avg_spec_accept_length, 2.04) self.assertGreater(metrics["accuracy"], 0.94)
self.assertGreater(avg_spec_accept_length, 2.04)
def test_bs_1_speed(self): def test_bs_1_speed(self):
args = BenchArgs(port=int(self.base_url.split(":")[-1]), max_new_tokens=2048) args = BenchArgs(port=int(self.base_url.split(":")[-1]), max_new_tokens=2048)
@@ -168,8 +171,9 @@ class TestDeepseekV3FP4MTP(CustomTestCase):
f"{acc_length=:.2f}\n" f"{acc_length=:.2f}\n"
f"{speed=:.2f} token/s\n" f"{speed=:.2f} token/s\n"
) )
self.assertGreater(acc_length, 2.04)
self.assertGreater(speed, 150) self.assertGreater(acc_length, 2.04)
self.assertGreater(speed, 150)
if __name__ == "__main__": if __name__ == "__main__":