Docs cleanup and Google-style tracker docstrings (#6751)

Signed-off-by: Glenn Jocher <glenn.jocher@ultralytics.com>
Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com>
This commit is contained in:
Glenn Jocher 2023-12-03 04:12:33 +01:00 committed by GitHub
parent 60041014a8
commit 80802be1e5
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23
44 changed files with 740 additions and 529 deletions

View file

@ -33,10 +33,10 @@ import cv2
model = YOLO("yolov8n.pt")
cap = cv2.VideoCapture("path/to/video/file.mp4")
counter = object_counter.ObjectCounter() # Init Object Counter
counter = object_counter.ObjectCounter() # Init Object Counter
region_points = [(20, 400), (1080, 404), (1080, 360), (20, 360)]
counter.set_args(view_img=True, reg_pts=region_points,
classes_names=model.model.names, draw_tracks=True)
classes_names=model.names, draw_tracks=True)
while cap.isOpened():
success, frame = cap.read()
@ -46,7 +46,7 @@ while cap.isOpened():
counter.start_counting(frame, tracks)
```
???+ tip "Region is Moveable"
???+ tip "Region is Movable"
You can move the region anywhere in the frame by clicking on its edges