class_docstr: Hooks-based implementation of AbstractGradSampleModule
  
  Computes per-sample gradients using custom-written methods for each layer.
  See README.md for more details
docstr: Checks if this individual model is supported (i.e. has a registered
  grad sampler function)
  
  Notes:
      Note that this method does not check submodules
  
  Args:
      module: nn.Module to be checked
  
  Returns:
      ``True`` if grad sampler is found, ``False`` otherwise
docstr_tok: ["Checks","if","this","individual","model","is","supported","(","i.e",".","has","a","registered","grad","sampler","function",")","Notes",":","Note","that","this","method","does","not","check","submodules","Args",":","module",":","nn.Module","to","be","checked","Returns",":","``","True","``","if","grad","sampler","is","found",",","``","False","``","otherwise"]
code: def is_supported(cls, module: nn.Module) -> bool:
      """
      Checks if this individual model is supported (i.e. has a registered
      grad sampler function)
  
      Notes:
          Note that this method does not check submodules
  
      Args:
          module: nn.Module to be checked
  
      Returns:
          ``True`` if grad sampler is found, ``False`` otherwise
      """
      warnings.warn(
          "GradSampleModule.is_supported is deprecated, as all layers can now be used with functorch.",
          DeprecationWarning,
      )
  
      return True
  
imports: from __future__ import annotations
  import logging
  import warnings
  from functools import partial
  from typing import Iterable, List, Tuple
  import torch
  import torch.nn
  from opacus.grad_sample.functorch import ft_compute_per_sample_gradient, prepare_layer
  from opacus.grad_sample.gsm_base import AbstractGradSampleModule
  from opacus.layers.dp_rnn import DPGRU, DPLSTM, DPRNN, RNNLinear
  from opacus.utils.module_utils import has_trainable_params, requires_grad, trainable_modules, trainable_parameters
label_desc: Use image node_id 12 for calling the GradSampleModule obj's underlying member method code with example usage: obj.is_supported(cls, module) and returns: True