pub enum ColumnData {
Float64(Vec<f64>),
Int64(Vec<i64>),
Bool(Vec<bool>),
Utf8(Vec<String>),
Timedelta64(Vec<i64>),
Datetime64(Vec<i64>),
Period(Vec<i64>),
Interval(Vec<Interval>),
}Expand description
AG-10: Typed array representation for vectorized batch execution.
Stores column data as contiguous typed arrays rather than Vec<Scalar>.
Validity is tracked by ValidityMask; invalid positions hold unspecified
values in the typed array (callers must check validity before reading).
This eliminates per-element enum dispatch for arithmetic operations,
enabling SIMD auto-vectorization on &[f64] / &[i64] slices.
Variants§
Float64(Vec<f64>)
Int64(Vec<i64>)
Bool(Vec<bool>)
Utf8(Vec<String>)
Timedelta64(Vec<i64>)
Datetime64(Vec<i64>)
Period(Vec<i64>)
Interval(Vec<Interval>)
Implementations§
Source§impl ColumnData
impl ColumnData
Sourcepub fn from_scalars(values: &[Scalar], dtype: DType) -> Self
pub fn from_scalars(values: &[Scalar], dtype: DType) -> Self
Materialize typed array from a Vec<Scalar> and its ValidityMask.
Invalid positions get a default sentinel (0 / 0.0 / false / “”).
The caller must pair this with the corresponding ValidityMask to
interpret which positions are actually valid.
Sourcepub fn to_scalars(&self, dtype: DType, validity: &ValidityMask) -> Vec<Scalar>
pub fn to_scalars(&self, dtype: DType, validity: &ValidityMask) -> Vec<Scalar>
Convert typed array back to Vec<Scalar>, respecting ValidityMask.
pub fn len(&self) -> usize
pub fn is_empty(&self) -> bool
Trait Implementations§
Source§impl Clone for ColumnData
impl Clone for ColumnData
Source§fn clone(&self) -> ColumnData
fn clone(&self) -> ColumnData
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for ColumnData
impl Debug for ColumnData
Source§impl PartialEq for ColumnData
impl PartialEq for ColumnData
Source§fn eq(&self, other: &ColumnData) -> bool
fn eq(&self, other: &ColumnData) -> bool
Tests for
self and other values to be equal, and is used by ==.impl StructuralPartialEq for ColumnData
Auto Trait Implementations§
impl Freeze for ColumnData
impl RefUnwindSafe for ColumnData
impl Send for ColumnData
impl Sync for ColumnData
impl Unpin for ColumnData
impl UnsafeUnpin for ColumnData
impl UnwindSafe for ColumnData
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more