Week 3 Assignment: Question Duplicates

Hi all, I have a question on Week 3 Assignment Exercise 03. I am getting the below error when the cell is evaluating on my train_model() function., but not sure how to resolve this. My lab id is qkuaicxsyeqe

Thank you.

Screenshot 2023-12-31 at 10.46.48 AM

Hi @Nathan_Lur

To me, this indicates that you probably have some mistakes in TripletLossFn implementation. Please check that function if it meets the expected output and passes the unit tests.

Let me know if that solves your issue.
Cheers

Hi,

I managed to pass all unit tests of the TripletLossFn but still facing the same error.

Do you by chance use TripletLossFn instead of TripletLoss in your train_model(..) model implementation?

I am using TripletLoss in the train_model implementation.

If someone else encounter the same problem in the future:

  • the inputs (input1 and input2) in the Exercise 1 Siamese(..) function are of type: tf.string and not any other type.
1 Like