code: def turn_model_into_encoder_decoder(model):
      encoder = model.encoder
      decoder = model.decoder
      lm_head = model.lm_head
  
      decoder_with_lm_head = CombinedDecoder(
          decoder, lm_head, model.config
      )
      simplified_encoder = SimplifiedT5Encoder(encoder)
  
      return simplified_encoder, decoder_with_lm_head
  
imports: from transformers import T5Tokenizer, T5ForConditionalGeneration
  from .models import CombinedDecoder, SimplifiedT5Encoder
  import torch
label_desc: Use image node_id 2 for calling a global function with example usage: turn_model_into_encoder_decoder(model) and returns: simplified_encoder,  decoder_with_lm_head