class_docstr: Adds adapters to the BartEncoderLayer module of BART.
code: def init_adapters(self, model_config, adapters_config):
      self.adapters_config = adapters_config
      # Wrap layers for LoRA
      self.fc1 = LoRALinear.wrap(
          self.fc1, "intermediate", model_config, adapters_config
      )
      self.fc2 = LoRALinear.wrap(
          self.fc2, "output", model_config, adapters_config
      )
  
      # Set attention layer location key for prefix tuning
      self.self_attn.location_key = "encoder"
      self.attention_adapters = BottleneckLayer("mh_adapter")
      self.output_adapters = BottleneckLayer("output_adapter")
  
imports: from typing import Iterable, Optional, Tuple
  import torch
  import torch.nn
  from ...composition import adjust_tensors_for_parallel
  from ...methods.bottleneck import BottleneckLayer
  from ...methods.lora import LoRALinear
  from ...methods.prefix_tuning import PrefixTuningLayer
  from ...model_mixin import EmbeddingAdaptersMixin, EmbeddingAdaptersWrapperMixin, InvertibleAdaptersMixin, InvertibleAdaptersWrapperMixin, ModelBaseAdaptersMixin
label_desc: Use image node_id 1 for calling the BartEncoderLayerAdaptersMixin obj's underlying member method code with example usage: obj.init_adapters(model_config, adapters_config) without return types