class_docstr: PipelineEngine class that computes each term independently.
  
  Parameters
  ----------
  get_loader : callable
      A function that is given a loadable term and returns a PipelineLoader
      to use to retrieve raw data for that term.
  calendar : DatetimeIndex
      Array of dates to consider as trading days when computing a range
      between a fixed start and end.
  asset_finder : catalyst.assets.AssetFinder
      An AssetFinder instance.  We depend on the AssetFinder to determine
      which assets are in the top-level universe at any point in time.
  populate_initial_workspace : callable, optional
      A function which will be used to populate the initial workspace when
      computing a pipeline. See
      :func:`catalyst.pipeline.engine.default_populate_initial_workspace`
      for more info.
  
  See Also
  --------
  :func:`catalyst.pipeline.engine.default_populate_initial_workspace`
docstr: Compute the Pipeline terms in the graph for the requested start and end
  dates.
  
  Parameters
  ----------
  graph : catalyst.pipeline.graph.TermGraph
  dates : pd.DatetimeIndex
      Row labels for our root mask.
  assets : pd.Int64Index
      Column labels for our root mask.
  initial_workspace : dict
      Map from term -> output.
      Must contain at least entry for `self._root_mask_term` whose shape
      is `(len(dates), len(assets))`, but may contain additional
      pre-computed terms for testing or optimization purposes.
  
  Returns
  -------
  results : dict
      Dictionary mapping requested results to outputs.
docstr_tok: ["Compute","the","Pipeline","terms","in","the","graph","for","the","requested","start","and","end","dates",".","Parameters","--","--","--","--","--","graph",":","catalyst.pipeline.graph.TermGraph","dates",":","pd.DatetimeIndex","Row","labels","for","our","root","mask",".","assets",":","pd.Int64Index","Column","labels","for","our","root","mask",".","initial_workspace",":","dict","Map","from","term","-",">","output",".","Must","contain","at","least","entry","for","`","self._root_mask_term","`","whose","shape","is","`","(","len","(","dates",")",",","len","(","assets",")",")","`",",","but","may","contain","additional","pre-computed","terms","for","testing","or","optimization","purposes",".","Returns","--","--","--","-","results",":","dict","Dictionary","mapping","requested","results","to","outputs","."]
code: def compute_chunk(self, graph, dates, assets, initial_workspace):
      """
      Compute the Pipeline terms in the graph for the requested start and end
      dates.
  
      Parameters
      ----------
      graph : catalyst.pipeline.graph.TermGraph
      dates : pd.DatetimeIndex
          Row labels for our root mask.
      assets : pd.Int64Index
          Column labels for our root mask.
      initial_workspace : dict
          Map from term -> output.
          Must contain at least entry for `self._root_mask_term` whose shape
          is `(len(dates), len(assets))`, but may contain additional
          pre-computed terms for testing or optimization purposes.
  
      Returns
      -------
      results : dict
          Dictionary mapping requested results to outputs.
      """
      self._validate_compute_chunk_params(
          dates, assets, initial_workspace
      )
      get_loader = self.get_loader
  
      # Copy the supplied initial workspace so we don't mutate it in place.
      workspace = initial_workspace.copy()
  
      # If loadable terms share the same loader and extra_rows, load them all
      # together.
      loader_group_key = juxt(get_loader, getitem(graph.extra_rows))
      loader_groups = groupby(loader_group_key, graph.loadable_terms)
  
      refcounts = graph.initial_refcounts(workspace)
  
      for term in graph.execution_order(refcounts):
          # `term` may have been supplied in `initial_workspace`, and in the
          # future we may pre-compute loadable terms coming from the same
          # dataset.  In either case, we will already have an entry for this
          # term, which we shouldn't re-compute.
          if term in workspace:
              continue
  
          # Asset labels are always the same, but date labels vary by how
          # many extra rows are needed.
          mask, mask_dates = graph.mask_and_dates_for_term(
              term,
              self._root_mask_term,
              workspace,
              dates,
          )
  
          if isinstance(term, LoadableTerm):
              # term_key = loader_group_key(term)
              # TODO: temp workaround
              to_load = sorted(
                  six.next(six.itervalues(loader_groups)),
                  key=lambda t: t.dataset,
              )
              loader = get_loader(term)
              loaded = loader.load_adjusted_array(
                  to_load,
                  mask_dates,
                  assets,
                  mask,
              )
              workspace.update(loaded)
          else:
              workspace[term] = term._compute(
                  self._inputs_for_term(term, workspace, graph),
                  mask_dates,
                  assets,
                  mask,
              )
              if term.ndim == 2:
                  assert workspace[term].shape == mask.shape
              else:
                  assert workspace[term].shape == (mask.shape[0], 1)
  
              # Decref dependencies of ``term``, and clear any terms whose
              # refcounts hit 0.
              for garbage_term in graph.decref_dependencies(
                  term, refcounts
              ):
                  del workspace[garbage_term]
  
      out = {}
      graph_extra_rows = graph.extra_rows
      for name, term in iteritems(graph.outputs):
          # Truncate off extra rows from outputs.
          out[name] = workspace[term][graph_extra_rows[term] :]
      return out
  
imports: from abc import ABCMeta, abstractmethod
  from uuid import uuid4
  import six
  from six import iteritems, with_metaclass
  from numpy import array
  from pandas import DataFrame, MultiIndex
  from toolz import groupby, juxt
  from toolz.curried.operator import getitem
  from catalyst.lib.adjusted_array import ensure_adjusted_array, ensure_ndarray
  from catalyst.errors import NoFurtherDataError
  from catalyst.utils.numpy_utils import as_column, repeat_first_axis, repeat_last_axis
  from catalyst.utils.pandas_utils import explode
  from .term import AssetExists, InputDates, LoadableTerm
  from catalyst.utils.date_utils import compute_date_range_chunks
  from catalyst.utils.pandas_utils import categorical_df_concat
  from catalyst.utils.sharedoc import copydoc
label_desc: Use image node_id 7 for calling the SimplePipelineEngine obj's underlying member method code with example usage: obj.compute_chunk(graph, dates, assets, initial_workspace) and returns: out