class_docstr: An implementation of GradCAM on graph in
  `Grad-CAM: Visual Explanations from Deep Networks via Gradient-based Localization <https://arxiv.org/abs/1610.02391>`_.
  
  Args:
      model (torch.nn.Module): The target model prepared to explain.
      explain_graph (bool, optional): Whether to explain graph classification model.
          (default: :obj:`False`)
  
  .. note::
      For node classification model, the :attr:`explain_graph` flag is False.
      For an example, see `benchmarks/xgraph
      <https://github.com/divelab/DIG/tree/dig/benchmarks/xgraph>`_.
class_docstr_tok: ["An","implementation","of","GradCAM","on","graph","in","`","Grad-CAM",":","Visual","Explanations","from","Deep","Networks","via","Gradient-based","Localization","<","https",":","\/\/arxiv.org\/abs\/1610.02391",">","`","_",".","Args",":","model","(","torch.nn.Module",")",":","The","target","model","prepared","to","explain",".","explain_graph","(","bool",",","optional",")",":","Whether","to","explain","graph","classification","model",".","(","default",":",":","obj",":","`","False","`",")","..","note",":",":","For","node","classification","model",",","the",":","attr",":","`","explain_graph","`","flag","is","False",".","For","an","example",",","see","`","benchmarks\/xgraph","<","https",":","\/\/github.com\/divelab\/DIG\/tree\/dig\/benchmarks\/xgraph",">","`","_","."]
code: def __init__(self, model: nn.Module, explain_graph: bool = False):
      super().__init__(model, explain_graph=explain_graph)
  
imports: from typing import Any, Callable, List, Tuple, Union, Dict
  import captum.attr
  import torch
  import torch.nn
  import torch.nn.functional
  from captum.attr._utils.common import _format_additional_forward_args, _format_attributions, _format_input
  from captum.attr._utils.gradient import apply_gradient_requirements, compute_layer_gradients_and_eval, undo_gradient_requirements
  from captum.attr._utils.typing import TargetType
  from torch import Tensor
  from torch.nn import Module
  from torch_geometric.utils.loop import add_remaining_self_loops
  from .base_explainer import WalkBase
  from ..models.utils import subgraph, normalize
label_desc: Use image node_id 1 to create a new GradCAM object from inherited base classes: WalkBase with example: obj = GradCAM(model, explain_graph)