OpenCompass/opencompass/utils/collect_env.py
Hubert 5c19c8c5fc
[Docs] add issue and pr template (#12)
* [Feat] add issue and pr template

* minor add utils

* minor fix
2023-07-06 11:55:01 +08:00

13 lines
352 B
Python

from mmengine.utils import get_git_hash
from mmengine.utils.dl_utils import collect_env as collect_base_env
import opencompass
def collect_env():
"""Collect the information of the running environments."""
env_info = collect_base_env()
env_info['opencompass'] = opencompass.__version__ + '+' + get_git_hash(
)[:7]
return env_info