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.
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
MOTA revisited #181
MOTA revisited #181
Changes from 33 commits
73ea420
768b81e
3036b06
f18a44c
6c0b0ed
a851e9f
611bd60
11bded7
4b9a794
cfe67ca
7de7561
25f36c7
de0b9cd
5e56e1a
6aa1b63
05faa18
a592c1a
eefcf33
f0bcf65
da0c62b
01cb0f4
3ca1872
4d32f77
ff059ea
1195854
67fe295
9bf3a73
93915e1
e1a8537
d6401e1
64ae8e8
73ae064
163cc06
cc6bbcf
f042b2b
56ff81d
73607b4
f8c91a9
21930ac
0e8a687
6e12530
36757a5
5b5e1de
e8f4446
a464d15
98e77c3
41ab8cc
491ae68
43e3c86
5e11991
8b8b9c9
cc1e8c6
fcf6e66
7a2ba9f
fa7fa08
24935ae
1d45dd6
File filter
Filter by extension
Conversations
Jump to
There are no files selected for viewing
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.
I like it, it's compact!
But we also discussed offline a different implementation that I feel structures the problem a bit more and reads a bit better.
We also initially thought it would cover cases that are missing here, but I think with all the fixes it doesn't anymore 😅. So just an alternative.
Below the pseudocode.
definitions
map_gt_to_pred_id_prev
: dictionary that maps fromgtID
inf-1
topredID
inf-1
map_gt_to_pred_id_current
: dictionary that maps fromgtID
inf
topredID
inf
For both of these maps, if a crab is not detected in the frame, then
predID = np.nan
.pseudocode
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.
Example 1:
previous frame = {1: 11, 2: 12, 3: 13},
current frame = {1: 11, 2: 12, 4: 13},
The previous gt ID 3 disappear, but the corresponding predicted ID 13 is in current frame. So we consider this ID switch.
The current gt ID 4 appear, and the current predicted ID 13 is in the previous frame. SO we consider this ID switch. In this example, switch_counter is equal to 2. It should be only one right?
Example 2:
previous frame = {1: 11, 2: 12, 3: 13, 4: 14},
current frame = {1: 11, 2: 12, 3: 14},
The gt ID 3 is continue to exist, but the current predicted ID is not the same to the previous predicted ID. We count this as 1 ID switch.
The gt ID 4 is disappear, but the predicted ID 14 is still exist in current frame. so we have total of 2 ID switch. This also should be one right?
The problem we have, we will check every condition, even if we already count the switch. So some example that can apply on more than one cases, will be counted more than once
I have added another condition to see if we already used red_ids in the previous case, then we will not count the switch -- considering we should not count the ID switch on the same predicted ID for more than once.
Let me know what you think
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.
thanks @nikk-nikaznan this is an excellent catch.
I think I agree with example 1 and 2 having an expected switch count = 1
I see, you used
used_pred_ids
to log if IDs in either the current or the previous frame have been involved in an already counted ID switch.I think this makes sense to me! I added a comment to that line just to mega clarify.