-
Notifications
You must be signed in to change notification settings - Fork 0
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
OSError: [WinError 193] %1 不是有效的 Win32 应用程序。 #2
Comments
It seems like a problem with mujoco-py. Can you try different versions of mujoco-py, like 2.0.2.9, 2.0.2.5, or 2.0.2.13? You can also try opening a new .py file which only imports mujoco_py to track if the problem is indeed with mujoco-py. |
I may not chech Github very frequently. You can email jin-zhan20@mails.tsinghua.edu.cn for faster responses. |
I do not think this is a problem about mujoco-py.Because it seems that mujoco_py is imported form rand_param_envs which is in your own code.And I do not see anything about mujoco in the enviroment.yaml. |
Both I and other researchers have successfully run IDAQ on Linux, but we have not tested it on Windows, so currently I have no clear idea on how to debug this. Maybe you can try replacing the rand_param_envs folder with the version in https://github.com/LanqingLi1993/FOCAL-ICLR/tree/master/rand_param_envs. If the problem still exists, please check your mujoco installation on Windows, perhaps this page can provide some help: https://zhuanlan.zhihu.com/p/104178775. |
Hello. I hope this message finds you well. I am very interested in your paper and have been attempting to reproduce the code from the [IDAQ_Public repository] on both Windows and Linux systems. However, I have encountered a recurring issue that I have not been able to resolve. The specific error message I receive is: I would greatly appreciate any guidance or suggestions you might have to help resolve this issue. Your assistance would be invaluable in helping me move forward with my research. |
Hi, it seems like an issue with mujoco-py installation. From the current error report, I cannot find out what is wrong. Is there any other error reports following it? Also, you can try to follow https://github.com/openai/mujoco-py to setup it. |
Thanks for your email. I commented out the mujoco-py from the
requirements.txt and installed it separately. However, I couldn't install
it anyway.
it is the whole error:
$ pip install mujoco-py==2.0.2.11
Collecting mujoco-py==2.0.2.11
Using cached mujoco-py-2.0.2.11.tar.gz (790 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: glfw>=1.4.0 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.12.0)
Requirement already satisfied: numpy>=1.11 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.19.1)
Requirement already satisfied: Cython>=0.27.2 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (0.29.21)
Requirement already satisfied: imageio>=2.1.2 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (2.9.0)
Requirement already satisfied: cffi>=1.10 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.14.0)
Requirement already satisfied: fasteners~=0.15 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (0.15)
Requirement already satisfied: pycparser in
./idaq_env/lib/python3.8/site-packages (from
cffi>=1.10->mujoco-py==2.0.2.11) (2.20)
Requirement already satisfied: six in
./idaq_env/lib/python3.8/site-packages (from
fasteners~=0.15->mujoco-py==2.0.2.11) (1.15.0)
Requirement already satisfied: monotonic>=0.1 in
./idaq_env/lib/python3.8/site-packages (from
fasteners~=0.15->mujoco-py==2.0.2.11) (1.5)
Requirement already satisfied: pillow in
./idaq_env/lib/python3.8/site-packages (from
imageio>=2.1.2->mujoco-py==2.0.2.11) (7.2.0)
Building wheels for collected packages: mujoco-py
Building wheel for mujoco-py (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for mujoco-py (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [95 lines of output]
running bdist_wheel
running build
performance hint: mujoco_py/cymj.pyx:67:5: Exception check on
'c_warning_callback' will always require the GIL to be acquired.
Possible solutions:
1. Declare 'c_warning_callback' as 'noexcept' if you control the
definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on 'c_warning_callback' to allow an
error code to be returned.
performance hint: mujoco_py/cymj.pyx:104:5: Exception check on
'c_error_callback' will always require the GIL to be acquired.
Possible solutions:
1. Declare 'c_error_callback' as 'noexcept' if you control the
definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on 'c_error_callback' to allow an
error code to be returned.
Error compiling Cython file:
------------------------------------------------------------
...
See c_warning_callback, which is the C wrapper to the user
defined function
'''
global py_warning_callback
global mju_user_warning
py_warning_callback = warn
mju_user_warning = c_warning_callback
^
------------------------------------------------------------
mujoco_py/cymj.pyx:92:23: Cannot assign type 'void (const char *)
except * nogil' to 'void (*)(const char *) noexcept nogil'. Exception
values are incompatible. Suggest adding 'noexcept' to the type of
'c_warning_callback'.
Error compiling Cython file:
------------------------------------------------------------
...
See c_warning_callback, which is the C wrapper to the user
defined function
'''
global py_error_callback
global mju_user_error
py_error_callback = err_callback
mju_user_error = c_error_callback
^
------------------------------------------------------------
mujoco_py/cymj.pyx:127:21: Cannot assign type 'void (const char *)
except * nogil' to 'void (*)(const char *) noexcept nogil'. Exception
values are incompatible. Suggest adding 'noexcept' to the type of
'c_error_callback'.
Removing old mujoco_py cext /path/to/temp/dir/mujoco_py/generated/
cymj_2.0.2.11_38_linuxcpuextensionbuilder_38.so
Compiling /path/to/temp/dir/mujoco_py/cymj.pyx because it changed.
[1/1] Cythonizing /path/to/temp/dir/mujoco_py/cymj.pyx
Traceback (most recent call last):
File
"/path/to/temp/dir/pip/_vendor/pyproject_hooks/_in_process/_in_process.py",
line 353, in <module>
main()
File
"/path/to/temp/dir/pip/_vendor/pyproject_hooks/_in_process/_in_process.py",
line 335, in main
json_out['return_val'] = hook(**hook_input['kwargs'])
File
"/path/to/temp/dir/pip/_vendor/pyproject_hooks/_in_process/_in_process.py",
line 251, in build_wheel
return _build_backend().build_wheel(wheel_directory,
config_settings,
File "/path/to/temp/dir/setuptools/build_meta.py", line 415, in
build_wheel
return self._build_with_temp_dir(
File "/path/to/temp/dir/setuptools/build_meta.py", line 397, in
_build_with_temp_dir
self.run_setup()
File "/path/to/temp/dir/setuptools/build_meta.py", line 497, in
run_setup
super().run_setup(setup_script=setup_script)
File "/path/to/temp/dir/setuptools/build_meta.py", line 313, in
run_setup
exec(code, locals())
File "<string>", line 33, in <module>
File "/path/to/temp/dir/setuptools/__init__.py", line 103, in setup
return distutils.core.setup(**attrs)
File "/path/to/temp/dir/setuptools/_distutils/core.py", line 184,
in setup
return run_commands(dist)
File "/path/to/temp/dir/setuptools/_distutils/core.py", line 200,
in run_commands
dist.run_commands()
File "/path/to/temp/dir/setuptools/_distutils/dist.py", line 969,
in run_commands
self.run_command(cmd)
File "/path/to/temp/dir/setuptools/dist.py", line 976, in
run_command
super().run_command(command)
File "/path/to/temp/dir/setuptools/_distutils/dist.py", line 988,
in run_command
cmd_obj.run()
File "/path/to/temp/dir/setuptools/command/bdist_wheel.py", line
373, in run
self.run_command("build")
File "/path/to/temp/dir/setuptools/_distutils/cmd.py", line 316, in
run_command
self.distribution.run_command(command)
File "/path/to/temp/dir/setuptools/dist.py", line 976, in
run_command
super().run_command(command)
File "/path/to/temp/dir/setuptools/_distutils/dist.py", line 988,
in run_command
cmd_obj.run()
File "<string>", line 29, in run
File "/path/to/temp/dir/mujoco_py/__init__.py", line 3, in <module>
from mujoco_py.builder import cymj, ignore_mujoco_warnings,
functions, MujocoException
File "/path/to/temp/dir/mujoco_py/builder.py", line 510, in <module>
cymj = load_cython_ext(mujoco_path)
File "/path/to/temp/dir/mujoco_py/builder.py", line 105, in
load_cython_ext
cext_so_path = builder.build()
File "/path/to/temp/dir/muj
…On Fri, Jun 28, 2024 at 4:07 PM NagisaZj ***@***.***> wrote:
Hello. I hope this message finds you well. I am very interested in your
paper and have been attempting to reproduce the code from the [IDAQ_Public
repository] on both Windows and Linux systems. However, I have encountered
a recurring issue that I have not been able to resolve.
The specific error message I receive is: note: This error originates from
a subprocess, and is likely not a problem with pip. ERROR: Failed building
wheel for mujoco-py Failed to build mujoco-py ERROR: ERROR: Failed to build
installable wheels for some pyproject.toml based projects (mujoco-py)
Following your advice, I tried using different versions of mujoco-py such
as 2.0.2.9, 2.0.2.5, and 2.0.2.13, but I continue to encounter the same
error.
I would greatly appreciate any guidance or suggestions you might have to
help resolve this issue. Your assistance would be invaluable in helping me
move forward with my research.
Hi, it seems like an issue with mujoco-py installation. From the current
error report, I cannot find out what is wrong. Is there any other error
reports following it? Also, you can try to follow
https://github.com/openai/mujoco-py to setup it.
—
Reply to this email directly, view it on GitHub
<#2 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQCMZN3VHKAAYQJJ7T3VIBLZJT4THAVCNFSM6AAAAABKBCE4TGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOJWGIYDONBRHE>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
It seems to be a problem with Cython. Please try Cython==0.29.36, as discussed in openai/mujoco-py#773. |
unfortunately the issue persists:
(idaq_env) $ pip install Cython==0.29.36
Collecting Cython==0.29.36
Using cached
Cython-0.29.36-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl.metadata
(3.1 kB)
Using cached
Cython-0.29.36-cp38-cp38-manylinux_2_17_x86_64.manylinux2014_x86_64.manylinux_2_24_x86_64.whl
(1.9 MB)
Installing collected packages: Cython
Successfully installed Cython-0.29.36
(idaq_env) $ pip install mujoco-py==2.0.2.11
Collecting mujoco-py==2.0.2.11
Using cached mujoco-py-2.0.2.11.tar.gz (790 kB)
Installing build dependencies ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: glfw>=1.4.0 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.12.0)
Requirement already satisfied: numpy>=1.11 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.19.1)
Requirement already satisfied: Cython>=0.27.2 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (0.29.36)
Requirement already satisfied: imageio>=2.1.2 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (2.9.0)
Requirement already satisfied: cffi>=1.10 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (1.14.0)
Requirement already satisfied: fasteners~=0.15 in
./idaq_env/lib/python3.8/site-packages (from mujoco-py==2.0.2.11) (0.15)
Requirement already satisfied: pycparser in
./idaq_env/lib/python3.8/site-packages (from
cffi>=1.10->mujoco-py==2.0.2.11) (2.20)
Requirement already satisfied: six in
./idaq_env/lib/python3.8/site-packages (from
fasteners~=0.15->mujoco-py==2.0.2.11) (1.15.0)
Requirement already satisfied: monotonic>=0.1 in
./idaq_env/lib/python3.8/site-packages (from
fasteners~=0.15->mujoco-py==2.0.2.11) (1.5)
Requirement already satisfied: pillow in
./idaq_env/lib/python3.8/site-packages (from
imageio>=2.1.2->mujoco-py==2.0.2.11) (7.2.0)
Building wheels for collected packages: mujoco-py
Building wheel for mujoco-py (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for mujoco-py (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [95 lines of output]
running bdist_wheel
running build
performance hint: mujoco_py/cymj.pyx:67:5: Exception check on
'c_warning_callback' will always require the GIL to be acquired.
Possible solutions:
1. Declare 'c_warning_callback' as 'noexcept' if you control the
definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on 'c_warning_callback' to allow an
error code to be returned.
performance hint: mujoco_py/cymj.pyx:104:5: Exception check on
'c_error_callback' will always require the GIL to be acquired.
Possible solutions:
1. Declare 'c_error_callback' as 'noexcept' if you control the
definition and you're sure you don't want the function to raise exceptions.
2. Use an 'int' return type on 'c_error_callback' to allow an
error code to be returned.
Error compiling Cython file:
------------------------------------------------------------
...
See c_warning_callback, which is the C wrapper to the user
defined function
'''
global py_warning_callback
global mju_user_warning
py_warning_callback = warn
mju_user_warning = c_warning_callback
^
------------------------------------------------------------
mujoco_py/cymj.pyx:92:23: Cannot assign type 'void (const char *)
except * nogil' to 'void (*)(const char *) noexcept nogil'. Exception
values are incompatible. Suggest adding 'noexcept' to the type of
'c_warning_callback'.
Error compiling Cython file:
------------------------------------------------------------
...
See c_warning_callback, which is the C wrapper to the user
defined function
'''
global py_error_callback
global mju_user_error
py_error_callback = err_callback
mju_user_error = c_error_callback
^
------------------------------------------------------------
mujoco_py/cymj.pyx:127:21: Cannot assign type 'void (const char *)
except * nogil' to 'void (*)(const char *) noexcept nogil'. Exception
values are incompatible. Suggest adding 'noexcept' to the type of
'c_error_callback'.
Removing old mujoco_py cext
/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/generated/
cymj_2.0.2.11_38_linuxcpuextensionbuilder_38.so
Compiling
/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/cymj.pyx
because it changed.
[1/1] Cythonizing
/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/cymj.pyx
Traceback (most recent call last):
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/__init__.py",
line 3, in <module>
from mujoco_py.builder import cymj, ignore_mujoco_warnings,
functions, MujocoException
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/builder.py",
line 510, in <module>
cymj = load_cython_ext(mujoco_path)
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/builder.py",
line 105, in load_cython_ext
cext_so_path = builder.build()
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/builder.py",
line 221, in build
built_so_file_path = self._build_impl()
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/builder.py",
line 273, in _build_impl
so_file_path = super()._build_impl()
File
"/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/builder.py",
line 234, in _build_impl
dist.ext_modules = cythonize([self.extension])
File
"/tmp/pip-build-env-b4p82wkn/overlay/lib/python3.8/site-packages/Cython/Build/Dependencies.py",
line 1154, in cythonize
cythonize_one(*args)
File
"/tmp/pip-build-env-b4p82wkn/overlay/lib/python3.8/site-packages/Cython/Build/Dependencies.py",
line 1321, in cythonize_one
raise CompileError(None, pyx_file)
Cython.Compiler.Errors.CompileError:
/tmp/pip-install-b8ojq3ig/mujoco-py_7f752a4cec16485b98b50c170527374d/mujoco_py/cymj.pyx
[end of output]
note: This error originates from a subprocess, and is likely not a
problem with pip.
ERROR: Failed building wheel for mujoco-py
Failed to build mujoco-py
ERROR: Failed to build installable wheels for some pyproject.toml based
projects (mujoco-py)
…On Fri, Jun 28, 2024 at 4:53 PM NagisaZj ***@***.***> wrote:
It seems to be a problem with Cython. Please try Cython==0.29.36, as
discussed in openai/mujoco-py#773
<openai/mujoco-py#773>.
—
Reply to this email directly, view it on GitHub
<#2 (comment)>,
or unsubscribe
<https://github.com/notifications/unsubscribe-auth/AQCMZN7RBCA45VP7DBLXGITZJUB7DAVCNFSM6AAAAABKBCE4TGVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDCOJWGI3DCNBZGE>
.
You are receiving this because you commented.Message ID:
***@***.***>
|
No more idea for this. Maybe trying different versions of mujoco_py can help. |
The text was updated successfully, but these errors were encountered: