Hi,
I am stuck. I have spent over a day on Exercise 3 - TripletLossFn. The instructions conflict, for example the detailed instruction say to use " triple_loss
is the fastnp.mean
of the sum of the two individual losses." while the code states " # add the two losses together and take the fastnp.sum
of it ".
I do not understand this requirement with the masks. I find it confusing.
create a composition of two masks:
# the first mask to extract the diagonal elements,
# the second mask to extract elements in the negative_zero_on_duplicate matrix that
# are larger than the elements in the diagonal
For the line " # the first mask to extract the diagonal elements, " → extract from what and in what shape ?
Again, for the second mask, what shape is it supposed to be. If I extract I reduce the shape. To extract elements that "are larger than the elements in the diagonal " - does this mean the the diagonal element in a row or the max of all diagonal elements or the diagonal i have already extracted ? How do you compare to elements ie the plural ?
The instructions are confusing and I am stuck. I have most of exercise 3 correct ( I hope ). I need some help with finalising this exercise please… so I can move on to the next exercise.
Thanks