code: def build_config(
      pretrained,
      global_pool_type,
      sync_bn,
      no_aug,
      mixup,
      cutmix,
      model_ema,
      model_ema_force_cpu,
      save_images,
      pin_mem,
      use_multi_epochs_loader,
      amp,
      apex_amp,
      native_amp,
      prefetcher,
      interpolation,
      batch_size,
      hflip,
      vflip,
      train_interpolation,
      num_workers,
      tta,
  ):
      config = {
          "model": {
              "model": "resnet50",
              "pretrained": pretrained,
              "global_pool_type": global_pool_type,
          },
          "dataset": {"interpolation": interpolation},
          "train": {
              "batch_size": batch_size,
              "sync_bn": sync_bn,
          },
          "augmentation": {
              "no_aug": no_aug,
              "mixup": mixup,
              "cutmix": cutmix,
              "hflip": hflip,
              "vflip": vflip,
              "train_interpolation": train_interpolation,
          },
          "model_ema": {
              "model_ema": model_ema,
              "model_ema_force_cpu": model_ema_force_cpu,
          },
          "misc": {
              "num_workers": num_workers,
              "save_images": save_images,
              "pin_mem": pin_mem,
              "tta": tta,
              "use_multi_epochs_loader": use_multi_epochs_loader,
              "amp": amp,
              "apex_amp": apex_amp,
              "native_amp": native_amp,
              "prefetcher": prefetcher,
          },
      }
      if (
          config["augmentation"]["mixup"]
          or config["augmentation"]["cutmix"]
      ):
          config["train"]["batch_size"] = 2
      config["train"]["epochs"] = 1
      config["gpus"] = list(range(get_gpu_count()))
      config["misc"][
          "apex_amp"
      ] = False  # apex amp cause mem leak: https://github.com/NVIDIA/apex/issues/439
      return config
  
file_path: gluon-cv/tests/auto/test_torch_auto_estimators.py
imports: from nose.tools import nottest
  from gluoncv.auto.estimators import TorchImageClassificationEstimator
  from gluoncv.auto.tasks import ImageClassification, ImagePrediction
  import autogluon.core
  from autogluon.core.scheduler.resource import get_cpu_count, get_gpu_count
label_desc: Use image node_id 7 for calling a global function with example usage: build_config(pretrained, global_pool_type, sync_bn, no_aug, mixup, cutmix, model_ema, model_ema_force_cpu, save_images, pin_mem, use_multi_epochs_loader, amp, apex_amp, native_amp, prefetcher, interpolation, batch_size, hflip, vflip, train_interpolation, num_workers, tta) and returns: config