          self._loss_weights = []
          self._mask_channels = []
          logger.debug("Initialized: %s", self.__class__.__name__)
  
      def add_loss(self, function, weight=1.0, mask_channel=-1):
          """ Add the given loss function with the given weight to the loss function chain.
  
          Parameters
          ----------
          function: :class:`keras.losses.Loss`
 
</s> remove         function: :class:`keras.losses.Loss`
 </s> add         function: :class:`tf.keras.losses.Loss` </s> remove         super().__init__(name="LossWrapper")
 </s> add  </s> remove     def __init__(self):
 </s> add     def __init__(self) -> None: </s> remove         If a mask is being applied to the loss, then the appropriate mask is extracted from y_true
        and added as the 4th channel being passed to the penalized loss function.
 </s> add         If masks are being applied to the loss function inputs, then they should be included as
        additional channels at the end of :param:`y_true`, so that they can be split off and
        applied to the actual inputs to the selected loss function(s). </s> remove     def _apply_mask(cls, y_true, y_pred, mask_channel, mask_prop=1.0):
 </s> add     def _apply_mask(cls,
                    y_true: tf.Tensor,
                    y_pred: tf.Tensor,
                    mask_channel: int,
                    mask_prop: float = 1.0) -> Tuple[tf.Tensor, tf.Tensor]:
    def add_loss(self,
                 function: tf.keras.losses.Loss,
                 weight: float = 1.0,
                 mask_channel: int = -1) -> None:
          self._loss_weights = []
          self._mask_channels = []
          logger.debug("Initialized: %s", self.__class__.__name__)
  
    def add_loss(self,
                 function: tf.keras.losses.Loss,
                 weight: float = 1.0,
                 mask_channel: int = -1) -> None:
          """ Add the given loss function with the given weight to the loss function chain.
  
          Parameters
          ----------
          function: :class:`keras.losses.Loss`
keep keep keep keep replace keep keep keep keep keep
 bugfix: distibuted training with dssim 
lib/model/losses_tf.py