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
ColossalAI
Commits
81145208
Unverified
Commit
81145208
authored
Mar 24, 2022
by
Jiarui Fang
Committed by
GitHub
Mar 24, 2022
Browse files
[install] run with out rich (#513)
parent
0f2d2191
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
7 additions
and
3 deletions
+7
-3
colossalai/logging/logging.py
colossalai/logging/logging.py
+7
-3
No files found.
colossalai/logging/logging.py
View file @
81145208
...
@@ -5,12 +5,16 @@ import colossalai
...
@@ -5,12 +5,16 @@ import colossalai
import
logging
import
logging
from
pathlib
import
Path
from
pathlib
import
Path
from
typing
import
Union
from
typing
import
Union
from
rich.logging
import
RichHandler
from
colossalai.context.parallel_mode
import
ParallelMode
from
colossalai.context.parallel_mode
import
ParallelMode
_FORMAT
=
'colossalai - %(name)s - %(asctime)s %(levelname)s: %(message)s'
try
:
logging
.
basicConfig
(
level
=
logging
.
INFO
,
format
=
_FORMAT
,
handlers
=
[
RichHandler
()])
from
rich.logging
import
RichHandler
_FORMAT
=
'colossalai - %(name)s - %(asctime)s %(levelname)s: %(message)s'
logging
.
basicConfig
(
level
=
logging
.
INFO
,
format
=
_FORMAT
,
handlers
=
[
RichHandler
()])
except
ImportError
:
_FORMAT
=
'colossalai - %(name)s - %(asctime)s %(levelname)s: %(message)s'
logging
.
basicConfig
(
level
=
logging
.
INFO
,
format
=
_FORMAT
)
class
DistributedLogger
:
class
DistributedLogger
:
...
...
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