Commit 3aabafd 1 parent f8d4663 commit 3aabafd Copy full SHA for 3aabafd
File tree 1 file changed +3
-3
lines changed
perception/multi_object_tracker/src
1 file changed +3
-3
lines changed Original file line number Diff line number Diff line change @@ -437,9 +437,9 @@ void MultiObjectTracker::sanitizeTracker(
437
437
}
438
438
439
439
if (delete_candidate_tracker) {
440
- /* erase only when prioritized one has a measurement or the other one doesn't */
441
- if (sorted_list_tracker[i]->getNoMeasurementCount ( ) <= 0 or
442
- sorted_list_tracker[j]->getNoMeasurementCount () > 0 ) {
440
+ /* erase only when prioritized one has later(or equal time) meas than the other's */
441
+ if (sorted_list_tracker[i]->getElapsedTimeFromLastUpdate ( time ) <=
442
+ sorted_list_tracker[j]->getElapsedTimeFromLastUpdate ( time ) ) {
443
443
// Remove from original list_tracker
444
444
list_tracker.remove (sorted_list_tracker[j]);
445
445
// Remove from sorted list
You can’t perform that action at this time.
0 commit comments