We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
unary
Describe the bug
unary kernel doesn't respect the offset when determining the null buffer, which means that the results are incorrect when applied to a slice.
To Reproduce Steps to reproduce the behavior:
#[test] fn test_unary_f64_slice() { let input = Float64Array::from(vec![Some(5.1f64), None, Some(6.8), None, Some(7.2)]); let input_slice = input.slice(1, 4); let input_slice: &Float64Array = as_primitive_array(&input_slice); let result = unary(input_slice, |n| n.round()); assert_eq!( result, Float64Array::from(vec![None, Some(7.0), None, Some(7.0)]) ) }
Expected behavior
The test should pass.
Actual behavior
The test fails:
thread 'compute::kernels::arity::tests::test_unary_f64_slice' panicked at 'assertion failed: `(left == right)` left: `PrimitiveArray<Float64> [ 0.0, null, 0.0, null, ]`, right: `PrimitiveArray<Float64> [ null, 7.0, null, 7.0, ]`', arrow/src/compute/kernels/arity.rs:88:9
Additional context
The text was updated successfully, but these errors were encountered:
Successfully merging a pull request may close this issue.
Describe the bug
unary
kernel doesn't respect the offset when determining the null buffer, which means that the results are incorrect when applied to a slice.To Reproduce
Steps to reproduce the behavior:
Expected behavior
The test should pass.
Actual behavior
The test fails:
Additional context
The text was updated successfully, but these errors were encountered: