singhpratech opened a new issue, #1296:
URL: https://github.com/apache/arrow-go/issues/1296
**Describe the enhancement requested**
`compute.GetFunctionRegistry()` in v18.7.0 registers 85 functions, all
scalar (80) or vector (5).
`FuncScalarAgg` and `FuncHashAgg` exist as kinds, but no function of either
kind is registered: `sum`,
`mean`, `min`, `max`, `min_max`, `count`, `count_distinct`, `any`, `all`,
`variance`, `stddev`,
`hash_sum` and `hash_count` are all absent. The package documentation
describes "an Acero-like arrow
compute engine" and marks the package experimental, but does not say that
aggregation is not
implemented, so a reader coming from pyarrow.compute or the C++ function
list discovers it by a
failed lookup.
Go 1.27.1, macOS 26.6 (arm64), arrow-go v18.7.0. On v18.8.0-rc1 the registry
holds 89 functions (76
scalar, 8 vector, 5 meta), still none of aggregate kind.
```go
reg := compute.GetFunctionRegistry()
names := reg.GetFunctionNames()
kinds := map[string]int{}
for _, n := range names {
fn, _ := reg.GetFunction(n)
kinds[fn.Kind().String()]++
}
fmt.Println(len(names), kinds)
for _, n := range []string{"sum", "mean", "min_max", "count", "hash_sum"} {
_, ok := reg.GetFunction(n)
fmt.Println(n, ok)
}
```
Output:
```
85 map[Scalar:80 Vector:5]
sum false
mean false
min_max false
count false
hash_sum false
```
**What would help**
Either of two things, and ideally both: a sentence in the `compute` package
documentation listing
what is and is not implemented (scalar and vector functions yes; scalar
aggregates and hash
aggregates not yet), and the aggregates themselves, starting with `sum`,
`min_max`, `count` and
`mean` over the primitive types. Context: a binding that uses arrow-go's
kernels as the reference for
its own reductions and group-bys currently has to write those references as
plain Go loops.
**Component(s)**
Go, Compute
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]