def METHOD_NAME(self, cfg: Union[DictConfig, Namespace]):
    if (isinstance(cfg, DictConfig) and cfg._name == "characters_asr") or (
        isinstance(cfg, Namespace) and getattr(cfg, "bpe", None) == "characters_asr"
    ):
        self.bpe = encoders.METHOD_NAME(
            cfg, space_symbol=self.space_word, non_lang_syms=self.non_lang_syms
        )
    else:
        self.bpe = encoders.METHOD_NAME(cfg)