DepthAI Python Library
Project description
DepthAI Python Library
Python bindings for C++ depthai-core library
Documentation
Documentation is available over at Luxonis DepthAI API
Installation
Prebuilt wheels are available in Luxonis repository Make sure pip is upgraded
python3 -m pip install -U pip
python3 -m pip install --extra-index-url https://artifacts.luxonis.com/artifactory/luxonis-python-snapshot-local/ depthai
Building from source
Dependencies
- cmake >= 3.4
- C++14 compiler (clang, gcc, msvc, ...)
- Python
Along these, dependencies of depthai-core are also required See: depthai-core dependencies
Building
To build a shared library from source perform the following:
mkdir build && cd build
cmake ..
cmake --build . --parallel
To build a wheel, execute the following
python3 -m pip wheel . -w wheelhouse
Tested platforms
- Windows 10
- Ubuntu 16.04, 18.04;
- Raspbian 10;
- macOS 10.14.6, 10.15.4;
Troubleshooting
Relocation link error
Build failure on Ubuntu 18.04 ("relocation ..." link error) with gcc 7.4.0 (default) - issue #3
-
the solution was to upgrade gcc to version 8:
sudo apt install g++-8 sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-8 70 sudo update-alternatives --install /usr/bin/g++ g++ /usr/bin/g++-8 70
Hunter
Hunter is a CMake-only dependency manager for C/C++ projects.
If you are stuck with error message which mentions external libraries (subdirectory of .hunter
) like the following:
/usr/bin/ld: /home/[user]/.hunter/_Base/062a19a/ccfed35/a84a713/Install/lib/liblzma.a(stream_flags_decoder.c.o): warning: relocation against `lzma_footer_magic' in read-only section `.text'
Try erasing the Hunter cache folder.
Linux/MacOS:
rm -r ~/.hunter
Windows:
del C:/.hunter
or
del C:/[user]/.hunter
LTO - link time optimization
If following message appears:
lto1: internal compiler error: in add_symbol_to_partition_1, at lto/lto-partition.c:152
Please submit a full bug report,
with preprocessed source if appropriate.
See <file:///usr/share/doc/gcc-10/README.Bugs> for instructions.
lto-wrapper: fatal error: /usr/bin/c++ returned 1 exit status
compilation terminated.
/usr/bin/ld: error: lto-wrapper failed
collect2: error: ld returned 1 exit status
make[2]: *** [CMakeFiles/depthai.dir/build.make:227: depthai.cpython-38-x86_64-linux-gnu.so] Error 1
make[1]: *** [CMakeFiles/Makefile2:98: CMakeFiles/depthai.dir/all] Error 2
make: *** [Makefile:130: all] Error 2
One fix is to update linker: (In case you are on Ubuntu 20.04: /usr/bin/ld --version
: 2.30)
# Add to the end of /etc/apt/sources.list:
echo "deb http://ro.archive.ubuntu.com/ubuntu groovy main" >> /etc/apt/sources.list
# Replace ro with your countries local cache server (check the content of the file to find out which is)
# Not mandatory, but faster
sudo apt update
sudo apt install binutils
# Should upgrade to 2.35.1
# Check version:
/usr/bin/ld --version
# Output should be: GNU ld (GNU Binutils for Ubuntu) 2.35.1
# Revert /etc/apt/sources.list to previous state (comment out line) to prevent updating other packages.
sudo apt update
Another option is to use clang compiler:
sudo apt install clang-10
mkdir build && cd build
CC=clang-10 CXX=clang++-10 cmake ..
cmake --build . --parallel
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distributions
File details
Details for the file depthai-2.0.0.0.tar.gz
.
File metadata
- Download URL: depthai-2.0.0.0.tar.gz
- Upload date:
- Size: 227.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
59c9330a8c5a7bdb16f3ea16a0ed3a149950257e9ce494e03cf2ab8b5fe2381d
|
|
MD5 |
314dfefe2452b324580c4997d63c253b
|
|
BLAKE2b-256 |
b60d4b99fa07bbae65aac40b882b0ba979b1453233f8f1945982acfbe76bab02
|
File details
Details for the file depthai-2.0.0.0-cp39-cp39-win_amd64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp39-cp39-win_amd64.whl
- Upload date:
- Size: 31.6 MB
- Tags: CPython 3.9, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
aa887623d38e3e662540958ae7c045a698384ae30fc977e2876cf11c329f666c
|
|
MD5 |
3a36360940739b53c98dfe762b858e56
|
|
BLAKE2b-256 |
0d87c0bf54f66a0c8e9fa4f12b752868692a167177b562292daa25fffa123660
|
File details
Details for the file depthai-2.0.0.0-cp39-cp39-win32.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp39-cp39-win32.whl
- Upload date:
- Size: 27.4 MB
- Tags: CPython 3.9, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
28e08ccc7bd05588827f4a9e39afb7582ae44cca1acb228066710b6c950e0cba
|
|
MD5 |
015fcb64003f834b802c15c78023804d
|
|
BLAKE2b-256 |
1d57a45d89677ce4c775ae6a834a27d218584b51463bbb812b3c775b1c423634
|
File details
Details for the file depthai-2.0.0.0-cp39-cp39-manylinux2014_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp39-cp39-manylinux2014_x86_64.whl
- Upload date:
- Size: 5.0 MB
- Tags: CPython 3.9
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
8a434ab384a8609b9338e586999411da5b7a07603c1b5a5d133bbc287fd571c5
|
|
MD5 |
b5cde418991121a34920462b2dd5b627
|
|
BLAKE2b-256 |
375597527e4224180f66fa755ef096b5b8117e578cc6b3867608367ff7c213fa
|
File details
Details for the file depthai-2.0.0.0-cp39-cp39-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp39-cp39-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.9, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
4f8fd0db2049a91849bcde300f962028b3bb40601dde511afdb53dad55856c58
|
|
MD5 |
4a35dacef457e105a68195b10fc3753b
|
|
BLAKE2b-256 |
4352c4ca26901b79de9bc12f22ce1612b41c81cd7af010e35f01d9a56a4f98ab
|
File details
Details for the file depthai-2.0.0.0-cp38-cp38-win_amd64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp38-cp38-win_amd64.whl
- Upload date:
- Size: 31.6 MB
- Tags: CPython 3.8, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
1d21d0905380d0db7b03169772ee9be015decd65bee6847893e613ac9b25e921
|
|
MD5 |
6e60ef6e6d4ab6379f52bd122c6a7c16
|
|
BLAKE2b-256 |
3a3b18226f8a8424e2000f303a4256d5d8a3f0ecb237f23f3a442fe92242c34b
|
File details
Details for the file depthai-2.0.0.0-cp38-cp38-win32.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp38-cp38-win32.whl
- Upload date:
- Size: 27.4 MB
- Tags: CPython 3.8, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
edb16a6b8160c025cf38fb04527eb9089dbdf1d58b933b05ac675094ad76b83f
|
|
MD5 |
f68c22536f4d43b1b1d8378f35d58bdd
|
|
BLAKE2b-256 |
d123ad29821c9c9f8147e9681819c398ac2e01ec930272b831cde8adce1cbfab
|
File details
Details for the file depthai-2.0.0.0-cp38-cp38-manylinux2014_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp38-cp38-manylinux2014_x86_64.whl
- Upload date:
- Size: 5.0 MB
- Tags: CPython 3.8
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
d387c1bbff57d5a0c71d9ba88a19edfd065688980e1b3a2a2262309fc84fc7fe
|
|
MD5 |
057facf949cd83fe788c40472251fa00
|
|
BLAKE2b-256 |
d021cc3b8bd08679d4b750f42c5ea548a6df359d196a114998c2531f06ebe9da
|
File details
Details for the file depthai-2.0.0.0-cp38-cp38-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp38-cp38-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.8, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
9a90130271a5caee2463bf2828c28f5003632867617874a99c3adb4c9ef45208
|
|
MD5 |
7e249d34aefb9d9094604da938a75581
|
|
BLAKE2b-256 |
61e783e7ef660134fb279964b6540fa27b0b9f573f37b49d1ee3eac3b90db048
|
File details
Details for the file depthai-2.0.0.0-cp37-cp37m-win_amd64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp37-cp37m-win_amd64.whl
- Upload date:
- Size: 31.4 MB
- Tags: CPython 3.7m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
3ffc0a46094c66a5766e2ec1402e67e9dce3f5795e3d1ff92d03463ac6647ebf
|
|
MD5 |
3cea05421e2aa5ea0db0157fe5af5f76
|
|
BLAKE2b-256 |
486f4c08cf42039735e29e01c7facd498e1ef89e1c53e1e56a2ed794ce7a8937
|
File details
Details for the file depthai-2.0.0.0-cp37-cp37m-win32.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp37-cp37m-win32.whl
- Upload date:
- Size: 27.2 MB
- Tags: CPython 3.7m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
ff641f71bd282a7686785eb46942f4fef0887a83bd2b8b5b7a7175e93979d560
|
|
MD5 |
73e85b804d4cf5caa85efce9b8d3e7ce
|
|
BLAKE2b-256 |
ba562fdc7da0f1840ae0710994fb1770fc2ed1786f4bf559302e4e3ab8aaaafb
|
File details
Details for the file depthai-2.0.0.0-cp37-cp37m-manylinux2014_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp37-cp37m-manylinux2014_x86_64.whl
- Upload date:
- Size: 5.0 MB
- Tags: CPython 3.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
6d7b3e9d97558bfbf5cfa44db505fd24cd4e3a89856f9e1035588791839b6f83
|
|
MD5 |
cdea2fb1b8e6203f099913f62058c3c3
|
|
BLAKE2b-256 |
631d003fa3620527f21c2101ac8162b081b434b8297333f451c477af816cbab5
|
File details
Details for the file depthai-2.0.0.0-cp37-cp37m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp37-cp37m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.7m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
e5fd73ae18e68c49a106c26689d07573edff9c76bdd23ad4417e449c27077f7d
|
|
MD5 |
72ae1b64e27341fba334d3b202d5ef3e
|
|
BLAKE2b-256 |
54609e72b0a8390cd6316b59e56078d6e196ebad20878f0d5168a1c459cde7af
|
File details
Details for the file depthai-2.0.0.0-cp37-cp37m-linux_armv7l.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp37-cp37m-linux_armv7l.whl
- Upload date:
- Size: 5.8 MB
- Tags: CPython 3.7m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
c1834ca8ec2531a28a39ce2de7b02742029301ec00192c29c7b7818bf46fe385
|
|
MD5 |
e9e971c240c759b1618e34853f41fa49
|
|
BLAKE2b-256 |
f0323d15c00477e21d97fec14355e1b53e78f04c22db68e87410b15e91b278f6
|
File details
Details for the file depthai-2.0.0.0-cp36-cp36m-win_amd64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp36-cp36m-win_amd64.whl
- Upload date:
- Size: 31.4 MB
- Tags: CPython 3.6m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
f387f7f97deacbf2e665311445d31424460961a33d105271959cee4c44934472
|
|
MD5 |
79f7405f71251163313d599e0816189c
|
|
BLAKE2b-256 |
65edac6ae564ec3f7c0283251170c28c26e0615590d41075b3119731cd02c47b
|
File details
Details for the file depthai-2.0.0.0-cp36-cp36m-win32.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp36-cp36m-win32.whl
- Upload date:
- Size: 27.2 MB
- Tags: CPython 3.6m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
7dde462e954a53136de562eab8100e02b4f2298a94dd9e763bc6f6bf639b5cca
|
|
MD5 |
9a3577f1f0039fe4effbe02091272258
|
|
BLAKE2b-256 |
29f01be1b62cf0183ad018fd08186dfe4c3a8f404c2f9e9e4f8eefcf812fd1fc
|
File details
Details for the file depthai-2.0.0.0-cp36-cp36m-manylinux2014_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp36-cp36m-manylinux2014_x86_64.whl
- Upload date:
- Size: 5.0 MB
- Tags: CPython 3.6m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
9d5fc1c837485317321b61b43a56467b86e30f2cbb2f278d8f67ab76e5628303
|
|
MD5 |
0cc3d6a4548093573ab269229e8662f8
|
|
BLAKE2b-256 |
c89a752ac4b090e92569a9184d96929b3b1caf822afc7ee0c54441bfe043f2ce
|
File details
Details for the file depthai-2.0.0.0-cp36-cp36m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp36-cp36m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.6m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
52ad5bdd26dce7b09b5d487c48d08cdcde34fa4bd4c717c64a7163cd081525d9
|
|
MD5 |
451ead2780ecaeb835e51f1fa0a136d4
|
|
BLAKE2b-256 |
e2c085ea61bf03fb88ae39d3079c29a4167132dfae02f2e7a7ae33137469d7b9
|
File details
Details for the file depthai-2.0.0.0-cp35-cp35m-win_amd64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp35-cp35m-win_amd64.whl
- Upload date:
- Size: 31.4 MB
- Tags: CPython 3.5m, Windows x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
a9975816a5f2ca49a72783d83d9498261538315cc08bd773ee8d1599b197b4bb
|
|
MD5 |
17c702f10af79874d1abfe8099ccee0f
|
|
BLAKE2b-256 |
08fe73b5cde8f794312a995aa59a8c286af36c068bd8923b6895f856952d51d5
|
File details
Details for the file depthai-2.0.0.0-cp35-cp35m-win32.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp35-cp35m-win32.whl
- Upload date:
- Size: 27.2 MB
- Tags: CPython 3.5m, Windows x86
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
cca38baee1a28f42a23e3e03d495b1c1498b2fe49041c24e8e018e40e83a73a4
|
|
MD5 |
91069ec187e0e434b0204f995100e205
|
|
BLAKE2b-256 |
f312d390a4cfec441cc3c65f041f215804adfb3a41b631abc5c4706dc08e6707
|
File details
Details for the file depthai-2.0.0.0-cp35-cp35m-manylinux2014_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp35-cp35m-manylinux2014_x86_64.whl
- Upload date:
- Size: 5.0 MB
- Tags: CPython 3.5m
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
b133b54148770d4cf41792603ec316d1f9a1761059d690f9d22d28fa57e540ef
|
|
MD5 |
8d1ecba4aae872c11d1885e55bdea8b2
|
|
BLAKE2b-256 |
21f415ebdd507837d2b579acb969dbca8385c22d2f8b32550b9229dc1296539e
|
File details
Details for the file depthai-2.0.0.0-cp35-cp35m-macosx_10_9_x86_64.whl
.
File metadata
- Download URL: depthai-2.0.0.0-cp35-cp35m-macosx_10_9_x86_64.whl
- Upload date:
- Size: 4.5 MB
- Tags: CPython 3.5m, macOS 10.9+ x86-64
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.3.0 pkginfo/1.7.0 requests/2.25.1 setuptools/54.0.0 requests-toolbelt/0.9.1 tqdm/4.58.0 CPython/3.6.9
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 |
37fe0d7bfba41bb05228bf882ab87da7e1cce2cfd98ccc8d7f212d912a1121bd
|
|
MD5 |
ff767b629df7afed04abb39ee9e80c30
|
|
BLAKE2b-256 |
46dd4560cda7c4085424d57b11e02f795ec23d3d391718f3fef6119fc1cd7a87
|