code: def __init__(self, config, tokenizer):
      super().__init__()
      self.tokenizer = tokenizer
      logger.info(f"Loading pre-trained model {config.model_name}")
      self.model_config = AutoConfig.from_pretrained(
          config.model_name, cache_dir=config.cache_dir
      )
      self.model = AutoModelForPreTraining.from_pretrained(
          config.model_name,
          cache_dir=config.cache_dir,
          config=self.model_config,
      )
      self.model.resize_token_embeddings(len(self.tokenizer))
  
file_path: DeepKE/src/deepke/event_extraction/standard/degree/model.py
imports: import logging
  import numpy
  import torch
  import torch.nn
  from transformers import AutoConfig, AutoModelForPreTraining
  import ipdb
label_desc: Use image node_id 1 to create a new GenerativeModel object from inherited base classes: nn with example: obj = GenerativeModel(config, tokenizer)