class_docstr: Subclass which constructs RNN decoder from student arguments.
  (dropout, attention_dropout, and vocab reduction params shared with teacher.)
class_docstr_tok: ["Subclass","which","constructs","RNN","decoder","from","student","arguments",".","(","dropout",",","attention_dropout",",","and","vocab","reduction","params","shared","with","teacher",".",")"]
code: def _init_dims(self, args, src_dict, dst_dict, embed_tokens):
      self.dropout = args.dropout
  
      embed_dim = embed_tokens.embedding_dim
      self.embed_tokens = embed_tokens
  
      self.lstm_units = args.student_decoder_lstm_units
      self.num_layers = args.student_decoder_layers
      self.initial_input_dim = embed_dim
  
      # for compatibility with transformer dimensions in encoder
      # and teacher decoder are different
      self.encoder_output_dim = args.decoder_embed_dim
      if args.student_decoder_reduced_attention_dim is None:
          self.attention_dim = self.encoder_output_dim
      else:
          self.attention_dim = (
              args.student_decoder_reduced_attention_dim
          )
      self.input_dim = self.lstm_units + self.attention_dim
  
      self.num_attention_heads = args.student_decoder_attention_heads
      self.bottleneck_dim = args.student_decoder_out_embed_dim
  
file_path: translate/pytorch_translate/research/knowledge_distillation/dual_decoder_kd_model.py
imports: from fairseq.models import FairseqEncoderDecoderModel, register_model, register_model_architecture
  from pytorch_translate import hybrid_transformer_rnn, transformer
  from pytorch_translate.utils import torch_find
label_desc: Use image node_id 1 for calling the StudentHybridRNNDecoder obj's underlying member method code with example usage: obj._init_dims(args, src_dict, dst_dict, embed_tokens) without return types