          logger.debug("Compiled Predictors. Losses: %s", loss_names)
  
      def loss_function(self, side):
          """ Set the loss function """
          if self.config.get("dssim_loss", False):
              if side == "a" and not self.predict:
 
</s> remove         # TODO Look to re-instate clipnorm
        # Clipnorm is ballooning VRAM useage, which is not expected behaviour
        # and may be a bug in Keras/TF?
        # For now this is commented out, but revisit in future to reinstate

        # # PlaidML has a bug regarding the clipnorm parameter
        # # See: https://github.com/plaidml/plaidml/issues/228
        # # Workaround by simply removing it.
        # # TODO: Remove this as soon it is fixed in PlaidML.
        # if keras.backend.backend() == "plaidml.keras.backend":
        #    optimizer = Adam(lr=5e-5, beta_1=0.5, beta_2=0.999)
        # else:
        #    optimizer = Adam(lr=5e-5, beta_1=0.5, beta_2=0.999, clipnorm=1.0)
        optimizer = Adam(lr=5e-5, beta_1=0.5, beta_2=0.999)
 </s> add         optimizer = self.get_optimizer(lr=5e-5, beta_1=0.5, beta_2=0.999)
    def get_optimizer(self, lr=5e-5, beta_1=0.5, beta_2=0.999):  # pylint: disable=invalid-name
        """ Build and return Optimizer """
        opt_kwargs = dict(lr=lr, beta_1=beta_1, beta_2=beta_2)
        if (self.config.get("clipnorm", False) and
                keras.backend.backend() != "plaidml.keras.backend"):
            # NB: Clipnorm is ballooning VRAM useage, which is not expected behaviour
            # and may be a bug in Keras/TF.
            # PlaidML has a bug regarding the clipnorm parameter
            # See: https://github.com/plaidml/plaidml/issues/228
            # Workaround by simply removing it.
            # TODO: Remove this as soon it is fixed in PlaidML.
            opt_kwargs["clipnorm"] = 1.0
        logger.debug("Optimizer kwargs: %s", opt_kwargs)
        return Adam(**opt_kwargs)

          logger.debug("Compiled Predictors. Losses: %s", loss_names)
  
    def get_optimizer(self, lr=5e-5, beta_1=0.5, beta_2=0.999):  # pylint: disable=invalid-name
        """ Build and return Optimizer """
        opt_kwargs = dict(lr=lr, beta_1=beta_1, beta_2=beta_2)
        if (self.config.get("clipnorm", False) and
                keras.backend.backend() != "plaidml.keras.backend"):
            # NB: Clipnorm is ballooning VRAM useage, which is not expected behaviour
            # and may be a bug in Keras/TF.
            # PlaidML has a bug regarding the clipnorm parameter
            # See: https://github.com/plaidml/plaidml/issues/228
            # Workaround by simply removing it.
            # TODO: Remove this as soon it is fixed in PlaidML.
            opt_kwargs["clipnorm"] = 1.0
        logger.debug("Optimizer kwargs: %s", opt_kwargs)
        return Adam(**opt_kwargs)

      def loss_function(self, side):
          """ Set the loss function """
          if self.config.get("dssim_loss", False):
              if side == "a" and not self.predict:
keep add keep keep keep keep
 Add clipnorm back in as optimizer option for unbalanced 
plugins/train/model/_base.py