class_docstr: Represents a Transformer-based decoder model.
docstr: :param decoder_frontend:
      The decoder frontend.
  :param decoder:
      The decoder.
  :param final_proj:
      The projection to apply to decoder outputs.
  :param vocab_info:
      The vocabulary information of sequences produced by the model.
docstr_tok: [":","param","decoder_frontend",":","The","decoder","frontend",".",":","param","decoder",":","The","decoder",".",":","param","final_proj",":","The","projection","to","apply","to","decoder","outputs",".",":","param","vocab_info",":","The","vocabulary","information","of","sequences","produced","by","the","model","."]
code: def __init__(
      self,
      decoder_frontend: TransformerFrontend,
      decoder: TransformerDecoder,
      final_proj: Projection,
      vocab_info: VocabularyInfo,
  ) -> None:
      """
      :param decoder_frontend:
          The decoder frontend.
      :param decoder:
          The decoder.
      :param final_proj:
          The projection to apply to decoder outputs.
      :param vocab_info:
          The vocabulary information of sequences produced by the model.
      """
      super().__init__(decoder.model_dim, vocab_info)
  
      self.decoder_frontend = decoder_frontend
      self.decoder = decoder
  
      self.final_proj = final_proj
  
file_path: fairseq2/src/fairseq2/models/transformer/decoder_model.py
imports: from typing import Optional, Tuple, final
  from torch import Tensor
  from fairseq2.data import VocabularyInfo
  from fairseq2.models.decoder import DecoderModel
  from fairseq2.models.sequence import SequenceModelOutput
  from fairseq2.models.transformer.frontend import TransformerFrontend
  from fairseq2.nn.incremental_state import IncrementalStateBag
  from fairseq2.nn.padding import PaddingMask
  from fairseq2.nn.projection import Projection
  from fairseq2.nn.transformer import TransformerDecoder
  from fairseq2.typing import finaloverride
label_desc: Use image node_id 1 to create a new TransformerDecoderModel object from inherited base classes: DecoderModel with example: obj = TransformerDecoderModel(decoder_frontend, decoder, final_proj, vocab_info)