I want to run a torchbeast agent on the minihack environment and follow the instructions of minihack.
When I ran the command pip install ".[polybeast]" I got the error:
Obtaining file:///home/yangqiuyu/minihack/torchbeast
Installing build dependencies ... done
Checking if build backend supports build_editable ... done
Getting requirements to build wheel ... done
Preparing metadata (pyproject.toml) ... done
WARNING: libtorchbeast 0.0.20 does not provide the extra 'polybeast'
Requirement already satisfied: torch>=1.4.0 in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from libtorchbeast==0.0.20) (1.7.1)
Requirement already satisfied: typing_extensions in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from torch>=1.4.0->libtorchbeast==0.0.20) (4.1.1)
Requirement already satisfied: numpy in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from torch>=1.4.0->libtorchbeast==0.0.20) (1.22.3)
Installing collected packages: libtorchbeast
Running setup.py develop for libtorchbeast
error: subprocess-exited-with-error
× python setup.py develop did not run successfully.
│ exit code: 1
╰─> [135 lines of output]
running develop
running egg_info
writing libtorchbeast.egg-info/PKG-INFO
writing dependency_links to libtorchbeast.egg-info/dependency_links.txt
writing requirements to libtorchbeast.egg-info/requires.txt
writing top-level names to libtorchbeast.egg-info/top_level.txt
reading manifest file 'libtorchbeast.egg-info/SOURCES.txt'
adding license file 'LICENSE'
writing manifest file 'libtorchbeast.egg-info/SOURCES.txt'
running build_ext
-- Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIRS NumPy) (found suitable version "3.8.13", minimum required is "3.7")
CMake Warning at CMakeLists.txt:19 (find_package):
By not providing "FindNumPy.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "NumPy", but
CMake did not find one.
Could not find a package configuration file provided by "NumPy" with any of
the following names:
NumPyConfig.cmake
numpy-config.cmake
Add the installation prefix of "NumPy" to CMAKE_PREFIX_PATH or set
"NumPy_DIR" to a directory containing one of the above files. If "NumPy"
provides a separate development package or SDK, be sure it has been
installed.
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'torch'
-- pybind11 v2.6.2
CMake Warning (dev) at /usr/local/cmake-3.22.3-linux-x86_64/share/cmake-3.22/Modules/CMakeDependentOption.cmake:84 (message):
Policy CMP0127 is not set: cmake_dependent_option() supports full Condition
Syntax. Run "cmake --help-policy CMP0127" for policy details. Use the
cmake_policy command to set the policy and suppress this warning.
Call Stack (most recent call first):
third_party/pybind11/CMakeLists.txt:98 (cmake_dependent_option)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning at third_party/pybind11/tools/pybind11Tools.cmake:46 (find_package):
By not providing "FindNumPy.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "NumPy", but
CMake did not find one.
Could not find a package configuration file provided by "NumPy" with any of
the following names:
NumPyConfig.cmake
numpy-config.cmake
Add the installation prefix of "NumPy" to CMAKE_PREFIX_PATH or set
"NumPy_DIR" to a directory containing one of the above files. If "NumPy"
provides a separate development package or SDK, be sure it has been
installed.
Call Stack (most recent call first):
third_party/pybind11/tools/pybind11Common.cmake:201 (include)
third_party/pybind11/CMakeLists.txt:188 (include)
--
-- 3.14.0.0
CMake Deprecation Warning at third_party/grpc/third_party/zlib/CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'torch'
-- Caffe2: CUDA detected: 10.0
-- Caffe2: CUDA nvcc is: /usr/local/cuda/bin/nvcc
-- Caffe2: CUDA toolkit directory: /usr/local/cuda
-- Caffe2: Header version is: 10.0
-- Found cuDNN: v7.6.5 (include: /usr/local/cuda/include, library: /usr/local/cuda/lib64/libcudnn.so)
-- Added CUDA NVCC flags for: -gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70
CMake Deprecation Warning at third_party/grpc/third_party/googletest/CMakeLists.txt:4 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Deprecation Warning at third_party/grpc/third_party/googletest/googlemock/CMakeLists.txt:45 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Deprecation Warning at third_party/grpc/third_party/googletest/googletest/CMakeLists.txt:56 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- Configuring done
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
/home/yangqiuyu/minihack/torchbeast/_Python3_NumPy_INCLUDE_DIR
used as include directory in directory /home/yangqiuyu/minihack/torchbeast
CMake Error at third_party/pybind11/tools/pybind11Tools.cmake:167 (add_library):
Target "_C" links to target "Python3::NumPy" but the target was not found.
Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?
Call Stack (most recent call first):
CMakeLists.txt:97 (pybind11_add_module)
CMake Warning at third_party/pybind11/tools/pybind11Tools.cmake:167 (add_library):
Cannot generate a safe runtime search path for target _C because files in
some directories may conflict with libraries in implicit directories:
runtime library [libtorch_python.so] in /lib may be hidden by files in:
/home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages/torch/lib
Some of these libraries may not be found correctly.
Call Stack (most recent call first):
CMakeLists.txt:97 (pybind11_add_module)
-- Generating done
CMake Generate step failed. Build files cannot be regenerated correctly.
/tmp/pip-build-env-yfrvjlsm/overlay/lib/python3.8/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
/tmp/pip-build-env-yfrvjlsm/overlay/lib/python3.8/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: subprocess-exited-with-error
× python setup.py develop did not run successfully.
│ exit code: 1
╰─> [135 lines of output]
running develop
running egg_info
writing libtorchbeast.egg-info/PKG-INFO
writing dependency_links to libtorchbeast.egg-info/dependency_links.txt
writing requirements to libtorchbeast.egg-info/requires.txt
writing top-level names to libtorchbeast.egg-info/top_level.txt
reading manifest file 'libtorchbeast.egg-info/SOURCES.txt'
adding license file 'LICENSE'
writing manifest file 'libtorchbeast.egg-info/SOURCES.txt'
running build_ext
-- Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIRS NumPy) (found suitable version "3.8.13", minimum required is "3.7")
CMake Warning at CMakeLists.txt:19 (find_package):
By not providing "FindNumPy.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "NumPy", but
CMake did not find one.
Could not find a package configuration file provided by "NumPy" with any of
the following names:
NumPyConfig.cmake
numpy-config.cmake
Add the installation prefix of "NumPy" to CMAKE_PREFIX_PATH or set
"NumPy_DIR" to a directory containing one of the above files. If "NumPy"
provides a separate development package or SDK, be sure it has been
installed.
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'torch'
-- pybind11 v2.6.2
CMake Warning (dev) at /usr/local/cmake-3.22.3-linux-x86_64/share/cmake-3.22/Modules/CMakeDependentOption.cmake:84 (message):
Policy CMP0127 is not set: cmake_dependent_option() supports full Condition
Syntax. Run "cmake --help-policy CMP0127" for policy details. Use the
cmake_policy command to set the policy and suppress this warning.
Call Stack (most recent call first):
third_party/pybind11/CMakeLists.txt:98 (cmake_dependent_option)
This warning is for project developers. Use -Wno-dev to suppress it.
CMake Warning at third_party/pybind11/tools/pybind11Tools.cmake:46 (find_package):
By not providing "FindNumPy.cmake" in CMAKE_MODULE_PATH this project has
asked CMake to find a package configuration file provided by "NumPy", but
CMake did not find one.
Could not find a package configuration file provided by "NumPy" with any of
the following names:
NumPyConfig.cmake
numpy-config.cmake
Add the installation prefix of "NumPy" to CMAKE_PREFIX_PATH or set
"NumPy_DIR" to a directory containing one of the above files. If "NumPy"
provides a separate development package or SDK, be sure it has been
installed.
Call Stack (most recent call first):
third_party/pybind11/tools/pybind11Common.cmake:201 (include)
third_party/pybind11/CMakeLists.txt:188 (include)
--
-- 3.14.0.0
CMake Deprecation Warning at third_party/grpc/third_party/zlib/CMakeLists.txt:1 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
Traceback (most recent call last):
File "<string>", line 1, in <module>
ModuleNotFoundError: No module named 'torch'
-- Caffe2: CUDA detected: 10.0
-- Caffe2: CUDA nvcc is: /usr/local/cuda/bin/nvcc
-- Caffe2: CUDA toolkit directory: /usr/local/cuda
-- Caffe2: Header version is: 10.0
-- Found cuDNN: v7.6.5 (include: /usr/local/cuda/include, library: /usr/local/cuda/lib64/libcudnn.so)
-- Added CUDA NVCC flags for: -gencode;arch=compute_60,code=sm_60;-gencode;arch=compute_70,code=sm_70
CMake Deprecation Warning at third_party/grpc/third_party/googletest/CMakeLists.txt:4 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Deprecation Warning at third_party/grpc/third_party/googletest/googlemock/CMakeLists.txt:45 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
CMake Deprecation Warning at third_party/grpc/third_party/googletest/googletest/CMakeLists.txt:56 (cmake_minimum_required):
Compatibility with CMake < 2.8.12 will be removed from a future version of
CMake.
Update the VERSION argument <min> value or use a ...<max> suffix to tell
CMake that the project does not need compatibility with older versions.
-- Configuring done
CMake Error: The following variables are used in this project, but they are set to NOTFOUND.
Please set them or make sure they are set and tested correctly in the CMake files:
/home/yangqiuyu/minihack/torchbeast/_Python3_NumPy_INCLUDE_DIR
used as include directory in directory /home/yangqiuyu/minihack/torchbeast
CMake Error at third_party/pybind11/tools/pybind11Tools.cmake:167 (add_library):
Target "_C" links to target "Python3::NumPy" but the target was not found.
Perhaps a find_package() call is missing for an IMPORTED target, or an
ALIAS target is missing?
Call Stack (most recent call first):
CMakeLists.txt:97 (pybind11_add_module)
CMake Warning at third_party/pybind11/tools/pybind11Tools.cmake:167 (add_library):
Cannot generate a safe runtime search path for target _C because files in
some directories may conflict with libraries in implicit directories:
runtime library [libtorch_python.so] in /lib may be hidden by files in:
/home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages/torch/lib
Some of these libraries may not be found correctly.
Call Stack (most recent call first):
CMakeLists.txt:97 (pybind11_add_module)
-- Generating done
CMake Generate step failed. Build files cannot be regenerated correctly.
/tmp/pip-build-env-yfrvjlsm/overlay/lib/python3.8/site-packages/setuptools/command/easy_install.py:144: EasyInstallDeprecationWarning: easy_install command is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
/tmp/pip-build-env-yfrvjlsm/overlay/lib/python3.8/site-packages/setuptools/command/install.py:34: SetuptoolsDeprecationWarning: setup.py install is deprecated. Use build and pip and other standards-based tools.
warnings.warn(
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
I would really appreciate it if someone could help me find out where the problem is.
I want to run a torchbeast agent on the minihack environment and follow the instructions of minihack. When I ran the command pip install ".[polybeast]" I got the error:
Obtaining file:///home/yangqiuyu/minihack/torchbeast Installing build dependencies ... done Checking if build backend supports build_editable ... done Getting requirements to build wheel ... done Preparing metadata (pyproject.toml) ... done WARNING: libtorchbeast 0.0.20 does not provide the extra 'polybeast' Requirement already satisfied: torch>=1.4.0 in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from libtorchbeast==0.0.20) (1.7.1) Requirement already satisfied: typing_extensions in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from torch>=1.4.0->libtorchbeast==0.0.20) (4.1.1) Requirement already satisfied: numpy in /home/yangqiuyu/anaconda3/envs/polybeast/lib/python3.8/site-packages (from torch>=1.4.0->libtorchbeast==0.0.20) (1.22.3) Installing collected packages: libtorchbeast Running setup.py develop for libtorchbeast error: subprocess-exited-with-error
error: subprocess-exited-with-error
× python setup.py develop did not run successfully. │ exit code: 1 ╰─> [135 lines of output] running develop running egg_info writing libtorchbeast.egg-info/PKG-INFO writing dependency_links to libtorchbeast.egg-info/dependency_links.txt writing requirements to libtorchbeast.egg-info/requires.txt writing top-level names to libtorchbeast.egg-info/top_level.txt reading manifest file 'libtorchbeast.egg-info/SOURCES.txt' adding license file 'LICENSE' writing manifest file 'libtorchbeast.egg-info/SOURCES.txt' running build_ext -- Could NOT find Python3 (missing: Python3_NumPy_INCLUDE_DIRS NumPy) (found suitable version "3.8.13", minimum required is "3.7") CMake Warning at CMakeLists.txt:19 (find_package): By not providing "FindNumPy.cmake" in CMAKE_MODULE_PATH this project has asked CMake to find a package configuration file provided by "NumPy", but CMake did not find one.
note: This error originates from a subprocess, and is likely not a problem with pip.
I would really appreciate it if someone could help me find out where the problem is.