Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
opencompass
Commits
ab21f3be
"test/git@developer.sourcefind.cn:change/sglang.git" did not exist on "f40942ad630c7e261c3cff5aa06be20e7e486d5b"
Unverified
Commit
ab21f3be
authored
Sep 04, 2023
by
Mashiro
Committed by
GitHub
Sep 04, 2023
Browse files
[Enhance] Supress warning raised by get_logger (#353)
parent
a1782f9a
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
3 deletions
+6
-3
opencompass/utils/logging.py
opencompass/utils/logging.py
+6
-3
No files found.
opencompass/utils/logging.py
View file @
ab21f3be
...
...
@@ -22,9 +22,12 @@ def get_logger(log_level='INFO', filter_duplicate_level=None) -> MMLogger:
log_level (str): The log level. Default: 'INFO'. Choices are 'DEBUG',
'INFO', 'WARNING', 'ERROR', 'CRITICAL'.
"""
logger
=
MMLogger
.
get_instance
(
'OpenCompass'
,
logger_name
=
'OpenCompass'
,
log_level
=
log_level
)
if
not
MMLogger
.
check_instance_created
(
'OpenCompass'
):
logger
=
MMLogger
.
get_instance
(
'OpenCompass'
,
logger_name
=
'OpenCompass'
,
log_level
=
log_level
)
else
:
logger
=
MMLogger
.
get_instance
(
'OpenCompass'
)
if
filter_duplicate_level
is
None
:
# export OPENCOMPASS_FILTER_DUPLICATE_LEVEL=error
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment