Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
change
sglang
Commits
9179ea15
"...ffmpeg/git@developer.sourcefind.cn:OpenDAS/torchaudio.git" did not exist on "0b6ca28db00833714e3909d1931eace5500b6422"
Unverified
Commit
9179ea15
authored
Jun 19, 2025
by
Chunyuan WU
Committed by
GitHub
Jun 18, 2025
Browse files
add seed in CPU UTs to avoid flaky failure (#7333)
parent
20a503c7
Changes
10
Hide whitespace changes
Inline
Side-by-side
Showing
10 changed files
with
20 additions
and
0 deletions
+20
-0
test/srt/cpu/test_activation.py
test/srt/cpu/test_activation.py
+2
-0
test/srt/cpu/test_decode.py
test/srt/cpu/test_decode.py
+2
-0
test/srt/cpu/test_extend.py
test/srt/cpu/test_extend.py
+2
-0
test/srt/cpu/test_gemm.py
test/srt/cpu/test_gemm.py
+2
-0
test/srt/cpu/test_mla.py
test/srt/cpu/test_mla.py
+2
-0
test/srt/cpu/test_moe.py
test/srt/cpu/test_moe.py
+2
-0
test/srt/cpu/test_norm.py
test/srt/cpu/test_norm.py
+2
-0
test/srt/cpu/test_rope.py
test/srt/cpu/test_rope.py
+2
-0
test/srt/cpu/test_shared_expert.py
test/srt/cpu/test_shared_expert.py
+2
-0
test/srt/cpu/test_topk.py
test/srt/cpu/test_topk.py
+2
-0
No files found.
test/srt/cpu/test_activation.py
View file @
9179ea15
...
@@ -8,6 +8,8 @@ from utils import SiluAndMul, precision
...
@@ -8,6 +8,8 @@ from utils import SiluAndMul, precision
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestActivation
(
CustomTestCase
):
class
TestActivation
(
CustomTestCase
):
M
=
[
128
,
129
,
257
]
M
=
[
128
,
129
,
257
]
...
...
test/srt/cpu/test_decode.py
View file @
9179ea15
...
@@ -6,6 +6,8 @@ from torch.nn.functional import scaled_dot_product_attention
...
@@ -6,6 +6,8 @@ from torch.nn.functional import scaled_dot_product_attention
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestDecodeAttention
(
CustomTestCase
):
class
TestDecodeAttention
(
CustomTestCase
):
def
_run_sdpa_forward_decode
(
def
_run_sdpa_forward_decode
(
...
...
test/srt/cpu/test_extend.py
View file @
9179ea15
...
@@ -6,6 +6,8 @@ from torch.nn.functional import scaled_dot_product_attention
...
@@ -6,6 +6,8 @@ from torch.nn.functional import scaled_dot_product_attention
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestExtendAttention
(
CustomTestCase
):
class
TestExtendAttention
(
CustomTestCase
):
...
...
test/srt/cpu/test_gemm.py
View file @
9179ea15
...
@@ -14,6 +14,8 @@ from utils import (
...
@@ -14,6 +14,8 @@ from utils import (
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
Mod
(
nn
.
Module
):
class
Mod
(
nn
.
Module
):
def
__init__
(
self
,
input_channel
,
output_channel
,
has_bias
):
def
__init__
(
self
,
input_channel
,
output_channel
,
has_bias
):
...
...
test/srt/cpu/test_mla.py
View file @
9179ea15
...
@@ -8,6 +8,8 @@ from utils import precision
...
@@ -8,6 +8,8 @@ from utils import precision
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestMLA
(
CustomTestCase
):
class
TestMLA
(
CustomTestCase
):
def
_run_sdpa_forward_decode
(
def
_run_sdpa_forward_decode
(
...
...
test/srt/cpu/test_moe.py
View file @
9179ea15
...
@@ -8,6 +8,8 @@ import torch
...
@@ -8,6 +8,8 @@ import torch
kernel
=
torch
.
ops
.
sgl_kernel
kernel
=
torch
.
ops
.
sgl_kernel
torch
.
manual_seed
(
0
)
from
utils
import
(
from
utils
import
(
BLOCK_K
,
BLOCK_K
,
BLOCK_N
,
BLOCK_N
,
...
...
test/srt/cpu/test_norm.py
View file @
9179ea15
...
@@ -8,6 +8,8 @@ from utils import make_non_contiguous, precision
...
@@ -8,6 +8,8 @@ from utils import make_non_contiguous, precision
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestNorm
(
CustomTestCase
):
class
TestNorm
(
CustomTestCase
):
M
=
[
4096
,
1024
]
M
=
[
4096
,
1024
]
...
...
test/srt/cpu/test_rope.py
View file @
9179ea15
...
@@ -10,6 +10,8 @@ from sglang.srt.layers.rotary_embedding import (
...
@@ -10,6 +10,8 @@ from sglang.srt.layers.rotary_embedding import (
)
)
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestROPE
(
CustomTestCase
):
class
TestROPE
(
CustomTestCase
):
def
test_deepseek_v2_rope
(
self
):
def
test_deepseek_v2_rope
(
self
):
...
...
test/srt/cpu/test_shared_expert.py
View file @
9179ea15
...
@@ -22,6 +22,8 @@ from utils import (
...
@@ -22,6 +22,8 @@ from utils import (
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
class
TestSharedExpert
(
CustomTestCase
):
class
TestSharedExpert
(
CustomTestCase
):
M
=
[
2
,
121
]
M
=
[
2
,
121
]
...
...
test/srt/cpu/test_topk.py
View file @
9179ea15
...
@@ -13,6 +13,8 @@ from sglang.srt.layers.moe.topk import grouped_topk_gpu as native_grouped_topk
...
@@ -13,6 +13,8 @@ from sglang.srt.layers.moe.topk import grouped_topk_gpu as native_grouped_topk
from
sglang.srt.models.llama4
import
Llama4MoE
from
sglang.srt.models.llama4
import
Llama4MoE
from
sglang.test.test_utils
import
CustomTestCase
from
sglang.test.test_utils
import
CustomTestCase
torch
.
manual_seed
(
0
)
# This is used by the Deepseek-V2 model
# This is used by the Deepseek-V2 model
class
TestGroupedTopK
(
CustomTestCase
):
class
TestGroupedTopK
(
CustomTestCase
):
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment