Course 4 Week 4 Assignment 1 Exercise 1

My code gets really close to the answer but is off by a few decimals. I have only used tensorflow methods so im not sure why this happens.

For exercise 2 and 3.

Interesting. Well, everything we do in floating point is an approximation and there can be different ways to express a computation that are mathematically equivalent, but have different rounding behavior.

That said, I’m not seeing too many ways to do things differently. In the case of triplet_loss, it’s just your code, but there aren’t too many variations I can think of that still give the correct answer. In the case of verify, it depends on the actual imported model and the img_to_encoding function. Are you sure you didn’t modify that function? E.g. change the “around” call parameters?

The other general question: I assume everything you are doing is in the Coursera web environment. If you have downloading things and are running them in your own environment or on Colab, then all bets are off: you may have different versions of the gazillion packages that are needed to support everything here.

Everything is on coursera web and I didnt change the img_to_encoding function. Is there a way where i can send you the code for this to check for any anomalies without violating coursera honur code?