Skip to content

Commit 463b7eb

Browse files
authored
Tone down the amount of logging when downloading cubins (#1477)
The level of verbosity when downloading cubins is on the high-side (3 messages for each file). It also reports a "Failed to load ..." which confuses some users into thinking that something went wrong.
1 parent e0aa4e7 commit 463b7eb

File tree

1 file changed

+3
-4
lines changed

1 file changed

+3
-4
lines changed

flashinfer/jit/cubin_loader.py

Lines changed: 3 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -114,7 +114,7 @@ def load_cubin(cubin_path, sha256) -> bytes:
114114
115115
Return None on failure.
116116
"""
117-
logger.info(f"Loading from {cubin_path}")
117+
logger.debug(f"Loading from {cubin_path}")
118118
try:
119119
with open(cubin_path, mode="rb") as f:
120120
cubin = f.read()
@@ -128,9 +128,8 @@ def load_cubin(cubin_path, sha256) -> bytes:
128128
logger.warning(
129129
f"sha256 mismatch (expected {sha256} actual {actual_sha}) for {cubin_path}"
130130
)
131-
except Exception as e:
132-
print(f"Failed to load cubin at {cubin_path} with sha256={sha256}: {e}")
133-
logger.info(f"Failed loading {cubin_path}")
131+
except Exception:
132+
pass
134133
return b""
135134

136135

0 commit comments

Comments
 (0)