Skip to content

Commit

Permalink
update for SparseArray change
Browse files Browse the repository at this point in the history
  • Loading branch information
a10y committed Oct 1, 2024
1 parent 72bd8ab commit 7cb597c
Showing 1 changed file with 5 additions and 10 deletions.
15 changes: 5 additions & 10 deletions encodings/alp/src/alp_rd/mod.rs
Original file line number Diff line number Diff line change
Expand Up @@ -29,10 +29,10 @@ use itertools::Itertools;
use num_traits::{Float, One, PrimInt};
use vortex::array::{PrimitiveArray, SparseArray};
use vortex::{ArrayDType, IntoArray};
use vortex_dtype::{DType, NativePType, Nullability, PType};
use vortex_dtype::{DType, NativePType};
use vortex_error::{VortexExpect, VortexUnwrap};
use vortex_fastlanes::{bitpack_encode_unchecked, BitPackedArray};
use vortex_scalar::Scalar;
use vortex_scalar::ScalarValue;

use crate::match_each_alp_float_ptype;

Expand Down Expand Up @@ -208,14 +208,9 @@ impl Encoder {
let exc_array =
PrimitiveArray::from_nullable_vec(exceptions.into_iter().map(Some).collect())
.into_array();
SparseArray::try_new(
packed_pos,
exc_array,
doubles.len(),
Scalar::null(DType::Primitive(PType::U16, Nullability::Nullable)),
)
.vortex_expect("ALP-RD: construction of exceptions SparseArray")
.into_array()
SparseArray::try_new(packed_pos, exc_array, doubles.len(), ScalarValue::Null)
.vortex_expect("ALP-RD: construction of exceptions SparseArray")
.into_array()
});

ALPRDArray::try_new(
Expand Down

0 comments on commit 7cb597c

Please sign in to comment.