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

SAM2 reverse propagation #688

Open
1 of 2 tasks
quantaji opened this issue Oct 19, 2024 · 4 comments
Open
1 of 2 tasks

SAM2 reverse propagation #688

quantaji opened this issue Oct 19, 2024 · 4 comments
Labels
enhancement New feature or request Implemented

Comments

@quantaji
Copy link

Search before asking

  • I have searched the X-AnyLabeling issues and found no similar feature requests.

Description

It would be very convenient if I can annotate a frame in the middle of a period where the object is appearing. Therefore, it would be nice if the tool can also reversely propagate key frame's annotation!

Use case

No response

Additional

No response

Are you willing to submit a PR?

  • Yes I'd like to help by submitting a PR!
@quantaji quantaji added the enhancement New feature or request label Oct 19, 2024
@CVHub520
Copy link
Owner

Hey there! @quantaji
Thank you for bringing this to our attention. I'd like to clarify that the current software actually does support annotating any object on any frame directly. Here's how you can achieve what you're looking for:

Let's say your task has n total frames. You can annotate objects on any arbitrary frame k as follows:

  1. Navigate to frame k
  2. Press Ctrl+Del to delete any existing annotations on that frame (if present)
  3. Click "Reset Tracker"
  4. You can now treat frame k as your initial frame and annotate objects of interest
  5. Assign appropriate label names and IDs based on your specific task requirements

This process can be applied to any frame in your sequence. It allows you to flexibly annotate objects appearing in the middle of a period without needing reverse propagation.

Does this approach meet your needs? If you have any questions about implementing this workflow or if there are any other specific functionalities you're looking for, please let me know and I'd be happy to provide further assistance.

@quantaji
Copy link
Author

If I annotate an object in frame k, can the current software propagate the annotation to frame k-1, k-2, k-3, ... etc?

Thanks!

@CVHub520
Copy link
Owner

@quantaji The current software doesn't support propagating annotations backwards to frames k-1, k-2, k-3, etc. However, it can propagate annotations forward to subsequent frames k+1, k+2, k+3, and so on. This forward propagation allows you to extend annotations to future frames after annotating an object in frame k. If you need to annotate previous frames, you would need to navigate to those frames and annotate them individually using the process described earlier.

@quantaji
Copy link
Author

Thank you for your reply! This can some times hard because there are cases when masks appear from a very small area of pixel and tracking from a small mask might be hard for the model and the result might be unreliable.

I would like to ask if it is possible to put backward (or "reverse" as this is the word used in sam2) propagation as a future feature? This would be really helpful and make this annotation tool outstanding among other tools!

Thanks!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request Implemented
Projects
None yet
Development

No branches or pull requests

2 participants