google-deepmind / open_spiel

OpenSpiel is a collection of environments and algorithms for research in general reinforcement learning and search/planning in games.
Apache License 2.0
4.26k stars 934 forks source link

issue on installation. #138

Closed KK666-AI closed 4 years ago

KK666-AI commented 4 years ago

Dear Authors,

I am trying to evaluate my new algorithm on this open-spiel. However, when I try to install this package, after I execute the installation command below, some error occurs: ./open_spiel/scripts/build_and_run_tests.sh

error:

5 errors generated. CMakeFiles/open_spiel_core.dir/build.make:101: recipe for target 'CMakeFiles/open_spiel_core.dir/matrix_game.cc.o' failed make[2]: [CMakeFiles/open_spiel_core.dir/matrix_game.cc.o] Error 1 CMakeFiles/Makefile2:72: recipe for target 'CMakeFiles/open_spiel_core.dir/all' failed make[1]: [CMakeFiles/open_spiel_core.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... [ 15%] Building CXX object abseil-cpp/absl/base/CMakeFiles/absl_base.dir/internal/sysinfo.cc.o [ 15%] Building CXX object abseil-cpp/absl/base/CMakeFiles/absl_base.dir/internal/thread_identity.cc.o [ 15%] Building CXX object abseil-cpp/absl/base/CMakeFiles/absl_base.dir/internal/unscaledcycleclock.cc.o [ 16%] Linking CXX static library libabsl_absl_debugging_internal.a [ 16%] Built target absl_debugging_internal [ 17%] Linking CXX static library libabsl_absl_base.a [ 17%] Built target absl_base Makefile:94: recipe for target 'all' failed make: [all] Error 2

How to handle this issue.

Best, Hui

KK666-AI commented 4 years ago

Any easier installation methods ,such as pip install -e .

lanctot commented 4 years ago

Looks like your ./install.sh failed because of the failing launchpad entry (this is a Ubuntu software package utility unrelated to OpenSpiel), you should remove it: https://askubuntu.com/questions/213843/how-to-remove-update-repo-that-always-fails and then rerun install.sh.

We have a pip package in the works but it is not ready yet.

KK666-AI commented 4 years ago

@lanctot Thanks a lot. You are right. After I change the sources list in ubuntu, I can correctly execute ./install.sh. Then I follow the install instructions in https://github.com/deepmind/open_spiel/blob/master/docs/install.md, and execute ./open_spiel/scripts/build_and_run_tests.sh.

Some other errors occurs: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:48:1: error: 'inline' can only appear on functions inline constexpr Action kInvalidAction = -1; ^ In file included from /home/ken/project/open_spiel/open_spiel/matrix_game.cc:15: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/matrix_game.h:22: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/normal_form_game.h:20: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:48:1: error: 'inline' can only appear on functions inline constexpr Action kInvalidAction = -1; ^ In file included from /home/ken/project/open_spiel/open_spiel/spiel_bots.cc:15: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel_bots.h:18: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/policy.h:23: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:48:1: error: 'inline' can only appear on functions

Looking forward to see you release the pip package, so that I can pay more attention on the algorithms rather than the installations.

lanctot commented 4 years ago

It looks like your compiler might be too old. What version of Ubuntu do you have?

We actually do have a pip package mostly ready, but it is not in PyPi yet because we have not thoroughly tested it. You can even try installing it with python3 setup.py, but it is an sdist wheel, which means it will need to compile OpenSpiel before it can be used. So I expect it will fail for the same reason.

KK666-AI commented 4 years ago

system version == ubuntu 16.04 LTS. gcc version == gcc (Ubuntu 5.4.0-6ubuntu1 16.04.12) 5.4.0 20160609 g++ version == g++ (Ubuntu 5.4.0-6ubuntu1 16.04.12) 5.4.0 20160609 python version == Python 3.6.7

lanctot commented 4 years ago

Ubuntu 16.04 LTS should be fine, but we use clang++ now. I recommend removing everything and clone again starting from scratch. Also maybe try the installations steps from the paper instead: https://arxiv.org/abs/1908.09453

KK666-AI commented 4 years ago

I follow the installations steps in https://arxiv.org/abs/1908.09453

Also, some other errors occur:

ken@ubuntu:~/project/open_spiel/build$ cmake -DPython_TARGET_VERSION=3.6 -DCMAKE_CXX_COMPILER=clang++ ../open_spiel -- The C compiler identification is GNU 5.4.0 -- The CXX compiler identification is Clang 3.8.0 -- Check for working C compiler: /usr/bin/cc -- Check for working C compiler: /usr/bin/cc -- works -- Detecting C compiler ABI info -- Detecting C compiler ABI info - done -- Detecting C compile features -- Detecting C compile features - done -- Check for working CXX compiler: /usr/bin/clang++ -- Check for working CXX compiler: /usr/bin/clang++ -- works -- Detecting CXX compiler ABI info -- Detecting CXX compiler ABI info - done -- Detecting CXX compile features -- Detecting CXX compile features - done BUILD_WITH_HANABI not set. Defaults to OFF BUILD_WITH_HANABI: OFF BUILD_WITH_ACPC not set. Defaults to OFF BUILD_WITH_ACPC: OFF BUILD_WITH_JULIA not set. Defaults to OFF BUILD_WITH_JULIA: OFF CMake Error at CMakeLists.txt:110 (add_subdirectory): add_subdirectory given source "abseil-cpp" which is not an existing directory.

-- Found Python3: /usr/bin/python3.6 (found version "3.6.7") found components: Interpreter Development -- Configuring incomplete, errors occurred! See also "/home/ken/project/open_spiel/build/CMakeFiles/CMakeOutput.log".

lanctot commented 4 years ago

If abseil-cpp is missing, then ./install.sh was either not run or it failed again. Can you paste the output of that command?

KK666-AI commented 4 years ago

sorry. It's my mistake. I didn't execute ./install.sh. I remove build folder, and re-execute cmake -DPython_TARGET_VERSION=3.6 -DCMAKE_CXX_COMPILER=clang++ ../open_spiel, this command has no error. Then I execute make -j12, some other errors occur:

In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:48:1: error: 'inline' can only appear on functions inline constexpr Action kInvalidAction = -1; ^ [ 16%] Linking CXX static library libabsl_absl_time_zone.a /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no type named 'optional' in namespace 'std' std::optional default_value = std::nullopt) const;


