NVIDIA / NVIDIA/cudf

[QST] Proper way to do mean centering for fixed-row-length LIST type column

Open
#9,683 5 comments 0 reactions 1 assignee Claimed by @isVoid View on GitHub
libcudf question
Dominant language
C++
Stars
9.8k
Forks
1.1k
Avg merge
3d 6m
Merged PRs (30d)
278

Description

In machine leaning practice, it's very common to calculate mean value and do mean subtractions for input column data. For example:

The input is a LIST type column data with fixed row-length of 3:
```
[1,2,3]
[3,1,2]
[2,3,1]
```
User wants to do mean centering for it: calculate the mean value for each sub column, in this case, it's always 2. Then do mean subtractions:
```
[-1, 0, 1]
[1, -1, 0]
[0, 1, -1]
```

Is their any nice way to do it? Currently I can only think of:
1. use `cudf::lists::extract_list_element` to extract all sub column
2. calculate mean value for each of them
3. do subtraction
4. construct them back to a LIST column.

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.