class_docstr: Supports T5, mBART, Marian, other models that inherit from Bart.
class_docstr_tok: ["Supports","T5",",","mBART",",","Marian",",","other","models","that","inherit","from","Bart","."]
code: def __init__(self, hparams, **kwargs):
      super().__init__(hparams, **kwargs)
      assert hparams.src_lang is not None
      assert hparams.tgt_lang is not None
      self.dataset_kwargs["src_lang"] = hparams.src_lang
      self.dataset_kwargs["tgt_lang"] = hparams.tgt_lang
      if (
          self.model.config.decoder_start_token_id is None
          and isinstance(self.tokenizer, MBartTokenizer)
      ):
          self.decoder_start_token_id = self.tokenizer.lang_code_to_id[
              hparams.tgt_lang
          ]
  
imports: import argparse
  import gc
  import os
  import sys
  from pathlib import Path
  from typing import List
  import pytorch_lightning
  import torch
  from finetune import SummarizationModule, TranslationModule
  from finetune import main
  from make_student import create_student_by_copying_alternating_layers, get_layers_to_supervise
  from torch import nn
  from transformers import AutoModelForSeq2SeqLM, MBartTokenizer, T5ForConditionalGeneration
  from transformers.models.bart.modeling_bart import shift_tokens_right
  from utils import calculate_bleu, check_output_dir, freeze_params, label_smoothed_nll_loss, use_task_specific_params
  from lightning_base import generic_train
label_desc: Use image node_id 1 to create a new TranslationDistiller object from inherited base classes: SummarizationDistiller with example: obj = TranslationDistiller(hparams)