-
Notifications
You must be signed in to change notification settings - Fork 25
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
slows down when there are lots of labels in a video sequence #15
Comments
@jascase901 , How many images and no of bounding boxes per image did you had in your data set ? also dimension of each image ? Thanks |
@manishs17 Thanks for working with me. I spent a little more time digging into the issue. And it turns out reproducing it is a bit more complicated then just adding labels to a video sequence. While adding labels, via the track function does slow it down. The main issue is adding new chains of labels. Heres what I ended up doing to come to this conclusion.
2.) I applied my merge request.
The meat of the function is this line 3.) I generated 3000 images of circles to test. In my test case the video sequence swaps between these two images Code to generate test images is here. 4.) This step is time consuming. But I labled every 100 frames, until about frame 1200 This gives me 649 annotations 6.) Then I trigger a redraw event. either draw a rectangle, move a rectangle, go to another frame, or hit f5, with my console open and time how long it takes to redraw all the rectangles in the image. With my early stop
without my early stop, where we go and set bounding boxes for every annotation
|
while annotating the above test set, did you annotate each object in each frame independently ? or you used a tracker to annotate objects in multiple frames at once. This is because the inherited design follows a track, multiple annotations become part of same annotation array, that's y this problem arises. |
I didn't use the tracker. When I tried to use the tracker the problem didn't come up. I think this is because
In my real example I was labeling vehicles on a small part of a busy street. New vehicles were constantly leaving and entering the area I was labeling. Which caused new annotations to be added to the annotation array. |
When there are a lot of labels in your video sequence, drawing boxes, moving boxes, and playing the video slows down.
every time you do one of these operations eva loops through all our bounding boxes for every annotation in your video sequence, and sets the box to hidden if its outside the frame, then calls set bounds on the rect. The math involved in set bounds can slow down the entire system if there are a lot of rectangles.
see pull request #14 for a potential fix.
The text was updated successfully, but these errors were encountered: