pub fn _agg_helper_slice<T, F>(groups: &[[IdxSize; 2]], f: F) -> Serieswhere
    F: Fn([IdxSize; 2]) -> Option<T::Native> + Send + Sync,
    T: PolarsNumericType,
    ChunkedArray<T>: IntoSeries,