class_docstr: Extends nn.Module so that its parameter tensors have an extra field called .grad_sample.
class_docstr_tok: ["Extends","nn.Module","so","that","its","parameter","tensors","have","an","extra","field","called",".grad_sample","."]
docstr: Sets ``.grad_sample`` to None
docstr_tok: ["Sets","``",".grad_sample","``","to","None"]
code: def set_grad_sample_to_none(self):
      """
      Sets ``.grad_sample`` to None
      """
      for p in self.parameters():
          p.grad_sample = None
  
imports: import logging
  from abc import ABC, abstractmethod
  from typing import Optional
  import torch.nn
  from opacus.utils.module_utils import trainable_parameters
  from torch.utils.hooks import RemovableHandle
label_desc: Use image node_id 5 for calling the AbstractGradSampleModule obj's underlying member method code with example usage: obj.set_grad_sample_to_none() without return types