tracker = sv.ByteTrack(minimum_consecutive_frames=3)
detections = tracker.update_with_detections(detections)
ByteTrack은 객체 감지 결과(detections)를 입력받아, 동일 객체를 여러 프레임에 걸쳐 추적tracker.update_with_detections()는 detections 변수에는 추적된 객체 정보가 포함됨tracker.update_with_detections()의 역할감지된 객체들(detections)을 추적 상태로 변환
detections는 현재 프레임에서 감지된 객체들의 정보(바운딩 박스, 클래스 등)를 담고 있어객체의 생명 주기 관리
minimum_consecutive_frames=3 설정).추적 ID 부여 및 업데이트
detections의 변화tracker.update_with_detections(detections) 메서드를 통해 다음과 같은 정보가 detections 변수에 추가됩니다:
추적 ID (tracking_id) 추가
객체 상태 갱신
좌표 및 속성 갱신
다음과 같은 추적 정보가 포함된 객체 리스트가 반환됩니다:
detections = [
{"tracking_id": 1, "bbox": [100, 50, 200, 150], "class": "player"},
{"tracking_id": 2, "bbox": [300, 80, 400, 180], "class": "referee"},
...
]