Mujoco 安装,未找到二进制文件
Mujoco installation, binaries not found
我在安装 mujoco 时遇到了麻烦。
我按照 https://github.com/openai/mujoco-py/issues/253 中的步骤操作。
一切正常,但是当我不得不 运行 "python examples\body_interaction.py" 我遇到了问题 :
Traceback (most recent call last):
File "D:\Session User\Desktop\computing\stage2021_hedwinb\mujoco-py\examples\body_interaction.py", line 10, in <module>
from mujoco_py import load_model_from_xml, MjSim, MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\__init__.py", line 2, in <module>
init_config()
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\config.py", line 37, in init_config
raise error.MujocoDependencyError('Found your MuJoCo license key but not binaries. Please put your binaries into ~/.mujoco/mjpro131 or set MUJOCO_PY_MJPRO_PATH. Follow the instructions on https://github.com/openai/mujoco-py for
setup.')
mujoco_py.error.MujocoDependencyError: Found your MuJoCo license key but not binaries. Please put your binaries into ~/.mujoco/mjpro131 or set MUJOCO_PY_MJPRO_PATH. Follow the instructions on https://github.com/openai/mujoco-py for
setup.
这是我的 .mujoco 目录的样子:
mujoco200 是我从那里下载的目录:https://www.roboti.us/index.html for win64,
这是我的 Env 变量的样子:
为了解决这个问题,我尝试从 there 下载“mjpro131 win64”并将其添加到环境中。使用名称“MUJOCO_PY_MJPRO_PATH”的变量,但它给了我另一个错误:
Traceback (most recent call last):
File "D:\Session User\Desktop\computing\stage2021_hedwinb\mujoco-py\examples\body_interaction.py", line 10, in <module>
from mujoco_py import load_model_from_xml, MjSim, MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\__init__.py", line 4, in <module>
from .mjviewer import MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjviewer.py", line 7, in <module>
from . import mjcore, mjconstants, glfw
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjcore.py", line 6, in <module>
from .mjlib import mjlib
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjlib.py", line 21, in <module>
mjlib = cdll.LoadLibrary(os.path.abspath(libfile))
File "C:\Users\User\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 452, in LoadLibrary
return self._dlltype(name)
File "C:\Users\User\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 374, in __init__
self._handle = _dlopen(self._name, mode)
OSError: [WinError 193] %1 n’est pas une application Win32 valide
最后一行翻译:
OSError: [WinError 193] %1 Is not a valid win32 application.
我也试过使用 win32 文件,但它给了我完全相同的错误。
我在 Linux 中遇到了同样的问题。我决定下载0.5.7版本的mujoco
pip install mujoco-py==0.5.7
然后将要求改为
click==7.0
xmltodict==0.12.0
scipy==1.3.1
gym==0.10.8
jsonnet==0.11.2
numpy
mujoco-py==0.5.7
这是另一个 link 说明:installing mujoco
我在安装 mujoco 时遇到了麻烦。
我按照 https://github.com/openai/mujoco-py/issues/253 中的步骤操作。
一切正常,但是当我不得不 运行 "python examples\body_interaction.py" 我遇到了问题 :
Traceback (most recent call last):
File "D:\Session User\Desktop\computing\stage2021_hedwinb\mujoco-py\examples\body_interaction.py", line 10, in <module>
from mujoco_py import load_model_from_xml, MjSim, MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\__init__.py", line 2, in <module>
init_config()
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\config.py", line 37, in init_config
raise error.MujocoDependencyError('Found your MuJoCo license key but not binaries. Please put your binaries into ~/.mujoco/mjpro131 or set MUJOCO_PY_MJPRO_PATH. Follow the instructions on https://github.com/openai/mujoco-py for
setup.')
mujoco_py.error.MujocoDependencyError: Found your MuJoCo license key but not binaries. Please put your binaries into ~/.mujoco/mjpro131 or set MUJOCO_PY_MJPRO_PATH. Follow the instructions on https://github.com/openai/mujoco-py for
setup.
这是我的 .mujoco 目录的样子:
mujoco200 是我从那里下载的目录:https://www.roboti.us/index.html for win64,
这是我的 Env 变量的样子:
为了解决这个问题,我尝试从 there 下载“mjpro131 win64”并将其添加到环境中。使用名称“MUJOCO_PY_MJPRO_PATH”的变量,但它给了我另一个错误:
Traceback (most recent call last):
File "D:\Session User\Desktop\computing\stage2021_hedwinb\mujoco-py\examples\body_interaction.py", line 10, in <module>
from mujoco_py import load_model_from_xml, MjSim, MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\__init__.py", line 4, in <module>
from .mjviewer import MjViewer
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjviewer.py", line 7, in <module>
from . import mjcore, mjconstants, glfw
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjcore.py", line 6, in <module>
from .mjlib import mjlib
File "D:\Session User\Desktop\computing\stage2021_hedwinb\venv\lib\site-packages\mujoco_py\mjlib.py", line 21, in <module>
mjlib = cdll.LoadLibrary(os.path.abspath(libfile))
File "C:\Users\User\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 452, in LoadLibrary
return self._dlltype(name)
File "C:\Users\User\AppData\Local\Programs\Python\Python39\lib\ctypes\__init__.py", line 374, in __init__
self._handle = _dlopen(self._name, mode)
OSError: [WinError 193] %1 n’est pas une application Win32 valide
最后一行翻译:
OSError: [WinError 193] %1 Is not a valid win32 application.
我也试过使用 win32 文件,但它给了我完全相同的错误。
我在 Linux 中遇到了同样的问题。我决定下载0.5.7版本的mujoco
pip install mujoco-py==0.5.7
然后将要求改为
click==7.0
xmltodict==0.12.0
scipy==1.3.1
gym==0.10.8
jsonnet==0.11.2
numpy
mujoco-py==0.5.7
这是另一个 link 说明:installing mujoco