出现报错:
This initial message can be silenced or aggravated in the future by setting the
$GIT_PYTHON_REFRESH environment variable. Use one of the following values:
- quiet|q|silence|s|silent|none|n|0: for no message or exception
- warn|w|warning|log|l|1: for a warning message (logging level CRITICAL, displayed by default)
- error|e|exception|raise|r|2: for a raised exception
Example:
export GIT_PYTHON_REFRESH=quiet
是因为环境中没有安装git,解决:
方法一:在train.py文件中的import os后面加上
os.environ["GIT_PYTHON_REFRESH"] = "quiet"
方法二:conda install git