mirror of
https://git.datalinker.icu/vllm-project/vllm.git
synced 2026-03-16 11:47:09 +08:00
fix mypy
Signed-off-by: yewentao256 <zhyanwentao@126.com>
This commit is contained in:
parent
8244ff7fee
commit
60ae003033
@ -649,7 +649,7 @@ class AsyncLLM(EngineClient):
|
|||||||
return self.tokenizer
|
return self.tokenizer
|
||||||
|
|
||||||
async def is_tracing_enabled(self) -> bool:
|
async def is_tracing_enabled(self) -> bool:
|
||||||
return self.observability_config.otlp_traces_endpoint is not None
|
return self.observability_config.otlp_traces_endpoint is not None # type: ignore
|
||||||
|
|
||||||
async def do_log_stats(self) -> None:
|
async def do_log_stats(self) -> None:
|
||||||
if self.logger_manager:
|
if self.logger_manager:
|
||||||
|
|||||||
@ -287,7 +287,7 @@ class LLMEngine:
|
|||||||
# Add the request to EngineCore.
|
# Add the request to EngineCore.
|
||||||
self.engine_core.add_request(child_request)
|
self.engine_core.add_request(child_request)
|
||||||
|
|
||||||
def step(self) -> list[RequestOutput] | list[PoolingRequestOutput]:
|
def step(self) -> list[RequestOutput | PoolingRequestOutput]:
|
||||||
if self.should_execute_dummy_batch:
|
if self.should_execute_dummy_batch:
|
||||||
self.should_execute_dummy_batch = False
|
self.should_execute_dummy_batch = False
|
||||||
self.engine_core.execute_dummy_batch()
|
self.engine_core.execute_dummy_batch()
|
||||||
@ -318,14 +318,7 @@ class LLMEngine:
|
|||||||
)
|
)
|
||||||
self.do_log_stats_with_interval()
|
self.do_log_stats_with_interval()
|
||||||
|
|
||||||
ro = processed_outputs.request_outputs
|
return processed_outputs.request_outputs
|
||||||
if not ro:
|
|
||||||
return []
|
|
||||||
first = ro[0]
|
|
||||||
if isinstance(first, RequestOutput):
|
|
||||||
return [x for x in ro if isinstance(x, RequestOutput)]
|
|
||||||
else:
|
|
||||||
return [x for x in ro if isinstance(x, PoolingRequestOutput)]
|
|
||||||
|
|
||||||
def start_profile(self):
|
def start_profile(self):
|
||||||
self.engine_core.profile(True)
|
self.engine_core.profile(True)
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user