Genetic Optimizer
Genetic algorithm optimizer using K-Means clustering with one way ANOVA algorithms
Before:
After:
Installation:
Use the package manager pip to install genetic_optimizer.
pip3 install genetic-optimizer
Note:
Package require =>Python 3.6.5, using genetic_optimizer in Python 2.x.x projects may not work correctly. If you are not sure about your python version, try:
python3 --version
Usage
import genetic_optimizer
some_object = genetic_optimizer.Optimizer()
some_object.generate(population_size=46, chromosome_size=8, equal_chromosomes=True, initialization_method='Random', representation='Binary', saving_method='csv')
These are default options for generator, you can change them in DEFAULTS.ini file in package directory
some_object.optimize(data=None, iterations=12, shuffle_scale=0.6, variety=0.8, chromosome_weight=0.0000001)
These are default options for optimizer, you can change them in STANDARDS.conf file in package directory
Note
-
If optimizer got stuck at the beginning, that usually means that your dataframe with population is to small to find appropiate parents in order to create next generations.
-
For more description, please check out project wiki.
Pros
-
There is no mutation and crossover probability. Program matches parents according to group differences and create new child, built from the most successful pairs of genes from them. That means new generations are closer to each one and every child is not worse that genetic worse parent.
-
You can play off with options to achive more precised results.
Cons
- Fitness and parent selection process takes place recursively. If you are not using some RDD computing, program execution may be longer.
Contributing
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change.
License
Tools
- micro editor
- Unix console
Code is mostly written in accordance with Google PEP style guide
Metadata
Release files for genetic-optimizer 0.1.8
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| genetic_optimizer-0.1.8.tar.gz | 13.2 kB | Without provenance | Details for genetic_optimizer-0.1.8.tar.gz |
Built distributions (wheels)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| genetic_optimizer-0.1.8-py3-none-any.whl | Python 3 | none | any | Details for genetic_optimizer-0.1.8-py3-none-any.whl |
| genetic_optimizer-0.1.8-py2-none-any.whl | Python 2 | none | any | Details for genetic_optimizer-0.1.8-py2-none-any.whl |
Total release size: 50.6 kB
Release files / genetic_optimizer-0.1.8.tar.gz
| Download URL | genetic_optimizer-0.1.8.tar.gz |
|---|---|
| Size | 13.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
fbeebfdce3b41571882845c6f14de5e1d42956142367bf5ff95595eedcda1b7d
|
|
BLAKE2b-256 checksum How to use checksums |
5fed4543d7fb37982559b346cc38b9cc3376c1b79a712a2232c4d7fc41e50041
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.7
|
Release files / genetic_optimizer-0.1.8-py3-none-any.whl
| Download URL | genetic_optimizer-0.1.8-py3-none-any.whl |
|---|---|
| Size | 18.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
1eda204aa75460c987a11607781d970d674e0e7f5d15c6d5484eff0ac70fc079
|
|
BLAKE2b-256 checksum How to use checksums |
7835000f6f8d5125fd08761b4b24f13d62fa08e1f9f5d5edff4e4d89173519da
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.7
|
Release files / genetic_optimizer-0.1.8-py2-none-any.whl
| Download URL | genetic_optimizer-0.1.8-py2-none-any.whl |
|---|---|
| Size | 18.7 kB |
| Tags | Python 2 |
|
SHA-256 checksum How to use checksums |
e2eefd2efecf7febb57d7cbfe39662f9c92a5b984edeb6a09cad969d22bcf784
|
|
BLAKE2b-256 checksum How to use checksums |
f7ef79535d1d08aa9228a35cb590ee3bf5c9c83592689116eb1634f366aeff82
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/1.13.0 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.6.7
|
Security for genetic-optimizer 0.1.8
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.