keras/src/losses/losses.py/LossFunctionWrapper/call
class LossFunctionWrapper:    def call(self, y_true, y_pred):
        y_true, y_pred = squeeze_or_expand_to_same_rank(y_true, y_pred)
        return self.fn(y_true, y_pred, **self._fn_kwargs)