You are viewing a plain text version of this content. The canonical link for it is here.
Posted to github@arrow.apache.org by "sgilmore10 (via GitHub)" <gi...@apache.org> on 2023/06/12 15:13:49 UTC
[GitHub] [arrow] sgilmore10 opened a new pull request, #36039: GH-35984: [MATLAB] Add null support to all numeric array classes
sgilmore10 opened a new pull request, #36039:
URL: https://github.com/apache/arrow/pull/36039
### Rationale for this change
We initially only enabled null support for `arrow.array.Float64Array` via the `InferNulls` and `Valid` name-value pairs. This pull request adds null-value support to the rest of the numeric array types.
### What changes are included in this PR?
1. All numeric array classes accept the `InferNulls` and `Valid` name-value pairs.
2. `arrow.array.Float32Array` treats `NaN` as `null` by default if `InferNulls=true` and `Valid` is not supplied.
3. To reduce code duplication, we added an abstract class called `arrow.array.NumericArray` that all numeric array classes inherit form.
Here's an example of creating an `Int32Array` with `null` values:
```MATLAB
>> matlabArray = int32([1 2 3 4 5]);
>> arrowArray = arrow.array.Int32Array(matlabArray, Valid=[1 4 5])
arrowArray =
[
1,
null,
null,
4,
5
]
```
### Are these changes tested?
1. Added two unit tests to `hNumericArray.m` called `LogicalValidNVPair` and `NumericValidNVPair` which test the null support integration of all numeric types.
2. Added unit tests to `tFloat32Array.m` to verify `NaN `is treated as a null value by default.
### Are there any user-facing changes?
Yes, users can now create numeric arrays of any type with null values.
### Notes
Thanks to @kevingurney for all the help!
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow] ursabot commented on pull request #36039: GH-35984: [MATLAB] Add null support to all numeric array classes
Posted by "ursabot (via GitHub)" <gi...@apache.org>.
ursabot commented on PR #36039:
URL: https://github.com/apache/arrow/pull/36039#issuecomment-1588673563
Benchmark runs are scheduled for baseline = ab7784455bd938f0190c139a906760d88647a6c3 and contender = c13275e1e16d2db1a076398e4061a38243069c09. c13275e1e16d2db1a076398e4061a38243069c09 is a master commit associated with this PR. Results will be available as each benchmark for each run completes.
Conbench compare runs links:
[Finished :arrow_down:25.0% :arrow_up:0.0%] [ec2-t3-xlarge-us-east-2](https://conbench.ursa.dev/compare/runs/342735d2f63b45f393022b9c257672e5...972a7c05811f43d899ae3bc2a8c3b05f/)
[Finished :arrow_down:3.28% :arrow_up:0.06%] [test-mac-arm](https://conbench.ursa.dev/compare/runs/6a8d21280ebd4a2c9edbd9570d03697e...f4658a1003f4478eb0e833f63715c7c5/)
[Finished :arrow_down:0.0% :arrow_up:0.0%] [ursa-i9-9960x](https://conbench.ursa.dev/compare/runs/6077df938752428388b23e5f459ae86d...84eb66e827ad4b9ea069dac77da7a29b/)
[Finished :arrow_down:0.27% :arrow_up:0.15%] [ursa-thinkcentre-m75q](https://conbench.ursa.dev/compare/runs/8ba580a94cc14cbb85d5e0b60fb05812...c1cd6185386647c68b16a1fbbd672faa/)
Buildkite builds:
[Finished] [`c13275e1` ec2-t3-xlarge-us-east-2](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ec2-t3-xlarge-us-east-2/builds/3028)
[Finished] [`c13275e1` test-mac-arm](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-test-mac-arm/builds/3064)
[Finished] [`c13275e1` ursa-i9-9960x](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-i9-9960x/builds/3029)
[Finished] [`c13275e1` ursa-thinkcentre-m75q](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-thinkcentre-m75q/builds/3054)
[Finished] [`ab778445` ec2-t3-xlarge-us-east-2](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ec2-t3-xlarge-us-east-2/builds/3027)
[Finished] [`ab778445` test-mac-arm](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-test-mac-arm/builds/3063)
[Finished] [`ab778445` ursa-i9-9960x](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-i9-9960x/builds/3028)
[Finished] [`ab778445` ursa-thinkcentre-m75q](https://buildkite.com/apache-arrow/arrow-bci-benchmark-on-ursa-thinkcentre-m75q/builds/3053)
Supported benchmarks:
ec2-t3-xlarge-us-east-2: Supported benchmark langs: Python, R. Runs only benchmarks with cloud = True
test-mac-arm: Supported benchmark langs: C++, Python, R
ursa-i9-9960x: Supported benchmark langs: Python, R, JavaScript
ursa-thinkcentre-m75q: Supported benchmark langs: C++, Java
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [arrow] kou merged pull request #36039: GH-35984: [MATLAB] Add null support to all numeric array classes
Posted by "kou (via GitHub)" <gi...@apache.org>.
kou merged PR #36039:
URL: https://github.com/apache/arrow/pull/36039
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: github-unsubscribe@arrow.apache.org
For queries about this service, please contact Infrastructure at:
users@infra.apache.org