code: def record_rng(self, *args):
      self.cpu_state = torch.get_rng_state()
      if torch.cuda._initialized:
          self.cuda_in_fwd = True
          self.gpu_devices, self.gpu_states = get_device_states(*args)
  
imports: import torch
  import torch.nn
  from operator import itemgetter
  from torch.autograd.function import Function
  from torch.utils.checkpoint import get_device_states, set_device_states
label_desc: Use image node_id 2 for calling the Deterministic obj's underlying member method code with example usage: obj.record_rng() without return types