code: def _homo_split(self, df: DataFrame, return_indexer):
      kf = sk_KFold(
          n_splits=self._n_splits,
          shuffle=self._shuffle,
          random_state=self._random_state,
      )
      indexer = list(df.get_indexer(target="sample_id").collect())
  
      for train, test in kf.split(indexer):
          train_indexer = [indexer[idx] for idx in train]
          test_indexer = [indexer[idx] for idx in test]
  
          train_indexer = self._ctx.computing.parallelize(
              train_indexer,
              include_key=True,
              partition=df.block_table.num_partitions,
          )
  
          test_indexer = self._ctx.computing.parallelize(
              test_indexer,
              include_key=True,
              partition=df.block_table.num_partitions,
          )
  
          train_frame = df.loc(train_indexer)
          test_frame = df.loc(test_indexer)
  
          if return_indexer:
              yield train_frame, test_frame, train_frame.get_indexer(
                  target="sample_id"
              ), test_frame.get_indexer(target="sample_id")
          else:
              yield train_frame, test_frame
  
file_path: FATE/python/fate/arch/dataframe/utils/_k_fold.py
imports: from .._dataframe import DataFrame
  from sklearn.model_selection import KFold
label_desc: Use image node_id 4 for calling the KFold obj's underlying member method code with example usage: obj._homo_split(df, return_indexer) without return types