Python——gym运行错误‘function‘ object has no attribute ‘Viewer‘解决方案

Posted Starzkg

tags:

篇首语:本文由小常识网(cha138.com)小编为大家整理,主要介绍了Python——gym运行错误‘function‘ object has no attribute ‘Viewer‘解决方案相关的知识,希望对你有一定的参考价值。

问题描述

‘function‘ object has no attribute ‘Viewer‘

问题分析

gym破坏性升级,版本不兼容。

解决方案

方法一:
Python Gym ImportError cannot import name ‘rendering‘ from ‘gym.envs.classic_control‘
方法二:
gym改到0.15.4版本

pip install gym=0.15.4

参考文章

以上是关于Python——gym运行错误‘function‘ object has no attribute ‘Viewer‘解决方案的主要内容,如果未能解决你的问题,请参考以下文章

Python——gym运行错误‘function‘ object has no attribute ‘Viewer‘解决方案

Python——gym运行错误‘function‘ object has no attribute ‘Viewer‘解决方案

openAi-gym 名称错误

python 笔记 :Gym库 (官方文档笔记)

通过命令提示符运行python程序时未找到模块错误

强化学习 平台 openAI 的 gym 安装 (Ubuntu环境下如何安装Python的gym模块)