Skip to content

Commit

Permalink
Merge pull request #41 from CornellDataScience/backend-updates
Browse files Browse the repository at this point in the history
Merge working demo into ball-202
  • Loading branch information
ericguo31 authored Dec 4, 2023
2 parents 9b568c1 + 8497ce1 commit 1cc8862
Show file tree
Hide file tree
Showing 4 changed files with 546 additions and 4 deletions.
2 changes: 1 addition & 1 deletion docker-compose.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ version: '3'

services:
hooptracker-backend:
image: kchiem12/hooptracker-backend:v1.0
image: kchiem12/hooptracker-backend:v2.0
ports:
- "8000:8000"
env_file: .env
2 changes: 1 addition & 1 deletion src/api/backend.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ async def process_file(file_name: str):
results_path = "results-" + file_name + ".txt"
court_reenc_path = "court_video_reenc-" + file_name + ".mp4"
s3.upload_file("tmp/results.txt", "hooptracker-uploads", results_path)
s3.upload_file("tmp/court_video_reenc.mp4", "hooptracker-uploads", court_reenc_path)
s3.upload_file("tmp/processed.mp4", "hooptracker-uploads", court_reenc_path)
return {"message": f"successfully processed {file_name}", "status": "success"}
except Exception as ex:
return {"error": str(ex)}
Expand Down
3 changes: 2 additions & 1 deletion src/strongsort/yolov5/detect.py
Original file line number Diff line number Diff line change
Expand Up @@ -170,7 +170,8 @@ def run(
parents=True, exist_ok=True
) # make dir

# Load model
# Load
# device = '0' # force it to get a gpu
device = select_device(device)
model = DetectMultiBackend(
yolo_weights, device=device, dnn=dnn, data=None, fp16=half
Expand Down
Loading

0 comments on commit 1cc8862

Please sign in to comment.