当我从openAI导入universe
模块时。我收到以下错误。
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/home/kunal/Desktop/OpenAi/openAI/lib/python3.7/site-packages/universe/__init__.py", line 22, in <module>
from universe import error, envs
File "/home/kunal/Desktop/OpenAi/openAI/lib/python3.7/site-packages/universe/envs/__init__.py", line 1, in <module>
import universe.envs.vnc_env
File "/home/kunal/Desktop/OpenAi/openAI/lib/python3.7/site-packages/universe/envs/vnc_env.py", line 11, in <module>
from universe.envs import diagnostics
File "/home/kunal/Desktop/OpenAi/openAI/lib/python3.7/site-packages/universe/envs/diagnostics.py", line 94
async = self.qr_pool.apply_async(self.method, (self._last_img, time.time(), available_at))
^
SyntaxError: invalid syntax
我为什么要得到这个?以及我该如何解决?
答案 0 :(得分:0)
在Ubuntu 16.04和18.04上:
sudo apt-get install -y libglu1-mesa-dev libgl1-mesa-dev libosmesa6-dev xvfb ffmpeg curl patchelf libglfw3 libglfw3-dev cmake zlib1g zlib1g-dev swig
之后,使用以下命令重新安装健身房:
git clone https://github.com/openai/gym.git
cd gym
pip install -e .