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.
Re-exports§
pub use crate::expr::BetweenExecuteAdaptor;pub use crate::expr::BetweenKernel;pub use crate::expr::BetweenReduce;pub use crate::expr::BetweenReduceAdaptor;pub use crate::expr::CastExecuteAdaptor;pub use crate::expr::CastKernel;pub use crate::expr::CastReduce;pub use crate::expr::CastReduceAdaptor;pub use crate::expr::FillNullExecuteAdaptor;pub use crate::expr::FillNullKernel;pub use crate::expr::FillNullReduce;pub use crate::expr::FillNullReduceAdaptor;pub use crate::expr::MaskExecuteAdaptor;pub use crate::expr::MaskKernel;pub use crate::expr::MaskReduce;pub use crate::expr::MaskReduceAdaptor;pub use crate::expr::NotExecuteAdaptor;pub use crate::expr::NotKernel;pub use crate::expr::NotReduce;pub use crate::expr::NotReduceAdaptor;
Modules§
Structs§
- Binary
Args - For binary compute functions, it’s useful to just have this short-cut.
- Compute
Fn - An instance of a compute function holding the implementation vtable and a set of registered compute kernels.
- Invocation
Args - Arguments to a compute function invocation.
- IsConstant
Kernel Adapter - IsConstant
Kernel Ref - IsConstant
Opts - Configuration for
is_constant_optsoperations. - IsSorted
Kernel Adapter - IsSorted
Kernel Ref - List
Contains - List
Contains Kernel Adapter - List
Contains Kernel Ref - MinMax
- MinMax
Kernel Adapter - MinMax
Kernel Ref - MinMax
Result - NaNCount
Kernel Adapter - NaNCount
Kernel Ref - SumArgs
- For unary compute functions, it’s useful to just have this short-cut.
- SumKernel
Adapter - SumKernel
Ref - Unary
Args - For unary compute functions, it’s useful to just have this short-cut.
Enums§
- Boolean
Operator - Operations over the nullable Boolean values.
- Cost
- When calling
is_constantthe 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.
- Operator
- Output
- Output from a compute function.
Traits§
- Compute
FnVTable - VTable for the implementation of a compute function.
- IsConstant
Kernel - IsSorted
Iterator Ext - Helper methods to check sortedness with strictness
- IsSorted
Kernel - Kernel
- Compute functions can ask arrays for compute kernels for a given invocation.
- List
Contains Kernel - MinMax
Kernel - The minimum and maximum non-null values of an array, or None if there are no non-null/or non-nan values.
- NaNCount
Kernel - Computes the min and max of an array, returning the (min, max) values
- Options
- Options for a compute function invocation.
- SumKernel
Functions§
- add
- Point-wise add two numeric arrays.
- add_
scalar - Point-wise add a scalar value to this array on the right-hand-side.
- and
Deprecated - Point-wise logical and between two Boolean arrays.
- and_
kleene - Point-wise Kleene logical and between two Boolean arrays.
- arrow_
filter_ fn - boolean
- Point-wise logical operator between two Boolean arrays.
- cast
Deprecated - Cast an array to the given data type.
- compare
- Compares two arrays and returns a new boolean array with the result of the comparison.
- compare_
lengths_ to_ empty - Helper function to compare empty values with arrays that have external value length information
like
VarBin. - div
- Point-wise divide two numeric arrays.
- div_
scalar - Point-wise divide a scalar value into this array on the right-hand-side.
- fill_
null Deprecated - Replace nulls in the array with another value.
- filter
- Keep only the elements for which the corresponding mask value is true.
- invert
Deprecated - 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_
contains - Compute a
Bool-typed array the same length asarraywhere elements istrueif the list item contains thevalue,falseotherwise. - mask
- 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.
- mul
- Point-wise multiply two numeric arrays.
- mul_
scalar - 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.
- numeric
- Point-wise numeric operation between two arrays of the same type and length.
- or
Deprecated - Point-wise logical or between two Boolean arrays.
- or_
kleene - Point-wise Kleene logical or between two Boolean arrays.
- scalar_
cmp - sub
- Point-wise subtract two numeric arrays.
- sub_
scalar - 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
ComputeFnvtables to register all available compute kernels. - zip
- Performs element-wise conditional selection between two arrays based on a mask.