code: def _cached_download(url, md5, dst):
      if os.path.isfile(dst) and _calc_md5(dst) == md5:
          return
  
      def reporthook(blocknum, bs, size):
          logger.debug("downloaded %s bytes", size)
  
      urls = (
          url
          if isinstance(url, list) or isinstance(url, tuple)
          else (url,)
      )
  
      for u in urls:
          try:
              six.moves.urllib.request.urlretrieve(
                  u, dst, reporthook=reporthook
              )
              break
          except (six.moves.urllib.error.URLError, IOError):
              logger.debug("failed to download from %s", u)
      else:
          raise RuntimeError("failed to download from %s", urls)
  
      dst_md5 = _calc_md5(dst)
      if dst_md5 != md5:
          raise RuntimeError(
              "md5 sum mismatch for url {url}; expected {expected}, but got {got}".format(
                  url=u, expected=md5, got=dst_md5
              )
          )
  
imports: import hashlib
  import logging
  import numpy
  import os
  import pandas
  import tarfile
  import tempfile
  import six
  import shutil
  from .core import PATH_TYPES, fspath
label_desc: Use image node_id 4 for calling a global function with example usage: _cached_download(url, md5, dst) without return types