code: def reader_wrapper(reader, input_list):
      def gen():
          for data in reader:
              in_dict = {}
              if isinstance(input_list, list):
                  for input_name in input_list:
                      in_dict[input_name] = data[input_name]
              elif isinstance(input_list, dict):
                  for input_name in input_list.keys():
                      in_dict[input_list[input_name]] = data[input_name]
              yield in_dict
  
      return gen
  
file_path: PaddleDetection/deploy/auto_compression/run.py
imports: import os
  import sys
  import numpy
  import argparse
  import paddle
  from ppdet.core.workspace import load_config, merge_config
  from ppdet.core.workspace import create
  from ppdet.metrics import COCOMetric, VOCMetric, KeyPointTopDownCOCOEval
  from paddleslim.auto_compression.config_helpers import load_config
  from paddleslim.auto_compression import AutoCompression
  from post_process import PPYOLOEPostProcess
  from paddleslim.common.dataloader import get_feed_vars
label_desc: Use image node_id 2 for calling a global function with example usage: reader_wrapper(reader, input_list) and returns: gen