code: def scan_batch_iter(data, batch_size, fid, num_workers):
      """node_batch_iter"""
      batch = []
      cc = 0
      for line_example in data.scan():
          cc += 1
          if cc % num_workers != fid:
              continue
          batch.append(line_example)
          if len(batch) == batch_size:
              yield batch
              batch = []
  
      if len(batch) > 0:
          yield batch
  
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  from __future__ import unicode_literals
  from __future__ import absolute_import
  import os
  import sys
  import six
  from io import open
  from collections import namedtuple
  import numpy
  import tqdm
  import paddle
  from pgl.utils import mp_reader
  import collections
  import time
  import traceback
label_desc: Use image node_id 2 for calling a global function with example usage: scan_batch_iter(data, batch_size, fid, num_workers) without return types