• Community
  • problem on M1 building wheels for depthai

Things looking good so far however it looks like the arm installed refers to python 3.11 based on what was posted above. I'll start with this and try python 3.11 next. Not sure if it's important to upgrade pip or if that messes with dependencies and whatnot. Will try next as well.

amandaperry@Amandas-MBP people % python3 -c 'import platform; print(platform.machine())'

arm64

amandaperry@Amandas-MBP people % curl https://www.python.org/ftp/python/3.9.13/python-3.9.13-macos11.pkg --output p3.9.pkg

% Total % Received % Xferd Average Speed Time Time Time Current

                             Dload  Upload   Total   Spent    Left  Speed

100 37.0M 100 37.0M 0 0 25.1M 0 0:00:01 0:00:01 --:--:-- 25.1M

amandaperry@Amandas-MBP people % sudo installer -pkg p3.9.pkg -target /

Password:

installer: Package name is Python

installer: Upgrading at base path /

installer: The upgrade was successful.

amandaperry@Amandas-MBP people % python3 -m pip install depthai

Collecting depthai

Downloading depthai-2.21.2.0-cp311-cp311-macosx_11_0_arm64.whl (10.0 MB)

 ━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 10.0/10.0 MB 19.5 MB/s eta 0:00:00

Installing collected packages: depthai

Successfully installed depthai-2.21.2.0

[notice] A new release of pip available: 22.3.1 -> 23.1.2

[notice] To update, run: pip3 install --upgrade pip

Similar result. Comes down to needing CMake:

Building wheels for collected packages: depthai
Building wheel for depthai (pyproject.toml) ... error
error: subprocess-exited-with-error
× Building wheel for depthai (pyproject.toml) did not run successfully.
│ exit code: 1
╰─> [71 lines of output]
….
RuntimeError: CMake must be installed to build the following extensions: depthai
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
ERROR: Failed building wheel for depthai
Failed to build depthai
ERROR: Could not build wheels for depthai, which is required to install pyproject.toml-based projects

looked up installing CMake: had me install MacPorts then install port cmake. Still get the error:

RuntimeError: CMake must be installed to build the following extensions: depthai

halp

12 days later

Hi,

Did you solve the "Building wheel for depthai (pyproject.toml) ... error" issue? I am having the similar problem but I am using Windows11.

/BR

Wu Bi

    Hi biwu
    Could you post the exact logs you are getting? Also, what depthai version are you building the wheels on (commit number/ branch)?

    Thanks,
    Jaka

    • biwu replied to this.

      jakaskerl

      Hi, Jaka,

      Sorry, indeed, the version number I used/copied was too old. So, what I did was remove the version number and it works!

      removed "==2.17.0.0"

      Now I am running into another problem:

      I am practicing "record and replay" example, and I got this error when running "record.py":

      Could you point out where did I go wrong?

      Thanks!

      /BR

      Wu Bi