code: def get_current_batch_size(feed_batch, dataflow):
      if hasattr(feed_batch, "iteritems"):
          iterator = feed_batch.iteritems
      else:
          iterator = feed_batch.items
      for k, v in iterator():
          if k.get_shape()[0].value == None:
              if type(v) is list:
                  return len(v)
              else:
                  return int(v.shape[0])
      return dataflow.batch_size
  
imports: from __future__ import division, print_function, absolute_import
  import re
  import os
  import numpy
  import tensorflow.compat.v1
  from tensorflow.python.training import optimizer
  import tflearn
  from ..None import callbacks
  from ..config import init_training_mode
  from ..utils import to_list, id_generator, check_dir_name, standarize_dict, get_dict_first_element, make_batches, slice_array, check_scope_path, check_restore_tensor
  from ..None import data_flow
  from ..None import variables
  from ..None import utils
  from .summarizer import summaries, summarize, summarize_gradients, summarize_variables, summarize_activations
label_desc: Use image node_id 2 for calling a global function with example usage: get_current_batch_size(feed_batch, dataflow) and returns: dataflow, len, int