8 releases (4 breaking)
Uses new Rust 2024
0.5.1 | Jun 4, 2025 |
---|---|
0.5.0 | May 12, 2025 |
0.4.0 | Jan 14, 2025 |
0.3.0 | Feb 15, 2023 |
0.1.2 | Feb 3, 2023 |
#996 in Algorithms
31 downloads per month
90KB
1.5K
SLoC
Ratio Genetic algorithms
Genetic algorithm library with a focus on the field of Dependency Structure Matrix (DSM) analysis. Currently in a very early state! Minor versions should be treated as major breaking changes. Therefore, make sure to pin your versions accordingly.
The library is setup according to the Strategy pattern
The basic idea behind the Strategy pattern is that, given an algorithm solving a particular problem, we define only the skeleton of the algorithm at an abstract level, and we separate the specific algorithm's implementation into different parts.
This makes it especially useful to create your very own specific implementation of a genetic algorithm while having some batteries included implementations to get up and running quickly.
Documentation
Please refer to the crate's documentation on docs.rs for more information on it's usage.
Changelog
This repository keeps a CHANGELOG.md according to the recommendations by Keep a Changelog.
Contributions
Contributions are welcome! By submitting a contribution, you agree to license your work under the terms of the Mozilla Public License 2.0. Please ensure that your contributions adhere to the existing code style and include appropriate tests and documentation where applicable.
To get started:
- Fork the repo
- Create a new branch
- Make your changes
- Make sure you run
just fix
to adhere to the project's formatting - Submit a merge request with a clear description of the changes
Licensing
This project is licensed under the Mozilla Public License 2.0. You are free to use, modify, and distribute this code, provided that any files you modify or create that are based on MPL-licensed files also remain under the MPL. You must include a copy of the license with the source and make the source code available when distributing binaries.
See the LICENSE file for the full license text.
Code examples both in the docstrings and rendered documentation thereof are free to use!
At Ratio, we are huge supporters of open-source code and the open-source community. In our Python projects we usually strive to use one of the (L)GPL flavors. These are difficult to pair with compiled codebases, however, which is where we see the MPL-2.0 as a great fit for our open-source Rust efforts. It's a weak copyleft license that just protects the source as it is written and encourages changes to the crate's source to be published accordingly. It's sort of "automagically" implied and done right when cargo
would pull in the source files to build with, as (the mentioning of) the license is included in the header of each file, and any binaries you generate with them are not of our concern from a distribution perspective.
Enjoy the code!
Dependencies
~4MB
~82K SLoC