lazy import attn backends (#4200)

This commit is contained in:
Lianmin Zheng
2025-03-08 00:41:35 -08:00
committed by GitHub
parent 96d0e37fa7
commit 08c4d764a5
4 changed files with 21 additions and 11 deletions

View File

@@ -302,7 +302,7 @@ class CudaGraphRunner:
self.stream = graph_capture_context.stream
# Reverse the order to enable better memory sharing across cuda graphs.
capture_range = (
tqdm.tqdm(reversed(self.capture_bs))
tqdm.tqdm(list(reversed(self.capture_bs)))
if get_tensor_model_parallel_rank() == 0
else reversed(self.capture_bs)
)