Skip to main content

Library with a collection of useful classes and methods to DRY

Project description

Mango Genetic

A Python library for implementing genetic algorithms and evolutionary computation methods.

Overview

Mango Genetic provides a comprehensive framework for building and running genetic algorithms. It includes implementations of various genetic operators such as selection, crossover, mutation, and replacement strategies.

Features

  • Individual Management: Base classes for representing individuals with different encoding types (real, binary, integer, categorical)
  • Population Control: Population management with configurable size and generation limits
  • Selection Methods: Multiple selection strategies including roulette wheel, tournament, rank-based, and elitism
  • Crossover Operators: Various crossover methods like blend, one-split, two-split, linear, flat, gaussian, and mask
  • Mutation Control: Configurable mutation rates with static, adaptive, gene-based, and population-based approaches
  • Replacement Strategies: Different replacement methods including elitist, stochastic elitist, random, and offspring-only
  • Configuration System: Flexible configuration management for all genetic algorithm parameters

Installation

pip install mango-genetic

Dependencies

  • Python >= 3.10
  • numpy >= 1.24.4
  • mango[data] == 0.3.0a8

Quick Start

from mango_genetic.config import GeneticBaseConfig
from mango_genetic.individual import Individual
from mango_genetic.population import Population

# Load configuration
config = GeneticBaseConfig("config.cfg")

# Create population and run genetic algorithm
population = Population(config, fitness_function)
population.run()

Documentation

For detailed documentation, visit the Mango Documentation.

License

This project is licensed under the Apache Software License.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

mango_genetic-0.1.0a2.tar.gz (72.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

mango_genetic-0.1.0a2-py3-none-any.whl (24.8 kB view details)

Uploaded Python 3

File details

Details for the file mango_genetic-0.1.0a2.tar.gz.

File metadata

  • Download URL: mango_genetic-0.1.0a2.tar.gz
  • Upload date:
  • Size: 72.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: uv/0.8.15

File hashes

Hashes for mango_genetic-0.1.0a2.tar.gz
Algorithm Hash digest
SHA256 72ea4466c77c911e65d2e1836d4f5474bd9ea264d5dbf8adcf5f15b681ca5056
MD5 b960dba35cca46a8d8d29196dfd4d009
BLAKE2b-256 78ab579b3aaec8cacc4fe04b13d7b88b3950afe89da9e219832eea3ff1a79572

See more details on using hashes here.

File details

Details for the file mango_genetic-0.1.0a2-py3-none-any.whl.

File metadata

File hashes

Hashes for mango_genetic-0.1.0a2-py3-none-any.whl
Algorithm Hash digest
SHA256 70460fb4baa72f6f7b055cc9c7307bd9c3e6042a826d499a19b9513ff74f0fb0
MD5 d14f7238914f96009baeaf44cea892b3
BLAKE2b-256 2c8116f1e4424c00eb1b45b3f30b9dbffef07f99acfe50cec5c51ccc6dea2011

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page