Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
OpenDAS
vllm_cscc
Commits
57973bcc
Commit
57973bcc
authored
Apr 10, 2026
by
zhangzbb
Browse files
[feature]编译之前不再做强制的的包版本检查,避免后续频繁改动setup中的指定版本号
parent
489b7626
Changes
3
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
1253 additions
and
65 deletions
+1253
-65
1
1
+1249
-0
requirements/hygon.text
requirements/hygon.text
+4
-2
setup.py
setup.py
+0
-63
No files found.
1
0 → 100644
View file @
57973bcc
This diff is collapsed.
Click to expand it.
requirements/hygon.text
View file @
57973bcc
...
@@ -8,7 +8,8 @@
...
@@ -8,7 +8,8 @@
# Pin numpy to 1.26.x: compatible with both custom torch ABI and
# Pin numpy to 1.26.x: compatible with both custom torch ABI and
# modern PyPI packages (pandas, opencv, etc.)
# modern PyPI packages (pandas, opencv, etc.)
numpy == 1.26.4
#numpy == 1.26.4
# numpy == 1.26.4 Pinning a specific version of this package will cause dependency conflicts with VLLM, making it impossible to install.
# Replace heavy extras dependency chains with the explicit versions
# Replace heavy extras dependency chains with the explicit versions
# already validated in the Hygon Docker image.
# already validated in the Hygon Docker image.
...
@@ -41,7 +42,8 @@ fastrlock==0.8.3
...
@@ -41,7 +42,8 @@ fastrlock==0.8.3
torch == 2.9.0
torch == 2.9.0
triton == 3.3.0
triton == 3.3.0
flash_attn == 2.6.1
flash_attn == 2.6.1
flash_mla == 1.2.0
#flash_mla == 1.2.0
flash_mla == 1.0.0
lightop == 0.6.0
lightop == 0.6.0
lmslim == 0.3.1
lmslim == 0.3.1
setup.py
View file @
57973bcc
...
@@ -1060,68 +1060,6 @@ def _dedupe_requirements(requirements: list[str]) -> list[str]:
...
@@ -1060,68 +1060,6 @@ def _dedupe_requirements(requirements: list[str]) -> list[str]:
return
list
(
seen
.
values
())
return
list
(
seen
.
values
())
def
_validate_hygon_build_env
()
->
None
:
"""Fail fast with actionable errors for the Hygon build env."""
import
importlib.metadata
exact_versions
=
{
"numpy"
:
"1.26.4"
,
}
das_versions
=
{
"torch"
:
"2.9.0"
,
"triton"
:
"3.3.0"
,
"flash_attn"
:
"2.6.1"
,
"flash_mla"
:
"1.2.0"
,
"lightop"
:
"0.6.0"
,
"lmslim"
:
"0.3.1"
,
}
errors
:
list
[
str
]
=
[]
for
pkg_name
,
expected_version
in
exact_versions
.
items
():
try
:
installed_ver
=
importlib
.
metadata
.
version
(
pkg_name
)
except
importlib
.
metadata
.
PackageNotFoundError
:
errors
.
append
(
f
"- Missing required package `
{
pkg_name
}
`. Expected "
f
"`
{
expected_version
}
`."
)
continue
if
installed_ver
!=
expected_version
:
errors
.
append
(
f
"- `
{
pkg_name
}
` version mismatch: expected "
f
"`
{
expected_version
}
`, got `
{
installed_ver
}
`."
)
for
pkg_name
,
expected_base
in
das_versions
.
items
():
try
:
installed_ver
=
importlib
.
metadata
.
version
(
pkg_name
)
except
importlib
.
metadata
.
PackageNotFoundError
:
errors
.
append
(
f
"- Missing required package `
{
pkg_name
}
`. Expected a "
f
"Hygon build based on `
{
expected_base
}
`."
)
continue
if
not
installed_ver
.
startswith
(
expected_base
):
errors
.
append
(
f
"- `
{
pkg_name
}
` version mismatch: expected base "
f
"`
{
expected_base
}
`, got `
{
installed_ver
}
`."
)
if
"+das"
not
in
installed_ver
:
errors
.
append
(
f
"- `
{
pkg_name
}
` is not a Hygon custom build: "
f
"`
{
installed_ver
}
`."
)
if
errors
:
joined
=
"
\n
"
.
join
(
errors
)
raise
RuntimeError
(
"Hygon build environment validation failed.
\n
"
"Please fix the following packages before running "
"`VLLM_USE_HYGON=1 python setup.py bdist_wheel`:
\n
"
f
"
{
joined
}
"
)
def
_rewrite_hygon_requirements
(
requirements
:
list
[
str
])
->
list
[
str
]:
def
_rewrite_hygon_requirements
(
requirements
:
list
[
str
])
->
list
[
str
]:
"""Replace heavy extras chains with explicit Hygon-validated packages."""
"""Replace heavy extras chains with explicit Hygon-validated packages."""
...
@@ -1174,7 +1112,6 @@ def get_requirements() -> list[str]:
...
@@ -1174,7 +1112,6 @@ def get_requirements() -> list[str]:
requirements
=
modified_requirements
requirements
=
modified_requirements
elif
_is_hip
():
elif
_is_hip
():
if
os
.
environ
.
get
(
"VLLM_USE_HYGON"
,
""
).
strip
().
lower
()
in
(
"1"
,
"true"
):
if
os
.
environ
.
get
(
"VLLM_USE_HYGON"
,
""
).
strip
().
lower
()
in
(
"1"
,
"true"
):
_validate_hygon_build_env
()
requirements
=
_read_requirements
(
"hygon.txt"
)
requirements
=
_read_requirements
(
"hygon.txt"
)
requirements
=
_rewrite_hygon_requirements
(
requirements
)
requirements
=
_rewrite_hygon_requirements
(
requirements
)
requirements
=
_dedupe_requirements
(
requirements
)
requirements
=
_dedupe_requirements
(
requirements
)
...
...
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