code: def from_pretrained(self, *args, training_args, model_args, **kwargs):
      self.config = kwargs["config"]
      model = super().from_pretrained(*args, **kwargs)
      if model_args.module_type == 1 or model_args.module_type == 2:
          inject_ls_layer(model, training_args, model_args, self.config)
      return model
  
imports: import torch
  from lightseq.training.pytorch_quantization.nn.modules.tensor_quantizer import enable_quant
  from lightseq.training.ops.pytorch.quantization import qat_mode, disable_quant, weight_quant_config, act_quant_config, relu_quant_config
  from lightseq.training.ops.pytorch.torch_transformer_layers import BertEmbeddingLayer
  from transformers import BertForSequenceClassification, BertPreTrainedModel, BertLayer, BertLMHeadModel, BertForMaskedLM, BertForNextSentencePrediction, BertForMultipleChoice, BertForTokenClassification, BertForQuestionAnswering
label_desc: Use image node_id 1 for calling the LSBertPreTrainedModel obj's underlying member method code with example usage: obj.from_pretrained() and returns: model