Update app.py
Browse files
app.py
CHANGED
@@ -31,7 +31,7 @@ BATCH_SIZE = 4 # Process 4 frames at a time
|
|
31 |
|
32 |
# Load model
|
33 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
34 |
-
model = attempt_load("
|
35 |
model.to(device).eval() # Move model to device and set to evaluation mode
|
36 |
|
37 |
# Function to process video and detect ball
|
|
|
31 |
|
32 |
# Load model
|
33 |
device = torch.device("cuda" if torch.cuda.is_available() else "cpu")
|
34 |
+
model = attempt_load("yolov5s.pt") # Load without map_location
|
35 |
model.to(device).eval() # Move model to device and set to evaluation mode
|
36 |
|
37 |
# Function to process video and detect ball
|