Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 3 additions & 3 deletions encodings/alp/src/alp/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -8,6 +8,7 @@ use std::hash::Hash;
use std::hash::Hasher;

use prost::Message;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -19,7 +20,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::TypedArrayRef;
use vortex_array::array_slots;
use vortex_array::arrays::Primitive;
Expand Down Expand Up @@ -55,14 +55,14 @@ use crate::alp::rules::RULES;
pub type ALPArray = Array<ALP>;

impl ArrayHash for ALPData {
fn array_hash<H: Hasher>(&self, state: &mut H, _precision: Precision) {
fn array_hash<H: Hasher>(&self, state: &mut H, _accuracy: Accuracy) {
self.exponents.hash(state);
self.patches_data.hash(state);
}
}

impl ArrayEq for ALPData {
fn array_eq(&self, other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, other: &Self, _accuracy: Accuracy) -> bool {
self.exponents == other.exponents && self.patches_data == other.patches_data
}
}
Expand Down
10 changes: 5 additions & 5 deletions encodings/alp/src/alp_rd/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ use std::hash::Hasher;

use itertools::Itertools;
use prost::Message;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -22,7 +23,6 @@ use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::LEGACY_SESSION;
use vortex_array::Precision;
use vortex_array::TypedArrayRef;
use vortex_array::VortexSessionExecute;
use vortex_array::arrays::Primitive;
Expand Down Expand Up @@ -75,17 +75,17 @@ pub struct ALPRDMetadata {
}

impl ArrayHash for ALPRDData {
fn array_hash<H: Hasher>(&self, state: &mut H, precision: Precision) {
self.left_parts_dictionary.array_hash(state, precision);
fn array_hash<H: Hasher>(&self, state: &mut H, accuracy: Accuracy) {
self.left_parts_dictionary.array_hash(state, accuracy);
self.right_bit_width.hash(state);
self.patches_data.hash(state);
}
}

impl ArrayEq for ALPRDData {
fn array_eq(&self, other: &Self, precision: Precision) -> bool {
fn array_eq(&self, other: &Self, accuracy: Accuracy) -> bool {
self.left_parts_dictionary
.array_eq(&other.left_parts_dictionary, precision)
.array_eq(&other.left_parts_dictionary, accuracy)
&& self.right_bit_width == other.right_bit_width
&& self.patches_data == other.patches_data
}
Expand Down
10 changes: 5 additions & 5 deletions encodings/bytebool/src/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ use std::fmt::Display;
use std::fmt::Formatter;
use std::hash::Hasher;

use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -17,7 +18,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::TypedArrayRef;
use vortex_array::arrays::BoolArray;
use vortex_array::buffer::BufferHandle;
Expand Down Expand Up @@ -45,14 +45,14 @@ use crate::kernel::PARENT_KERNELS;
pub type ByteBoolArray = Array<ByteBool>;

impl ArrayHash for ByteBoolData {
fn array_hash<H: Hasher>(&self, state: &mut H, precision: Precision) {
self.buffer.array_hash(state, precision);
fn array_hash<H: Hasher>(&self, state: &mut H, accuracy: Accuracy) {
self.buffer.array_hash(state, accuracy);
}
}

impl ArrayEq for ByteBoolData {
fn array_eq(&self, other: &Self, precision: Precision) -> bool {
self.buffer.array_eq(&other.buffer, precision)
fn array_eq(&self, other: &Self, accuracy: Accuracy) -> bool {
self.buffer.array_eq(&other.buffer, accuracy)
}
}

Expand Down
6 changes: 3 additions & 3 deletions encodings/datetime-parts/src/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use std::fmt::Formatter;
use std::hash::Hasher;

use prost::Message;
use vortex_array::Accuracy;
use vortex_array::AnyCanonical;
use vortex_array::Array;
use vortex_array::ArrayEq;
Expand All @@ -18,7 +19,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::array_slots;
use vortex_array::arrays::Primitive;
use vortex_array::arrays::TemporalArray;
Expand Down Expand Up @@ -50,11 +50,11 @@ use crate::split_temporal;
pub type DateTimePartsArray = Array<DateTimeParts>;

impl ArrayHash for DateTimePartsData {
fn array_hash<H: Hasher>(&self, _state: &mut H, _precision: Precision) {}
fn array_hash<H: Hasher>(&self, _state: &mut H, _accuracy: Accuracy) {}
}

impl ArrayEq for DateTimePartsData {
fn array_eq(&self, _other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, _other: &Self, _accuracy: Accuracy) -> bool {
true
}
}
Expand Down
6 changes: 3 additions & 3 deletions encodings/decimal-byte-parts/src/decimal_byte_parts/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -13,14 +13,14 @@ mod rules;
mod slice;

use prost::Message as _;
use vortex_array::Accuracy;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
use vortex_array::ArrayId;
use vortex_array::ArrayRef;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::TypedArrayRef;
use vortex_array::arrays::DecimalArray;
use vortex_array::arrays::PrimitiveArray;
Expand Down Expand Up @@ -53,11 +53,11 @@ use crate::decimal_byte_parts::rules::PARENT_RULES;
pub type DecimalBytePartsArray = Array<DecimalByteParts>;

impl ArrayHash for DecimalBytePartsData {
fn array_hash<H: Hasher>(&self, _state: &mut H, _precision: Precision) {}
fn array_hash<H: Hasher>(&self, _state: &mut H, _accuracy: Accuracy) {}
}

impl ArrayEq for DecimalBytePartsData {
fn array_eq(&self, _other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, _other: &Self, _accuracy: Accuracy) -> bool {
true
}
}
Expand Down
10 changes: 5 additions & 5 deletions encodings/experimental/onpair/src/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ use std::fmt::Formatter;
use std::hash::Hasher;

use prost::Message as _;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -18,7 +19,6 @@ use vortex_array::Canonical;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::array_slots;
use vortex_array::buffer::BufferHandle;
use vortex_array::builders::ArrayBuilder;
Expand Down Expand Up @@ -196,19 +196,19 @@ impl Debug for OnPairData {
}

impl ArrayHash for OnPairData {
fn array_hash<H: Hasher>(&self, state: &mut H, precision: Precision) {
self.dict_bytes.as_host().array_hash(state, precision);
fn array_hash<H: Hasher>(&self, state: &mut H, accuracy: Accuracy) {
self.dict_bytes.as_host().array_hash(state, accuracy);
state.write_u32(self.bits);
}
}

impl ArrayEq for OnPairData {
fn array_eq(&self, other: &Self, precision: Precision) -> bool {
fn array_eq(&self, other: &Self, accuracy: Accuracy) -> bool {
self.bits == other.bits
&& self
.dict_bytes
.as_host()
.array_eq(other.dict_bytes.as_host(), precision)
.array_eq(other.dict_bytes.as_host(), accuracy)
}
}

Expand Down
10 changes: 5 additions & 5 deletions encodings/fastlanes/src/bitpacking/vtable/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use std::hash::Hash;
use std::hash::Hasher;

use prost::Message;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -16,7 +17,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::buffer::BufferHandle;
use vortex_array::builders::ArrayBuilder;
use vortex_array::dtype::DType;
Expand Down Expand Up @@ -69,19 +69,19 @@ pub struct BitPackedMetadata {
}

impl ArrayHash for BitPackedData {
fn array_hash<H: Hasher>(&self, state: &mut H, precision: Precision) {
fn array_hash<H: Hasher>(&self, state: &mut H, accuracy: Accuracy) {
self.offset.hash(state);
self.bit_width.hash(state);
self.packed.array_hash(state, precision);
self.packed.array_hash(state, accuracy);
self.patches_data.hash(state);
}
}

impl ArrayEq for BitPackedData {
fn array_eq(&self, other: &Self, precision: Precision) -> bool {
fn array_eq(&self, other: &Self, accuracy: Accuracy) -> bool {
self.offset == other.offset
&& self.bit_width == other.bit_width
&& self.packed.array_eq(&other.packed, precision)
&& self.packed.array_eq(&other.packed, accuracy)
&& self.patches_data == other.patches_data
}
}
Expand Down
6 changes: 3 additions & 3 deletions encodings/fastlanes/src/delta/vtable/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use std::hash::Hash;
use std::hash::Hasher;

use prost::Message;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -15,7 +16,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::arrays::PrimitiveArray;
use vortex_array::buffer::BufferHandle;
use vortex_array::dtype::DType;
Expand Down Expand Up @@ -58,13 +58,13 @@ pub struct DeltaMetadata {
}

impl ArrayHash for DeltaData {
fn array_hash<H: Hasher>(&self, state: &mut H, _precision: Precision) {
fn array_hash<H: Hasher>(&self, state: &mut H, _accuracy: Accuracy) {
self.offset.hash(state);
}
}

impl ArrayEq for DeltaData {
fn array_eq(&self, other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, other: &Self, _accuracy: Accuracy) -> bool {
self.offset == other.offset
}
}
Expand Down
6 changes: 3 additions & 3 deletions encodings/fastlanes/src/for/vtable/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use std::fmt::Debug;
use std::hash::Hash;
use std::hash::Hasher;

use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -15,7 +16,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::arrays::PrimitiveArray;
use vortex_array::buffer::BufferHandle;
use vortex_array::dtype::DType;
Expand Down Expand Up @@ -50,13 +50,13 @@ mod validity;
pub type FoRArray = Array<FoR>;

impl ArrayHash for FoRData {
fn array_hash<H: Hasher>(&self, state: &mut H, _precision: Precision) {
fn array_hash<H: Hasher>(&self, state: &mut H, _accuracy: Accuracy) {
self.reference.hash(state);
}
}

impl ArrayEq for FoRData {
fn array_eq(&self, other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, other: &Self, _accuracy: Accuracy) -> bool {
self.reference == other.reference
}
}
Expand Down
6 changes: 3 additions & 3 deletions encodings/fastlanes/src/rle/vtable/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ use std::hash::Hash;
use std::hash::Hasher;

use prost::Message;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -15,7 +16,6 @@ use vortex_array::ArrayView;
use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::Precision;
use vortex_array::arrays::Primitive;
use vortex_array::buffer::BufferHandle;
use vortex_array::dtype::DType;
Expand Down Expand Up @@ -65,13 +65,13 @@ pub struct RLEMetadata {
}

impl ArrayHash for RLEData {
fn array_hash<H: Hasher>(&self, state: &mut H, _precision: Precision) {
fn array_hash<H: Hasher>(&self, state: &mut H, _accuracy: Accuracy) {
self.offset.hash(state);
}
}

impl ArrayEq for RLEData {
fn array_eq(&self, other: &Self, _precision: Precision) -> bool {
fn array_eq(&self, other: &Self, _accuracy: Accuracy) -> bool {
self.offset == other.offset
}
}
Expand Down
18 changes: 9 additions & 9 deletions encodings/fsst/src/array.rs
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@ use fsst::Compressor;
use fsst::Decompressor;
use fsst::Symbol;
use prost::Message as _;
use vortex_array::Accuracy;
use vortex_array::Array;
use vortex_array::ArrayEq;
use vortex_array::ArrayHash;
Expand All @@ -25,7 +26,6 @@ use vortex_array::ExecutionCtx;
use vortex_array::ExecutionResult;
use vortex_array::IntoArray;
use vortex_array::LEGACY_SESSION;
use vortex_array::Precision;
use vortex_array::TypedArrayRef;
use vortex_array::VortexSessionExecute;
use vortex_array::arrays::VarBin;
Expand Down Expand Up @@ -80,23 +80,23 @@ impl FSSTMetadata {
}

impl ArrayHash for FSSTData {
fn array_hash<H: Hasher>(&self, state: &mut H, precision: Precision) {
self.symbols.array_hash(state, precision);
self.symbol_lengths.array_hash(state, precision);
self.codes_bytes.as_host().array_hash(state, precision);
fn array_hash<H: Hasher>(&self, state: &mut H, accuracy: Accuracy) {
self.symbols.array_hash(state, accuracy);
self.symbol_lengths.array_hash(state, accuracy);
self.codes_bytes.as_host().array_hash(state, accuracy);
}
}

impl ArrayEq for FSSTData {
fn array_eq(&self, other: &Self, precision: Precision) -> bool {
self.symbols.array_eq(&other.symbols, precision)
fn array_eq(&self, other: &Self, accuracy: Accuracy) -> bool {
self.symbols.array_eq(&other.symbols, accuracy)
&& self
.symbol_lengths
.array_eq(&other.symbol_lengths, precision)
.array_eq(&other.symbol_lengths, accuracy)
&& self
.codes_bytes
.as_host()
.array_eq(other.codes_bytes.as_host(), precision)
.array_eq(other.codes_bytes.as_host(), accuracy)
}
}

Expand Down
Loading
Loading