按照官网Gym指导安装Gym,输入以下代码
pip install gym
成功安装gym0.21.0,输入下面代码克隆gym在github的库
git clone https://github.com/openai/gym
出现错误
(RL) johnwatson@rescuer-r720:~$ git clone https://github.com/openai/gym
正克隆到 'gym'...
fatal: 无法访问 'https://github.com/openai/gym/':GnuTLS recv error (-110): The TLS connection was non-properly terminated.
将代码更改为
git clone git://github.com/openai/gym
成功克隆。
运行代码来添加环境
cd gym
pip install -e .
出现问题
(RL) johnwatson@rescuer-r720:~/gym$ pip install -e .
Obtaining file:///home/johnwatson/gym
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing wheel metadata ... done
ERROR: Could not find a version that satisfies the requirement importlib-metadata>=4.10.0; python_version < "3.10" (from gym) (from versions: 0.0, 0.1, 0.2, 0.3, 0.4, 0.5, 0.6, 0.7, 0.8, 0.9, 0.10, 0.11, 0.12, 0.13, 0.14, 0.15, 0.16, 0.17, 0.18, 0.19, 0.20, 0.21, 0.22, 0.23, 1.0.0, 1.1.0, 1.1.1, 1.1.2, 1.1.3, 1.2.0, 1.3.0, 1.4.0, 1.5.0, 1.5.1, 1.5.2, 1.6.0, 1.6.1, 1.7.0, 2.0.0, 2.1.0, 2.1.1, 2.1.2, 3.0.0, 3.1.0, 3.1.1, 3.2.0, 3.3.0, 3.4.0, 3.5.0, 3.6.0, 3.7.0, 3.7.1, 3.7.2, 3.7.3, 3.8.0, 3.8.1, 3.8.2, 3.9.0, 3.9.1, 3.10.0, 3.10.1, 4.0.0, 4.0.1, 4.1.0, 4.2.0, 4.3.0, 4.3.1, 4.4.0, 4.5.0, 4.6.0, 4.6.1, 4.6.2, 4.6.3, 4.6.4, 4.7.0, 4.7.1, 4.8.0, 4.8.1, 4.8.2, 4.8.3)
ERROR: No matching distribution found for importlib-me

本文详细记录了在Linux环境下安装Gym及其所有环境的过程,包括解决安装过程中遇到的importlib-metadata版本冲突问题、mujoco-py造轮子失败等问题。
1398

被折叠的 条评论
为什么被折叠?



