river
rayon
Our great sponsors
river | rayon | |
---|---|---|
17 | 66 | |
4,715 | 10,082 | |
2.0% | 2.9% | |
9.2 | 9.0 | |
5 days ago | 3 days ago | |
Python | Rust | |
BSD 3-clause "New" or "Revised" License | Apache License 2.0 |
Stars - the number of stars that a project has on GitHub. Growth - month over month growth in stars.
Activity is a relative number indicating how actively a project is being developed. Recent commits have higher weight than older ones.
For example, an activity of 9.0 indicates that a project is amongst the top 10% of the most actively developed projects that we are tracking.
river
-
🔍Underrated Open Source Projects You Should Know About 🧠
River is a Python library for online machine learning. Online machine learning can dynamically adapt to new patterns in the data, or when the data itself is generated as a function of time, e.g., stock price prediction, content personalization.
- Ask HN: What Underrated Open Source Project Deserves More Recognition?
-
Unexpected Expected Thriller: A Tale of Coding Curiosity
Today, I'm going to take you on a thrilling coding adventure inspired by a LinkedIn code snippet, where I tangled with FastAPI, River, Watchdog, and Tenacity. Ready? Buckle up!
-
Elevate Your Python Skills: Machine Learning Packages That Transformed My Journey as ML Engineer
Complimentary: river and skorch
-
What are your favorite tools or components in the Kafka ecosystem?
River - https://github.com/online-ml/river (Online machine learning, best used with Bytewax for Kafka integration)
-
Show HN: Want something better than k-means? Try BanditPAM
Hey, great work. Do you think this algorithm would be amenable to be done online? I'm the author of River (https://riverml.xyz) where we're looking for good online clustering algorithms.
-
Python's “Disappointing” Superpowers
If you don't know Rust, but know Python, you can install Python libraries written in Rust with pip. Like, pip install polars or pip install robyn. In this case you follow the two bottom links. But then you don't write your own libraries and stuff so.. I guess that's not what you want.
But, if you want to learn Rust, you probably wouldn't start out with pyo3. You first install Rust with https://rustup.rs/ and then check out the official book, and the book rust by example, that you can find here https://www.rust-lang.org/learn - and maybe write some code on the Rust playground https://play.rust-lang.org/ - then, you use pyo3 to build Python libraries in Rust, and then use maturin https://www.maturin.rs/ to build and publish them to Pypi.
But if you still prefer to begin with Rust by writing Python libraries (it's a valid strategy if you are very comfortable with working with multiple stacks), the Maturin link has a tutorial that setups a program that is half written in python, half written in Rust, https://www.maturin.rs/tutorial.html (well the pyo3 link I sent also has one too. You should refer to the documentation of both, because you will use the two together)
After learning Rust, the next step is looking for libraries that you could leverage to make Python programs ultra fast. Here https://github.com/rayon-rs/rayon is an obvious choice, see some examples from the Rust cookbook https://rust-lang-nursery.github.io/rust-cookbook/concurrenc... - when you create a parallel iterator, it will distribute the processing to many threads (by default, one per core). The rust cookbook, by the way, is a nice reference to see the most used crates (Rust libraries) in the Rust ecosystem.
Anyway there are some posts about pyo3 on the web, like this blog post https://boring-guy.sh/posts/river-rust/ (note: it uses an outdated version of pyo3, and doesn't seem to use maturin which is a newer tool). This post was written by the developers of https://github.com/online-ml/river - another Python library written in Rust
-
[D] How do you deal with covariate shift and concept drift in production?
Have a look at here: https://github.com/online-ml/river
-
Integration test: Complexity of privacy-preserving bird call bio-sensor for distributed ecological monitoring?
Some of the technologies which could be integrated include differential privacy, distributed online machine learning, misinformation resilience and multi-party computation, all within the context of smart contracts and bioinformatics.
rayon
- Too Dangerous for C++
-
What Are The Rust Crates You Use In Almost Every Project That They Are Practically An Extension of The Standard Library?
rayon: Async CPU runtime for parallelism.
-
Moving from Typescript and Langchain to Rust and Loops
In the quest for more efficient solutions, the ONNX runtime emerged as a beacon of performance. The decision to transition from Typescript to Rust was an unconventional yet pivotal one. Driven by Rust's robust parallel processing capabilities using Rayon and seamless integration with ONNX through the ort crate, Repo-Query unlocked a realm of unparalleled efficiency. The result? A transformation from sluggish processing to, I have to say it, blazing-fast performance.
-
The Rust I Wanted Had No Future
(see https://github.com/rayon-rs/rayon/tree/master/src/iter/plumbing)
-
General Recommendations: Should I Use Tree-sitter as the AST for the LSP I am developing?
Sequentially, generating tree-sitter AST for each file and querying for the links of each file takes around 2.3 seconds. However, I randomly remembered this crate rayon, and I decided to test it. It ended up improving the performance (just by changing 2 lines of code) to 200-300ms by parallelizing the iterators and tree-sitter queries. MAJOR.
-
python to rust migration
Now if you really want to use Rust, you can rewrite only the part that are slowing down your consumer. It's easy by using Py03 and maturin. Maybe also rayon to parallelize.
-
AI learns to play flappy bird (code in comments)
Maybe rayon could make some loops there and there faster if needed.
-
Making Python 100x faster with less than 100 lines of Rust
One of the others understated pros of rewriting some parts in Rust, it's that you can parallelize easily with Rayon[0]
-
Trying to learn by tutorials, for cannot find a single Actix/Diesel tutorial that actually compiles
On that topic, have you heard about our lord and savior rayon? 😊
-
Brett Slatkin: Why am I building a new functional programming language?
> He spoke of the potential for functional languages to provide a significant, intrinsic advantage when it comes to parallel computing.
> (...)
> If that were true, you'd expect that the many existing functional programming languages would have already satisfied this need. But in my opinion, they haven't
Well there is https://futhark-lang.org/ - it runs on the GPU, and is awesome.
On the CPU side, I think that Rust plus https://github.com/rayon-rs/rayon was a huge breakthrough on writing parallel programs using both functional and imperative programming, and future languages should learn from its successes. The ownership system & the borrow checker, plus other type-level features like the Send and Sync traits, were essential to enable sharing read-only data between threads without synchronization, or sharing read-write data with synchronization, all checked at compile time for data races (which is a huge problem to solve, and is something that neither Go nor Java protects against at compile time)
Indeed Futhark shares a key feature with Rust: it uses uniqueness types to enable in-place updates, which is kind like a limited form of Rust ownership: if you are the sole user of some memory, you can update it and other code will be none the wiser. This kind of thing is very important to build functional programs that are performant in practice.
What are some alternatives?
crossbeam - Tools for concurrent programming in Rust
tokio - A runtime for writing reliable asynchronous applications with Rust. Provides I/O, networking, scheduling, timers, ...
RxRust - The Reactive Extensions for the Rust Programming Language
rust-numpy - PyO3-based Rust bindings of the NumPy C-API
tokio-rayon - Mix async code with CPU-heavy thread pools using Tokio + Rayon
sqlx - 🧰 The Rust SQL Toolkit. An async, pure Rust SQL crate featuring compile-time checked queries without a DSL. Supports PostgreSQL, MySQL, and SQLite.
coroutine-rs - Coroutine Library in Rust
libfringe - a Rust library implementing safe, lightweight context switches, without relying on kernel services
alibi-detect - Algorithms for outlier, adversarial and drift detection
rxRust - Rust implementation of Reactive Extensions.
rust-postgres - Native PostgreSQL driver for the Rust programming language
PyO3 - Rust bindings for the Python interpreter