Title: C3W4 Saliency Maps Assignment - Consistently getting ~0.87 SSIM instead of the expected ~0.95
Hi everyone,
I’m working on the C3W4 Cats vs Dogs Saliency Maps assignment in the Advanced Computer Vision with TensorFlow course, and I’m stuck on the grader.
The grader reports:
Your images achieved an average structural similarity index of 0.87. At least 0.88 is required to pass.
Per-image scores:
-
salientcat1.jpg: 0.85
-
salientcat2.jpg: 0.86
-
salientcatanddog.jpg: 0.90
-
salientdog1.jpg: 0.87
-
salientdog2.jpg: 0.85
According to the notebook instructions, the expected average should be around 0.95, so I believe something in my implementation is still incorrect.
Here’s what I’ve already verified:
-
The model architecture matches the notebook.
-
I load the provided 15_epochs.h5 weights before training.
-
I train for exactly 3 additional epochs.
-
I’m using
RMSprop(learning_rate=0.001)andsparse_categorical_crossentropyas specified. -
Images are converted from BGR to RGB, resized to 300×300, and normalized by dividing by 255.0.
-
The saliency function uses
GradientTape,tf.one_hot,categorical_crossentropy,tf.reduce_max(tf.abs(gradient), axis=-1), and min-max normalization exactly as described.
Could someone point out any common mistakes that typically lead to SSIM values around 0.87 instead of the expected 0.95? If needed, I can also share my notebook or the graded cells.
Thanks!

