def get_splitter(data: NDFrame, labels: np.ndarray, ngroups: int, axis: int=0) -> DataSplitter:
    if isinstance(data, Series):
        klass: type[DataSplitter] = SeriesSplitter
    else:
        klass = FrameSplitter
    return klass(data, labels, ngroups, axis)
def get_splitter(data: NDFrame, labels: np.ndarray, ngroups: int, axis: int=0) -> DataSplitter:
    if isinstance(data, Series):
        klass: type[DataSplitter] = SeriesSplitter
    else:
        klass = FrameSplitter
    return klass(data, labels, ngroups, axis)