class_docstr: Estimates loader that loads data that needs to be split-adjusted.
  
  Parameters
  ----------
  split_adjustments_loader : SQLiteAdjustmentReader
      The loader to use for reading split adjustments.
  split_adjusted_column_names : iterable of str
      The column names that should be split-adjusted.
  split_adjusted_asof : pd.Timestamp
      The date that separates data into 2 halves: the first half is the set
      of dates up to and including the split_adjusted_asof date. All
      adjustments occurring during this first half are applied  to all
      dates in this first half. The second half is the set of dates after
      the split_adjusted_asof date. All adjustments occurring during this
      second half are applied sequentially as they appear in the timeline.
class_docstr_tok: ["Estimates","loader","that","loads","data","that","needs","to","be","split-adjusted",".","Parameters","--","--","--","--","--","split_adjustments_loader",":","SQLiteAdjustmentReader","The","loader","to","use","for","reading","split","adjustments",".","split_adjusted_column_names",":","iterable","of","str","The","column","names","that","should","be","split-adjusted",".","split_adjusted_asof",":","pd.Timestamp","The","date","that","separates","data","into","2","halves",":","the","first","half","is","the","set","of","dates","up","to","and","including","the","split_adjusted_asof","date",".","All","adjustments","occurring","during","this","first","half","are","applied","to","all","dates","in","this","first","half",".","The","second","half","is","the","set","of","dates","after","the","split_adjusted_asof","date",".","All","adjustments","occurring","during","this","second","half","are","applied","sequentially","as","they","appear","in","the","timeline","."]
docstr: Collect split adjustments that occur before the
  split-adjusted-asof-date. All those adjustments must first be
  UN-applied at the first date index and then re-applied on the
  appropriate dates in order to match point in time share pricing data.
  
  Parameters
  ----------
  split_adjusted_asof_date_idx : int
      The index in the calendar dates as-of which all data was
      split-adjusted.
  sid_idx : int
      The index of the sid for which adjustments should be collected in
      the adjusted array.
  pre_adjustments : tuple(list(float), list(int))
      The adjustment values, indexes in `dates`, and timestamps for
      adjustments that happened after the split-asof-date.
  requested_split_adjusted_columns : list of str
      The requested split adjusted columns.
  
  Returns
  -------
  col_to_split_adjustments : dict[str -> dict[int -> list of Adjustment]]
      The adjustments for this sid that occurred on or before the
      split-asof-date.
docstr_tok: ["Collect","split","adjustments","that","occur","before","the","split-adjusted-asof-date",".","All","those","adjustments","must","first","be","UN-applied","at","the","first","date","index","and","then","re-applied","on","the","appropriate","dates","in","order","to","match","point","in","time","share","pricing","data",".","Parameters","--","--","--","--","--","split_adjusted_asof_date_idx",":","int","The","index","in","the","calendar","dates","as-of","which","all","data","was","split-adjusted",".","sid_idx",":","int","The","index","of","the","sid","for","which","adjustments","should","be","collected","in","the","adjusted","array",".","pre_adjustments",":","tuple","(","list","(","float",")",",","list","(","int",")",")","The","adjustment","values",",","indexes","in","`","dates","`",",","and","timestamps","for","adjustments","that","happened","after","the","split-asof-date",".","requested_split_adjusted_columns",":","list","of","str","The","requested","split","adjusted","columns",".","Returns","--","--","--","-","col_to_split_adjustments",":","dict","[","str","-",">","dict","[","int","-",">","list","of","Adjustment","]","]","The","adjustments","for","this","sid","that","occurred","on","or","before","the","split-asof-date","."]
code: def collect_pre_split_asof_date_adjustments(
      self,
      split_adjusted_asof_date_idx,
      sid_idx,
      pre_adjustments,
      requested_split_adjusted_columns,
  ):
      """
      Collect split adjustments that occur before the
      split-adjusted-asof-date. All those adjustments must first be
      UN-applied at the first date index and then re-applied on the
      appropriate dates in order to match point in time share pricing data.
  
      Parameters
      ----------
      split_adjusted_asof_date_idx : int
          The index in the calendar dates as-of which all data was
          split-adjusted.
      sid_idx : int
          The index of the sid for which adjustments should be collected in
          the adjusted array.
      pre_adjustments : tuple(list(float), list(int))
          The adjustment values, indexes in `dates`, and timestamps for
          adjustments that happened after the split-asof-date.
      requested_split_adjusted_columns : list of str
          The requested split adjusted columns.
  
      Returns
      -------
      col_to_split_adjustments : dict[str -> dict[int -> list of Adjustment]]
          The adjustments for this sid that occurred on or before the
          split-asof-date.
      """
      col_to_split_adjustments = {}
      if len(pre_adjustments[0]):
          adjustment_values, date_indexes = pre_adjustments
          for column_name in requested_split_adjusted_columns:
              col_to_split_adjustments[column_name] = {}
              # We need to undo all adjustments that happen before the
              # split_asof_date here by reversing the split ratio.
              col_to_split_adjustments[column_name][0] = [
                  Float64Multiply(
                      0,
                      split_adjusted_asof_date_idx,
                      sid_idx,
                      sid_idx,
                      1 / future_adjustment,
                  )
                  for future_adjustment in adjustment_values
              ]
  
              for adjustment, date_index in zip(
                  adjustment_values, date_indexes
              ):
                  adj = Float64Multiply(
                      0,
                      split_adjusted_asof_date_idx,
                      sid_idx,
                      sid_idx,
                      adjustment,
                  )
                  add_new_adjustments(
                      col_to_split_adjustments,
                      [adj],
                      column_name,
                      date_index,
                  )
  
      return col_to_split_adjustments
  
imports: from abc import abstractmethod, abstractproperty
  import numpy
  import pandas
  from six import viewvalues
  from toolz import groupby
  from catalyst.lib.adjusted_array import AdjustedArray
  from catalyst.lib.adjustment import Datetime641DArrayOverwrite, Datetime64Overwrite, Float641DArrayOverwrite, Float64Multiply, Float64Overwrite
  from catalyst.pipeline.common import EVENT_DATE_FIELD_NAME, FISCAL_QUARTER_FIELD_NAME, FISCAL_YEAR_FIELD_NAME, SID_FIELD_NAME, TS_FIELD_NAME
  from catalyst.pipeline.loaders.base import PipelineLoader
  from catalyst.utils.numpy_utils import datetime64ns_dtype, float64_dtype
  from catalyst.pipeline.loaders.utils import ffill_across_cols, last_in_date_group
label_desc: Use image node_id 6 for calling the SplitAdjustedEstimatesLoader obj's underlying member method code with example usage: obj.collect_pre_split_asof_date_adjustments(split_adjusted_asof_date_idx, sid_idx, pre_adjustments, requested_split_adjusted_columns) and returns: col_to_split_adjustments