code: def _open_for_csv(path):
      """Open a file with flags suitable for csv.reader.
  
      This is different for python2 it means with mode 'rb',
      for python3 this means 'r' with "universal newlines".
      """
      if sys.version_info[0] < 3:
          return open(path, "rb")
      else:
          return open(path, "r", newline="")
  
imports: from .generator import Generator
  from ..utils.image import read_image_bgr
  import numpy
  from PIL import Image
  from six import raise_from
  import csv
  import sys
  import os.path
  from collections import OrderedDict
label_desc: Use image node_id 4 for calling a global function with example usage: _open_for_csv(path) and returns: open, open