code: def __init__(self) -> None:
      self._old_torch_load_state_dict = Module.load_state_dict
      self._old_torch_to_device = Module.to
      self._old_torch_load_from_state_dict = (
          Module._load_from_state_dict
      )
      # Chatglm2 init weights manually,
      # and `skip_init` init on `cpu` by default
      self._old_skip_init = torch.nn.utils.skip_init
  
imports: import torch
  import os
  import json
  from .transformers import ggml_convert_low_bit
  from torch.nn.modules import Module
  from torch.nn.modules.module import _IncompatibleKeys
  from accelerate import init_empty_weights
  from accelerate.utils import set_module_tensor_to_device
  from bigdl.llm.ggml.quantize import ggml_tensor_qtype
  from bigdl.llm.utils.common import invalidInputError
  from bigdl.llm.transformers.utils import extract_local_archive_file, get_local_shard_files
  import transformers
  import warnings
  from transformers import PreTrainedModel
  from .utils.common import MuteHFLogger
  from .utils.lazy_load_torch import LazyLoadTensors
  from contextlib import ExitStack, contextmanager
label_desc: Use image node_id 1 to create a new DisableTorchAllocTensor object  with example: obj = DisableTorchAllocTensor()