FRmodel.compile in Face_Recognition_v3a

In triplet_loss(), if I set axis = 1 in tf.reduce_sum() of both pos_dist and neg_dist, then I can pass the triplet_loss with loss = 528.143 as expected, but couldn’t pass the FRmodel.compile(); if I set that as axis=None, then I can pass the FRmodel.compile but couldn’t pass the triplet_loss because I got a loss = 350.026, which is not expected. In either case, the pretained weights for FRmodel can be correctly loaded (mask the FRmodel.compile if necessary) and I can pass the verify() and who_is_it() with expected outputs.

Refer the Additional Hints in the previous block, it gives a clue about how to choose the last axis in a tensor.