Skip to content
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

Fix landing pad tracking return #207

Merged
merged 1 commit into from
Oct 12, 2024
Merged

Fix landing pad tracking return #207

merged 1 commit into from
Oct 12, 2024

Conversation

Xierumeng
Copy link
Collaborator

Changed return from single object in world to list of object in world.

Copy link
Member

@maxlou05 maxlou05 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Just some questions

@@ -54,10 +54,14 @@ def mark_confirmed_positive(self, detection: object_in_world.ObjectInWorld) -> N

Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Why does the mark false positive remove it from unconfirmed positives, but confirmed positive does not?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No idea, I will investigate.

@@ -82,16 +86,16 @@ def run(
# If new landing pad, add to list of unconfirmed positives
self.__unconfirmed_positives.append(detection)
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This seems to add it regardless of it already exists or not in the list?

Copy link
Collaborator Author

@Xierumeng Xierumeng Oct 9, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The expectation is that the input is already filtered (I think). I can add it to the docstring.

Actually, might be a bug.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it breaks if it finds a match right? so it only gets added if the loop doesn't get broken

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, you are correct. continue will skip.

Copy link
Contributor

@TongguangZhang TongguangZhang left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

approved

@@ -82,16 +86,16 @@ def run(
# If new landing pad, add to list of unconfirmed positives
self.__unconfirmed_positives.append(detection)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

it breaks if it finds a match right? so it only gets added if the loop doesn't get broken

if len(self.__confirmed_positives) > 0:
return True, self.__confirmed_positives[0]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

this changes the behaviour of decision module right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, this is the fix.

@AshishA26 AshishA26 self-requested a review October 11, 2024 03:41
Copy link
Contributor

@AshishA26 AshishA26 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

lgtm

@Xierumeng Xierumeng merged commit f01f598 into main Oct 12, 2024
1 check passed
@Xierumeng Xierumeng deleted the landing-pad-tracking-fix branch October 12, 2024 18:09
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

4 participants