code: def init_model(
      self,
      preprocessor: Preprocessor,
      vectorizer: BertVectorizer,
      embedding_weights_encoder=None,
      embedding_weights_decoder=None,
  ) -> None:
      self.preprocessor = preprocessor
      self.vectorizer = vectorizer
      self.embedding_shape_in = (
          self.vectorizer.encoding_dim,
          self.embedding_size_encoder,
      )
      self.embedding_shape_out = (
          self.vectorizer.decoding_dim,
          self.embedding_size_decoder,
      )
      self.transformer = Transformer(
          num_layers_encoder=self.num_layers_encoder,
          num_layers_decoder=self.num_layers_decoder,
          num_heads=self.num_heads,
          feed_forward_dim=self.feed_forward_dim,
          embedding_shape_encoder=self.embedding_shape_in,
          embedding_shape_decoder=self.embedding_shape_out,
          bert_embedding_encoder=self.bert_embedding_encoder,
          embedding_encoder_trainable=self.embedding_encoder_trainable,
          embedding_decoder_trainable=self.embedding_decoder_trainable,
          embedding_weights_encoder=embedding_weights_encoder,
          embedding_weights_decoder=embedding_weights_decoder,
          dropout_rate=self.dropout_rate,
          max_seq_len=self.max_sequence_len,
      )
      self.transformer.encoder.compile(optimizer=self.optimizer_encoder)
      self.transformer.decoder.compile(optimizer=self.optimizer_decoder)
  
imports: import os
  import pickle
  from typing import Callable
  from typing import Dict, Union
  import numpy
  import tensorflow
  from headliner.model.bert_model import Transformer, create_masks
  from headliner.model.summarizer import Summarizer
  from headliner.preprocessing.bert_vectorizer import BertVectorizer
  from headliner.preprocessing.preprocessor import Preprocessor
  from headliner.utils.logger import get_logger
label_desc: Use image node_id 3 for calling the BertSummarizer obj's underlying member method code with example usage: obj.init_model(preprocessor, vectorizer, embedding_weights_encoder, embedding_weights_decoder) without return types