Skip to content

Commit

Permalink
fix logger init (#1598)
Browse files Browse the repository at this point in the history
  • Loading branch information
AllentDan authored May 16, 2024
1 parent 14b6c02 commit 8f79144
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion lmdeploy/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -265,6 +265,7 @@ def _get_and_verify_max_len(
max_model_len: Optional[int],
) -> int:
"""Get and verify the model's maximum length."""
logger = get_logger('lmdeploy')
derived_max_model_len = float('inf')
possible_keys = [
# OPT
Expand Down Expand Up @@ -295,7 +296,6 @@ def _get_and_verify_max_len(
return max_model_len

default_max_len = 2048
logger = get_logger('lmdeploy')
logger.warning(
"The model's config.json does not contain any of the following "
'keys to determine the original maximum length of the model: '
Expand Down

0 comments on commit 8f79144

Please sign in to comment.