Clean up server startup log noise (#26205)
This commit is contained in:
@@ -1450,15 +1450,15 @@ def _get_and_verify_dtype(
|
||||
if torch_dtype != config_dtype:
|
||||
if torch_dtype == torch.float32:
|
||||
# Upcasting to float32 is allowed.
|
||||
logger.info("Upcasting %s to %s.", config_dtype, torch_dtype)
|
||||
logger.debug("Upcasting %s to %s.", config_dtype, torch_dtype)
|
||||
pass
|
||||
elif config_dtype == torch.float32:
|
||||
# Downcasting from float32 to float16 or bfloat16 is allowed.
|
||||
logger.info("Downcasting %s to %s.", config_dtype, torch_dtype)
|
||||
logger.debug("Downcasting %s to %s.", config_dtype, torch_dtype)
|
||||
pass
|
||||
else:
|
||||
# Casting between float16 and bfloat16 is allowed with a warning.
|
||||
logger.warning("Casting %s to %s.", config_dtype, torch_dtype)
|
||||
logger.debug("Casting %s to %s.", config_dtype, torch_dtype)
|
||||
|
||||
return torch_dtype
|
||||
|
||||
|
||||
@@ -243,12 +243,10 @@ class FlashInferAttnBackend(AttentionBackend):
|
||||
|
||||
fmha_backend = "auto"
|
||||
if is_sm100_supported():
|
||||
# Disable CUTLASS backend when piecewise cuda graph is enabled
|
||||
# due to TMA descriptor initialization issues on B200
|
||||
if not model_runner.server_args.disable_piecewise_cuda_graph:
|
||||
logger.warning(
|
||||
logger.info(
|
||||
"CUTLASS backend is disabled when piecewise cuda graph is enabled "
|
||||
"due to TMA descriptor initialization issues on B200. "
|
||||
"due to TMA descriptor initialization issues on SM100 GPUs. "
|
||||
"Using auto backend instead for stability."
|
||||
)
|
||||
else:
|
||||
|
||||
@@ -334,12 +334,6 @@ def match_rules(
|
||||
for rule in rules:
|
||||
try:
|
||||
if rule.predicate(ctx):
|
||||
logger.info(
|
||||
"Detected %s '%s' from template rule '%s'.",
|
||||
label,
|
||||
rule.value,
|
||||
rule.name,
|
||||
)
|
||||
return rule.value
|
||||
except Exception as e:
|
||||
logger.warning(
|
||||
@@ -367,11 +361,6 @@ def detect_reasoning_pattern(
|
||||
)
|
||||
for rule in REASONING_MODE_RULES:
|
||||
if rule.predicate(ctx):
|
||||
logger.info(
|
||||
"Detected reasoning config '%s' from template rule '%s'.",
|
||||
rule.value,
|
||||
rule.name,
|
||||
)
|
||||
return rule.value.always_on, rule.value
|
||||
|
||||
return False, None
|
||||
|
||||
@@ -173,14 +173,15 @@ class TemplateManager:
|
||||
if tokenizer_manager.tokenizer:
|
||||
template = tokenizer_manager.tokenizer.chat_template
|
||||
self._run_template_detection(template, tokenizer_manager.tokenizer)
|
||||
parts = []
|
||||
if self._reasoning_config:
|
||||
parts.append(f"reasoning_config={self._reasoning_config}")
|
||||
if self._suggested_reasoning_parser:
|
||||
logger.info(
|
||||
f"Auto-detected reasoning parser: {self._suggested_reasoning_parser}"
|
||||
)
|
||||
parts.append(f"reasoning_parser={self._suggested_reasoning_parser}")
|
||||
if self._suggested_tool_call_parser:
|
||||
logger.info(
|
||||
f"Auto-detected tool-call parser: {self._suggested_tool_call_parser}"
|
||||
)
|
||||
parts.append(f"tool_call_parser={self._suggested_tool_call_parser}")
|
||||
if parts:
|
||||
logger.info(f"Auto-detected template features: {', '.join(parts)}")
|
||||
|
||||
def _load_explicit_chat_template(
|
||||
self, tokenizer_manager: TokenizerManager, chat_template_arg: str
|
||||
|
||||
@@ -738,13 +738,13 @@ class KVCache(abc.ABC):
|
||||
k_size_GB = k_size / GB
|
||||
v_size_GB = v_size / GB
|
||||
logger.info(
|
||||
f"KV Cache is allocated. #tokens: {num_tokens}, K size: {k_size_GB:.2f} GB, V size: {v_size_GB:.2f} GB"
|
||||
f"KV Cache is allocated. dtype: {self.dtype}, #tokens: {num_tokens}, K size: {k_size_GB:.2f} GB, V size: {v_size_GB:.2f} GB"
|
||||
)
|
||||
self.mem_usage = k_size_GB + v_size_GB
|
||||
else:
|
||||
kv_size_GB = kv_size_bytes / GB
|
||||
logger.info(
|
||||
f"KV Cache is allocated. #tokens: {num_tokens}, KV size: {kv_size_GB:.2f} GB"
|
||||
f"KV Cache is allocated. dtype: {self.dtype}, #tokens: {num_tokens}, KV size: {kv_size_GB:.2f} GB"
|
||||
)
|
||||
self.mem_usage = kv_size_GB
|
||||
|
||||
|
||||
@@ -2214,8 +2214,6 @@ class ModelRunner(ModelRunnerKVCacheMixin):
|
||||
f"Unsupported kv_cache_dtype: {self.server_args.kv_cache_dtype}."
|
||||
)
|
||||
|
||||
log_info_on_rank0(logger, f"Using KV cache dtype: {self.kv_cache_dtype}")
|
||||
|
||||
def init_cublas(self):
|
||||
"""We need to run a small matmul to init cublas. Otherwise, it will raise some errors later."""
|
||||
dtype = torch.float16
|
||||
|
||||
@@ -219,7 +219,7 @@ class GptOssSparseMoeBlock(nn.Module):
|
||||
bias=True,
|
||||
quant_config=None,
|
||||
prefix=add_prefix("gate", prefix),
|
||||
params_dtype=config.torch_dtype,
|
||||
params_dtype=config.dtype,
|
||||
)
|
||||
|
||||
def forward(
|
||||
@@ -468,7 +468,7 @@ class GptOssDecoderLayer(nn.Module):
|
||||
prefix=add_prefix("self_attn", prefix),
|
||||
sliding_window_size=self.sliding_window_size,
|
||||
layer_type=config.layer_types[layer_id],
|
||||
params_dtype=config.torch_dtype,
|
||||
params_dtype=config.dtype,
|
||||
)
|
||||
|
||||
self.layer_id = layer_id
|
||||
|
||||
@@ -105,7 +105,7 @@ def _load_tokenizer_by_declared_class(tokenizer_name, *args, **kwargs):
|
||||
if tok_cls is None:
|
||||
return None
|
||||
|
||||
logger.info(
|
||||
logger.debug(
|
||||
"Loading tokenizer for %s directly as %s (bypassing AutoTokenizer)",
|
||||
tokenizer_name,
|
||||
tok_class_name,
|
||||
@@ -208,7 +208,7 @@ def _resolve_tokenizers_backend(tokenizer_name, *args, **common_kwargs):
|
||||
``tokenizer_config.json``. May still return a ``TokenizersBackend``
|
||||
if all retries fail (with a warning).
|
||||
"""
|
||||
logger.warning(
|
||||
logger.debug(
|
||||
"Tokenizer loaded as generic TokenizersBackend for %s, "
|
||||
"retrying with use_fast=False",
|
||||
tokenizer_name,
|
||||
@@ -239,7 +239,7 @@ def _resolve_tokenizers_backend(tokenizer_name, *args, **common_kwargs):
|
||||
tokenizer_name,
|
||||
)
|
||||
else:
|
||||
logger.warning(
|
||||
logger.debug(
|
||||
"Tokenizer for %s loaded as generic TokenizersBackend. "
|
||||
"Set --trust-remote-code to load the model-specific tokenizer.",
|
||||
tokenizer_name,
|
||||
|
||||
Reference in New Issue
Block a user