Spaces:
Runtime error
Runtime error
Update app.py
Browse files
app.py
CHANGED
|
@@ -10,7 +10,7 @@ from io import BytesIO
|
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
# Load the model
|
| 13 |
-
MODEL_PATH = "BacterialMorphologyClassification_model.ipynb"
|
| 14 |
model = models.mobilenet_v2(weights=None)
|
| 15 |
model.classifier[1] = nn.Linear(model.last_channel, 3)
|
| 16 |
model.load_state_dict(torch.hub.load_state_dict_from_url(MODEL_PATH, map_location=torch.device('cpu')))
|
|
|
|
| 10 |
app = FastAPI()
|
| 11 |
|
| 12 |
# Load the model
|
| 13 |
+
MODEL_PATH = "BacterialMorphologyClassification_model.pth.ipynb"
|
| 14 |
model = models.mobilenet_v2(weights=None)
|
| 15 |
model.classifier[1] = nn.Linear(model.last_channel, 3)
|
| 16 |
model.load_state_dict(torch.hub.load_state_dict_from_url(MODEL_PATH, map_location=torch.device('cpu')))
|