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

Extending SAM2 Video Tracking to Multiple Objects #657

Closed
Buckler89 opened this issue Oct 30, 2024 · 1 comment
Closed

Extending SAM2 Video Tracking to Multiple Objects #657

Buckler89 opened this issue Oct 30, 2024 · 1 comment

Comments

@Buckler89
Copy link

I'm currently working on extending the SAM2 video tracking (example) to support tracking multiple objects, as currently, only a single object can be tracked.

After diving into the example code (and fixing unrelated issues such as [#656]), I've found that the primary limitation seems to be related to the context parameter passed to the predict method. If I understand correctly, this parameter only contains information about the current label added by the user, and lacks context about other existing labels.

Is there a way to pass the full "context" to the predict method so that all existing labels are accessible during the tracking?

Here is my labeling interface setup:

<View>
   <Labels name="videoLabels" toName="video" allowEmpty="true">
     <Label value="Man" background="blue"/>
     <Label value="Woman" background="red"/>
     <Label value="Other" background="green"/>
   </Labels>
   
   <!-- Please specify FPS carefully, it will be used for all project videos -->
   <Video name="video" value="$video" framerate="25.0"/>
   <VideoRectangle name="box" toName="video" />
</View>

<!--{
 "video": "/static/samples/opossum_snow.mp4"
}-->
@Buckler89
Copy link
Author

Closing this issue as it will be resolved once issue #664 is resolved.

@Buckler89 Buckler89 closed this as not planned Won't fix, can't repro, duplicate, stale Nov 19, 2024
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

No branches or pull requests

1 participant