[Fix] Fix errors caused by MMEngine 0.8.1 (#48)

This commit is contained in:
Tong Gao 2023-07-12 11:22:16 +08:00 committed by GitHub
parent c8f1d513b2
commit 014b24dd02
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 3 additions and 3 deletions

View File

@ -7,7 +7,7 @@ evaluate>=0.3.0
fairscale
faiss_gpu==1.7.2
jieba
mmengine>0.8.0
mmengine>=0.8.2
nltk==3.8
numpy==1.23.4
openai

4
run.py
View File

@ -139,7 +139,7 @@ def main():
# initialize logger
logger = get_logger(log_level='DEBUG' if args.debug else 'INFO')
cfg = Config.fromfile(args.config)
cfg = Config.fromfile(args.config, format_python_code=False)
if args.work_dir is not None:
cfg['work_dir'] = args.work_dir
else:
@ -172,7 +172,7 @@ def main():
cfg.dump(output_config_path)
# Config is intentally reloaded here to avoid initialized
# types cannot be serialized
cfg = Config.fromfile(output_config_path)
cfg = Config.fromfile(output_config_path, format_python_code=False)
# report to lark bot if specify --lark
if not args.lark: