-
Notifications
You must be signed in to change notification settings - Fork 158
Pipeline debugging #1470
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
Open
asahtik
wants to merge
113
commits into
develop
Choose a base branch
from
feature/pipeline_debugging
base: develop
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Open
Pipeline debugging #1470
Changes from 79 commits
Commits
Show all changes
113 commits
Select commit
Hold shift + click to select a range
5110bcc
Added pipeline events messages and node
asahtik e165806
Added the pipeline event dispatcher
asahtik fbd4137
Add Pipeline event bindings
asahtik 9876101
Integrate pipeline events
asahtik 0e00bff
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik b2024f0
RVC4 FW: initial pipeline debugging impl
asahtik 75e9386
Pipeline events bugfixes, pipeline state merge node
asahtik a1668e7
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 99ce452
Some pipeline debugging bugfixes
asahtik 10753f0
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 914cbc5
Fix pipeline events on host
asahtik d30b5fd
Fix RVC4 pipeline events crash
asahtik 3a579ac
RVC4 FW: Fix pipeline events crash
asahtik 2e9b26d
Add more stats, queue state WIP
asahtik a5e93d8
Event instances now have independent sequence numbers
asahtik 38481f0
Do not update stats for every event
asahtik 978e9b9
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 962d4af
Fix dropped pipeline events
asahtik b79ded6
RVC4 FW: Fix dropped pipeline events
asahtik de20f54
Added queue size stats
asahtik 4854124
WIP pipeline state api
asahtik c34cc45
Implement service like api for pipeline state
asahtik f9835ee
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik fcbfe78
Remove static assert
asahtik 28e5b93
Bugfixes
asahtik 215119d
Collect events in a different thread
asahtik e8045e4
WIP: dispatcher + state improvements
asahtik 36e917a
Do not require adding events, node / input states, other improvements
asahtik 1991426
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 48c1b6a
Add ability to get the entire pipeline schema, add bridge info to pip…
asahtik c8ec85a
Add comments to pipeline state
asahtik 1a2b848
Bugfix
asahtik 8b87d55
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 5a6d765
Update input queue size more often
asahtik af86cae
Add ability to disable sending pipeline events
asahtik 0405afb
Remove ongoing event warnings
asahtik af4d644
RVC4 FW: core bump
asahtik 5024bc9
Fix getting pipeline state from device
asahtik a5dbc4a
Bugfix, implement API for getting state (c++)
asahtik 89a168f
Fix pipeline state filtering
asahtik c5befed
RVC4 FW: time main loop of some nodes
asahtik c79abbf
Add python bindings for getting pipeline state
asahtik df8011b
Implement tracking events through threads
asahtik fd27d19
Add missing files
asahtik 66e4fcd
Add mutex lock to pipeline event dispatcher
asahtik c084252
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 75592f7
Fix docstrings errors
asahtik c55d212
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 4cef1e6
Disable pipeline events
asahtik bb92f4f
Reduce pipeline state stat calculation, add ability to disable sendin…
asahtik a13c0ef
RVC4 FW: update core with pipeline debugging improvemets
asahtik b3e34dc
Bugfixes, add block events for host runnable nodes
asahtik 0017ab7
RVC4 FW: Add io events to some nodes
asahtik 55e7dd7
Use group and name for event source
asahtik eb699aa
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik ef20c8b
Add default values to pipeline state
asahtik e0a4775
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 6b58440
Add pipeline debugging tests
asahtik b4a8834
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 312384a
Pipeline debugging bugfixes
asahtik 5e1847b
Pipeline debugging test improvements, bugfixes
asahtik cc8638e
Add pipeline debugging test for rvc4
asahtik 7149f32
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 5632e03
RVC4 FW: Pipeline debugging fixes, add to nodes
asahtik ddef6df
TMP: run tests with pipeline debugging enabled
asahtik 411134a
RVC2 FW: Pipeline debugging bugfixes
asahtik 1dd9736
Add DEPTHAI_PIPELINE_DEBUGGING to tests env
asahtik 4677f08
PR fixes
asahtik 9874b63
Add ability go get schema without pipeline debugging stuff [no ci]
asahtik 1b3533c
clangformat
asahtik ab22e6b
Pipeline debugging: fix HostNode crash [no ci]
asahtik ae05e48
RVC4 FW: Added pipeline debugging info to videoencoder
asahtik c0aef2a
Make block events thread safe
asahtik 04f50b0
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 19422fb
Bugfixes [no ci]
asahtik a8cd279
RVC4 FW: Core update
asahtik 4879c08
RVC2 FW: Fix pipeline debugging fps calculation [no ci]
asahtik d1c961e
Add pipeline debugging input duration test
asahtik 065a97c
Add foxglove service for full pipeline and pipeline state + support f…
asahtik ab48d74
Change pipeline state fg json [no ci]
asahtik 0c87474
RVC2 FW: Fix script node issue with pipeline debugging
asahtik 22ac8fd
Add toJson to PipelineState
asahtik fd4e692
Add pipeline debugging examples
asahtik 0f89f3e
Fix try get pipeline debugging issue
asahtik 5e194e3
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik aeaa95a
bugfixes, pipeline event dispatcher improvements [no ci]
asahtik 4e242b7
RVC4 FW: Add pipeline debugging to stereo depth, camera
asahtik d758208
Fix macos build?
asahtik b9cda65
Change device to deviceId & deviceNode in objinfo [no ci]
asahtik d32da8a
RVC4 FW: update core [no ci]
asahtik 8589893
RVC2 FW: update core
asahtik 568ad64
PR fixes
asahtik e6e28b5
Merge branch 'feature/pipeline_debugging' of github.com:luxonis/depth…
asahtik a79afee
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik d0087cf
Remove pipeline debugging env var from tests
asahtik 2d0fc90
Add example for pipeline event subscription
asahtik 560d764
Clangformat
asahtik 2c80e92
Macos build fix v2?
asahtik c4ba9a2
Fix windows build of example
asahtik 921993f
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik bcbf584
MacOs build fix v3 [no ci]
asahtik 97897e1
RVC4 FW: merge develop [no ci]
asahtik 201bbd3
RVC2 FW: merge develop
asahtik c04ed85
Fix include [no ci]
asahtik 7637f2e
RVC2 FW: Update core [no ci]
asahtik f3eeb97
Added pipeline debugging docs
asahtik 7bd26b6
Merge branch 'feature/pipeline_debugging' of github.com:luxonis/depth…
asahtik 3a14630
Move section in PD docs
asahtik b71c87f
Add background to PD doc schema
asahtik e5bc755
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik cd4b338
RVC2 FW: Update core
asahtik c84b861
Merge branch 'develop' of github.com:luxonis/depthai-core into featur…
asahtik 0caa3d3
RVC4 FW: Update core
asahtik File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
59 changes: 59 additions & 0 deletions
59
bindings/python/src/pipeline/datatype/PipelineEventBindings.cpp
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,59 @@ | ||
| #include <memory> | ||
| #include <unordered_map> | ||
|
|
||
| #include "DatatypeBindings.hpp" | ||
| #include "pipeline/CommonBindings.hpp" | ||
|
|
||
| // depthai | ||
| #include "depthai/pipeline/datatype/PipelineEvent.hpp" | ||
|
|
||
| // pybind | ||
| #include <pybind11/chrono.h> | ||
| #include <pybind11/numpy.h> | ||
|
|
||
| // #include "spdlog/spdlog.h" | ||
|
|
||
| void bind_pipelineevent(pybind11::module& m, void* pCallstack) { | ||
| using namespace dai; | ||
|
|
||
| py::class_<PipelineEvent, Py<PipelineEvent>, Buffer, std::shared_ptr<PipelineEvent>> pipelineEvent(m, "PipelineEvent", DOC(dai, PipelineEvent)); | ||
| py::enum_<PipelineEvent::Type> pipelineEventType(pipelineEvent, "Type", DOC(dai, PipelineEvent, Type)); | ||
| py::enum_<PipelineEvent::Interval> pipelineEventInterval(pipelineEvent, "Interval", DOC(dai, PipelineEvent, Interval)); | ||
|
|
||
| /////////////////////////////////////////////////////////////////////// | ||
| /////////////////////////////////////////////////////////////////////// | ||
| /////////////////////////////////////////////////////////////////////// | ||
| // Call the rest of the type defines, then perform the actual bindings | ||
| Callstack* callstack = (Callstack*)pCallstack; | ||
| auto cb = callstack->top(); | ||
| callstack->pop(); | ||
| cb(m, pCallstack); | ||
| // Actual bindings | ||
| /////////////////////////////////////////////////////////////////////// | ||
| /////////////////////////////////////////////////////////////////////// | ||
| /////////////////////////////////////////////////////////////////////// | ||
|
|
||
| pipelineEventType.value("CUSTOM", PipelineEvent::Type::CUSTOM) | ||
| .value("LOOP", PipelineEvent::Type::LOOP) | ||
| .value("INPUT", PipelineEvent::Type::INPUT) | ||
| .value("OUTPUT", PipelineEvent::Type::OUTPUT); | ||
| pipelineEventInterval.value("NONE", PipelineEvent::Interval::NONE) | ||
| .value("START", PipelineEvent::Interval::START) | ||
| .value("END", PipelineEvent::Interval::END); | ||
|
|
||
| // Message | ||
| pipelineEvent.def(py::init<>()) | ||
| .def("__repr__", &PipelineEvent::str) | ||
| .def_readwrite("nodeId", &PipelineEvent::nodeId, DOC(dai, PipelineEvent, nodeId)) | ||
| .def_readwrite("status", &PipelineEvent::status, DOC(dai, PipelineEvent, status)) | ||
| .def_readwrite("queueSize", &PipelineEvent::queueSize, DOC(dai, PipelineEvent, queueSize)) | ||
| .def_readwrite("interval", &PipelineEvent::interval, DOC(dai, PipelineEvent, interval)) | ||
| .def_readwrite("type", &PipelineEvent::type, DOC(dai, PipelineEvent, type)) | ||
| .def_readwrite("source", &PipelineEvent::source, DOC(dai, PipelineEvent, source)) | ||
|
Collaborator
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Doesn't need bindings, should work "automagically" |
||
| .def("getTimestamp", &PipelineEvent::Buffer::getTimestamp, DOC(dai, Buffer, getTimestamp)) | ||
| .def("getTimestampDevice", &PipelineEvent::Buffer::getTimestampDevice, DOC(dai, Buffer, getTimestampDevice)) | ||
| .def("getSequenceNum", &PipelineEvent::Buffer::getSequenceNum, DOC(dai, Buffer, getSequenceNum)) | ||
| .def("setTimestamp", &PipelineEvent::setTimestamp, DOC(dai, Buffer, setTimestamp)) | ||
| .def("setTimestampDevice", &PipelineEvent::setTimestampDevice, DOC(dai, Buffer, setTimestampDevice)) | ||
| .def("setSequenceNum", &PipelineEvent::setSequenceNum, DOC(dai, Buffer, setSequenceNum)); | ||
| } | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
SyncBindings were duplicated (line 96)