class_docstr: Resolve documentation links using searchindex.js generated by Sphinx
  
  Parameters
  ----------
  doc_url : str
      The base URL of the project website.
  searchindex : str
      Filename of searchindex, relative to doc_url.
  extra_modules_test : list of str
      List of extra module names to test.
  relative : bool
      Return relative links (only useful for links to documentation of this
      package).
code: def __init__(
      self,
      doc_url,
      searchindex="searchindex.js",
      extra_modules_test=None,
      relative=False,
  ):
      self.doc_url = doc_url
      self.relative = relative
      self._link_cache = {}
  
      self.extra_modules_test = extra_modules_test
      self._page_cache = {}
      if doc_url.startswith("http://"):
          if relative:
              raise ValueError(
                  "Relative links are only supported for local "
                  'URLs (doc_url cannot start with "http://)"'
              )
          searchindex_url = doc_url + "/" + searchindex
      else:
          searchindex_url = os.path.join(doc_url, searchindex)
  
      # detect if we are using relative links on a Windows system
      if os.name.lower() == "nt" and not doc_url.startswith("http://"):
          if not relative:
              raise ValueError(
                  "You have to use relative=True for the local"
                  " package on a Windows system."
              )
          self._is_windows = True
      else:
          self._is_windows = False
  
      # download and initialize the search index
      sindex = get_data(searchindex_url)
      filenames, objects = parse_sphinx_searchindex(sindex)
  
      self._searchindex = dict(filenames=filenames, objects=objects)
  
imports: from __future__ import division, print_function
  from time import time
  import ast
  import os
  import re
  import shutil
  import traceback
  import glob
  import sys
  import gzip
  import posixpath
  import subprocess
  import warnings
  from sklearn.externals import six
  from docutils.core import publish_string
  import token
  import tokenize
  import numpy
  import joblib
label_desc: Use image node_id 1 to create a new SphinxDocLinkResolver object from inherited base classes: object with example: obj = SphinxDocLinkResolver(doc_url, searchindex, extra_modules_test, relative)