facebookresearch / torchbeast

A PyTorch Platform for Distributed RL
Apache License 2.0
734 stars 113 forks source link

Error on installing PolyBeast #33

Closed ZhihuaLiuEd closed 2 years ago

ZhihuaLiuEd commented 2 years ago

Hi there:

First I got the permission error on python setup.py install

error: can't create or remove files in install directory

The following error occurred while trying to add or remove files in the
installation directory:

    [Errno 13] Permission denied: '/home/ubuntu/miniconda3/envs/nle_challenge/lib/python3.8/site-packages/test-easy-install-26145.write-test'

The installation directory you specified (via --install-dir, --prefix, or
the distutils default setting) was:

    /home/ubuntu/miniconda3/envs/nle_challenge/lib/python3.8/site-packages/

After I use sudo python3 setup.py install, I got the ABI error with:

[  1%] Building CXX object grpc/third_party/abseil-cpp/absl/base/CMakeFiles/absl_exponential_biased.dir/internal/exponential_biased.cc.o
In file included from /usr/include/c++/7/cassert:43:0,
                 from /home/ubuntu/torchbeast/third_party/grpc/third_party/abseil-cpp/absl/numeric/int128.h:25,
                 from /home/ubuntu/torchbeast/third_party/grpc/third_party/abseil-cpp/absl/numeric/int128.cc:15:

/usr/include/x86_64-linux-gnu/c++/7/bits/c++config.h:250:27: error: #if with no expression
 #if _GLIBCXX_USE_CXX11_ABI

I am using an AWS-EC2 instance with ubuntu 18.04, gcc 7.5.0.

Any idea on this?

Best, Zhihua

heiner commented 2 years ago

Hey Zhihua,

Thanks for your interest in TorchBeast.

The first issue you share appears to be purely a question of file system access.

Your second issue looks as if your C++ library isn't the one that came with the GCC version you are using (if, indeed, you are using GCC, I'd check that again): Notice that the error is inside a system library, triggered via a dependency of TorchBeast. This isn't, strictly speaking, an ABI error. I suspect trying clang instead of GCC or using a different C++ standard library implementation would fix the issue.

Neither of this is an issue directly with TorchBeast itself. TorchBeast works on Ubuntu 18.04; one example of how to install things there is shown in this Dockerfile. In your case I suspect you are not working in a vanilla Ubuntu 18.04 setting.