code: def __init__(self, config, add_pooling_layer=True):
      super(ErnieMModel, self).__init__(config)
      self.initializer_range = config.initializer_range
      self.embeddings = ErnieMEmbeddings(config)
      self.encoder = ErnieMEncoder(config)
      self.pooler = ErnieMPooler(config) if add_pooling_layer else None
      self.post_init()
  
imports: import math
  from typing import List, Optional, Tuple, Union
  import torch
  import torch.utils.checkpoint
  from torch import nn, tensor
  from torch.nn import BCEWithLogitsLoss, CrossEntropyLoss, MSELoss
  from ...activations import ACT2FN
  from ...modeling_outputs import BaseModelOutputWithPastAndCrossAttentions, BaseModelOutputWithPoolingAndCrossAttentions, MultipleChoiceModelOutput, QuestionAnsweringModelOutput, SequenceClassifierOutput, TokenClassifierOutput
  from ...modeling_utils import PreTrainedModel
  from ...pytorch_utils import find_pruneable_heads_and_indices, prune_linear_layer
  from ...utils import add_code_sample_docstrings, add_start_docstrings, add_start_docstrings_to_model_forward, logging
  from .configuration_ernie_m import ErnieMConfig
label_desc: Use image node_id 1 to create a new ErnieMModel object from inherited base classes: ErnieMPreTrainedModel with example: obj = ErnieMModel(config, add_pooling_layer)