code: def np_array_datetime64_compat(arr, *args, **kwargs):
      """
      provide compat for construction of an array of strings to a
      np.array(..., dtype=np.datetime64(..))
      tz-changes in 1.11 that make '2015-01-01 09:00:00Z' show a deprecation
      warning, when need to pass '2015-01-01 09:00:00'
      """
      # is_list_like
      if hasattr(arr, "__iter__") and not isinstance(
          arr, string_and_binary_types
      ):
          arr = [tz_replacer(s) for s in arr]
      else:
          arr = tz_replacer(arr)
  
      return np.array(arr, *args, **kwargs)
  
imports: import re
  import numpy
  from distutils.version import LooseVersion
  from pandas.compat import string_types, string_and_binary_types
label_desc: Use image node_id 3 for calling a global function with example usage: np_array_datetime64_compat(arr) and returns: np