MCPcopy
hub / github.com/InternLM/lmdeploy / cancel

Method cancel

lmdeploy/pytorch/engine/engine_loop.py:596–601  ·  view source on GitHub ↗

Cancel all loops.

(self)

Source from the content-addressed store, hash-verified

594 self.cancel()
595
596 def cancel(self):
597 """Cancel all loops."""
598 for task in self.tasks:
599 if not task.done():
600 task.cancel()
601 self.tasks.clear()
602
603
604def build_engine_loop(engine: 'Engine'):

Callers 15

stopMethod · 0.95
_cancel_all_tasksMethod · 0.45
async_cancelMethod · 0.45
async_stream_inferMethod · 0.45
stopMethod · 0.45
lifespan_handlerFunction · 0.45
stop_metrics_handlerMethod · 0.45
wait_for_async_tasksFunction · 0.45
cancel_async_tasksFunction · 0.45
wait_tasksMethod · 0.45
stop_loopMethod · 0.45
closeMethod · 0.45

Calls 2

doneMethod · 0.80
clearMethod · 0.45