From d1f22b10911caade87f19d387c46ff3e51a8215c Mon Sep 17 00:00:00 2001 From: SzabolcsGergely Date: Mon, 19 Jul 2021 08:33:41 +0300 Subject: [PATCH 1/3] Fix name clash for accuracy field in RotationVector structure --- depthai-core | 2 +- examples/imu_rotation_vector.py | 2 +- src/DatatypeBindings.cpp | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/depthai-core b/depthai-core index 70ad1005c..c7865c240 160000 --- a/depthai-core +++ b/depthai-core @@ -1 +1 @@ -Subproject commit 70ad1005cdfaf6a12b5627f75d177d6f37081c6a +Subproject commit c7865c240c0bda74fae3d4d26af954a18380c0b6 diff --git a/examples/imu_rotation_vector.py b/examples/imu_rotation_vector.py index 61f20292b..63563fae6 100755 --- a/examples/imu_rotation_vector.py +++ b/examples/imu_rotation_vector.py @@ -53,7 +53,7 @@ def timeDeltaToMilliS(delta) -> float: print(f"Rotation vector timestamp: {tsF.format(timeDeltaToMilliS(rvTs))} ms") print(f"Quaternion: i: {imuF.format(rVvalues.i)} j: {imuF.format(rVvalues.j)} " f"k: {imuF.format(rVvalues.k)} real: {imuF.format(rVvalues.real)}") - print(f"Accuracy (rad): {imuF.format(rVvalues.accuracy)}") + print(f"Accuracy (rad): {imuF.format(rVvalues.rotationVectorAccuracy)}") if cv2.waitKey(1) == ord('q'): diff --git a/src/DatatypeBindings.cpp b/src/DatatypeBindings.cpp index c939b8f3b..365aa9d82 100644 --- a/src/DatatypeBindings.cpp +++ b/src/DatatypeBindings.cpp @@ -338,7 +338,7 @@ void DatatypeBindings::bind(pybind11::module& m){ .def_readwrite("j", &IMUReportRotationVectorWAcc::j) .def_readwrite("k", &IMUReportRotationVectorWAcc::k) .def_readwrite("real", &IMUReportRotationVectorWAcc::real) - .def_readwrite("accuracy", &IMUReportRotationVectorWAcc::accuracy) + .def_readwrite("rotationVectorAccuracy", &IMUReportRotationVectorWAcc::rotationVectorAccuracy) ; #if 0 From 0a39db32a341786b50c8942ff9a60d85cacf8805 Mon Sep 17 00:00:00 2001 From: SzabolcsGergely Date: Mon, 19 Jul 2021 11:53:47 +0300 Subject: [PATCH 2/3] Rename IMUReportAccuracy enum to Accuracy --- depthai-core | 2 +- src/DatatypeBindings.cpp | 10 +++++----- 2 files changed, 6 insertions(+), 6 deletions(-) diff --git a/depthai-core b/depthai-core index c7865c240..a1999e1ba 160000 --- a/depthai-core +++ b/depthai-core @@ -1 +1 @@ -Subproject commit c7865c240c0bda74fae3d4d26af954a18380c0b6 +Subproject commit a1999e1ba3f7f0413e39a6197ab366899a046dfc diff --git a/src/DatatypeBindings.cpp b/src/DatatypeBindings.cpp index 365aa9d82..60f2c8243 100644 --- a/src/DatatypeBindings.cpp +++ b/src/DatatypeBindings.cpp @@ -304,11 +304,11 @@ void DatatypeBindings::bind(pybind11::module& m){ .def_readwrite("timestamp", &IMUReport::timestamp) ; - py::enum_(imureport, "IMUReportAccuracy") - .value("UNRELIABLE", IMUReport::IMUReportAccuracy::UNRELIABLE) - .value("LOW", IMUReport::IMUReportAccuracy::LOW) - .value("MEDIUM", IMUReport::IMUReportAccuracy::MEDIUM) - .value("HIGH", IMUReport::IMUReportAccuracy::HIGH) + py::enum_(imureport, "Accuracy") + .value("UNRELIABLE", IMUReport::Accuracy::UNRELIABLE) + .value("LOW", IMUReport::Accuracy::LOW) + .value("MEDIUM", IMUReport::Accuracy::MEDIUM) + .value("HIGH", IMUReport::Accuracy::HIGH) ; py::class_>(m, "IMUReportAccelerometer", DOC(dai, IMUReportAccelerometer)) From 62965fca1fd61b4eff2b58701a98d04649f8953d Mon Sep 17 00:00:00 2001 From: SzabolcsGergely Date: Mon, 19 Jul 2021 12:10:37 +0300 Subject: [PATCH 3/3] Update core to latest develop --- depthai-core | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/depthai-core b/depthai-core index a1999e1ba..4fe04c507 160000 --- a/depthai-core +++ b/depthai-core @@ -1 +1 @@ -Subproject commit a1999e1ba3f7f0413e39a6197ab366899a046dfc +Subproject commit 4fe04c507b00a67789a57708d6be4e76125c8a1f