No project description provided
Project description
Pymetaheuristics
Combinatorial Optimization problems with quickly good soving.
Introduction
Pymetaheuristics is a package to help build and train Metaheuristics to solve real world problems mathematically modeled. It strives to generalize the overall idea of the technic and delivers to the user a friendly wrapper so the cientist may focus on the problem modeling rather than the heuristic implementation. This package is an open source project so feel free to send your implementations and fixes so they may be helpful for others too.
Requires
Only need Python>=3.7. For now, no additional packages will be used.
Subpackages
The idea is to implement all possible Metaheuristics found on the market today and some helper functions to improve what is already there. Note: This package is under construction, new features will come up soon.
What Metaheuristics can be found on this project?
- Genetic Algorithm
How to use
First install the package (available on pypi)
$ pip install pymetaheuristics
Import the algorithm model you want to use to solve you problem. Implement the needed functions and pass to the model. Train and get the results.
from pymetaheuristics.genetic_algorithm.model import GeneticAlgorithm
model = GeneticAlgorithm(
fitness_function=fitness_function,
genome_generator=genome_generator
)
result = model.train(
epochs=15, pop_size=10, crossover=pmx_single_point, verbose=True)
Every module has its integration test, which I submit the model for testing with very know NP-Hard problems today (Knapsack, tsp, ...). If you want to see how it goes, check out the integrations under the model testing folder.
How to contribute
Your code and help is very appreciate! Please, send your issue and pr's whenever is good for you! If needed, send an email to me I'll be very glad to help. Let's build up together.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file pymetaheuristics-0.1.1.tar.gz
.
File metadata
- Download URL: pymetaheuristics-0.1.1.tar.gz
- Upload date:
- Size: 8.2 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.8.5 Linux/5.4.0-1047-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | b30aedb2367ac4123f2e6db97036b26c7d82abd7c4375c53ea5732fd0a7374a8 |
|
MD5 | 04853e2595f5bb53632752b6a0248d90 |
|
BLAKE2b-256 | ad88d2c7b053e7dd515229628603e376fde4a98495aaf004f1b32fddd8509233 |
File details
Details for the file pymetaheuristics-0.1.1-py3-none-any.whl
.
File metadata
- Download URL: pymetaheuristics-0.1.1-py3-none-any.whl
- Upload date:
- Size: 10.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.1.6 CPython/3.8.5 Linux/5.4.0-1047-azure
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 38424dd2ba5bea7dd69ca6eff1a3417dd57248f7c2243e5ff4237193d0ab381b |
|
MD5 | f78f733e489e276e2a246cd823962b9c |
|
BLAKE2b-256 | 668429a4e0c81109d820489e29c8ae1ceb0070a8584f9db09c0b0cb720bd682a |