!7215 modify checkpoint warning info

Merge pull request !7215 from changzherui/mod_ckpt_info
This commit is contained in:
mindspore-ci-bot 2020-10-15 17:15:53 +08:00 committed by Gitee
commit 62bee291b2
1 changed files with 2 additions and 1 deletions

View File

@ -51,7 +51,8 @@ def _set_pb_env():
"""Set env variable `PROTOCOL_BUFFERS` to prevent memory overflow."""
if os.getenv("PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION") == "cpp":
logger.warning("Current env variable `PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=cpp`,\
When the parameter is too large, it may cause memory limit error.")
When the parameter is too large, it may cause memory limit error.\
This can be solved by set env `PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python`.")
else:
os.environ["PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION"] = "python"
logger.debug("Set the `PROTOCOL_BUFFERS_PYTHON_IMPLEMENTATION=python`.")