Spaces:
Sleeping
Sleeping
Update app.py
Browse files
app.py
CHANGED
@@ -29,7 +29,7 @@ def preprocess_image(img):
|
|
29 |
return img
|
30 |
|
31 |
# ✅ 4. Grad-CAM Generation
|
32 |
-
def make_gradcam(img_array, model, last_conv_layer_name='
|
33 |
"""Generate Grad-CAM for the given image and model."""
|
34 |
last_conv_layer = model.get_layer(last_conv_layer_name)
|
35 |
grad_model = Model(inputs=model.inputs, outputs=[last_conv_layer.output, model.output])
|
|
|
29 |
return img
|
30 |
|
31 |
# ✅ 4. Grad-CAM Generation
|
32 |
+
def make_gradcam(img_array, model, last_conv_layer_name='Conv_1_bn'):
|
33 |
"""Generate Grad-CAM for the given image and model."""
|
34 |
last_conv_layer = model.get_layer(last_conv_layer_name)
|
35 |
grad_model = Model(inputs=model.inputs, outputs=[last_conv_layer.output, model.output])
|