code: def _get_sc_folds(
      date_range: Union[pd.DatetimeIndex, pd.PeriodIndex],
      date_fold_filter_fn: Callable[[DateType], pd.DataFrame],
      time_column: str,
      min_samples: int,
  ) -> List[Tuple[pd.Series, pd.Series]]:
      return pipe(
          date_range,
          map(date_fold_filter_fn),  # iteratively filter the dates
          map(lambda df: df[time_column]),  # keep only time column
          filter(lambda s: len(s.index) > min_samples),
          list,
      )
  
imports: import operator
  from datetime import datetime, timedelta
  from itertools import chain, repeat, starmap
  from typing import Callable, Iterable, List, Tuple, Union
  import numpy
  import pandas
  from sklearn.model_selection import GroupKFold, KFold, StratifiedKFold
  from sklearn.utils import check_random_state
  from toolz.curried import curry, partial, pipe, assoc, accumulate, map, filter
  from fklearn.common_docstrings import splitter_return_docstring
  from fklearn.types import DateType, LogType, SplitterReturnType
label_desc: Use image node_id 3 for calling a global function with example usage: _get_sc_folds(date_range, date_fold_filter_fn, time_column, min_samples) and returns: pipe