-
Notifications
You must be signed in to change notification settings - Fork 691
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
feat(multi_object_tracker): reduce publish delay #6710
feat(multi_object_tracker): reduce publish delay #6710
Conversation
4091973
to
705eb8c
Compare
Codecov ReportAttention: Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #6710 +/- ##
==========================================
- Coverage 14.93% 14.93% -0.01%
==========================================
Files 1944 1944
Lines 134061 134051 -10
Branches 39891 39879 -12
==========================================
- Hits 20027 20025 -2
+ Misses 91735 91733 -2
+ Partials 22299 22293 -6
*This pull request uses carry forward flags. Click here to find out more. ☔ View full report in Codecov by Sentry. |
5fe9b3c
to
76c47f7
Compare
@YoshiRi One another key tuning point is The cyclic time is occasionally drops near to 40 ms, but the publish interval is kept within 116 ms (111 ms of configured maximum + onTimer maximum latency 5 ms) in my environment. |
// check the publish period | ||
const auto elapsed_time = (current_time - last_published_time_).seconds(); | ||
// if the elapsed time is over the period, publish objects with prediction | ||
constexpr double maximum_latency_ratio = 1.11; // 11% margin |
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.
[imo]
Since early publish is better for the planning module, I prefer larger value like 1.4 or more.
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.
the acceptable publish interval is set to 70% to 111%, as agreed with @yukkysaito
5187953
to
079f34d
Compare
This PR will be reviewed and merged after a bugfix of the MOT #6775 is merged. |
Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: reduce lower limit of publish interval Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: enlarge publish range upper limit Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: set parameter tested and agreed Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
03c087e
to
f9b483d
Compare
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.
…6710) * feat: implement a new publish timer Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * chore: add comments for new variables Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * fix: variable name was wrong Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: reduce lower limit of publish interval Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: enlarge publish range upper limit Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: set parameter tested and agreed Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> --------- Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
* feat: implement a new publish timer Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * chore: add comments for new variables Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * fix: variable name was wrong Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: reduce lower limit of publish interval Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: enlarge publish range upper limit Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: set parameter tested and agreed Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> --------- Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
…6710) * feat: implement a new publish timer Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * chore: add comments for new variables Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> * fix: variable name was wrong Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: reduce lower limit of publish interval Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: enlarge publish range upper limit Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> fix: set parameter tested and agreed Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp> --------- Signed-off-by: Taekjin LEE <taekjin.lee@tier4.jp>
Description
This PR suggests a new method to reduce latency about 100 ms.
Background:
Current multi_object_tracker publishes the tracked object triggered by a timer. This timer ensures the topic is published in target frequency. The delay is compensated by predict the tracked objects motion.
However, the input (merged objects from multiple detectors) frequency is unstable (see the following plots, name of
input_latency_ms
). The instability of the detection latency is absorbed by the multi_object_tracker and adds latency about one cycle (100 ms of TIER IV configuration).The new method:
there is two triggers to publish the tracked object
Side effect:
The publishing frequency will not be kept precisely. (see the following plots, name of
cycle_time_ms
)Related links
TIER IV INTERNAL
Tests performed
Current

Improved

Notes for reviewers
This PR will be merged after
PR #6706
PR #6757
PR #6775
This PR is an alternative work of PR #6687
TODO: improve input (merged object) stability
Interface changes
N/A
Effects on system behavior
It may reduces overall latency about one cycle of the perception (100 ms).
Pre-review checklist for the PR author
The PR author must check the checkboxes below when creating the PR.
In-review checklist for the PR reviewers
The PR reviewers must check the checkboxes below before approval.
Post-review checklist for the PR author
The PR author must check the checkboxes below before merging.
After all checkboxes are checked, anyone who has write access can merge the PR.