Skip to content

Commit 32ec4c8

Browse files
committed
Rename the skip-warm-up constant so Bandit B105 passes
Bandit's B105 read SKIP_WARMUP_PASS_ENV as a password name. The environment variable stays TLLM_CUDA_GRAPH_SKIP_WARMUP_PASS. Signed-off-by: ziyixiong-nv <219238287+ziyixiong-nv@users.noreply.github.com>
1 parent 5820bc6 commit 32ec4c8

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

  • tensorrt_llm/_torch/pyexecutor/engine/runners/decoder

‎tensorrt_llm/_torch/pyexecutor/engine/runners/decoder/graphs.py‎

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,7 @@
6565
_BREAK_GRAPH_NUM_CONTEXTS = (1, 2)
6666

6767
# "1": the final executor captures its graphs in one pass when every rank can keep them.
68-
SKIP_WARMUP_PASS_ENV = "TLLM_CUDA_GRAPH_SKIP_WARMUP_PASS"
68+
SKIP_WARMUP_CAPTURE_ENV = "TLLM_CUDA_GRAPH_SKIP_WARMUP_PASS"
6969

7070

7171
def _make_single_token_context_graph_batch(
@@ -379,7 +379,7 @@ def _capture_in_one_pass(self, resource_manager: ResourceManager) -> bool:
379379
if not self.cuda_graph_runner.enabled:
380380
return False
381381
# Every rank joins, so a rank without the switch keeps all ranks on two passes.
382-
wanted = os.environ.get(SKIP_WARMUP_PASS_ENV, "0") == "1"
382+
wanted = os.environ.get(SKIP_WARMUP_CAPTURE_ENV, "0") == "1"
383383
if not self._agreement.agree_flag(wanted and self._single_pass_supported()):
384384
return False
385385
self._captured_tensor_ptrs = []

0 commit comments

Comments
 (0)