Spaces:
Paused
Paused
Zhen Ye Claude Opus 4.6 commited on
Commit ·
0d3be57
1
Parent(s): ba91677
Fix Grounding DINO detections dropped by ByteTracker threshold mismatch
Browse filesLower ByteTracker new_track_thresh from 0.40 to 0.30 so DINO scores
(≥0.35) can spawn tracks. Harden DINO _post_process to remove bare
fallback that silently dropped to HuggingFace default threshold of 0.25.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Files changed (2)
61 unmodified lines6263646566676869707172737475767778798081828384858661 unmodified linesreturn self.processor.post_process_grounded_object_detection(outputs,input_ids,box_threshold=self.box_threshold,text_threshold=self.text_threshold,target_sizes=target_sizes,)except TypeError:try:return self.processor.post_process_grounded_object_detection(outputs,input_ids,threshold=self.box_threshold,text_threshold=self.text_threshold,target_sizes=target_sizes,)except TypeError:return self.processor.post_process_grounded_object_detection(outputs,input_ids,target_sizes=target_sizes,)def _parse_single_result(self, processed) -> DetectionResult:boxes = processed["boxes"].cpu().numpy()61 unmodified lines6263646566676869707172737475767778798061 unmodified linesreturn self.processor.post_process_grounded_object_detection(outputs,input_ids,threshold=self.box_threshold,text_threshold=self.text_threshold,target_sizes=target_sizes,)except TypeError:# Older transformers versions used box_thresholdreturn self.processor.post_process_grounded_object_detection(outputs,input_ids,box_threshold=self.box_threshold,text_threshold=self.text_threshold,target_sizes=target_sizes,)def _parse_single_result(self, processed) -> DetectionResult:boxes = processed["boxes"].cpu().numpy()
359 unmodified lines360361362363364365366359 unmodified linesclass ByteTracker:def __init__(self, track_high_thresh=0.3, track_low_thresh=0.1,new_track_thresh=0.4, track_buffer=60, match_thresh=0.8,frame_rate=30, min_hits=3):STrack.reset_count()self.track_high_thresh = track_high_thresh359 unmodified lines360361362363364365366359 unmodified linesclass ByteTracker:def __init__(self, track_high_thresh=0.3, track_low_thresh=0.1,new_track_thresh=0.3, track_buffer=60, match_thresh=0.8,frame_rate=30, min_hits=3):STrack.reset_count()self.track_high_thresh = track_high_thresh
models/detectors/grounding_dino.py+9-15
utils/tracker.py+1-1