code: def _serve_colab(self, blocking=False, debug=False, port=None):
      import ipywidgets as widgets
      from captum.insights.attr_vis.server import start_server
      from IPython.display import display, HTML
  
      # TODO: Output widget only captures beginning of server logs. It seems
      # the context manager isn't respected when the web server is run on a
      # separate thread. We should fix to display entirety of the logs
      out = widgets.Output()
      with out:
          port = start_server(
              self, blocking=blocking, debug=debug, _port=port
          )
      shell = """
              <div id="root"></div>
              <script>
              (function() {
                document.querySelector("base").href = "http://localhost:%PORT%";
                function reloadScriptsAndCSS(root) {
                  // Referencing TensorBoard's method for reloading scripts,
                  // we remove and reinsert each script
                  for (const script of root.querySelectorAll("script")) {
                    const newScript = document.createElement("script");
                    newScript.type = script.type;
                    if (script.src) {
                      newScript.src = script.src;
                    }
                    if (script.textContent) {
                      newScript.textContent = script.textContent;
                    }
                    root.appendChild(newScript);
                    script.remove();
                  }
                  // A similar method is used to reload styles
                  for (const link of root.querySelectorAll("link")) {
                    const newLink = document.createElement("link");
                    newLink.rel = link.rel;
                    newLink.href = link.href;
                    document.querySelector("head").appendChild(newLink);
                    link.remove();
                  }
                }
                const root = document.getElementById("root");
                fetch(".")
                  .then(x => x.text())
                  .then(html => void (root.innerHTML = html))
                  .then(() => reloadScriptsAndCSS(root));
              })();
              </script>
          """.replace(
          "%PORT%", str(port)
      )
      html = HTML(shell)
      display(html)
      display(out)
  
imports: from collections import namedtuple
  from itertools import cycle
  from typing import Any, Callable, Dict, Iterable, List, NamedTuple, Optional, Tuple, Union
  import torch
  from captum.attr import IntegratedGradients
  from captum.attr._utils.batching import _batched_generator
  from captum.insights.attr_vis.attribution_calculation import AttributionCalculation, OutputScore
  from captum.insights.attr_vis.config import ATTRIBUTION_METHOD_CONFIG, ATTRIBUTION_NAMES_TO_METHODS
  from captum.insights.attr_vis.features import BaseFeature
  from captum.insights.attr_vis.server import namedtuple_to_dict
  from captum.log import log_usage
  from torch import Tensor
  from torch.nn import Module
label_desc: Use image node_id 7 for calling the AttributionVisualizer obj's underlying member method code with example usage: obj._serve_colab(blocking, debug, port) without return types