We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1610034 commit 7ff4d2eCopy full SHA for 7ff4d2e
pytorch_grad_cam/utils/image.py
@@ -165,7 +165,7 @@ def scale_cam_image(cam, target_size=None):
165
img = img - np.min(img)
166
img = img / (1e-7 + np.max(img))
167
if target_size is not None:
168
- if len(img.shape) > 3:
+ if len(img.shape) > 2:
169
img = zoom(np.float32(img), [
170
(t_s / i_s) for i_s, t_s in zip(img.shape, target_size[::-1])])
171
else:
0 commit comments