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
5e1e0a0f
Unverified
Commit
5e1e0a0f
authored
Feb 04, 2026
by
Wentao Ye
Committed by
GitHub
Feb 03, 2026
Browse files
[Refactor] Remove unused dead code (#33718)
Signed-off-by:
yewentao256
<
zhyanwentao@126.com
>
parent
eb5ed207
Changes
3
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
0 additions
and
77 deletions
+0
-77
vllm/collect_env.py
vllm/collect_env.py
+0
-8
vllm/compilation/fx_utils.py
vllm/compilation/fx_utils.py
+0
-15
vllm/config/utils.py
vllm/config/utils.py
+0
-54
No files found.
vllm/collect_env.py
View file @
5e1e0a0f
...
@@ -146,14 +146,6 @@ def run_and_parse_first_match(run_lambda, command, regex):
...
@@ -146,14 +146,6 @@ def run_and_parse_first_match(run_lambda, command, regex):
return
match
.
group
(
1
)
return
match
.
group
(
1
)
def
run_and_return_first_line
(
run_lambda
,
command
):
"""Run command using run_lambda and returns first line if output is not empty."""
rc
,
out
,
_
=
run_lambda
(
command
)
if
rc
!=
0
:
return
None
return
out
.
split
(
"
\n
"
)[
0
]
def
get_conda_packages
(
run_lambda
,
patterns
=
None
):
def
get_conda_packages
(
run_lambda
,
patterns
=
None
):
if
patterns
is
None
:
if
patterns
is
None
:
patterns
=
DEFAULT_CONDA_PATTERNS
patterns
=
DEFAULT_CONDA_PATTERNS
...
...
vllm/compilation/fx_utils.py
View file @
5e1e0a0f
...
@@ -18,21 +18,6 @@ def is_auto_func(node: fx.Node, op: OpOverload) -> bool:
...
@@ -18,21 +18,6 @@ def is_auto_func(node: fx.Node, op: OpOverload) -> bool:
return
is_func
(
node
,
auto_functionalized
)
and
node
.
args
[
0
]
==
op
return
is_func
(
node
,
auto_functionalized
)
and
node
.
args
[
0
]
==
op
# Returns the first specified node with the given op (if it exists)
def
find_specified_fn_maybe
(
nodes
:
Iterable
[
fx
.
Node
],
op
:
OpOverload
)
->
fx
.
Node
|
None
:
for
node
in
nodes
:
if
node
.
target
==
op
:
return
node
return
None
# Returns the first specified node with the given op
def
find_specified_fn
(
nodes
:
Iterable
[
fx
.
Node
],
op
:
OpOverload
)
->
fx
.
Node
:
node
=
find_specified_fn_maybe
(
nodes
,
op
)
assert
node
is
not
None
,
f
"Could not find
{
op
}
in nodes
{
nodes
}
"
return
node
# Returns the first auto_functionalized node with the given op (if it exists)
# Returns the first auto_functionalized node with the given op (if it exists)
def
find_auto_fn_maybe
(
nodes
:
Iterable
[
fx
.
Node
],
op
:
OpOverload
)
->
fx
.
Node
|
None
:
def
find_auto_fn_maybe
(
nodes
:
Iterable
[
fx
.
Node
],
op
:
OpOverload
)
->
fx
.
Node
|
None
:
for
node
in
nodes
:
for
node
in
nodes
:
...
...
vllm/config/utils.py
View file @
5e1e0a0f
...
@@ -14,7 +14,6 @@ from dataclasses import MISSING, Field, field, fields, is_dataclass
...
@@ -14,7 +14,6 @@ from dataclasses import MISSING, Field, field, fields, is_dataclass
from
itertools
import
pairwise
from
itertools
import
pairwise
from
typing
import
TYPE_CHECKING
,
Any
,
Protocol
,
TypeVar
,
cast
from
typing
import
TYPE_CHECKING
,
Any
,
Protocol
,
TypeVar
,
cast
import
regex
as
re
import
torch
import
torch
from
pydantic
import
ConfigDict
from
pydantic
import
ConfigDict
from
pydantic.dataclasses
import
dataclass
from
pydantic.dataclasses
import
dataclass
...
@@ -144,34 +143,6 @@ def getattr_iter(
...
@@ -144,34 +143,6 @@ def getattr_iter(
return
default_factory
()
if
default_factory
is
not
None
else
default
return
default_factory
()
if
default_factory
is
not
None
else
default
def
contains_object_print
(
text
:
str
)
->
bool
:
"""
Check if the text looks like a printed Python object, e.g.
contains any substring matching the pattern: "at 0xFFFFFFF>"
We match against 0x followed by 2-16 hex chars (there's
a max of 16 on a 64-bit system).
Args:
text (str): The text to check
Returns:
result (bool): `True` if a match is found, `False` otherwise.
"""
pattern
=
r
"at 0x[a-fA-F0-9]{2,16}>"
match
=
re
.
search
(
pattern
,
text
)
return
match
is
not
None
def
assert_hashable
(
text
:
str
)
->
bool
:
if
not
contains_object_print
(
text
):
return
True
raise
AssertionError
(
f
"vLLM tried to hash some configs that may have Python objects ids "
f
"in them. This is a bug, please file an issue. "
f
"Text being hashed:
{
text
}
"
)
def
get_attr_docs
(
cls
:
type
[
Any
])
->
dict
[
str
,
str
]:
def
get_attr_docs
(
cls
:
type
[
Any
])
->
dict
[
str
,
str
]:
"""
"""
Get any docstrings placed after attribute assignments in a class body.
Get any docstrings placed after attribute assignments in a class body.
...
@@ -354,31 +325,6 @@ def hash_factors(items: dict[str, object]) -> str:
...
@@ -354,31 +325,6 @@ def hash_factors(items: dict[str, object]) -> str:
return
hashlib
.
sha256
(
json
.
dumps
(
items
,
sort_keys
=
True
).
encode
()).
hexdigest
()
return
hashlib
.
sha256
(
json
.
dumps
(
items
,
sort_keys
=
True
).
encode
()).
hexdigest
()
def
handle_deprecated
(
config
:
ConfigT
,
old_name
:
str
,
new_name_or_names
:
str
|
list
[
str
],
removal_version
:
str
,
)
->
None
:
old_val
=
getattr
(
config
,
old_name
)
if
old_val
is
None
:
return
if
isinstance
(
new_name_or_names
,
str
):
new_names
=
[
new_name_or_names
]
else
:
new_names
=
new_name_or_names
msg
=
(
f
"
{
old_name
}
is deprecated and will be removed in
{
removal_version
}
. "
f
"Use
{
', '
.
join
(
new_names
)
}
instead."
)
logger
.
warning
(
msg
)
for
new_name
in
new_names
:
setattr
(
config
,
new_name
,
old_val
)
@
dataclass
@
dataclass
class
Range
:
class
Range
:
"""
"""
...
...
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