class_docstr: Adds adapters to the TransformerBlock module of DistilBert.
class_docstr_tok: ["Adds","adapters","to","the","TransformerBlock","module","of","DistilBert","."]
code: def init_adapters(self, model_config, adapters_config):
      # Wrap layers for LoRA
      self.mlp.c_fc = LoRALinear.wrap(
          self.mlp.c_fc,
          "intermediate",
          model_config,
          adapters_config,
          fan_in_fan_out=True,
          no_init_bias=True,
      )
      self.mlp.c_proj = LoRALinear.wrap(
          self.mlp.c_proj,
          "output",
          model_config,
          adapters_config,
          fan_in_fan_out=True,
          no_init_bias=True,
      )
  
      self.attention_adapters = BottleneckLayer("mh_adapter")
      self.output_adapters = BottleneckLayer("output_adapter")
  
file_path: adapters/src/adapters/models/gpt2/mixin_gpt2.py
imports: from typing import Iterable, Tuple
  import torch.nn
  from ...methods.bottleneck import BottleneckLayer
  from ...methods.lora import LoRALinear, LoRAMergedLinear
  from ...methods.prefix_tuning import PrefixTuningLayer
  from ...model_mixin import EmbeddingAdaptersMixin, InvertibleAdaptersMixin, ModelBaseAdaptersMixin
label_desc: Use image node_id 1 for calling the GPT2DecoderBlockAdaptersMixin obj's underlying member method code with example usage: obj.init_adapters(model_config, adapters_config) without return types