class_docstr: Captum Interpretation for Resnet
class_docstr_tok: ["Captum","Interpretation","for","Resnet"]
code: def __init__(
      self,
      learn,
      cmap_name="custom blue",
      colors=None,
      N=256,
      methods=("original_image", "heat_map"),
      signs=("all", "positive"),
      outlier_perc=1,
  ):
      if colors is None:
          colors = [(0, "#ffffff"), (0.25, "#000000"), (1, "#000000")]
      store_attr()
      self.dls, self.model = learn.dls, self.learn.model
      self.supported_metrics = ["IG", "NT", "Occl"]
  
file_path: fastai/fastai/callback/captum.py
imports: from __future__ import annotations
  import tempfile
  from ..basics import *
  from ipykernel import jsonutil
  from captum.attr import IntegratedGradients, NoiseTunnel, GradientShap, Occlusion
  from captum.attr import visualization
  from matplotlib.colors import LinearSegmentedColormap
  from captum.insights import AttributionVisualizer, Batch
  from captum.insights.attr_vis.features import ImageFeature
label_desc: Use image node_id 1 to create a new CaptumInterpretation object  with example: obj = CaptumInterpretation(learn, cmap_name, colors, N, methods, signs, outlier_perc)