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
b532a5fd
Unverified
Commit
b532a5fd
authored
Dec 16, 2024
by
xiaobochen
Committed by
GitHub
Dec 16, 2024
Browse files
fix moe-ep accuracy issue for fp8 (#2489)
parent
a0592c05
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
0 deletions
+4
-0
python/sglang/srt/layers/ep_moe/layer.py
python/sglang/srt/layers/ep_moe/layer.py
+4
-0
No files found.
python/sglang/srt/layers/ep_moe/layer.py
View file @
b532a5fd
...
@@ -644,6 +644,10 @@ class Fp8EPMoEMethod(Fp8MoEMethod):
...
@@ -644,6 +644,10 @@ class Fp8EPMoEMethod(Fp8MoEMethod):
"QuantConfig has static quantization, but found "
"QuantConfig has static quantization, but found "
"activation scales are None."
"activation scales are None."
)
)
layer
.
w13_weight_scale
=
torch
.
nn
.
Parameter
(
torch
.
max
(
layer
.
w13_weight_scale
,
dim
=
1
).
values
,
requires_grad
=
False
,
)
return
return
def
apply
(
def
apply
(
...
...
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