              os.remove(backupfile)
          if os.path.exists(origfile):
              os.rename(origfile, backupfile)
  
      def replace_config(self, config_changeable_items):
          """ Replace the loaded config with the one contained within the state file
              Check for any fixed=False parameters changes and log info changes
          """
          global _CONFIG  # pylint: disable=global-statement
 
</s> remove         print("\n")
 </s> add  </s> remove     def save_models(self):
 </s> add     def save_models(self, snapshot_iteration): </s> remove     def save(self, should_backup=False):
 </s> add     def save(self, should_backup=False, snapshot=False): </s> remove         model.save_models()
 </s> add         model.save_models(False)
    def snapshot_model(self):
        """ Take a snapshot of the model at current state and back up """
        logger.info("Saving snapshot")
        src = os.path.dirname(self.filename)
        dst = get_folder("{}_{}".format(src, self.iterations))
        for filename in os.listdir(src):
            if filename.endswith(".bk"):
                continue
            srcfile = os.path.join(src, filename)
            dstfile = os.path.join(dst, filename)
            copyfunc = copytree if os.path.isdir(srcfile) else copyfile
            logger.debug("Saving snapshot: '%s' > '%s'", srcfile, dstfile)
            copyfunc(srcfile, dstfile)
        logger.info("Saved snapshot")

              os.remove(backupfile)
          if os.path.exists(origfile):
              os.rename(origfile, backupfile)
  
    def snapshot_model(self):
        """ Take a snapshot of the model at current state and back up """
        logger.info("Saving snapshot")
        src = os.path.dirname(self.filename)
        dst = get_folder("{}_{}".format(src, self.iterations))
        for filename in os.listdir(src):
            if filename.endswith(".bk"):
                continue
            srcfile = os.path.join(src, filename)
            dstfile = os.path.join(dst, filename)
            copyfunc = copytree if os.path.isdir(srcfile) else copyfile
            logger.debug("Saving snapshot: '%s' > '%s'", srcfile, dstfile)
            copyfunc(srcfile, dstfile)
        logger.info("Saved snapshot")

      def replace_config(self, config_changeable_items):
          """ Replace the loaded config with the one contained within the state file
              Check for any fixed=False parameters changes and log info changes
          """
          global _CONFIG  # pylint: disable=global-statement
keep keep keep add keep keep keep keep keep
 Add save snapshot backup option for training 
plugins/train/model/_base.py