class_docstr: Temporal train-test splitter, based on cutoff and forecasting horizon.
  
  Train and test splits are determied as follows:
  
  for each cutoff point `k=cutoff[i]`, in `split`:
  
  * training fold is all loc indices up to and including `k`
  * if `fh` is not passed, test fold is all loc indices strictly after `k`
  * if `fh is passed`, test fold is all loc indices in `k + fh`, if `fh` is relative.
    More precisely, `fh.to_absolute_index(cutoff=k)
    If `fh` is absolute, then the test window is `fh` itself.
  
  It should be noted that, unlike in `CutoffSplitter`,
  test folds are not determined by a window length,
  but by indices of the forecasting horizon `fh`, i.e., test folds can be
  non-contiguous, even if the data index is regular.
  
  Parameters
  ----------
  cutoff : np.array or pd.Index
      Cutoff points, positive and integer- or datetime-index like.
      Type should match the type of `fh` input.
  fh : None, ForecastingHorizon, int, timedelta, iterable of ints or timedeltas
      Forecasting horizon, relative or absolute, to determine test folds.
      Type should match the type of `cutoffs` input.
      If not ForecastingHorizon, is coerced.
docstr: Get loc references to train/test splits of `y`.
  
  private _split containing the core logic, called from split_loc
  
  Parameters
  ----------
  y : pd.Index
      index of time series to split
  
  Yields
  ------
  train : pd.Index
      Training window indices, loc references to training indices in y
  test : pd.Index
      Test window indices, loc references to test indices in y
docstr_tok: ["Get","loc","references","to","train\/test","splits","of","`","y","`",".","private","_split","containing","the","core","logic",",","called","from","split_loc","Parameters","--","--","--","--","--","y",":","pd.Index","index","of","time","series","to","split","Yields","--","--","--","train",":","pd.Index","Training","window","indices",",","loc","references","to","training","indices","in","y","test",":","pd.Index","Test","window","indices",",","loc","references","to","test","indices","in","y"]
code: def _split_loc(self, y):
      """Get loc references to train/test splits of `y`.
  
      private _split containing the core logic, called from split_loc
  
      Parameters
      ----------
      y : pd.Index
          index of time series to split
  
      Yields
      ------
      train : pd.Index
          Training window indices, loc references to training indices in y
      test : pd.Index
          Test window indices, loc references to test indices in y
      """
      cutoff = self.cutoff
      fh = self.fh
  
      if fh is not None:
          from sktime.forecasting.base import ForecastingHorizon
  
          if not isinstance(fh, ForecastingHorizon):
              fh = ForecastingHorizon(fh)
  
      for k in cutoff:
          train = y[y <= k]
          if fh is not None:
              test = fh.to_absolute_index(cutoff=k)
          else:
              test = y[y > k]
          yield train, test
  
imports: from typing import Optional
  import numpy
  import pandas
  from sktime.split.base import BaseSplitter
  from sktime.split.base._common import ACCEPTED_Y_TYPES, DEFAULT_FH, DEFAULT_WINDOW_LENGTH, FORECASTING_HORIZON_TYPES, SPLIT_GENERATOR_TYPE, _check_fh, _check_inputs_for_compatibility, _get_train_window_via_endpoint
  from sktime.utils.validation import ACCEPTED_WINDOW_LENGTH_TYPES, array_is_datetime64, array_is_int, check_window_length, is_datetime, is_int, is_timedelta
  from sktime.utils.validation.forecasting import VALID_CUTOFF_TYPES, check_cutoffs
label_desc: Use image node_id 2 for calling the CutoffFhSplitter obj's underlying member method code with example usage: obj._split_loc(y) without return types