          return KerasModel(input_, outputs=outputs, name="decoder_{}".format(side))
  
      def _legacy_mapping(self):
          """ The mapping of legacy separate model names to single model names """
          mappings = dict(df={"{}_encoder.h5".format(self.name): "encoder_df",
                              "{}_decoder_A.h5".format(self.name): "decoder_a",
                              "{}_decoder_B.h5".format(self.name): "decoder_b"},
                          liae={"{}_encoder.h5".format(self.name): "encoder_liae",
                                "{}_intermediate_B.h5".format(self.name): "intermediate_both",
                                "{}_intermediate.h5".format(self.name): "intermediate_b",
                                "{}_decoder.h5".format(self.name): "decoder_both"})
          return mappings[self.config["architecture"]]
 
</s> remove         return KerasModel(input_, outputs=outputs, name="decoder_{}".format(side))
 </s> add         return KerasModel(input_, outputs=outputs, name=f"decoder_{side}") </s> remove         return {"{}_encoder.h5".format(self.name): "encoder",
                "{}_decoder_A.h5".format(self.name): "decoder_a",
                "{}_decoder_B.h5".format(self.name): "decoder_b"}
 </s> add         return {f"{self.name}_encoder.h5": "encoder",
                f"{self.name}_decoder_A.h5": "decoder_a",
                f"{self.name}_decoder_B.h5": "decoder_b"}
 </s> remove         return {"{}_encoder.h5".format(self.name): "encoder",
                "{}_decoder_A.h5".format(self.name): "decoder_a",
                "{}_decoder_B.h5".format(self.name): "decoder_b"}
 </s> add         return {f"{self.name}_encoder.h5": "encoder",
                f"{self.name}_decoder_A.h5": "decoder_a",
                f"{self.name}_decoder_B.h5": "decoder_b"} </s> remove         return {"{}_encoder.h5".format(self.name): "encoder",
                "{}_decoder_A.h5".format(self.name): "decoder_a",
                "{}_decoder_B.h5".format(self.name): "decoder_b"}
 </s> add         return {f"{self.name}_encoder.h5": "encoder",
                f"{self.name}_decoder_A.h5": "decoder_a",
                f"{self.name}_decoder_B.h5": "decoder_b"} </s> remove         return KerasModel(input_, outputs=outputs, name="decoder_{}".format(side))
 </s> add         return KerasModel(input_, outputs=outputs, name=f"decoder_{side}")

        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
          return KerasModel(input_, outputs=outputs, name="decoder_{}".format(side))
  
      def _legacy_mapping(self):
          """ The mapping of legacy separate model names to single model names """
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
        mappings = dict(df={f"{self.name}_encoder.h5": "encoder_df",
                            f"{self.name}_decoder_A.h5": "decoder_a",
                            f"{self.name}_decoder_B.h5": "decoder_b"},
                        liae={f"{self.name}_encoder.h5": "encoder_liae",
                              f"{self.name}_intermediate_B.h5": "intermediate_both",
                              f"{self.name}_intermediate.h5": "intermediate_b",
                              f"{self.name}_decoder.h5": "decoder_both"})
          return mappings[self.config["architecture"]]
keep keep keep keep replace replace replace replace replace replace replace keep
 Update all Keras Imports to be conditional (#1214)

* Remove custom keras importer

* first round keras imports fix

* launcher.py: Remove KerasFinder references

* 2nd round keras imports update (lib and extract)

* 3rd round keras imports update (train)

* remove KerasFinder from tests

* 4th round keras imports update (tests) 
plugins/train/model/dfl_sae.py