Skip to main content

Module compute

Module compute 

Source
Expand description

Compute kernels on top of Vortex Arrays.

We aim to provide a basic set of compute kernels that can be used to efficiently index, slice, and filter Vortex Arrays in their encoded forms.

Every array encoding has the ability to implement their own efficient implementations of these operators, else we will decode, and perform the equivalent operator from Arrow.

Modules§

conformance

Structs§

BinaryArgs
For binary compute functions, it’s useful to just have this short-cut.
ComputeFn
An instance of a compute function holding the implementation vtable and a set of registered compute kernels.
InvocationArgs
Arguments to a compute function invocation.
IsConstantKernelAdapter
IsConstantKernelRef
IsConstantOpts
Configuration for is_constant_opts operations.
IsSortedKernelAdapter
IsSortedKernelRef
MinMax
MinMaxKernelAdapter
MinMaxKernelRef
MinMaxResult
NaNCountKernelAdapter
NaNCountKernelRef
SumArgs
For unary compute functions, it’s useful to just have this short-cut.
SumKernelAdapter
SumKernelRef
UnaryArgs
For unary compute functions, it’s useful to just have this short-cut.

Enums§

Cost
When calling is_constant the children are all checked for constantness. This enum decide at each precision/cost level the constant check should run as. The cost increase as we move down the list.
Input
Input to a compute function.
Output
Output from a compute function.

Traits§

ComputeFnVTable
VTable for the implementation of a compute function.
IsConstantKernel
IsSortedIteratorExt
Helper methods to check sortedness with strictness
IsSortedKernel
Kernel
Compute functions can ask arrays for compute kernels for a given invocation.
MinMaxKernel
The minimum and maximum non-null values of an array, or None if there are no non-null/or non-nan values.
NaNCountKernel
Computes the min and max of an array, returning the (min, max) values
Options
Options for a compute function invocation.
SumKernel

Functions§

addDeprecated
Point-wise add two numeric arrays.
add_scalarDeprecated
Point-wise add a scalar value to this array on the right-hand-side.
and_kleeneDeprecated
Point-wise Kleene logical and between two Boolean arrays.
arrow_filter_fn
castDeprecated
Cast an array to the given data type.
compare_lengths_to_empty
Helper function to compare empty values with arrays that have external value length information like VarBin.
divDeprecated
Point-wise divide two numeric arrays.
div_scalarDeprecated
Point-wise divide a scalar value into this array on the right-hand-side.
fill_nullDeprecated
Replace nulls in the array with another value.
filter
Keep only the elements for which the corresponding mask value is true.
invertDeprecated
Logically invert a boolean array, preserving its validity.
is_constant
Computes whether an array has constant values. If the array’s encoding doesn’t implement the relevant VTable, it’ll try and canonicalize in order to make a determination.
is_constant_opts
Computes whether an array has constant values. Configurable by IsConstantOpts.
is_sorted
is_sorted_opts
is_strict_sorted
list_containsDeprecated
Compute a Bool-typed array the same length as array where elements is true if the list item contains the value, false otherwise.
maskDeprecated
Replace values with null where the mask is true.
min_max
The minimum and maximum non-null values of an array, or None if there are no non-null values.
mulDeprecated
Point-wise multiply two numeric arrays.
mul_scalarDeprecated
Point-wise multiply a scalar value into this array on the right-hand-side.
nan_count
Computes the number of NaN values in the array.
numericDeprecated
Point-wise numeric operation between two arrays of the same type and length.
or_kleeneDeprecated
Point-wise Kleene logical or between two Boolean arrays.
subDeprecated
Point-wise subtract two numeric arrays.
sub_scalarDeprecated
Point-wise subtract a scalar value from this array on the right-hand-side.
sum
Sum an array, starting from zero.
sum_impl
Sum an array.
warm_up_vtables
Force all the default ComputeFn vtables to register all available compute kernels.
zipDeprecated
Performs element-wise conditional selection between two arrays based on a mask.