ds4dm / ecole

Extensible Combinatorial Optimization Learning Environments
https://www.ecole.ai
BSD 3-Clause "New" or "Revised" License
313 stars 69 forks source link

installation error #320

Open AyachiOmarChaima opened 2 years ago

AyachiOmarChaima commented 2 years ago

Describe the bug

<-- when I install ecole, I got this error

Collecting ecole
  Using cached ecole-0.8.0.tar.gz (376 kB)
  Installing build dependencies ... done
  Getting requirements to build wheel ... done
  Preparing metadata (pyproject.toml) ... done
Requirement already satisfied: numpy>=1.4 in ./lib-eco/lib-eco/lib/python3.9/site-packages (from ecole) (1.22.3)
Building wheels for collected packages: ecole
  Building wheel for ecole (pyproject.toml) ... error
  error: subprocess-exited-with-error

  × Building wheel for ecole (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> [92 lines of output]
      Not searching for unused variables given on the command line.
      -- The CXX compiler identification is GNU 9.4.0
      -- Detecting CXX compiler ABI info
      -- Detecting CXX compiler ABI info - done
      -- Check for working CXX compiler: /usr/bin/c++ - skipped
      -- Detecting CXX compile features
      -- Detecting CXX compile features - done
      -- Configuring done
      -- Generating done
      -- Build files have been written to: /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_cmake_test_compile/build
      -- Ecole version 0.8.0
      -- The CXX compiler identification is GNU 9.4.0
      -- Detecting CXX compiler ABI info
      -- Detecting CXX compiler ABI info - done
      -- Check for working CXX compiler: /usr/bin/c++ - skipped
      -- Detecting CXX compile features
      -- Detecting CXX compile features - done
      -- IPO enabled
      -- Performing Test COMPILER_HAS_HIDDEN_VISIBILITY
      -- Performing Test COMPILER_HAS_HIDDEN_VISIBILITY - Success
      -- Performing Test COMPILER_HAS_HIDDEN_INLINE_VISIBILITY
      -- Performing Test COMPILER_HAS_HIDDEN_INLINE_VISIBILITY - Success
      -- Performing Test COMPILER_HAS_DEPRECATED_ATTR
      -- Performing Test COMPILER_HAS_DEPRECATED_ATTR - Success
      -- Downloading xtl
      -- Building xtl
      -- Downloading xsimd
      -- Building xsimd
      -- Downloading xtensor
      -- Building xtensor
      -- Performing Test arch_native_supported
      -- Performing Test arch_native_supported - Success
      -- Downloading span-lite
      -- Building span-lite
      -- Downloading range-v3
      -- Building range-v3
      -- Found fmt
      -- Downloading robin_hood
      -- Building robin_hood
      CMake Error at libecole/CMakeLists.txt:98 (find_package):
        Could not find a configuration file for package "SCIP" that is compatible
        with requested version "8".
        The following configuration files were considered but not accepted:
          /home/chaima/anaconda3/lib/cmake/scip/scip-config.cmake, version: 7.0.3

      -- Configuring incomplete, errors occurred!
      See also "/tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_skbuild/linux-x86_64-3.9/cmake-build/CMakeFiles/CMakeOutput.log".
        File "/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/skbuild/setuptools_wrap.py", line 588, in setup
          env = cmkr.configure(cmake_args,
        File "/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/skbuild/cmaker.py", line 289, in configure
          raise SKBuildError(

      --------------------------------------------------------------------------------
      -- Trying "Ninja" generator
      --------------------------------
      ---------------------------
      ----------------------
      -----------------
      ------------
      -------
      --
      --
      -------
      ------------
      -----------------
      ----------------------
      ---------------------------
      --------------------------------
      -- Trying "Ninja" generator - success
      --------------------------------------------------------------------------------

      Configuring Project
        Working directory:
          /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_skbuild/linux-x86_64-3.9/cmake-build
        Command:
          cmake /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a -G Ninja -DCMAKE_INSTALL_PREFIX:PATH=/tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_skbuild/linux-x86_64-3.9/cmake-install/python/ecole/src/ecole -DPYTHON_EXECUTABLE:FILEPATH=/home/chaima/lib-eco/lib-eco/bin/python -DPYTHON_VERSION_STRING:STRING=3.9.10 -DPYTHON_INCLUDE_DIR:PATH=/usr/local/include/python3.9 -DPYTHON_LIBRARY:FILEPATH=/usr/local/lib/libpython3.9.a -DSKBUILD:INTERNAL=TRUE -DCMAKE_MODULE_PATH:PATH=/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/skbuild/resources/cmake -DCMAKE_MAKE_PROGRAM:FILEPATH=/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/ninja/data/bin/ninja -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_INSTALL_BINDIR=bin -DCMAKE_INSTALL_INCLUDEDIR=include '-DECOLE_PY_EXT_INSTALL_LIBDIR='"'"'.'"'"'' '-DECOLE_PY_EXT_INSTALL_RPATH=\${ORIGIN}/lib' -DCMAKE_BUILD_TYPE:STRING=Release

      Traceback (most recent call last):

      An error occurred while configuring with CMake.
        Command:
          cmake /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a -G Ninja -DCMAKE_INSTALL_PREFIX:PATH=/tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_skbuild/linux-x86_64-3.9/cmake-install/python/ecole/src/ecole -DPYTHON_EXECUTABLE:FILEPATH=/home/chaima/lib-eco/lib-eco/bin/python -DPYTHON_VERSION_STRING:STRING=3.9.10 -DPYTHON_INCLUDE_DIR:PATH=/usr/local/include/python3.9 -DPYTHON_LIBRARY:FILEPATH=/usr/local/lib/libpython3.9.a -DSKBUILD:INTERNAL=TRUE -DCMAKE_MODULE_PATH:PATH=/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/skbuild/resources/cmake -DCMAKE_MAKE_PROGRAM:FILEPATH=/tmp/pip-build-env-hsmppl6_/overlay/lib/python3.9/site-packages/ninja/data/bin/ninja -DBUILD_SHARED_LIBS=ON -DCMAKE_INSTALL_LIBDIR=lib -DCMAKE_INSTALL_BINDIR=bin -DCMAKE_INSTALL_INCLUDEDIR=include '-DECOLE_PY_EXT_INSTALL_LIBDIR='"'"'.'"'"'' '-DECOLE_PY_EXT_INSTALL_RPATH=\${ORIGIN}/lib' -DCMAKE_BUILD_TYPE:STRING=Release
        Source directory:
          /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a
        Working directory:
          /tmp/pip-install-n11psw03/ecole_8edeb1fd300841309626fab026bdaa1a/_skbuild/linux-x86_64-3.9/cmake-build
      Please see CMake's output for more information.
      [end of output]

  note: This error originates from a subprocess, and is likely not a problem with pip.
  ERROR: Failed building wheel for ecole
Failed to build ecole
ERROR: Could not build wheels for ecole, which is required to install pyproject.toml-based projects

I used different version of python but it shown me same error PLz if can someone help me to know why this error and how can I resolved it --->

Setting

To Reproduce

Expected behavior

Additional context

AntoinePrv commented 2 years ago

Hi @AyachiOmarChaima ,

The error you are looking for is here:

CMake Error at libecole/CMakeLists.txt:98 (find_package):
        Could not find a configuration file for package "SCIP" that is compatible
        with requested version "8".

The installation script (CMake in particular) cannot find SCIP8. Either you have SCIP7, or you installed SCIP in a non-standard location without telling the script where that is. In the latter case, you need to play with a command like (from the install doc):

CMAKE_ARGS="-DSCIP_DIR=path/to/lib/cmake/scip -DCMAKE_INSTALL_RPATH_USE_LINK_PATH=ON" python -m pip install ecole

This is a more complex way of installing Ecole, that's why we recommend using conda.