forked from rust-ndarray/ndarray
-
Notifications
You must be signed in to change notification settings - Fork 0
[pull] master from rust-ndarray:master #1
New issue
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
Open
pull
wants to merge
865
commits into
mesalock-linux:master
Choose a base branch
from
rust-ndarray:master
base: master
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Fix typo
In `fill()` and in `assign()`.
Co-authored-by: Adam Reichold <[email protected]>
When an array has 0 or 1 elements, strides don't matter anymore. The general case of this function handled this correctly, but the special case for ndim == 1 did not.
Use merge queue
Originally contributed by @messense in pyo3, copied their solution with thanks.
Setup ci so that most checks run in merge queue only
Somehow, these take 30m on powerpc, which is too slow (much slower than anything else.) Try to use s390x instead and run numeric tests in release mode.
* add test case for empty array * return early when the array has zero lenth dims --------- Co-authored-by: Adam Kern <[email protected]>
--------- Co-authored-by: Adam Kern <[email protected]>
* draft for inplace reverse, permute * add test cases * formatter * cycle detection logic with bitmask * formatter * satisfying CI(cargo doc, etc.) * add comments from doc, to describe how the logic works
These allow the iterators to act on the lifetime of the data, not the lifetime of the view.
Specifically, deals with CVE-2025-4574, GHSA-4fcv-w3qc-ppgg, and GHSA-255r-3prx-mf99 by updating the lockfile and one set of dependencies for testing serialization.
Simple update, just an edition change in Cargo.toml and a run of `cargo update` with an MSRV-aware resolver.
* Fixes some broken references in the docs * Raise allowable epsilon errors on logspace and geomspace For some reason, when Miri runs, we get higher floating point error on these methods.
Also, remove the `if: always()` on the conclusion step of CI so that it doesn't pop up when we just change the `latest-deps.yaml`.
ndarray-rand crate on the main branch uses the workspace rand and rand_distr versions, which are 0.9 and 0.5 respectively. This commit documents those versions at ndarray-rand's lib.rs' module level.
The current implementation of ArrayRef and its cousins has them as sized types, which turns out to be a critical and unsound mistake. This PR is large, but its heart is small: change the ArrayRef implementation to be unsized. The approach this PR takes is to package the core array "metadata" - the pointer, dim, and strides - into a struct that can either be sized or unsized. This is done by appending a generic "_dst_control" field. For the "sized" version of the metadata, that field is a 0-length array. For the "unsized" version of the metadata, that sized field is a struct. This core type is private, so users cannot construct any other variants other than these two. We then put the sized version into the ArrayBase types, put the unsized version into the reference types, and perform an unsizing coercion to convert from one to the other. Because Rust has no (safe, supported) "resizing" coercion, this switch is irreversible. Sized types cannot be recovered from the unsized reference types.
…1540) Prior to ndarray 0.17, the RandomExt trait exposed by ndarray-rand contained methods for both creating new arrays randomly whole-cloth (random_using) and sampling from existing arrays (sample_axis_using). With the introduction of reference types in ndarray 0.17, users should be able to sample from ArrayRef instances as well. We choose to expose an additional extension trait, RandomRefExt, that provides this functionality. We keep the methods on the old trait for backwards compatibility, but collapse the implementation and documentation to the new trait to maintain a single source of truth.
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
See Commits and Changes for more details.
Created by
pull[bot]
Can you help keep this open source service alive? 💖 Please sponsor : )