NVIDIA / NVIDIA/cudf

[FEA] center implementation for rolling window

Open
#14,334 3 comments 0 reactions 0 assignees View on GitHub
feature request Python
Dominant language
C++
Stars
9.8k
Forks
1.1k
Avg merge
3d 6m
Merged PRs (30d)
278

Description

Hi,

I am currently doing some feature engineering on a timeseries. My index is a datetime and I want to apply a rolling window.
FYI the pandas code is running.
`df['feature'] = df['feature'].rolling(f'{120}s', center=True, min_periods=1).sum()`

which leads to the following error:

`NotImplementedError: center is not implemented for offset-based windows`

basically, I want to change to cudf for runtime optimization. As I have a datetime as an index, rolling operation with centring is much appreciated due to the fact of handling missing values, just shifting by timestamp is not trivial as discussed [here.](https://github.com/pandas-dev/pandas/issues/20012)

I would appreciate if you could take a look. (Maybe it occurs due to some changes in the API interface)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.