Update app.py
Browse files
app.py
CHANGED
|
@@ -166,7 +166,8 @@ m = model.to(device)
|
|
| 166 |
# print(sum(p.numel() for p in m.parameters()) / 1e3, "K parameters")
|
| 167 |
|
| 168 |
# load the model.pth
|
| 169 |
-
model.load_state_dict(torch.load("model.pth", weights_only=
|
|
|
|
| 170 |
model.eval()
|
| 171 |
|
| 172 |
def respond(
|
|
|
|
| 166 |
# print(sum(p.numel() for p in m.parameters()) / 1e3, "K parameters")
|
| 167 |
|
| 168 |
# load the model.pth
|
| 169 |
+
model.load_state_dict(torch.load("model.pth", weights_only=false, map_location=torch.device('cpu') )
|
| 170 |
+
|
| 171 |
model.eval()
|
| 172 |
|
| 173 |
def respond(
|