File tree Expand file tree Collapse file tree 2 files changed +9
-4
lines changed
Expand file tree Collapse file tree 2 files changed +9
-4
lines changed Original file line number Diff line number Diff line change @@ -896,20 +896,26 @@ def tracking(self) -> str:
896896 delete_last_predictions = max ((1 , int ((self .get_average_tracking_fps ()+ 1 )* 0.5 * HYPERPARAMETER ['user_reaction_time_in_milliseconds' ]/ 1000.0 )))
897897 break
898898
899+ stop_tracking = False
899900 for tracker_number in range (self .params .number_of_trackers ):
900901 (woman_tracker_status , bbox_woman [tracker_number ]) = trackers_woman [tracker_number ].result ()
901902 if woman_tracker_status != StaticVideoTracker .Status .OK :
902903 status = 'Woman ' + woman_tracker_status
903- delete_last_predictions = (self .params .skip_frames + 1 )* 2
904+ delete_last_predictions = (self .params .skip_frames + 1 )
905+ stop_tracking = True
904906 break
905907
906908 if self .params .track_men :
907909 (men_tracker_status , bbox_men [tracker_number ]) = trackers_men [tracker_number ].result ()
908910 if men_tracker_status != StaticVideoTracker .Status .OK :
909911 status = 'Men ' + men_tracker_status
910- delete_last_predictions = (self .params .skip_frames + 1 )* 2
912+ delete_last_predictions = (self .params .skip_frames + 1 )
913+ stop_tracking = True
911914 break
912915
916+ if stop_tracking :
917+ break
918+
913919 last_frame = frame
914920
915921 if cycle_time_in_ms > 0 :
Original file line number Diff line number Diff line change @@ -18,8 +18,7 @@ preview_scaling: 0.6
1818tracker : ' CSRT'
1919
2020# Specify the wav file to play when tracking finished (write 'off' to disable the sound notification)
21- # This feature was removed in v0.1.1 due to problems on windows
22- notification_sound : ' sound_notification.wav'
21+ notification_sound : ' off'
2322
2423# Time in milliseconds at which the tracking is stopped if the selected feature is not found
2524# THIS feature is not available since v0.1.2
You can’t perform that action at this time.
0 commit comments