Skip to content
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

Draft: Python bindings using nanobind #8

Draft
wants to merge 4 commits into
base: master
Choose a base branch
from

Conversation

diiigle
Copy link

@diiigle diiigle commented Feb 7, 2023

I started adding python bindings based on the nanobind example.

Supplied bindings:

  • the high level BSDF class (RGB for now, but can be trivially switched for the spectral version)

Missing bindings:

  • Warp2D
  • spectral variants (ideally alongside RGB)

So far this is a quick and dirty job, but if there is interest I can add the missing bits as well.

@soufianekhiat
Copy link

Tested on collab:

# merged PR on this fork:
!git clone https://github.com/soufianekhiat/brdf-loader.git

run:

import sys
!{sys.executable} -m pip install brdf-loader/. -v

Results:

Using pip 23.1.2 from /usr/local/lib/python3.10/dist-packages/pip (python 3.10)
Processing ./brdf-loader
  Running command pip subprocess to install build dependencies
  Using pip 23.1.2 from /usr/local/lib/python3.10/dist-packages/pip (python 3.10)
  Collecting setuptools>=42
    Using cached setuptools-69.5.1-py3-none-any.whl (894 kB)
  Collecting wheel
    Using cached wheel-0.43.0-py3-none-any.whl (65 kB)
  Collecting scikit-build==0.14.0
    Using cached scikit_build-0.14.0-py2.py3-none-any.whl (76 kB)
  Collecting cmake>=3.18
    Using cached cmake-3.29.2-py3-none-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (26.7 MB)
  Collecting nanobind>=0.0.9
    Using cached nanobind-1.9.2-py3-none-any.whl (192 kB)
  Collecting ninja
    Using cached ninja-1.11.1.1-py2.py3-none-manylinux1_x86_64.manylinux_2_5_x86_64.whl (307 kB)
  Collecting distro (from scikit-build==0.14.0)
    Using cached distro-1.9.0-py3-none-any.whl (20 kB)
  Collecting packaging (from scikit-build==0.14.0)
    Using cached packaging-24.0-py3-none-any.whl (53 kB)
  Installing collected packages: ninja, nanobind, wheel, setuptools, packaging, distro, cmake, scikit-build
    Creating /tmp/pip-build-env-9vsatusw/overlay/local/bin
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/ninja to 755
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/wheel to 755
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/distro to 755
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/cmake to 755
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/cpack to 755
    changing mode of /tmp/pip-build-env-9vsatusw/overlay/local/bin/ctest to 755
  ERROR: pip's dependency resolver does not currently take into account all the packages that are installed. This behaviour is the source of the following dependency conflicts.
  ipython 7.34.0 requires jedi>=0.16, which is not installed.
  Successfully installed cmake-3.29.2 distro-1.9.0 nanobind-1.9.2 ninja-1.11.1.1 packaging-24.0 scikit-build-0.14.0 setuptools-69.5.1 wheel-0.43.0
  Installing build dependencies ... done
  Running command Getting requirements to build wheel
  running egg_info
  writing python/brdf_loader.egg-info/PKG-INFO
  writing dependency_links to python/brdf_loader.egg-info/dependency_links.txt
  writing top-level names to python/brdf_loader.egg-info/top_level.txt
  reading manifest file 'python/brdf_loader.egg-info/SOURCES.txt'
  adding license file 'LICENSE.md'
  writing manifest file 'python/brdf_loader.egg-info/SOURCES.txt'
  Getting requirements to build wheel ... done
  Running command Preparing metadata (pyproject.toml)
  running dist_info
  creating /tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info
  writing /tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/PKG-INFO
  writing dependency_links to /tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/dependency_links.txt
  writing top-level names to /tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/top_level.txt
  writing manifest file '/tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/SOURCES.txt'
  reading manifest file '/tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/SOURCES.txt'
  adding license file 'LICENSE.md'
  writing manifest file '/tmp/pip-modern-metadata-s6j9q2jl/brdf_loader.egg-info/SOURCES.txt'
  creating '/tmp/pip-modern-metadata-s6j9q2jl/brdf_loader-0.0.1.dist-info'
  Preparing metadata (pyproject.toml) ... done
