Skip to content
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

Example repository #674

Open
LukeMathWalker opened this issue Jul 23, 2019 · 6 comments
Open

Example repository #674

LukeMathWalker opened this issue Jul 23, 2019 · 6 comments
Labels

Comments

@LukeMathWalker
Copy link
Member

In rust-ndarray/ndarray-linalg#166 @munckymagik advanced the idea of adding a new repository to rust-ndarray to host more complex standalone examples.

It could be a good place to showcase what is possible using the different pieces of the ecosystem, in a sort of cookbook format.

I love the idea and I think it could provide a lot of value. What are your thoughts?

@max-sixty
Copy link
Contributor

Yes agree! Personally I'd also find a side-by-side example of numpy / scipy v helpful, furthering the existing docs there. Even without that, I think it's a great idea.

@jturner314
Copy link
Member

That sounds like a good idea to me. We do have a few examples in modules linked at the bottom of ndarray_for_numpy_users, but they're pretty minimal and focus more on ndarray than the ecosystem as a whole. We should also review the files in the examples directory to see if we need to update/remove any of them.

@LukeMathWalker
Copy link
Member Author

LukeMathWalker commented Jul 26, 2019 via email

@LukeMathWalker
Copy link
Member Author

LukeMathWalker commented Aug 4, 2019

First sketch is out: https://github.com/rust-ndarray/ndarray-examples

I still need to add a CI pipeline (mirroring @termoshtt's work on ndarray-linalg) - suggestions are welcome 👍

P.S. The linear regression example is currently using a hard-coded openblas feature for ndarray-linalg (even though the README says it's selectable). Still some work to do there to figure out how to actually make it selectable when running the example 👀

@LukeMathWalker
Copy link
Member Author

LukeMathWalker commented Aug 5, 2019

Backend selection is now working as expected. Unfortunately, it seems we can't provide a top-level backend selection mechanism due to rust-lang/cargo#5015 - it has to be done in the Cargo.toml of each example. (Tracking issue for the feature request on cargo: rust-lang/cargo#4753)

@LukeMathWalker
Copy link
Member Author

I have another PR up, with a simple implementation of K-Means clustering: rust-ndarray/ndarray-examples#2

Looking for 👀

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants