我正在尝试使用 openai gym 模块,但出现此错误:
>>> import atari_py
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "C:\Users\ssit5\AppData\Local\Programs\Python\Python38\lib\site-packages\atari_py\__init__.py", line 1, in <module>
from .ale_python_interface import *
File "C:\Users\ssit5\AppData\Local\Programs\Python\Python38\lib\site-packages\atari_py\ale_python_interface.py", line 17, in <module>
ale_lib = cdll.LoadLibrary(os.path.join(os.path.dirname(__file__),
File "C:\Users\ssit5\AppData\Local\Programs\Python\Python38\lib\ctypes\__init__.py", line 451, in LoadLibrary
return self._dlltype(name)
File "C:\Users\ssit5\AppData\Local\Programs\Python\Python38\lib\ctypes\__init__.py", line 373, in __init__
self._handle = _dlopen(self._name, mode)
FileNotFoundError: Could not find module 'C:\Users\ssit5\AppData\Local\Programs\Python\Python38\lib\site-packages\atari_py\ale_interface\ale_c.dll' (or one of its dependencies). Try using the full path with constructor syntax.
我没有 ale_c.dll 并尝试寻找解决方案但没有任何效果。我在这里遵循了解决方案https://github.com/openai/gym/issues/1726但是在尝试导入 atari_py 时出现了同样的错误。我不明白为什么__init__
会搜索模块没有附带的东西。我查看了其他 StackOverflow 问题,但也没有产生任何结果。我能想到的唯一解决方案是获取 ale_c.dll 的副本,但我不知道如何获取它。