def METHOD_NAME(self, args):
    if hasattr(args, "enable_attack") and args.enable_attack:
        logging.info("------init attack..." + args.attack_type.strip())
        self.is_enabled = True
        self.attack_type = args.attack_type.strip()
        self.attacker = None
        if self.attack_type == ATTACK_METHOD_BYZANTINE_ATTACK:
            self.attacker = ByzantineAttack(args)
        elif self.attack_type == ATTACK_LABEL_FLIPPING:
            self.attacker = LabelFlippingAttack(args)
        elif self.attack_type == BACKDOOR_ATTACK_MODEL_REPLACEMENT:
            self.attacker = ModelReplacementBackdoorAttack(args)
        elif self.attack_type == ATTACK_METHOD_DLG:
            self.attacker = DLGAttack(args=args)
    else:
        self.is_enabled = False
    if self.is_enabled:
        if hasattr(args, MLEngineBackend.ml_engine_args_flag) and args.ml_engine in [
            MLEngineBackend.ml_engine_backend_tf,
            MLEngineBackend.ml_engine_backend_jax,
            MLEngineBackend.ml_engine_backend_mxnet,
        ]:
            logging.info(
                "FedMLAttacker is not supported for the machine learning engine: %s. "
                "We will support more engines in the future iteration."
                % args.ml_engine
            )
            self.is_enabled = False