code: def reporthook(blocknum, blocksize, totalsize):
      readsofar = blocknum * blocksize
      if totalsize > 0:
          percent = readsofar * 1e2 / totalsize
          s = "\r%5.1f%% %*d / %d" % (
              percent,
              len(str(totalsize)),
              readsofar,
              totalsize,
          )
          sys.stderr.write(s)
          if readsofar >= totalsize:  # near the end
              sys.stderr.write("\n")
      else:  # total size is unknown
          sys.stderr.write("read %d\n" % (readsofar,))
  
file_path: tflearn/tflearn/datasets/cifar10.py
imports: from __future__ import absolute_import, print_function
  import os
  import sys
  from six.moves import urllib
  import tarfile
  import numpy
  import pickle
  from ..data_utils import to_categorical
label_desc: Use image node_id 4 for calling a global function with example usage: reporthook(blocknum, blocksize, totalsize) without return types