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

Release v2.12.0 #261

Merged
merged 30 commits into from
Nov 13, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
30 commits
Select commit Hold shift + click to select a range
8af5641
Set fine tuned stereo settings
SzabolcsGergely Sep 23, 2021
d5fa958
Update catch2 package to 2.13.7
SzabolcsGergely Oct 24, 2021
fdde8eb
Merge pull request #236 from luxonis/catch_dependency_fix_new_glibc
SzabolcsGergely Oct 24, 2021
a6a30e5
Merge branch 'main' into develop
themarpe Oct 24, 2021
c6451c3
Merge branch 'develop' of github.com:luxonis/depthai-core into develop
themarpe Oct 24, 2021
22da78b
Added CMake version into CI and Ubuntu 18.04 fix (#237)
themarpe Oct 25, 2021
7622cef
StereoDepth: Add extended disparity mode
SzabolcsGergely Oct 29, 2021
7c30492
Merge remote-tracking branch 'origin/develop' into extended_disparity
SzabolcsGergely Oct 29, 2021
c021c8f
Add extended mode debug outputs
SzabolcsGergely Oct 30, 2021
f469f73
Spdlog version change (#239)
saching13 Oct 30, 2021
98e13c7
FW - fixed OpenVINO layer issue
themarpe Nov 2, 2021
0b34c37
Merge remote-tracking branch 'origin/develop' into HEAD
SzabolcsGergely Nov 3, 2021
e0565e7
Add addtional outputs to output list
SzabolcsGergely Nov 3, 2021
d680721
Update FW before merge
SzabolcsGergely Nov 4, 2021
9e60bf1
Merge pull request #240 from luxonis/extended_disparity
SzabolcsGergely Nov 4, 2021
24664ce
Merge remote-tracking branch 'origin/main' into HEAD
SzabolcsGergely Nov 4, 2021
52783c2
Revert "Set fine tuned stereo settings"
SzabolcsGergely Nov 5, 2021
7d7babd
Merge remote-tracking branch 'origin/develop' into HEAD
SzabolcsGergely Nov 5, 2021
1b427f2
Add fine tuned stereo settings, configurable P1/P2 cost aggregation p…
SzabolcsGergely Nov 5, 2021
abc5ddb
Increase LR-check threshold to 10; disparity confidence threshold to …
SzabolcsGergely Nov 5, 2021
3e8acdf
Merge pull request #216 from luxonis/stereo_depth_fine_tuning
SzabolcsGergely Nov 5, 2021
6754cbb
Update FW with Script node (DynamicPool) related fixes
SzabolcsGergely Nov 7, 2021
3837fee
Add support for non-square YOLO output
SzabolcsGergely Nov 7, 2021
630b461
Update FW with error reporting for DetectionNetwork
SzabolcsGergely Nov 7, 2021
26dac71
Update FW before merge
SzabolcsGergely Nov 7, 2021
0465f5e
Merge pull request #245 from luxonis/non_square_yolo_output
SzabolcsGergely Nov 7, 2021
4df2c68
Fixes for object tracker; support for KCF and imageless short term tr…
SzabolcsGergely Nov 11, 2021
f7c26ce
Update FW with latest improvements
SzabolcsGergely Nov 12, 2021
23d7d44
Merge pull request #256 from luxonis/object_tracker_update
SzabolcsGergely Nov 12, 2021
5a5b2f0
Release v2.12.0
SzabolcsGergely Nov 13, 2021
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
25 changes: 19 additions & 6 deletions .github/workflows/main.workflow.yml
Original file line number Diff line number Diff line change
Expand Up @@ -65,24 +65,31 @@ jobs:
strategy:
matrix:
os: [macos-latest, windows-latest, ubuntu-latest]
cmake: ['3.10.x', ''] # Older version (Ubuntu 18.04) and newest

steps:
- name: Cache .hunter folder
if: matrix.os != 'windows-latest'
uses: actions/cache@v2
with:
path: ~/.hunter/
key: hunter-${{ matrix.os }}
key: hunter-${{ matrix.os }}-${{ matrix.cmake }}
- name: Cache .hunter folder
if: matrix.os == 'windows-latest'
uses: actions/cache@v2
with:
path: C:/.hunter/
key: hunter-${{ matrix.os }}
key: hunter-${{ matrix.os }}-${{ matrix.cmake }}

- uses: actions/checkout@v2
with:
submodules: 'recursive'

- name: Setup cmake
uses: jwlawson/actions-setup-cmake@v1.9
with:
cmake-version: ${{ matrix.cmake }}

- name: Install dependencies
if: matrix.os == 'macos-latest'
run: |
Expand All @@ -102,11 +109,17 @@ jobs:
echo "OpenCV_DIR=C:\tools\opencv\build" | Out-File -FilePath $env:GITHUB_ENV -Encoding utf8 -Append
echo "C:\tools\opencv\build\x64\vc15\bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append

- name: configure
run: cmake -S . -B build -D DEPTHAI_BUILD_EXAMPLES=ON -D DEPTHAI_BUILD_TESTS=ON
- name: Build (old CMake, gcc/Clang)
if: matrix.cmake == '3.10.x' && matrix.os != 'windows-latest'
run: |
cmake -H. -Bbuild -D'DEPTHAI_BUILD_EXAMPLES=ON' -D'DEPTHAI_BUILD_TESTS=ON'
cmake --build build -- -j8

- name: build
run: cmake --build build --parallel 8
- name: Build (newest CMake)
if: matrix.cmake != '3.10.x'
run: |
cmake -S . -B build -D DEPTHAI_BUILD_EXAMPLES=ON -D DEPTHAI_BUILD_TESTS=ON
cmake --build build --parallel 8

integration:
runs-on: ${{ matrix.os }}
Expand Down
2 changes: 1 addition & 1 deletion CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,7 @@ if(WIN32)
endif()

# Create depthai project
project(depthai VERSION "2.11.1" LANGUAGES CXX C)
project(depthai VERSION "2.12.0" LANGUAGES CXX C)
get_directory_property(has_parent PARENT_DIRECTORY)
if(has_parent)
set(DEPTHAI_VERSION ${PROJECT_VERSION} PARENT_SCOPE)
Expand Down
22 changes: 11 additions & 11 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Documentation is available over at [Luxonis DepthAI API](https://docs.luxonis.co
DepthAI library doesn't yet provide API stability guarantees. While we take care to properly deprecate old functions, some changes might still be breaking. We expect to provide API stability from version 3.0.0 onwards.

## Dependencies
- cmake >= 3.4
- CMake >= 3.10
- libusb1 development package (MacOS & Linux only)
- C/C++14 compiler
- [optional] OpenCV 4 (required if building examples)
Expand Down Expand Up @@ -44,15 +44,15 @@ For older versions use: Linux/macOS: `cmake --build build -- -j[num CPU cores]`,

To build dynamic version of library configure with following option added
```
cmake -S. -Bbuild -D BUILD_SHARED_LIBS=ON
cmake -S. -Bbuild -D'BUILD_SHARED_LIBS=ON'
cmake --build build
```

## Running examples

To build the examples configure with following option added
```
cmake -S. -Bbuild -D DEPTHAI_BUILD_EXAMPLES=ON
cmake -S. -Bbuild -D'DEPTHAI_BUILD_EXAMPLES=ON'
cmake --build build
```

Expand Down Expand Up @@ -87,11 +87,11 @@ target_link_libraries([my-app] PRIVATE depthai::opencv)

And point CMake to either build directory or install directory:
```
-D depthai_DIR=depthai-core/build
-D'depthai_DIR=depthai-core/build'
```
or
```
-D depthai_DIR=depthai-core/build/install/lib/cmake/depthai
-D'depthai_DIR=depthai-core/build/install/lib/cmake/depthai'
```

If library was installed to default search path like `/usr/local` on Linux, specifying `depthai_DIR` isn't necessary as CMake will find it automatically.
Expand Down Expand Up @@ -136,7 +136,7 @@ The generated integration file also specifies include paths without requiring in

To install specify optional prefix and build target install
```
cmake -S. -Bbuild -D CMAKE_INSTALL_PREFIX=[path/to/install/dir]
cmake -S. -Bbuild -D'CMAKE_INSTALL_PREFIX=[path/to/install/dir]'
cmake --build build --target install
```

Expand All @@ -147,7 +147,7 @@ If `CMAKE_INSTALL_PREFIX` isn't specified, the library is installed under build

To run the tests build the library with the following options
```
cmake -S. -Bbuild -D DEPTHAI_TEST_EXAMPLES=ON -D DEPTHAI_BUILD_TESTS=ON -D DEPTHAI_BUILD_EXAMPLES=ON
cmake -S. -Bbuild -D'DEPTHAI_TEST_EXAMPLES=ON' -D'DEPTHAI_BUILD_TESTS=ON' -D'DEPTHAI_BUILD_EXAMPLES=ON'
cmake --build build
```

Expand Down Expand Up @@ -176,7 +176,7 @@ cmake --build build --target clangformat

Doxygen is used to generate documentation. Follow [doxygen download](https://www.doxygen.nl/download.html#srcbin) and install the required binaries for your platform.

After that specify CMake define `-D DEPTHAI_BUILD_DOCS=ON` and build the target `doxygen`
After that specify CMake define `-D'DEPTHAI_BUILD_DOCS=ON`' and build the target `doxygen`

## Debugging tips

Expand All @@ -191,7 +191,7 @@ rm -r ~/.hunter

And configuring the project with the following CMake option set to `ON`
```
cmake . -D HUNTER_KEEP_PACKAGE_SOURCES=ON
cmake . -D'HUNTER_KEEP_PACKAGE_SOURCES=ON'
```

This retains the libraries source code, so that debugger can step through it (the paths are already set up correctly)
Expand All @@ -202,10 +202,10 @@ This retains the libraries source code, so that debugger can step through it (th
### Build fails with missing OpenCV dependency

If your build process happen to fail due to OpenCV library not being found, but you have the OpenCV installed, please
run build with additional `-D OpenCV_DIR` flag (replacing default Ubuntu path `/usr/lib/x86_64-linux-gnu/cmake/opencv4` with yours)
run build with additional `-D'OpenCV_DIR=...`' flag (replacing default Ubuntu path `/usr/lib/x86_64-linux-gnu/cmake/opencv4` with yours)

```
cmake -S. -Bbuild -D OpenCV_DIR=/usr/lib/x86_64-linux-gnu/cmake/opencv4
cmake -S. -Bbuild -D'OpenCV_DIR=/usr/lib/x86_64-linux-gnu/cmake/opencv4'
```

Now the build process should correctly discover your OpenCV installation
Expand Down
2 changes: 1 addition & 1 deletion cmake/Depthai/DepthaiDeviceSideConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
set(DEPTHAI_DEVICE_SIDE_MATURITY "snapshot")

# "full commit hash of device side binary"
set(DEPTHAI_DEVICE_SIDE_COMMIT "2021725697c9b570383b0597951a9d7b162e6182")
set(DEPTHAI_DEVICE_SIDE_COMMIT "3bb469fa08b7b0abc4353cd27219521dfd763a9d")

# "version if applicable"
set(DEPTHAI_DEVICE_SIDE_VERSION "")
17 changes: 17 additions & 0 deletions cmake/Hunter/config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,8 @@ hunter_config(
CMAKE_ARGS
SPDLOG_BUILD_EXAMPLE=OFF
SPDLOG_FMT_EXTERNAL=OFF
CMAKE_CXX_VISIBILITY_PRESET=hidden
CMAKE_C_VISIBILITY_PRESET=hidden
)

# libarchive, luxonis fork
Expand Down Expand Up @@ -84,4 +86,19 @@ hunter_config(
SHA1 "4ecb711eabfd15bc88ff9dd9342907fc5da46b62"
CMAKE_ARGS
BACKWARD_TESTS=OFF
)

hunter_config(
Catch2
VERSION "2.13.7"
URL "https://github.com/catchorg/Catch2/archive/refs/tags/v2.13.7.tar.gz"
SHA1 "fa8f14ccf852413d3c6d3999145ada934d37d773"
)

# ZLib - Luxonis fix for alias on imported target for old CMake versions
hunter_config(
ZLIB
VERSION "1.2.11-p2"
URL "https://github.com/luxonis/zlib/archive/refs/tags/v1.2.11-p2.tar.gz"
SHA1 "fb8b6486183b13a86040f793a939b128f6d27095"
)
6 changes: 6 additions & 0 deletions include/depthai/pipeline/datatype/StereoDepthConfig.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -69,6 +69,12 @@ class StereoDepthConfig : public Buffer {
*/
void setLeftRightCheck(bool enable);

/**
* Disparity range increased from 95 to 190, combined from full resolution and downscaled images.
* Suitable for short range objects
*/
void setExtendedDisparity(bool enable);

/**
* Computes disparity with sub-pixel interpolation (5 fractional bits).
*
Expand Down
12 changes: 12 additions & 0 deletions include/depthai/pipeline/node/StereoDepth.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -105,6 +105,18 @@ class StereoDepth : public Node {
*/
Output debugDispLrCheckIt2{*this, "debugDispLrCheckIt2", Output::Type::MSender, {{DatatypeEnum::ImgFrame, false}}};

/**
* Outputs ImgFrame message that carries extended left-right check first iteration (downscaled frame, before combining with second iteration) disparity map.
* Useful for debugging/fine tuning.
*/
Output debugExtDispLrCheckIt1{*this, "debugExtDispLrCheckIt1", Output::Type::MSender, {{DatatypeEnum::ImgFrame, false}}};

/**
* Outputs ImgFrame message that carries extended left-right check second iteration (downscaled frame, before combining with first iteration) disparity map.
* Useful for debugging/fine tuning.
*/
Output debugExtDispLrCheckIt2{*this, "debugExtDispLrCheckIt2", Output::Type::MSender, {{DatatypeEnum::ImgFrame, false}}};

/**
* Outputs ImgFrame message that carries cost dump of disparity map.
* Useful for debugging/fine tuning.
Expand Down
6 changes: 5 additions & 1 deletion src/pipeline/datatype/StereoDepthConfig.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,10 @@ void StereoDepthConfig::setLeftRightCheck(bool enable) {
cfg.algorithmControl.enableLeftRightCheck = enable;
}

void StereoDepthConfig::setExtendedDisparity(bool enable) {
cfg.algorithmControl.enableExtended = enable;
}

void StereoDepthConfig::setSubpixel(bool enable) {
cfg.algorithmControl.enableSubpixel = enable;
}
Expand All @@ -56,7 +60,7 @@ float StereoDepthConfig::getMaxDisparity() const {
maxDisp = 63;
}
if(cfg.costMatching.enableCompanding) maxDisp = 175;
if(false) maxDisp *= 2; // TODO re-enable with extended
if(cfg.algorithmControl.enableExtended) maxDisp *= 2;
if(cfg.algorithmControl.enableSubpixel) maxDisp *= (1 << cfg.algorithmControl.subpixelFractionalBits);
return maxDisp;
}
Expand Down
17 changes: 15 additions & 2 deletions src/pipeline/node/StereoDepth.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,19 @@ StereoDepth::StereoDepth(const std::shared_ptr<PipelineImpl>& par, int64_t nodeI
: Node(par, nodeId), rawConfig(std::make_shared<RawStereoDepthConfig>()), initialConfig(rawConfig) {
// 'properties' defaults already set
inputs = {&inputConfig, &left, &right};
outputs = {&depth, &disparity, &syncedLeft, &syncedRight, &rectifiedLeft, &rectifiedRight};
outputs = {&depth,
&disparity,
&syncedLeft,
&syncedRight,
&rectifiedLeft,
&rectifiedRight,
&outConfig,
&debugDispLrCheckIt1,
&debugDispLrCheckIt2,
&debugExtDispLrCheckIt1,
&debugExtDispLrCheckIt2,
&debugDispCostDump,
&confidenceMap};
}

std::string StereoDepth::getName() const {
Expand Down Expand Up @@ -128,7 +140,8 @@ void StereoDepth::setSubpixel(bool enable) {
properties.initialConfig = *rawConfig;
}
void StereoDepth::setExtendedDisparity(bool enable) {
properties.enableExtendedDisparity = enable;
initialConfig.setExtendedDisparity(enable);
properties.initialConfig = *rawConfig;
}
void StereoDepth::setRectifyEdgeFillColor(int color) {
properties.rectifyEdgeFillColor = color;
Expand Down
2 changes: 1 addition & 1 deletion tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ include(CTest)
enable_testing()

# Add catch2 for writing tests
hunter_add_package(Catch)
hunter_add_package(Catch2)
find_package(Catch2 CONFIG REQUIRED)

# Macro for adding new tests
Expand Down