/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:33: error: expected ')'
                   std::optional<T> default_value = std::nullopt) const;
                                ^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:691:19: note: to match this '('
  T ParameterValue(const std::string& key,
                  ^
[ 16%] Built target absl_time_zone
[ 17%] Linking CXX static library libabsl_absl_scoped_set_env.a
[ 17%] Built target absl_scoped_set_env
[ 17%] Linking CXX static library libabsl_absl_bad_variant_access.a
[ 17%] Linking CXX static library libabsl_absl_bad_any_cast_impl.a
[ 17%] Built target absl_bad_any_cast_impl
[ 17%] Built target absl_bad_variant_access
3 errors generated.
CMakeFiles/open_spiel_core.dir/build.make:153: recipe for target 'CMakeFiles/open_spiel_core.dir/tensor_game.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/tensor_game.cc.o] Error 1
CMakeFiles/Makefile2:72: recipe for target 'CMakeFiles/open_spiel_core.dir/all' failed
make[1]: *** [CMakeFiles/open_spiel_core.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 18%] Linking CXX static library libabsl_absl_stacktrace.a
[ 18%] Built target absl_stacktrace
[ 19%] Linking CXX static library libabsl_absl_base.a
[ 19%] Built target absl_base
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2
lanctot commented 4 years ago

Ok, we are definitely missing #include <optional> at the top of spiel.h. That is a bug we need to fix, thanks for catching that.

That should fix two of the errors you showed. I am still trying to figure out how to fix the other one about inline only being allowed on functions.

elkhrt commented 4 years ago

Which version of clang are you using?

KK666-AI commented 4 years ago

clang version 3.8.0-2ubuntu4 (tags/RELEASE_380/final)

elkhrt commented 4 years ago

You need to update (e.g. to clang v8). That version is a few years old.

KK666-AI commented 4 years ago

I have updated the clang. clang version 8.0.1- (branches/release_80)

New errors occur:

In file included from /home/ken/project/open_spiel/open_spiel/spiel.cc:15: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std' std::optional default_value = std::nullopt) const;


/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
/home/ken/project/open_spiel/open_spiel/spiel.cc:210:34: error: no template named 'optional' in namespace 'std'
    const std::string& key, std::optional<GameParameters> default_value) const {
                            ~~~~~^
/home/ken/project/open_spiel/open_spiel/spiel.cc:216:29: error: no member named 'nullopt' in namespace 'std'
  if (default_value == std::nullopt) {
                       ~~~~~^
/home/ken/project/open_spiel/open_spiel/spiel.cc:228:1: error: extraneous 'template<>' in declaration of variable 'ParameterValue'
template <>
^~~~~~~~~~~
/home/ken/project/open_spiel/open_spiel/spiel.cc:229:11: error: redefinition of 'ParameterValue' as different kind of symbol
int Game::ParameterValue<int>(const std::string& key,
          ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:209:22: note: previous definition is here
GameParameters Game::ParameterValue<GameParameters>(
                     ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:229:25: error: expected ';' at end of declaration
int Game::ParameterValue<int>(const std::string& key,
                        ^
                        ;
/home/ken/project/open_spiel/open_spiel/spiel.cc:229:25: error: expected unqualified-id
/home/ken/project/open_spiel/open_spiel/spiel.cc:252:1: error: extraneous 'template<>' in declaration of variable 'ParameterValue'
template <>
^~~~~~~~~~~
/home/ken/project/open_spiel/open_spiel/spiel.cc:253:14: error: redefinition of 'ParameterValue' as different kind of symbol
double Game::ParameterValue<double>(const std::string& key,
             ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:209:22: note: previous definition is here
GameParameters Game::ParameterValue<GameParameters>(
                     ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:253:28: error: expected ';' at end of declaration
double Game::ParameterValue<double>(const std::string& key,
                           ^
                           ;
/home/ken/project/open_spiel/open_spiel/spiel.cc:253:28: error: expected unqualified-id
/home/ken/project/open_spiel/open_spiel/spiel.cc:276:1: error: extraneous 'template<>' in declaration of variable 'ParameterValue'
template <>
^~~~~~~~~~~
/home/ken/project/open_spiel/open_spiel/spiel.cc:277:19: error: redefinition of 'ParameterValue' as different kind of symbol
std::string Game::ParameterValue<std::string>(
                  ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:209:22: note: previous definition is here
GameParameters Game::ParameterValue<GameParameters>(
                     ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:277:33: error: expected ';' at end of declaration
std::string Game::ParameterValue<std::string>(
                                ^
                                ;
/home/ken/project/open_spiel/open_spiel/spiel.cc:277:33: error: expected unqualified-id
/home/ken/project/open_spiel/open_spiel/spiel.cc:300:1: error: extraneous 'template<>' in declaration of variable 'ParameterValue'
template <>
^~~~~~~~~~~
/home/ken/project/open_spiel/open_spiel/spiel.cc:301:12: error: redefinition of 'ParameterValue' as different kind of symbol
bool Game::ParameterValue<bool>(const std::string& key,
           ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:209:22: note: previous definition is here
GameParameters Game::ParameterValue<GameParameters>(
                     ^
/home/ken/project/open_spiel/open_spiel/spiel.cc:301:26: error: expected ';' at end of declaration
bool Game::ParameterValue<bool>(const std::string& key,
                         ^
                         ;
fatal error: too many errors emitted, stopping now [-ferror-limit=]
20 errors generated.
In file included from /home/ken/project/open_spiel/open_spiel/matrix_game.cc:15:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/matrix_game.h:22:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/normal_form_game.h:20:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20:
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                   ~~~~~^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
CMakeFiles/open_spiel_core.dir/build.make:75: recipe for target 'CMakeFiles/open_spiel_core.dir/spiel.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/spiel.cc.o] Error 1
make[2]: *** Waiting for unfinished jobs....
[ 33%] Building CXX object abseil-cpp/absl/synchronization/CMakeFiles/absl_synchronization.dir/internal/create_thread_identity.cc.o
In file included from /home/ken/project/open_spiel/open_spiel/tensor_game.cc:15:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/tensor_game.h:23:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/normal_form_game.h:20:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20:
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                   ~~~~~^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
In file included from /home/ken/project/open_spiel/open_spiel/policy.cc:15:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/policy.h:23:
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                   ~~~~~^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
[ 34%] Building CXX object abseil-cpp/absl/synchronization/CMakeFiles/absl_synchronization.dir/internal/per_thread_sem.cc.o
In file included from /home/ken/project/open_spiel/open_spiel/spiel_bots.cc:15:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel_bots.h:18:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/policy.h:23:
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                   ~~~~~^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
2 errors generated.
CMakeFiles/open_spiel_core.dir/build.make:101: recipe for target 'CMakeFiles/open_spiel_core.dir/matrix_game.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/matrix_game.cc.o] Error 1
[ 34%] Building CXX object abseil-cpp/absl/synchronization/CMakeFiles/absl_synchronization.dir/internal/waiter.cc.o
In file included from /home/ken/project/open_spiel/open_spiel/simultaneous_move_game.cc:15:
In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20:
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:25: error: no template named 'optional' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                   ~~~~~^
/home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:692:58: error: no member named 'nullopt' in namespace 'std'
                   std::optional<T> default_value = std::nullopt) const;
                                                    ~~~~~^
2 errors generated.
CMakeFiles/open_spiel_core.dir/build.make:153: recipe for target 'CMakeFiles/open_spiel_core.dir/tensor_game.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/tensor_game.cc.o] Error 1
[ 34%] Building CXX object abseil-cpp/absl/synchronization/CMakeFiles/absl_synchronization.dir/notification.cc.o
[ 34%] Linking CXX static library libabsl_absl_random_seed_sequences.a
2 errors generated.
[ 34%] Building CXX object abseil-cpp/absl/synchronization/CMakeFiles/absl_synchronization.dir/mutex.cc.o
CMakeFiles/open_spiel_core.dir/build.make:114: recipe for target 'CMakeFiles/open_spiel_core.dir/policy.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/policy.cc.o] Error 1
2 errors generated.
CMakeFiles/open_spiel_core.dir/build.make:127: recipe for target 'CMakeFiles/open_spiel_core.dir/simultaneous_move_game.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/simultaneous_move_game.cc.o] Error 1
[ 34%] Built target absl_random_seed_sequences
[ 34%] Linking CXX static library libabsl_absl_random_internal_distribution_test_util.a
[ 34%] Linking CXX static library libabsl_absl_flags_marshalling.a
[ 34%] Built target absl_random_internal_distribution_test_util
2 errors generated.
CMakeFiles/open_spiel_core.dir/build.make:88: recipe for target 'CMakeFiles/open_spiel_core.dir/spiel_bots.cc.o' failed
make[2]: *** [CMakeFiles/open_spiel_core.dir/spiel_bots.cc.o] Error 1
CMakeFiles/Makefile2:72: recipe for target 'CMakeFiles/open_spiel_core.dir/all' failed
make[1]: *** [CMakeFiles/open_spiel_core.dir/all] Error 2
make[1]: *** Waiting for unfinished jobs....
[ 34%] Built target absl_flags_marshalling
[ 35%] Linking CXX static library libabsl_absl_synchronization.a
[ 35%] Built target absl_synchronization
Makefile:94: recipe for target 'all' failed
make: *** [all] Error 2
elkhrt commented 4 years ago

Please try adding the line:

include <optional>

Near the top of spiel.h

KK666-AI commented 4 years ago

there is no include file called optional, do i need to install some packages?

after add #include <optional> into the includes list in spiel.h the errors occur:

Scanning dependencies of target absl_throw_delegate [ 12%] Building CXX object abseil-cpp/absl/types/CMakeFiles/absl_bad_optional_access.dir/bad_optional_access.cc.o [ 12%] Building CXX object abseil-cpp/absl/base/CMakeFiles/absl_throw_delegate.dir/internal/throw_delegate.cc.o [ 12%] Building CXX object abseil-cpp/absl/time/CMakeFiles/absl_time_zone.dir/internal/cctz/src/time_zone_info.cc.o In file included from /home/ken/project/open_spiel/open_spiel/simultaneous_move_game.cc:15: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:18:10: fatal error: 'optional' file not found

include

     ^~~~~~~~~~

[ 12%] Building CXX object abseil-cpp/absl/time/CMakeFiles/absl_time_zone.dir/internal/cctz/src/time_zone_libc.cc.o In file included from /home/ken/project/open_spiel/open_spiel/matrix_game.cc:15: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/matrix_game.h:22: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/normal_form_game.h:20: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/simultaneous_move_game.h:20: /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel.h:18:10: fatal error: 'optional' file not found

include

     ^~~~~~~~~~

1 error generated. CMakeFiles/open_spiel_core.dir/build.make:75: recipe for target 'CMakeFiles/open_spiel_core.dir/spiel.cc.o' failed make[2]: [CMakeFiles/open_spiel_core.dir/spiel.cc.o] Error 1 make[2]: Waiting for unfinished jobs.... In file included from /home/ken/project/open_spiel/open_spiel/spiel_bots.cc:15: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/spiel_bots.h:18: In file included from /home/ken/project/open_spiel/open_spiel/../open_spiel/policy.h:23:

lanctot commented 4 years ago

It is not finding the optional header, which is a standard C++17 header. Probably because you need to rerun the cmake command to point to your upgraded clang instead of the old one.

The default compilers on Ubuntu 16.04 are too old for our code, since we are using C++17.

KK666-AI commented 4 years ago

New errors:

[ 36%] Building CXX object abseil-cpp/absl/flags/CMakeFiles/absl_flags_program_name.dir/internal/program_name.cc.o /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/random/internal/distribution_test_util.cc:75:32: error: 'FormatSpecTemplate' is unavailable: Format std::string is not constexpr. return os << absl::StrFormat("mean=%f, stddev=%f, skewness=%f, kurtosis=%f", ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/strings/internal/str_format/bind.h:82:3: note: 'FormatSpecTemplate' has been explicitly marked unavailable here FormatSpecTemplate(...) // NOLINT ^ 1 error generated. abseil-cpp/absl/random/CMakeFiles/absl_random_internal_distribution_test_util.dir/build.make:75: recipe for target 'abseil-cpp/absl/random/CMakeFiles/absl_random_internal_distribution_test_util.dir/internal/distribution_test_util.cc.o' failed make[2]: [abseil-cpp/absl/random/CMakeFiles/absl_random_internal_distribution_test_util.dir/internal/distribution_test_util.cc.o] Error 1 CMakeFiles/Makefile2:2000: recipe for target 'abseil-cpp/absl/random/CMakeFiles/absl_random_internal_distribution_test_util.dir/all' failed make[1]: [abseil-cpp/absl/random/CMakeFiles/absl_random_internal_distribution_test_util.dir/all] Error 2 make[1]: Waiting for unfinished jobs.... /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:178:23: error: 'FormatSpecTemplate' is unavailable: Format std::string is not constexpr. absl::StrFormat("%.g", std::numeric_limits::digits10, v); ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:192:39: note: in instantiation of function template specialization 'absl::flags_internal::UnparseFloatingPointVal' requested here std::string Unparse(float v) { return UnparseFloatingPointVal(v); } ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/strings/internal/str_format/bind.h:82:3: note: 'FormatSpecTemplate' has been explicitly marked unavailable here FormatSpecTemplate(...) // NOLINT ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:190:26: error: 'FormatSpecTemplate' is unavailable: Format std::string is not constexpr. return absl::StrFormat("%.g", std::numeric_limits::max_digits10, v); ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/strings/internal/str_format/bind.h:82:3: note: 'FormatSpecTemplate' has been explicitly marked unavailable here FormatSpecTemplate(...) // NOLINT ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:178:23: error: 'FormatSpecTemplate' is unavailable: Format std::string is not constexpr. absl::StrFormat("%.g", std::numeric_limits::digits10, v); ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:193:40: note: in instantiation of function template specialization 'absl::flags_internal::UnparseFloatingPointVal' requested here std::string Unparse(double v) { return UnparseFloatingPointVal(v); } ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/strings/internal/str_format/bind.h:82:3: note: 'FormatSpecTemplate' has been explicitly marked unavailable here FormatSpecTemplate(...) // NOLINT ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/flags/marshalling.cc:190:26: error: 'FormatSpecTemplate' is unavailable: Format std::string is not constexpr. return absl::StrFormat("%.g", std::numeric_limits::max_digits10, v); ^ /home/ken/project/open_spiel-master/open_spiel/abseil-cpp/absl/strings/internal/str_format/bind.h:82:3: note: 'FormatSpecTemplate' has been explicitly marked unavailable here FormatSpecTemplate(...) // NOLINT ^ 4 errors generated. abseil-cpp/absl/flags/CMakeFiles/absl_flags_marshalling.dir/build.make:62: recipe for target 'abseil-cpp/absl/flags/CMakeFiles/absl_flags_marshalling.dir/marshalling.cc.o' failed make[2]: [abseil-cpp/absl/flags/CMakeFiles/absl_flags_marshalling.dir/marshalling.cc.o] Error 1 CMakeFiles/Makefile2:1722: recipe for target 'abseil-cpp/absl/flags/CMakeFiles/absl_flags_marshalling.dir/all' failed make[1]: [abseil-cpp/absl/flags/CMakeFiles/absl_flags_marshalling.dir/all] Error 2 [ 36%] Linking CXX static library libabsl_absl_random_seed_sequences.a [ 36%] Built target absl_random_seed_sequences [ 36%] Linking CXX static library libabsl_absl_flags_program_name.a [ 36%] Built target absl_flags_program_name [ 36%] Linking CXX static library libabsl_absl_hashtablez_sampler.a [ 36%] Built target absl_hashtablez_sampler Makefile:94: recipe for target 'all' failed make: [all] Error 2

lanctot commented 4 years ago

Bug (missing header) was fixed in a recent commit, so removing the label.

KK666-AI commented 4 years ago

Dear @lanctot ,

I update by linux system to Ubuntu 18.04 and install the open_spiel according to the tutorial in arxiv. It seems that the package in my system is installed successfully. However, some tests are not passed, I list the logs as follows.

I will try to do some experiments on your package. Thanks very much for your help.

57% tests passed, 56 tests failed out of 129

Total Test time (real) = 217.28 sec

The following tests FAILED: 65 - python_api_test (Failed) 66 - python_playthrough_test (Failed) 67 - python_action_value_test (Failed) 68 - python_action_value_vs_best_response_test (Failed) 69 - python_best_response_test (Failed) 70 - python_cfr_br_test (Failed) 71 - python_cfr_test (Failed) 72 - python_deep_cfr_test (Failed) 73 - python_discounted_cfr_test (Failed) 74 - python_dqn_test (Failed) 75 - python_eva_test (Failed) 76 - python_evaluate_bots_test (Failed) 77 - python_expected_game_score_test (Failed) 78 - python_exploitability_descent_test (Failed) 79 - python_exploitability_test (Failed) 80 - python_fictitious_play_test (Failed) 81 - python_generate_playthrough_test (Failed) 82 - python_get_all_states_test (Failed) 83 - python_rl_losses_test (Failed) 84 - python_lp_solver_test (Failed) 85 - python_masked_softmax_test (Failed) 86 - python_mcts_test (Failed) 87 - python_minimax_test (Failed) 88 - python_neurd_test (Failed) 89 - python_nfsp_test (Failed) 90 - python_outcome_sampling_mccfr_test (Failed) 91 - python_policy_aggregator_test (Failed) 92 - python_policy_gradient_test (Failed) 93 - python_projected_replicator_dynamics_test (Failed) 94 - python_generalized_psro_test (Failed) 95 - python_rectified_nash_response_test (Failed) 96 - python_random_agent_test (Failed) 97 - python_rcfr_test (Failed) 98 - python_sequence_form_lp_test (Failed) 99 - python_value_iteration_test (Failed) 100 - python_bluechip_bridge_uncontested_bidding_test (Failed) 101 - python_uniform_random_test (Failed) 102 - python_alpharank_test (Failed) 103 - python_alpharank_visualizer_test (Failed) 104 - python_dynamics_test (Failed) 105 - python_heuristic_payoff_table_test (Failed) 106 - python_utils_test (Failed) 107 - python_visualization_test (Failed) 108 - python_catch_test (Failed) 109 - python_cliff_walking_test (Failed) 110 - python_data_test (Failed) 111 - python_tic_tac_toe_test (Failed) 112 - python_bot_test (Failed) 113 - python_games_sim_test (Failed) 114 - python_matrix_game_utils_test (Failed) 115 - python_policy_test (Failed) 116 - python_pyspiel_test (Failed) 117 - python_rl_environment_test (Failed) 118 - python_tensor_game_utils_test (Failed) 119 - python_examples_bridge_supervised_learning (Failed) 121 - data_logger_test (Failed) Errors while running CTest

KK666-AI commented 4 years ago

I have already solved all the problems and now all the test cases have passed.

I close this issue. Thanks all. @lanctot @elkhrt

lanctot commented 4 years ago

Great to hear @lihuiknight , thanks for letting us know!

chenxli commented 4 years ago

I am meeting the same problem with you , could you please tell me how you fixed it?