code: def minute_to_session(column, close_locs, data, out):
      """
      Resample an array with minute data into an array with session data.
  
      This function assumes that the minute data is the exact length of all
      minutes in the sessions in the output.
  
      Parameters
      ----------
      column : str
          The `open`, `high`, `low`, `close`, or `volume` column.
      close_locs : array[intp]
          The locations in `data` which are the market close minutes.
      data : array[float64|uint32]
          The minute data to be sampled into session data.
          The first value should align with the market open of the first session,
          containing values for all minutes for all sessions. With the last value
          being the market close of the last session.
      out : array[float64|uint32]
          The output array into which to write the sampled sessions.
      """
      if column == "open":
          _minute_to_session_open(close_locs, data, out)
      elif column == "high":
          _minute_to_session_high(close_locs, data, out)
      elif column == "low":
          _minute_to_session_low(close_locs, data, out)
      elif column == "close":
          _minute_to_session_close(close_locs, data, out)
      elif column == "volume":
          _minute_to_session_volume(close_locs, data, out)
      return out
  
imports: from collections import OrderedDict
  from abc import ABCMeta, abstractmethod
  import numpy
  import pandas
  from six import with_metaclass
  from zipline.data._resample import _minute_to_session_open, _minute_to_session_high, _minute_to_session_low, _minute_to_session_close, _minute_to_session_volume
  from zipline.data.bar_reader import NoDataOnDate
  from zipline.data.minute_bars import MinuteBarReader
  from zipline.data.session_bars import SessionBarReader
  from zipline.utils.memoize import lazyval
label_desc: Use image node_id 2 for calling a global function with example usage: minute_to_session(column, close_locs, data, out) and returns: out