Skip to content

Commit 334ba54

Browse files
committed
Merge branch 'release_2.17.2.0' into main
2 parents c9abca8 + 8855548 commit 334ba54

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

52 files changed

+4197
-2918
lines changed

CMakeLists.txt

Lines changed: 45 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -96,11 +96,55 @@ pybind11_add_module(${TARGET_NAME}
9696
src/DatatypeBindings.cpp
9797
src/DataQueueBindings.cpp
9898
src/pipeline/PipelineBindings.cpp
99-
src/pipeline/NodeBindings.cpp
10099
src/pipeline/CommonBindings.cpp
101100
src/pipeline/AssetManagerBindings.cpp
102101
src/openvino/OpenVINOBindings.cpp
103102
src/log/LogBindings.cpp
103+
104+
src/pipeline/node/NodeBindings.cpp
105+
106+
src/pipeline/node/XLinkInBindings.cpp
107+
src/pipeline/node/XLinkOutBindings.cpp
108+
src/pipeline/node/ColorCameraBindings.cpp
109+
src/pipeline/node/MonoCameraBindings.cpp
110+
src/pipeline/node/StereoDepthBindings.cpp
111+
src/pipeline/node/NeuralNetworkBindings.cpp
112+
src/pipeline/node/VideoEncoderBindings.cpp
113+
src/pipeline/node/ImageManipBindings.cpp
114+
src/pipeline/node/SPIOutBindings.cpp
115+
src/pipeline/node/SPIInBindings.cpp
116+
src/pipeline/node/DetectionNetworkBindings.cpp
117+
src/pipeline/node/SystemLoggerBindings.cpp
118+
src/pipeline/node/ScriptBindings.cpp
119+
src/pipeline/node/SpatialLocationCalculatorBindings.cpp
120+
src/pipeline/node/SpatialDetectionNetworkBindings.cpp
121+
src/pipeline/node/ObjectTrackerBindings.cpp
122+
src/pipeline/node/IMUBindings.cpp
123+
src/pipeline/node/EdgeDetectorBindings.cpp
124+
src/pipeline/node/FeatureTrackerBindings.cpp
125+
src/pipeline/node/AprilTagBindings.cpp
126+
src/pipeline/node/DetectionParserBindings.cpp
127+
128+
src/pipeline/datatype/ADatatypeBindings.cpp
129+
src/pipeline/datatype/AprilTagConfigBindings.cpp
130+
src/pipeline/datatype/AprilTagsBindings.cpp
131+
src/pipeline/datatype/BufferBindings.cpp
132+
src/pipeline/datatype/CameraControlBindings.cpp
133+
src/pipeline/datatype/EdgeDetectorConfigBindings.cpp
134+
src/pipeline/datatype/FeatureTrackerConfigBindings.cpp
135+
src/pipeline/datatype/ImageManipConfigBindings.cpp
136+
src/pipeline/datatype/ImgDetectionsBindings.cpp
137+
src/pipeline/datatype/ImgFrameBindings.cpp
138+
src/pipeline/datatype/IMUDataBindings.cpp
139+
src/pipeline/datatype/NNDataBindings.cpp
140+
src/pipeline/datatype/SpatialImgDetectionsBindings.cpp
141+
src/pipeline/datatype/SpatialLocationCalculatorConfigBindings.cpp
142+
src/pipeline/datatype/SpatialLocationCalculatorDataBindings.cpp
143+
src/pipeline/datatype/StereoDepthConfigBindings.cpp
144+
src/pipeline/datatype/SystemInformationBindings.cpp
145+
src/pipeline/datatype/TrackedFeaturesBindings.cpp
146+
src/pipeline/datatype/TrackletsBindings.cpp
147+
104148
)
105149

106150
if(WIN32)