Building wheels for collected packages: brdf-loader
  Running command Building wheel for brdf-loader (pyproject.toml)
  CMake Deprecation Warning at CMakeLists.txt:1 (cmake_minimum_required):
    Compatibility with CMake < 3.5 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.

  Not searching for unused variables given on the command line.

  -- The C compiler identification is GNU 11.4.0
  -- Detecting C compiler ABI info
  -- Detecting C compiler ABI info - done
  -- Check for working C compiler: /usr/bin/cc - skipped
  -- Detecting C compile features
  -- Detecting C compile features - done
  -- The CXX compiler identification is GNU 11.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 (0.5s)
  -- Generating done (0.0s)
  -- Build files have been written to: /content/brdf-loader/_cmake_test_compile/build
  CMake Warning (dev) at CMakeLists.txt:1 (project):
    cmake_minimum_required() should be called prior to this top-level project()
    call.  Please see the cmake-commands(7) manual for usage documentation of
    both commands.
  This warning is for project developers.  Use -Wno-dev to suppress it.

  -- Configuring done (0.1s)
  -- Generating done (0.0s)
  -- Build files have been written to: /content/brdf-loader/_skbuild/linux-x86_64-3.10/cmake-build
  [1/14] Building CXX object CMakeFiles/nanobind-static.dir/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/src/nb_internals.cpp.o
  [2/14] Building CXX object CMakeFiles/brdf_loader_ext.dir/python/brdf_loader_ext.cpp.o
  FAILED: CMakeFiles/brdf_loader_ext.dir/python/brdf_loader_ext.cpp.o
  /usr/bin/c++ -Dbrdf_loader_ext_EXPORTS -I/content/brdf-loader -I/usr/include/python3.10 -I/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include -O3 -DNDEBUG -fPIC -fvisibility=hidden -fno-stack-protector -Os -ffunction-sections -fdata-sections -MD -MT CMakeFiles/brdf_loader_ext.dir/python/brdf_loader_ext.cpp.o -MF CMakeFiles/brdf_loader_ext.dir/python/brdf_loader_ext.cpp.o.d -o CMakeFiles/brdf_loader_ext.dir/python/brdf_loader_ext.cpp.o -c /content/brdf-loader/python/brdf_loader_ext.cpp
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h: In instantiation of ‘static void nanobind::init<Args>::execute(Class&, const Extra& ...) [with Class = nanobind::class_<powitacq_rgb::Vector<float, 2> >; Extra = {}; Args = {std::array<float, 2>}]’:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:460:21:   required from ‘nanobind::class_<T, Ts>& nanobind::class_<T, Ts>::def(nanobind::init<Args ...>&&, const Extra& ...) [with Args = {std::array<float, 2>}; Extra = {}; T = powitacq_rgb::Vector<float, 2>; Ts = {}]’
  /content/brdf-loader/python/brdf_loader_ext.cpp:19:13:   required from ‘void bind_vector(Cls&) [with Type = float; long unsigned int Dim = 2; Cls = nanobind::class_<powitacq_rgb::Vector<float, 2> >]’
  /content/brdf-loader/python/brdf_loader_ext.cpp:39:26:   required from here
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:17: error: no matching function for call to ‘powitacq_rgb::Vector<float, 2>::Vector(<brace-enclosed initializer list>)’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:84:31: note: candidate: ‘template<class Type2> powitacq_rgb::Vector<Type, Dim>::Vector(const powitacq_rgb::Vector<Type2, Dim>&) [with Type2 = Type2; Type = float; long unsigned int Dim = 2]’
     84 |     template <typename Type2> Vector(const Vector<Type2, Dim> &v) {
        |                               ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:84:31: note:   template argument deduction/substitution failed:
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:17: note:   ‘std::array<float, 2>’ is not derived from ‘const powitacq_rgb::Vector<Type2, 2>’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:81:5: note: candidate: ‘template<class Arg, class ... Args, typename std::enable_if<(sizeof... (Args) >= 1), int>::type <anonymous> > powitacq_rgb::Vector<Type, Dim>::Vector(Arg, Args ...) [with Arg = Arg; Args = {Args ...}; typename std::enable_if<(sizeof... (Args) >= 1), int>::type <anonymous> = <anonymous>; Type = float; long unsigned int Dim = 2]’
     81 |     Vector(Arg arg, Args... args) : values { (Type) arg, (Type) args... } { }
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:81:5: note:   template argument deduction/substitution failed:
  /content/brdf-loader/powitacq_rgb.h:80:95: error: no type named ‘type’ in ‘struct std::enable_if<false, int>’
     80 |     template <typename Arg, typename... Args, std::enable_if_t<(sizeof...(Args) >= 1), int> = 0>
        |                                                                                               ^
  /content/brdf-loader/powitacq_rgb.h:74:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector(std::array<_Tp, _Nm>&) [with Type = float; long unsigned int Dim = 2]’ (near match)
     74 |     Vector(std::array<Type, Dim>& v) {
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:74:5: note:   conversion of argument 1 would be ill-formed:
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:43: error: cannot bind non-const lvalue reference of type ‘std::array<float, 2>&’ to an rvalue of type ‘std::array<float, 2>’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:68:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector(Type) [with Type = float; long unsigned int Dim = 2]’
     68 |     Vector(Type v) {
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:68:17: note:   no known conversion for argument 1 from ‘std::array<float, 2>’ to ‘float’
     68 |     Vector(Type v) {
        |            ~~~~~^
  /content/brdf-loader/powitacq_rgb.h:65:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector() [with Type = float; long unsigned int Dim = 2]’
     65 |     Vector() = default;
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:65:5: note:   candidate expects 0 arguments, 1 provided
  /content/brdf-loader/powitacq_rgb.h:64:45: note: candidate: ‘constexpr powitacq_rgb::Vector<float, 2>::Vector(const powitacq_rgb::Vector<float, 2>&)’
     64 | template <typename Type, size_t Dim> struct Vector {
        |                                             ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:64:45: note:   no known conversion for argument 1 from ‘std::array<float, 2>’ to ‘const powitacq_rgb::Vector<float, 2>&’
  /content/brdf-loader/powitacq_rgb.h:64:45: note: candidate: ‘constexpr powitacq_rgb::Vector<float, 2>::Vector(powitacq_rgb::Vector<float, 2>&&)’
  /content/brdf-loader/powitacq_rgb.h:64:45: note:   no known conversion for argument 1 from ‘std::array<float, 2>’ to ‘powitacq_rgb::Vector<float, 2>&&’
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h: In instantiation of ‘static void nanobind::init<Args>::execute(Class&, const Extra& ...) [with Class = nanobind::class_<powitacq_rgb::Vector<float, 3> >; Extra = {}; Args = {std::array<float, 3>}]’:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:460:21:   required from ‘nanobind::class_<T, Ts>& nanobind::class_<T, Ts>::def(nanobind::init<Args ...>&&, const Extra& ...) [with Args = {std::array<float, 3>}; Extra = {}; T = powitacq_rgb::Vector<float, 3>; Ts = {}]’
  /content/brdf-loader/python/brdf_loader_ext.cpp:19:13:   required from ‘void bind_vector(Cls&) [with Type = float; long unsigned int Dim = 3; Cls = nanobind::class_<powitacq_rgb::Vector<float, 3> >]’
  /content/brdf-loader/python/brdf_loader_ext.cpp:42:26:   required from here
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:17: error: no matching function for call to ‘powitacq_rgb::Vector<float, 3>::Vector(<brace-enclosed initializer list>)’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:84:31: note: candidate: ‘template<class Type2> powitacq_rgb::Vector<Type, Dim>::Vector(const powitacq_rgb::Vector<Type2, Dim>&) [with Type2 = Type2; Type = float; long unsigned int Dim = 3]’
     84 |     template <typename Type2> Vector(const Vector<Type2, Dim> &v) {
        |                               ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:84:31: note:   template argument deduction/substitution failed:
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:17: note:   ‘std::array<float, 3>’ is not derived from ‘const powitacq_rgb::Vector<Type2, 3>’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                 ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:81:5: note: candidate: ‘template<class Arg, class ... Args, typename std::enable_if<(sizeof... (Args) >= 1), int>::type <anonymous> > powitacq_rgb::Vector<Type, Dim>::Vector(Arg, Args ...) [with Arg = Arg; Args = {Args ...}; typename std::enable_if<(sizeof... (Args) >= 1), int>::type <anonymous> = <anonymous>; Type = float; long unsigned int Dim = 3]’
     81 |     Vector(Arg arg, Args... args) : values { (Type) arg, (Type) args... } { }
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:81:5: note:   template argument deduction/substitution failed:
  /content/brdf-loader/powitacq_rgb.h:80:95: error: no type named ‘type’ in ‘struct std::enable_if<false, int>’
     80 |     template <typename Arg, typename... Args, std::enable_if_t<(sizeof...(Args) >= 1), int> = 0>
        |                                                                                               ^
  /content/brdf-loader/powitacq_rgb.h:74:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector(std::array<_Tp, _Nm>&) [with Type = float; long unsigned int Dim = 3]’ (near match)
     74 |     Vector(std::array<Type, Dim>& v) {
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:74:5: note:   conversion of argument 1 would be ill-formed:
  In file included from /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nanobind.h:52,
                   from /content/brdf-loader/python/brdf_loader_ext.cpp:1:
  /tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/include/nanobind/nb_class.h:318:43: error: cannot bind non-const lvalue reference of type ‘std::array<float, 3>&’ to an rvalue of type ‘std::array<float, 3>’
    318 |                 new ((void *) v.p) Alias{ (detail::forward_t<Args>) args... };
        |                                           ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  In file included from /content/brdf-loader/python/brdf_loader_ext.cpp:6:
  /content/brdf-loader/powitacq_rgb.h:68:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector(Type) [with Type = float; long unsigned int Dim = 3]’
     68 |     Vector(Type v) {
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:68:17: note:   no known conversion for argument 1 from ‘std::array<float, 3>’ to ‘float’
     68 |     Vector(Type v) {
        |            ~~~~~^
  /content/brdf-loader/powitacq_rgb.h:65:5: note: candidate: ‘powitacq_rgb::Vector<Type, Dim>::Vector() [with Type = float; long unsigned int Dim = 3]’
     65 |     Vector() = default;
        |     ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:65:5: note:   candidate expects 0 arguments, 1 provided
  /content/brdf-loader/powitacq_rgb.h:64:45: note: candidate: ‘constexpr powitacq_rgb::Vector<float, 3>::Vector(const powitacq_rgb::Vector<float, 3>&)’
     64 | template <typename Type, size_t Dim> struct Vector {
        |                                             ^~~~~~
  /content/brdf-loader/powitacq_rgb.h:64:45: note:   no known conversion for argument 1 from ‘std::array<float, 3>’ to ‘const powitacq_rgb::Vector<float, 3>&’
  /content/brdf-loader/powitacq_rgb.h:64:45: note: candidate: ‘constexpr powitacq_rgb::Vector<float, 3>::Vector(powitacq_rgb::Vector<float, 3>&&)’
  /content/brdf-loader/powitacq_rgb.h:64:45: note:   no known conversion for argument 1 from ‘std::array<float, 3>’ to ‘powitacq_rgb::Vector<float, 3>&&’
  [3/14] Building CXX object CMakeFiles/nanobind-static.dir/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/src/nb_func.cpp.o
  [4/14] Building CXX object CMakeFiles/nanobind-static.dir/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/nanobind/src/nb_type.cpp.o
  ninja: build stopped: subcommand failed.
    File "/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/skbuild/setuptools_wrap.py", line 645, in setup
      cmkr.make(make_args, install_target=cmake_install_target, env=env)
    File "/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/skbuild/cmaker.py", line 660, in make
      self.make_impl(clargs=clargs, config=config, source_dir=source_dir, install_target=install_target, env=env)
    File "/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/skbuild/cmaker.py", line 684, in make_impl
      raise SKBuildError(


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

  Configuring Project
    Working directory:
      /content/brdf-loader/_skbuild/linux-x86_64-3.10/cmake-build
    Command:
      cmake /content/brdf-loader -G Ninja -DCMAKE_INSTALL_PREFIX:PATH=/content/brdf-loader/_skbuild/linux-x86_64-3.10/cmake-install/python/brdf_loader -DPYTHON_EXECUTABLE:FILEPATH=/usr/bin/python3 -DPYTHON_VERSION_STRING:STRING=3.10.12 -DPYTHON_INCLUDE_DIR:PATH=/usr/include/python3.10 -DPYTHON_LIBRARY:FILEPATH=/usr/lib/x86_64-linux-gnu/libpython3.10.so -DSKBUILD:INTERNAL=TRUE -DCMAKE_MODULE_PATH:PATH=/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/skbuild/resources/cmake -DCMAKE_MAKE_PROGRAM:FILEPATH=/tmp/pip-build-env-9vsatusw/overlay/local/lib/python3.10/dist-packages/ninja/data/bin/ninja -DCMAKE_BUILD_TYPE:STRING=Release

  Traceback (most recent call last):

  An error occurred while building with CMake.
    Command:
      cmake --build . --target install --config Release --
    Install target:
      install
    Source directory:
      /content/brdf-loader
    Working directory:
      /content/brdf-loader/_skbuild/linux-x86_64-3.10/cmake-build
  Please check the install target is valid and see CMake's output for more information.
  error: subprocess-exited-with-error
  
  × Building wheel for brdf-loader (pyproject.toml) did not run successfully.
  │ exit code: 1
  ╰─> See above for output.
  
  note: This error originates from a subprocess, and is likely not a problem with pip.
  full command: /usr/bin/python3 /usr/local/lib/python3.10/dist-packages/pip/_vendor/pyproject_hooks/_in_process/_in_process.py build_wheel /tmp/tmplxpc0r4l
  cwd: /content/brdf-loader
  Building wheel for brdf-loader (pyproject.toml) ... error
  ERROR: Failed building wheel for brdf-loader
Failed to build brdf-loader
ERROR: Could not build wheels for brdf-loader, which is required to install pyproject.toml-based projects

Hope that help to have this PR going forward

@soufianekhiat
Copy link

Added comment to had the PR working. Tested on collab.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants