Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
63 commits
Select commit Hold shift + click to select a range
381bc45
Add bindings for CameraControl setMisc
alex-luxonis May 5, 2023
89217b8
FW: IMX378/IMX582 manual ISO up to 3200, handle miscellaneous controls:
alex-luxonis May 12, 2023
7856f10
FW: IMX378/IMX582 manual ISO up to 35000, higher than 3200 only with …
alex-luxonis May 12, 2023
a9d69ae
cam_test.py: `-misc`/`--misc-controls` option. FW: IMX586 on-sensor H…
alex-luxonis May 27, 2023
2c3c86e
FW: initial IMX678 support (4K). TMP IMX462 enable HCG (high conversi…
alex-luxonis Feb 2, 2024
a0fa92a
Merge 'origin/develop' into camera_controls_misc
alex-luxonis Feb 7, 2024
34f285d
Merge 'origin/imx678' into camera_controls_misc
alex-luxonis Feb 7, 2024
faa4bd8
Fix build, develop got broken
alex-luxonis Feb 7, 2024
05827b4
FW: "high-conversion-gain" camera misc control for IMX462 and IMX678,…
alex-luxonis Feb 7, 2024
2d8fabc
FW: initial support for IMX715, 4lane, 4K, max FPS 9.7 for now
alex-luxonis Feb 8, 2024
74f0144
FW: IMX678 binning option (1080p, 60fps), IMX582 HDR:
alex-luxonis Feb 9, 2024
596d3b1
Add runtime stereo calib reconfig
May 10, 2024
ee22f22
Add getCalibration bindings
Jun 4, 2024
c6f7964
Merge remote-tracking branch 'origin/develop' into HEAD
Jun 4, 2024
31b0fab
Add runtime calib update example for stereo
Jun 4, 2024
60f7c57
FW: AR0234 tuning increase max exposure: 33 -> 890 ms
alex-luxonis Aug 19, 2024
7629453
FW: fix ToF EEPROM reading for certain FFC camera permutations
alex-luxonis Aug 22, 2024
f6d110d
Merge 'origin/develop' into camera_controls_misc
alex-luxonis Aug 22, 2024
bff906d
FW: update after merge, add "3a-follow" misc control:
alex-luxonis Aug 26, 2024
21bea7e
FW: update after merge. Also fix colors for IMX378 THE_1352X1012 with…
alex-luxonis Sep 23, 2024
ba0e78b
Merge pull request #986 from luxonis/camera_controls_misc
alex-luxonis Sep 23, 2024
65f306b
Remove Ubuntu:18.04 from OS tests
jakaskerl Sep 23, 2024
6de68e6
CrashDump: disable on shutdown
Sep 25, 2024
572492e
FW: misc controls for multi-ToF staggering: frame-sync-id, frame-sync…
alex-luxonis Sep 25, 2024
c9a23c4
Merge remote-tracking branch 'origin/develop' into HEAD
Sep 26, 2024
6a3b60b
Update examples with python shebang and executable permission
Sep 26, 2024
a1d2c06
Merge pull request #1017 from luxonis/dynamic_calib
SzabolcsGergely Sep 26, 2024
f17cfb4
Add ubuntu24.04
jakaskerl Sep 26, 2024
517b933
Merge pull request #1074 from luxonis/workflows/update
moratom Sep 26, 2024
d3b92a9
Format
Sep 30, 2024
118cf0c
SpeckleFilter: Add differenceThreshold config
Oct 3, 2024
c3af129
Implement configurable filtering order
Oct 4, 2024
9d437e1
Stereo: Scale disparity to 13 bit range prior to filtering
Oct 9, 2024
ef571f1
StereoDepth: postprocessing: handle edge case when post-processing fi…
Oct 11, 2024
1f1a1e4
StereoDepth: Add back MedianFilter to filtering order
Oct 17, 2024
53887f7
StereoDepth: add arbitrary filtering order support with scaling
Oct 21, 2024
1740463
FW: Stereo: issue debug prints once on calibration update event
Oct 29, 2024
fe29bde
Stereo: Core: add new stereo presets
Nov 7, 2024
4448c91
Merge remote-tracking branch 'origin/develop' into HEAD
Nov 7, 2024
872b74c
Update core to latest develop
Nov 8, 2024
78fd99b
Merge pull request #1081 from luxonis/stereo_filter_improvements
SzabolcsGergely Nov 8, 2024
5afbbc3
Add Python3.13 to the CI
Nov 9, 2024
7c6cbf1
Merge pull request #1082 from luxonis/ci_python_3_13
moratom Nov 10, 2024
d72e152
Bump core to the release branch
Nov 10, 2024
8731a36
Merge remote-tracking branch 'origin/main' into release_v2.29.0.0
Nov 10, 2024
0c3d39d
Stereo: PostProcessing: Handle edge case
Nov 11, 2024
fdee281
Update core
Nov 11, 2024
77eaab0
Merge remote-tracking branch 'origin/develop' into release_v2.29.0.0
Nov 11, 2024
cefc2b3
Stereo: PostProcess: Fix edge case when decimation is before median
Nov 12, 2024
7a3d64d
StereoDepth: update getMaxDisparity
Nov 12, 2024
c64d0de
Update core
Nov 12, 2024
d3d0e89
Merge remote-tracking branch 'origin/develop' into release_v2.29.0.0
Nov 12, 2024
e17221e
Added width and height to EncodedFrame
asahtik Nov 14, 2024
61208ec
Merge pull request #1085 from luxonis/encframe_add_width_height
asahtik Nov 15, 2024
74e168d
Update stereo profile presets
Nov 18, 2024
bd8cb9a
Remove HIGH_ACCURACY2
Nov 18, 2024
e6f60aa
Fix ImageAlign examples
Nov 18, 2024
e33723b
Obtain intrinsics dynamically
Nov 18, 2024
b214072
Fix the thermal_align.py example
Nov 18, 2024
8c72ef9
Merge pull request #1087 from luxonis/img_align_example_fix
SzabolcsGergely Nov 18, 2024
27a630a
Update core
Nov 21, 2024
1a994f1
Update core
Nov 22, 2024
a0b1842
Update core to main
Nov 22, 2024
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
8 changes: 4 additions & 4 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
Expand Up @@ -188,7 +188,7 @@ jobs:
runs-on: windows-latest
strategy:
matrix:
python-version: [3.7, 3.8, 3.9, '3.10', '3.11', '3.12']
python-version: [3.7, 3.8, 3.9, '3.10', '3.11', '3.12', '3.13']
python-architecture: [x64, x86]
fail-fast: false
steps:
Expand Down Expand Up @@ -244,7 +244,7 @@ jobs:
needs: build-docstrings
strategy:
matrix:
python-version: [3.8, 3.9, '3.10', '3.11', '3.12']
python-version: [3.8, 3.9, '3.10', '3.11', '3.12', '3.13']
os: [macos-13, macos-14] # macos-13 is x64, macos-14 is arm64
runs-on: ${{ matrix.os }}
steps:
Expand Down Expand Up @@ -352,7 +352,7 @@ jobs:
/opt/python/cp38-cp38/bin/python3.8 setup.py sdist --formats=gztar
mv dist/* wheelhouse/audited/
- name: Build wheels
run: for PYBIN in /opt/python/cp3{7..12}*/bin; do "${PYBIN}/pip" wheel . -w ./wheelhouse/ --verbose; done
run: for PYBIN in /opt/python/cp3{7..13}*/bin; do "${PYBIN}/pip" wheel . -w ./wheelhouse/ --verbose; done
- name: Audit wheels
run: for whl in wheelhouse/*.whl; do auditwheel repair "$whl" --plat $PLAT -w wheelhouse/audited/; done
- name: Archive wheel artifacts
Expand Down Expand Up @@ -413,7 +413,7 @@ jobs:
if: startsWith(github.ref, 'refs/tags/v') != true
run: echo "BUILD_COMMIT_HASH=${{github.sha}}" >> $GITHUB_ENV
- name: Building wheels
run: for PYBIN in /opt/python/cp3{7..12}*/bin; do "${PYBIN}/pip" wheel . -w ./wheelhouse/ --verbose; done
run: for PYBIN in /opt/python/cp3{7..13}*/bin; do "${PYBIN}/pip" wheel . -w ./wheelhouse/ --verbose; done
- name: Auditing wheels
run: for whl in wheelhouse/*.whl; do auditwheel repair "$whl" --plat $PLAT -w wheelhouse/audited/; done
- name: Archive wheel artifacts
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/test-install-dependencies.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
runs-on: ubuntu-latest
strategy:
matrix:
container_image: ["fedora:34", "fedora:35", "fedora:36", "ubuntu:18.04", "ubuntu:20.04", "ubuntu:22.04", "ubuntu:rolling"]
container_image: ["fedora:34", "fedora:35", "fedora:36", "ubuntu:20.04", "ubuntu:22.04", "ubuntu:24.04", "ubuntu:rolling"]
container:
image: ${{ matrix.container_image }}
steps:
Expand Down
2 changes: 2 additions & 0 deletions examples/Camera/camera_undistort.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import cv2

Expand Down
2 changes: 2 additions & 0 deletions examples/Camera/thermal_cam.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import cv2
import numpy as np
Expand Down
2 changes: 2 additions & 0 deletions examples/Cast/cast_blur.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import cv2
from pathlib import Path
Expand Down
2 changes: 2 additions & 0 deletions examples/Cast/cast_concat.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import numpy as np
import cv2
import depthai as dai
Expand Down
2 changes: 2 additions & 0 deletions examples/Cast/cast_diff.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import cv2
import depthai as dai
from pathlib import Path
Expand Down
2 changes: 2 additions & 0 deletions examples/ColorCamera/rgb_scene.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import cv2
import depthai as dai
from itertools import cycle
Expand Down
2 changes: 2 additions & 0 deletions examples/ColorCamera/rgb_undistort.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import cv2
import depthai as dai
import numpy as np
Expand Down
2 changes: 2 additions & 0 deletions examples/CrashReport/capture_diagnostic.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import zipfile
from json import dump, JSONEncoder
Expand Down
2 changes: 2 additions & 0 deletions examples/FeatureTracker/feature_motion_estimation.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import numpy as np
import cv2
from collections import deque
Expand Down
7 changes: 5 additions & 2 deletions examples/ImageAlign/depth_align.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import numpy as np
import cv2
import depthai as dai
Expand Down Expand Up @@ -32,7 +34,6 @@ def getFps(self):
device = dai.Device()

calibrationHandler = device.readCalibration()
rgbIntrinsics = calibrationHandler.getCameraIntrinsics(RGB_SOCKET, int(1920 / ISP_SCALE), int(1080 / ISP_SCALE))
rgbDistortion = calibrationHandler.getDistortionCoefficients(RGB_SOCKET)
distortionModel = calibrationHandler.getDistortionModel(RGB_SOCKET)
if distortionModel != dai.CameraModel.Perspective:
Expand Down Expand Up @@ -158,6 +159,8 @@ def updateBlendWeights(percentRgb):
if frameDepth is not None:
cvFrame = frameRgb.getCvFrame()

rgbIntrinsics = calibrationHandler.getCameraIntrinsics(RGB_SOCKET, int(cvFrame.shape[1]), int(cvFrame.shape[0]))

# Undistort the rgb frame
cvFrameUndistorted = cv2.undistort(
cvFrame,
Expand All @@ -170,7 +173,7 @@ def updateBlendWeights(percentRgb):
cv2.imshow("Depth aligned", alignedDepthColorized)

blended = cv2.addWeighted(
cvFrame, rgbWeight, alignedDepthColorized, depthWeight, 0
cvFrameUndistorted, rgbWeight, alignedDepthColorized, depthWeight, 0
)
cv2.putText(
blended,
Expand Down
28 changes: 24 additions & 4 deletions examples/ImageAlign/image_align.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,6 +1,9 @@
#!/usr/bin/env python3

import cv2
import depthai as dai
from datetime import timedelta
import numpy as np

# This is an interactive example that shows how two frame sources without depth information.
FPS = 30.0
Expand All @@ -12,7 +15,16 @@
COLOR_RESOLUTION = dai.ColorCameraProperties.SensorResolution.THE_1080_P
LEFT_RIGHT_RESOLUTION = dai.MonoCameraProperties.SensorResolution.THE_720_P

ISP_SCALE = 3

device = dai.Device()

calibrationHandler = device.readCalibration()
rgbDistortion = calibrationHandler.getDistortionCoefficients(RGB_SOCKET)
distortionModel = calibrationHandler.getDistortionModel(RGB_SOCKET)
if distortionModel != dai.CameraModel.Perspective:
raise RuntimeError("Unsupported distortion model for RGB camera. This example supports only Perspective model.")

pipeline = dai.Pipeline()

# Define sources and outputs
Expand All @@ -30,7 +42,7 @@
camRgb.setBoardSocket(RGB_SOCKET)
camRgb.setResolution(COLOR_RESOLUTION)
camRgb.setFps(FPS)
camRgb.setIspScale(1, 3)
camRgb.setIspScale(1, ISP_SCALE)

out.setStreamName("out")

Expand Down Expand Up @@ -107,12 +119,20 @@ def updateDepthPlane(depth):
# Colorize the aligned depth
leftCv = leftAligned.getCvFrame()

rgbIntrinsics = calibrationHandler.getCameraIntrinsics(RGB_SOCKET, int(frameRgbCv.shape[1]), int(frameRgbCv.shape[0]))

cvFrameUndistorted = cv2.undistort(
frameRgbCv,
np.array(rgbIntrinsics),
np.array(rgbDistortion),
)

if len(leftCv.shape) == 2:
leftCv = cv2.cvtColor(leftCv, cv2.COLOR_GRAY2BGR)
if leftCv.shape != frameRgbCv.shape:
leftCv = cv2.resize(leftCv, (frameRgbCv.shape[1], frameRgbCv.shape[0]))
if leftCv.shape != cvFrameUndistorted.shape:
leftCv = cv2.resize(leftCv, (cvFrameUndistorted.shape[1], cvFrameUndistorted.shape[0]))

blended = cv2.addWeighted(frameRgbCv, rgbWeight, leftCv, leftWeight, 0)
blended = cv2.addWeighted(cvFrameUndistorted, rgbWeight, leftCv, leftWeight, 0)
cv2.imshow(windowName, blended)

key = cv2.waitKey(1)
Expand Down
22 changes: 20 additions & 2 deletions examples/ImageAlign/thermal_align.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import cv2
import depthai as dai
import numpy as np
Expand Down Expand Up @@ -38,6 +40,14 @@ def getFps(self):
raise RuntimeError("No thermal camera found!")


ISP_SCALE = 3

calibrationHandler = device.readCalibration()
rgbDistortion = calibrationHandler.getDistortionCoefficients(RGB_SOCKET)
distortionModel = calibrationHandler.getDistortionModel(RGB_SOCKET)
if distortionModel != dai.CameraModel.Perspective:
raise RuntimeError("Unsupported distortion model for RGB camera. This example supports only Perspective model.")

pipeline = dai.Pipeline()

# Define sources and outputs
Expand All @@ -55,7 +65,7 @@ def getFps(self):
camRgb.setBoardSocket(RGB_SOCKET)
camRgb.setResolution(COLOR_RESOLUTION)
camRgb.setFps(FPS)
camRgb.setIspScale(1,3)
camRgb.setIspScale(1,ISP_SCALE)

out.setStreamName("out")

Expand Down Expand Up @@ -130,6 +140,14 @@ def updateDepthPlane(depth):
frameRgbCv = frameRgb.getCvFrame()
fpsCounter.tick()

rgbIntrinsics = calibrationHandler.getCameraIntrinsics(RGB_SOCKET, int(frameRgbCv.shape[1]), int(frameRgbCv.shape[0]))

cvFrameUndistorted = cv2.undistort(
frameRgbCv,
np.array(rgbIntrinsics),
np.array(rgbDistortion),
)

# Colorize the aligned depth
thermalFrame = thermalAligned.getCvFrame().astype(np.float32)
# Create a mask for nan values
Expand All @@ -141,7 +159,7 @@ def updateDepthPlane(depth):
# Apply the mask back with black pixels (0)
colormappedFrame[mask] = 0

blended = cv2.addWeighted(frameRgbCv, rgbWeight, colormappedFrame, thermalWeight, 0)
blended = cv2.addWeighted(cvFrameUndistorted, rgbWeight, colormappedFrame, thermalWeight, 0)

cv2.putText(
blended,
Expand Down
25 changes: 22 additions & 3 deletions examples/ImageAlign/tof_align.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import numpy as np
import cv2
import depthai as dai
Expand Down Expand Up @@ -27,8 +29,18 @@ def getFps(self):
return (len(self.frameTimes) - 1) / (self.frameTimes[-1] - self.frameTimes[0])


ISP_SCALE = 2

device = dai.Device()

calibrationHandler = device.readCalibration()
rgbDistortion = calibrationHandler.getDistortionCoefficients(RGB_SOCKET)
distortionModel = calibrationHandler.getDistortionModel(RGB_SOCKET)
if distortionModel != dai.CameraModel.Perspective:
raise RuntimeError("Unsupported distortion model for RGB camera. This example supports only Perspective model.")

pipeline = dai.Pipeline()

# Define sources and outputs
camRgb = pipeline.create(dai.node.ColorCamera)
tof = pipeline.create(dai.node.ToF)
Expand All @@ -46,7 +58,7 @@ def getFps(self):
camRgb.setBoardSocket(RGB_SOCKET)
camRgb.setResolution(dai.ColorCameraProperties.SensorResolution.THE_800_P)
camRgb.setFps(FPS)
camRgb.setIspScale(1, 2)
camRgb.setIspScale(1, ISP_SCALE)

out.setStreamName("out")

Expand Down Expand Up @@ -107,7 +119,8 @@ def updateBlendWeights(percentRgb):


# Connect to device and start pipeline
with dai.Device(pipeline) as device:
with device:
device.startPipeline(pipeline)
queue = device.getOutputQueue("out", 8, False)

# Configure windows; trackbar adjusts blending ratio of rgb/depth
Expand Down Expand Up @@ -136,6 +149,12 @@ def updateBlendWeights(percentRgb):
# Blend when both received
if frameDepth is not None:
cvFrame = frameRgb.getCvFrame()
rgbIntrinsics = calibrationHandler.getCameraIntrinsics(RGB_SOCKET, int(cvFrame.shape[1]), int(cvFrame.shape[0]))
cvFrameUndistorted = cv2.undistort(
cvFrame,
np.array(rgbIntrinsics),
np.array(rgbDistortion),
)
# Colorize the aligned depth
alignedDepthColorized = colorizeDepth(frameDepth.getFrame())
# Resize depth to match the rgb frame
Expand All @@ -151,7 +170,7 @@ def updateBlendWeights(percentRgb):
cv2.imshow("depth", alignedDepthColorized)

blended = cv2.addWeighted(
cvFrame, rgbWeight, alignedDepthColorized, depthWeight, 0
cvFrameUndistorted, rgbWeight, alignedDepthColorized, depthWeight, 0
)
cv2.imshow(rgbDepthWindowName, blended)

Expand Down
2 changes: 2 additions & 0 deletions examples/NeuralNetwork/thermal_nnet.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import cv2
from pathlib import Path
Expand Down
2 changes: 2 additions & 0 deletions examples/PointCloud/pointcloud_control.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import numpy as np
import cv2
Expand Down
2 changes: 2 additions & 0 deletions examples/PointCloud/visualize_pointcloud.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
from time import sleep
import numpy as np
Expand Down
2 changes: 2 additions & 0 deletions examples/Script/script_emmc_access.py
100644 → 100755
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
#!/usr/bin/env python3

import depthai as dai
import cv2

Expand Down
Empty file modified examples/Script/script_read_calibration.py
100644 → 100755
Empty file.
Empty file modified examples/Script/script_uart.py
100644 → 100755
Empty file.
Empty file modified examples/StereoDepth/stereo_depth_custom_mesh.py
100644 → 100755
Empty file.
Loading