{moderator edit - solution code removed}
I am getting error:
AssertionError: Test does not match. Did you get the reduce sum of your loss functions?
Can you plz assist me why I am getting this error
{moderator edit - solution code removed}
I am getting error:
AssertionError: Test does not match. Did you get the reduce sum of your loss functions?
Can you plz assist me why I am getting this error
Which week of the course and which assignment is this from?
Assignment: Tensorflow Introduction
Weak: 3
There is no “compute_loss” function in that assignment.
It in “Improving Deep Neural Networks: Hyperparameter Tuning, Regularization and Optimization” course
Do you mean the “compute_total_loss()” function?
Please post a screen capture image of the entire cell that contains the error message.
You have to transpose logits and labels. Check this.
I have transposed them but still having same error:
{moderator edit - solution code removed}
Instead of sharing your code, share your full error.
AssertionError Traceback (most recent call last)
in
17 print(“\033[92mAll test passed”)
18
—> 19 compute_total_loss_test(compute_total_loss, new_y_train )
in compute_total_loss_test(target, Y)
13 print(result)
14 assert(type(result) == EagerTensor), “Use the TensorFlow API”
—> 15 assert (np.abs(result - (0.50722074 + 1.1133534) / 2.0) < 1e-7), “Test does not match. Did you get the reduce sum of your loss functions?”
16
17 print(“\033[92mAll test passed”)
AssertionError: Test does not match. Did you get the reduce sum of your loss functions?
Expected output
tf.Tensor(0.810287, shape=(), dtype=float32)
Please check the definition of the loss function API. You are passing the arguments incorrectly.