examples/ObjectTracker/object_tracker_video.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -107,7 +107,7 @@ def displayFrame(name, frame):
107107
cap = cv2.VideoCapture(args.videoPath)
108108
baseTs = time.monotonic()
109109
simulatedFps = 30
110-
inputFrameShape = (1280, 720)
110+
inputFrameShape = (1920, 1080)
111111

112112
while cap.isOpened():
113113
read_correctly, frame = cap.read()

src/DatatypeBindings.cpp

Lines changed: 42 additions & 1592 deletions
Large diffs are not rendered by default.

src/DatatypeBindings.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -4,5 +4,5 @@
44
#include "pybind11_common.hpp"
55

66
struct DatatypeBindings {
7-
static void bind(pybind11::module& m, void* pCallstack);
7+
static void addToCallstack(std::deque<StackFunction>& callstack);
88
};

src/pipeline/CommonBindings.cpp

Lines changed: 31 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -15,6 +15,8 @@
1515
#include "depthai-shared/common/UsbSpeed.hpp"
1616
#include "depthai-shared/common/DetectionNetworkType.hpp"
1717
#include "depthai-shared/common/DetectionParserOptions.hpp"
18+
#include "depthai-shared/common/RotatedRect.hpp"
19+
#include "depthai-shared/common/Rect.hpp"
1820

1921
void CommonBindings::bind(pybind11::module& m, void* pCallstack){
2022

@@ -39,6 +41,8 @@ void CommonBindings::bind(pybind11::module& m, void* pCallstack){
3941
py::enum_<DetectionNetworkType> detectionNetworkType(m, "DetectionNetworkType");
4042
py::enum_<SerializationType> serializationType(m, "SerializationType");
4143
py::class_<DetectionParserOptions> detectionParserOptions(m, "DetectionParserOptions", DOC(dai, DetectionParserOptions));
44+
py::class_<RotatedRect> rotatedRect(m, "RotatedRect", DOC(dai, RotatedRect));
45+
py::class_<Rect> rect(m, "Rect", DOC(dai, Rect));
4246

4347
///////////////////////////////////////////////////////////////////////
4448
///////////////////////////////////////////////////////////////////////
@@ -53,6 +57,33 @@ void CommonBindings::bind(pybind11::module& m, void* pCallstack){
5357
///////////////////////////////////////////////////////////////////////
5458
///////////////////////////////////////////////////////////////////////
5559

60+
rotatedRect
61+
.def(py::init<>())
62+
.def_readwrite("center", &RotatedRect::center)
63+
.def_readwrite("size", &RotatedRect::size)
64+
.def_readwrite("angle", &RotatedRect::angle)
65+
;
66+
67+
rect
68+
.def(py::init<>())
69+
.def(py::init<float, float, float, float>())
70+
.def(py::init<Point2f, Point2f>())
71+
.def(py::init<Point2f, Size2f>())
72+
73+
.def("topLeft", &Rect::topLeft, DOC(dai, Rect, topLeft))
74+
.def("bottomRight", &Rect::bottomRight, DOC(dai, Rect, bottomRight))
75+
.def("size", &Rect::size, DOC(dai, Rect, size))
76+
.def("area", &Rect::area, DOC(dai, Rect, area))
77+
.def("empty", &Rect::empty, DOC(dai, Rect, empty))
78+
.def("contains", &Rect::contains, DOC(dai, Rect, contains))
79+
.def("isNormalized", &Rect::isNormalized, DOC(dai, Rect, isNormalized))
80+
.def("denormalize", &Rect::denormalize, py::arg("width"), py::arg("height"), DOC(dai, Rect, denormalize))
81+
.def("normalize", &Rect::normalize, py::arg("width"), py::arg("height"), DOC(dai, Rect, normalize))
82+
.def_readwrite("x", &Rect::x)
83+
.def_readwrite("y", &Rect::y)
84+
.def_readwrite("width", &Rect::width)
85+
.def_readwrite("height", &Rect::height)
86+
;
5687

5788
timestamp
5889
.def(py::init<>())

0 commit comments

Comments
 (0)