Update app.py
Browse files
app.py
CHANGED
@@ -15,7 +15,7 @@ with open('best_model.pth', 'wb') as f:
|
|
15 |
f.write(model_content)
|
16 |
|
17 |
# Load your custom model onto the CPU
|
18 |
-
model = torch.hub.load('ultralytics/yolov5', 'custom', path='best_model.pth')
|
19 |
model.eval()
|
20 |
|
21 |
# Define a function that takes an image as input and uses the model for inference
|
|
|
15 |
f.write(model_content)
|
16 |
|
17 |
# Load your custom model onto the CPU
|
18 |
+
model = torch.hub.load('ultralytics/yolov5', 'custom', path='best_model.pth', force_reload=True)
|
19 |
model.eval()
|
20 |
|
21 |
# Define a function that takes an image as input and uses the model for inference
|