-
Notifications
You must be signed in to change notification settings - Fork 308
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
Smarter Debug formatting for arrays #398
Comments
Hi @bluss , @LukeMathWalker . I've never contributed to ndarray before and since it is a good first issue now I would like to pick this up. Could you please provide any guidance? Thanks. |
Welcome @andrei-papou! The You can find You can get a taste of what this looks like using 1-dimensional arrays: extern crate ndarray;
use ndarray::Array;
fn main() {
let v = Array::linspace(0., 1., 128);
println!("{:?}", v);
} This produces:
It would look much better if it were to be something like:
When you move to multi-dimensional arrays additional issues arise (e.g. alignment of array elements), but I'd say that a good starting point could be to reduce the number of printed elements adding ellipsis ( I am happy to provide you with additional info if you need! |
@LukeMathWalker Thanks a lot, everything is pretty clear! I'll submit a PR soon. |
Hi @LukeMathWalker. I am trying to contribute to ndarray. To get started I had a look at |
Yes @dineshadepu, |
@LukeMathWalker I've submitted a PR #606 |
Fixed by #606. |
inspiration:
The text was updated successfully, but these errors were encountered: