docstr: Return the id of a parameter which the gradient slice belongs to
  
  Args:
      grad (Tensor): the gradient slice
  
  Returns:
      int: the id of a parameter which the gradient slice belongs to
docstr_tok: ["Return","the","id","of","a","parameter","which","the","gradient","slice","belongs","to","Args",":","grad","(","Tensor",")",":","the","gradient","slice","Returns",":","int",":","the","id","of","a","parameter","which","the","gradient","slice","belongs","to"]
code: def get_param_id_for_grad(self, grad: Tensor) -> int:
      """Return the id of a parameter which the gradient slice belongs to
  
      Args:
          grad (Tensor): the gradient slice
  
      Returns:
          int: the id of a parameter which the gradient slice belongs to
      """
  
      return self.grad_to_param_mapping[id(grad)]
  
file_path: ColossalAI/colossalai/zero/low_level/bookkeeping/gradient_store.py
imports: from typing import List
  from torch import Tensor
  from .base_store import BaseStore
label_desc: Use image node_id 9 for calling the GradientStore obj's underlying member method code with example usage: obj.get_param_id_for_grad(grad) and returns: self