Update app.py
Browse files
app.py
CHANGED
@@ -239,7 +239,8 @@ def create_cam_visualization_pil(image_pil, cam, alpha=0.6, vis_threshold=0.2):
|
|
239 |
Returns:
|
240 |
PIL.Image.Image with overlay
|
241 |
"""
|
242 |
-
|
|
|
243 |
w, h = image_pil.size
|
244 |
|
245 |
# Resize CAM to match image
|
|
|
239 |
Returns:
|
240 |
PIL.Image.Image with overlay
|
241 |
"""
|
242 |
+
if cam is None:
|
243 |
+
return image_pil
|
244 |
w, h = image_pil.size
|
245 |
|
246 |
# Resize CAM to match image
|