code: def download_checkpoint(
      network, network_filename, checkpoint_path, checkpoint_filename
  ):
      tarball_filename = BASE_NETWORK_FILENAMES[network]
      url = TENSORFLOW_OFFICIAL_ENDPOINT + tarball_filename
      response = requests.get(url, stream=True)
      total_size = int(response.headers.get("Content-Length"))
      tarball_path = os.path.join(checkpoint_path, tarball_filename)
      tmp_tarball = tf.gfile.Open(tarball_path, "wb")
      tf.logging.info(
          "Downloading {} checkpoint.".format(network_filename)
      )
      with click.progressbar(length=total_size) as bar:
          for data in response.iter_content(chunk_size=4096):
              tmp_tarball.write(data)
              bar.update(len(data))
      tmp_tarball.flush()
  
      tf.logging.info("Saving checkpoint to {}".format(checkpoint_path))
      # Open saved tarball as readable binary
      tmp_tarball = tf.gfile.Open(tarball_path, "rb")
      # Open tarfile object
      tar_obj = tarfile.open(fileobj=tmp_tarball)
      # Get checkpoint file name
      checkpoint_file_name = tar_obj.getnames()[0]
      # Create buffer with extracted network checkpoint
      checkpoint_fp = tar_obj.extractfile(checkpoint_file_name)
      # Define where to save.
      checkpoint_file = tf.gfile.Open(checkpoint_filename, "wb")
      # Write extracted checkpoint to file
      checkpoint_file.write(checkpoint_fp.read())
      checkpoint_file.flush()
      checkpoint_file.close()
      tmp_tarball.close()
      # Remove temp tarball
      tf.gfile.Remove(tarball_path)
  
file_path: luminoth/luminoth/utils/checkpoint_downloader.py
imports: import click
  import json
  import os
  import requests
  import tarfile
  import tensorflow
  from luminoth.utils.homedir import get_luminoth_home
label_desc: Use image node_id 3 for calling a global function with example usage: download_checkpoint(network, network_filename, checkpoint_path, checkpoint_filename) without return types