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.0a3.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.0a3-py3-none-any.whl (24.8 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: mango_genetic-0.1.0a3.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.0a3.tar.gz
Algorithm Hash digest
SHA256 17d075e874ca300f980486c017e0026195f5995b161380bdc60d0375a56c8f6d
MD5 ede7b646367179b550573d794136a022
BLAKE2b-256 b86663a444790fdd553e109cbf84af579c5d4cab6f8661c8a47cbbfb61edae77

See more details on using hashes here.

File details

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

File metadata

File hashes

Hashes for mango_genetic-0.1.0a3-py3-none-any.whl
Algorithm Hash digest
SHA256 3f0d432cfcb58c744568fe395286513b3e3b34526592041c3069445936dec582
MD5 55f3fa239c06379d53de1704868769ee
BLAKE2b-256 756084cb7cd6236172ac3a872b19968a8d8ea09fc0e4dc6d30622325530731a6

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