|
21 | 21 | import requests |
22 | 22 | from PIL import Image, ImageDraw, ImageFont |
23 | 23 |
|
| 24 | +from sglang.multimodal_gen.runtime.platforms import current_platform |
24 | 25 | from sglang.multimodal_gen.runtime.utils.common import get_bool_env_var |
25 | 26 | from sglang.multimodal_gen.runtime.utils.logging_utils import init_logger |
26 | 27 | from sglang.multimodal_gen.runtime.utils.perf_logger import ( |
|
34 | 35 | logger = init_logger(__name__) |
35 | 36 |
|
36 | 37 | SGL_TEST_FILES_CI_DATA_REVISION = "caa56302ccf2d289e4488ed06d952edf5d2314cf" |
| 38 | + |
| 39 | +if current_platform.is_npu(): |
| 40 | + SGL_TEST_FILES_CI_DATA_REVISION = "670d66a8a290b62c0c3c077b3e9b0f4a4d9a44e7" |
| 41 | + |
37 | 42 | SGL_TEST_FILES_CONSISTENCY_GT_ROOT = ( |
38 | 43 | "https://raw.githubusercontent.com/" |
39 | 44 | f"sgl-project/ci-data/{SGL_TEST_FILES_CI_DATA_REVISION}/" |
|
51 | 56 | SGL_TEST_FILES_SGLANG_CONSISTENCY_GT_BASE_ASCEND = ( |
52 | 57 | f"{SGL_TEST_FILES_CONSISTENCY_GT_ROOT}/sglang_generated/ascend" |
53 | 58 | ) |
| 59 | + |
54 | 60 | SGL_TEST_FILES_CONSISTENCY_GT_BASE = SGL_TEST_FILES_SGLANG_CONSISTENCY_GT_BASE |
| 61 | + |
| 62 | +if current_platform.is_npu(): |
| 63 | + SGL_TEST_FILES_CONSISTENCY_GT_BASE = ( |
| 64 | + SGL_TEST_FILES_SGLANG_CONSISTENCY_GT_BASE_ASCEND |
| 65 | + ) |
| 66 | + |
55 | 67 | SGL_TEST_FILES_CONSISTENCY_GT_BASES = ( |
56 | 68 | SGL_TEST_FILES_OFFICIAL_CONSISTENCY_GT_BASE, |
57 | 69 | SGL_TEST_FILES_SGLANG_CONSISTENCY_GT_BASE, |
@@ -1018,7 +1030,7 @@ def _find_remote_consistency_gt_files( |
1018 | 1030 | bases = SGL_TEST_FILES_CONSISTENCY_GT_BASES |
1019 | 1031 | else: |
1020 | 1032 | # Avoid accidentally comparing non-comparable CI cases against official GT. |
1021 | | - bases = (SGL_TEST_FILES_SGLANG_CONSISTENCY_GT_BASE,) |
| 1033 | + bases = (SGL_TEST_FILES_CONSISTENCY_GT_BASE,) |
1022 | 1034 | for base_url in bases: |
1023 | 1035 | candidates = _remote_consistency_gt_candidates( |
1024 | 1036 | base_url, case_id, num_gpus, is_video, output_format |
|
0 commit comments