Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
|
@@ -60,7 +60,7 @@ def inference(input_img, show_gradcam, layer_name, num_classes, transparancy = 0
|
|
| 60 |
softmax = torch.nn.Softmax(dim=0)
|
| 61 |
o = softmax(outputs.flatten())
|
| 62 |
|
| 63 |
-
output_numpy = np.squeeze(np.asarray(outputs.numpy()))
|
| 64 |
index_sort = np.argsort(output_numpy)[::-1]
|
| 65 |
|
| 66 |
confidences = {}
|
|
|
|
| 60 |
softmax = torch.nn.Softmax(dim=0)
|
| 61 |
o = softmax(outputs.flatten())
|
| 62 |
|
| 63 |
+
output_numpy = np.squeeze(np.asarray(outputs.detach().numpy()))
|
| 64 |
index_sort = np.argsort(output_numpy)[::-1]
|
| 65 |
|
| 66 |
confidences = {}
|