code: def get_data(args):
      datadir = args.data
      imgs = glob.glob(os.path.join(datadir, "*.jpg"))
      ds = ImageFromFile(imgs, channel=3, shuffle=True)
  
      ds = MapData(ds, functools.partial(split_input, args.mode))
      augs = [imgaug.Resize(286), imgaug.RandomCrop(256)]
      ds = AugmentImageComponents(ds, augs, (0, 1))
      ds = BatchData(ds, BATCH)
      ds = MultiProcessRunner(ds, 100, 1)
      return ds
  
imports: import argparse
  import functools
  import glob
  import numpy
  import os
  import cv2
  import tensorflow
  from tensorpack import *
  from tensorpack.tfutils.scope_utils import auto_reuse_variable_scope
  from tensorpack.tfutils.summary import add_moving_summary
  from tensorpack.utils.gpu import get_num_gpu
  from tensorpack.utils.viz import stack_patches
  from GAN import GANModelDesc, GANTrainer
label_desc: Use image node_id 4 for calling a global function with example usage: get_data(args) and returns: ds