C4:W4 Face Recognition: Exercise 1 - triplet_loss

loss = tf.Tensor([ 0. 552.6598 0. ], shape=(3,), dtype=float32)
I have added alpha using tf.add and tf.reduce_sum with axis-1 is getting me the above

I keep getting the above and then the following Assertion Error:

AssertionError Traceback (most recent call last)
in
14 y_pred_perfect = ([1., 1.], [1., 1.], [1., 1.,])
15 loss = triplet_loss(y_true, y_pred_perfect, 5)
—> 16 assert loss == 5, “Wrong value. Did you add the alpha to basic_loss?”
17 y_pred_perfect = ([1., 1.],[1., 1.], [0., 0.,])
18 loss = triplet_loss(y_true, y_pred_perfect, 3)

AssertionError: Wrong value. Did you add the alpha to basic_loss?

I realized I was forgetting to do reduce_sum for the L2 norm’s, now I’m getting:
loss = tf.Tensor([ 0. 527.2598 0. ], shape=(3,), dtype=float32)

I figured the problem out