util.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:chi 作者: rmst 项目源码 文件源码
def print_env(env: Env):
    spec = getattr(env, 'spec', False)
    if spec:
        print(f'Env spec: {vars(spec)}')

    acsp = env.action_space
    obsp = env.observation_space

    print(f'Observation space {obsp}')
    if isinstance(obsp, Box) and len(obsp.high) < 20:
            print(f'low = {obsp.low}\nhigh = {obsp.high}')

    print(f'Action space {acsp}')
    if isinstance(acsp, Box) and len(acsp.high) < 20:
            print(f'low = {acsp.low}\nhigh = {acsp.high}')

    print("")
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号