update default logger (#100) (#101)

This commit is contained in:
ver217
2022-01-04 20:03:26 +08:00
committed by GitHub
parent 96780e6ee4
commit a951bc6089
2 changed files with 17 additions and 3 deletions

View File

@@ -5,6 +5,7 @@ import inspect
import sys
from importlib.machinery import SourceFileLoader
from pathlib import Path
from colossalai.logging import get_dist_logger
class Config(dict):
@@ -88,8 +89,8 @@ class Config(dict):
else:
config._add_item(k, v)
# TODO: replace with logger warning here when logger is done
print('warning: variables which starts with __, is a module or class declaration are omitted')
logger = get_dist_logger()
logger.debug('variables which starts with __, is a module or class declaration are omitted in config file')
# remove module
del sys.modules[module_name]