evolib 0.2.0b4.dev9__tar.gz → 0.3.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- {evolib-0.2.0b4.dev9/evolib.egg-info → evolib-0.3.0}/PKG-INFO +58 -39
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/README.md +40 -30
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/config_guide.md +22 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/config_parameter.md +34 -14
- evolib-0.3.0/docs/evoenv.md +2 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/getting_started.md +1 -1
- evolib-0.3.0/docs/index.md +97 -0
- evolib-0.3.0/evoenv/cli.py +75 -0
- evolib-0.3.0/evoenv/core/checkpoint.py +44 -0
- evolib-0.3.0/evoenv/core/config.py +33 -0
- evolib-0.3.0/evoenv/core/controller.py +27 -0
- evolib-0.3.0/evoenv/core/difficulty.py +44 -0
- evolib-0.3.0/evoenv/core/env.py +204 -0
- evolib-0.3.0/evoenv/core/evaluator.py +33 -0
- evolib-0.3.0/evoenv/core/sensors.py +181 -0
- evolib-0.3.0/evoenv/core/task.py +89 -0
- evolib-0.3.0/evoenv/core/task_registry.py +43 -0
- evolib-0.3.0/evoenv/core/utils.py +11 -0
- evolib-0.3.0/evoenv/envs/__init__.py +14 -0
- evolib-0.3.0/evoenv/envs/collector.py +471 -0
- evolib-0.3.0/evoenv/envs/collector_config.py +131 -0
- evolib-0.3.0/evoenv/envs/collector_defaults.py +5 -0
- evolib-0.3.0/evoenv/envs/collector_objects.py +77 -0
- evolib-0.3.0/evoenv/envs/collector_task.py +163 -0
- evolib-0.3.0/evoenv/envs/gap_navigator.py +344 -0
- evolib-0.3.0/evoenv/envs/gap_navigator_config.py +94 -0
- evolib-0.3.0/evoenv/envs/gap_navigator_defaults.py +5 -0
- evolib-0.3.0/evoenv/envs/gap_navigator_objects.py +162 -0
- evolib-0.3.0/evoenv/envs/gap_navigator_task.py +217 -0
- evolib-0.3.0/evoenv/envs/jumper.py +326 -0
- evolib-0.3.0/evoenv/envs/jumper_config.py +69 -0
- evolib-0.3.0/evoenv/envs/jumper_defaults.py +10 -0
- evolib-0.3.0/evoenv/envs/jumper_objects.py +127 -0
- evolib-0.3.0/evoenv/envs/jumper_task.py +157 -0
- evolib-0.3.0/evoenv/envs/line_follower.py +208 -0
- evolib-0.3.0/evoenv/envs/line_follower_config.py +37 -0
- evolib-0.3.0/evoenv/envs/line_follower_defaults.py +7 -0
- evolib-0.3.0/evoenv/envs/line_follower_objects.py +148 -0
- evolib-0.3.0/evoenv/envs/line_follower_task.py +142 -0
- evolib-0.3.0/evoenv/renderers/pygame_collector.py +108 -0
- evolib-0.3.0/evoenv/renderers/pygame_common.py +227 -0
- evolib-0.3.0/evoenv/renderers/pygame_gap_navigator.py +82 -0
- evolib-0.3.0/evoenv/renderers/pygame_jumper.py +86 -0
- evolib-0.3.0/evoenv/renderers/pygame_line_follower.py +136 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/base_component_config.py +46 -21
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/evonet_component_config.py +68 -65
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/vector_component_config.py +1 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/core/individual.py +11 -17
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/core/population.py +3 -14
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/envs/gym_wrapper.py +41 -21
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/initializers/evonet_initializers.py +2 -6
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/initializers/vector_initializers.py +5 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/io/checkpoint.py +0 -4
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/io/serialization.py +1 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/crossover.py +0 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/evonet_structural_mutation.py +1 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/heli.py +0 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/mutation.py +0 -12
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/replacement.py +0 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/reproduction.py +0 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/selection.py +12 -10
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/strategy.py +0 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/base.py +4 -8
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/evo_params.py +2 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/evonet.py +8 -7
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/netvector.py +4 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/vector.py +4 -6
- evolib-0.3.0/evolib/utils/README.md +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/benchmarks.py +3 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/heli_experiment_logger.py +2 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/heli_utils.py +0 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/loss_functions.py +0 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/parallel.py +4 -5
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/plotting.py +3 -8
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/registry.py +1 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0/evolib.egg-info}/PKG-INFO +58 -39
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib.egg-info/SOURCES.txt +57 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib.egg-info/requires.txt +17 -7
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib.egg-info/top_level.txt +1 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/03_delay_bitseq_echo.py +1 -1
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/05_image_approximation.py +1 -2
- evolib-0.3.0/examples/09_evoenv/01_line_follower/line_follower_play.py +106 -0
- evolib-0.3.0/examples/09_evoenv/01_line_follower/line_follower_rule.py +83 -0
- evolib-0.3.0/examples/09_evoenv/01_line_follower/line_follower_train.py +70 -0
- evolib-0.3.0/examples/09_evoenv/01_line_follower/line_follower_watch.py +21 -0
- evolib-0.3.0/examples/09_evoenv/02_jumper/jumper_play.py +83 -0
- evolib-0.3.0/examples/09_evoenv/02_jumper/jumper_rule.py +75 -0
- evolib-0.3.0/examples/09_evoenv/02_jumper/jumper_train.py +73 -0
- evolib-0.3.0/examples/09_evoenv/02_jumper/jumper_watch.py +21 -0
- evolib-0.3.0/examples/09_evoenv/03_gap_navigator/gap_navigator_play.py +93 -0
- evolib-0.3.0/examples/09_evoenv/03_gap_navigator/gap_navigator_rule.py +85 -0
- evolib-0.3.0/examples/09_evoenv/03_gap_navigator/gap_navigator_train.py +91 -0
- evolib-0.3.0/examples/09_evoenv/03_gap_navigator/gap_navigator_watch.py +21 -0
- evolib-0.3.0/examples/09_evoenv/04_collector/collector_play.py +92 -0
- evolib-0.3.0/examples/09_evoenv/04_collector/collector_rule.py +84 -0
- evolib-0.3.0/examples/09_evoenv/04_collector/collector_train.py +75 -0
- evolib-0.3.0/examples/09_evoenv/04_collector/collector_watch.py +27 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/pyproject.toml +21 -11
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_evonet_deepcopy.py +2 -2
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_evonet_neuron_dynamics.py +9 -3
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_initializer_evonet.py +4 -0
- evolib-0.2.0b4.dev9/docs/index.md +0 -310
- evolib-0.2.0b4.dev9/evolib/interfaces/enum_helpers.py +0 -31
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/LICENSE +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/MANIFEST.in +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_core_individual.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_core_population.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_crossover.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_evonet_structural_mutation.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_mutation.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_replacement.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_reproduction.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_selection.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_operators_strategy.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_public_api.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_representation_evonet.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_representation_netvector.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_representation_vector.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_utils_benchmarks.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_utils_history_logger.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_utils_loss_functions.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/api_utils_plotting.rst +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/docs/conf.py +0 -0
- /evolib-0.2.0b4.dev9/evolib/core/README.md → /evolib-0.3.0/evoenv/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/api.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/component_registry.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/config/schema.py +0 -0
- {evolib-0.2.0b4.dev9/evolib/globals → evolib-0.3.0/evolib/core}/README.md +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/core/__init__.py +0 -0
- {evolib-0.2.0b4.dev9/evolib/operators → evolib-0.3.0/evolib/globals}/README.md +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/globals/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/globals/numeric.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/initializers/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/initializers/net_initializers.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/initializers/registry.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/interfaces/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/interfaces/enums.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/interfaces/structs.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/interfaces/types.py +0 -0
- {evolib-0.2.0b4.dev9/evolib/utils → evolib-0.3.0/evolib/operators}/README.md +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/operators/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/registry/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/registry/replacement_registry.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/registry/selection_registry.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/registry/strategy_registry.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/_apply_config_mapping.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/composite.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/representation/dummy.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/__init__.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/config_loader.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/fitness.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/history_logger.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/lineage_logger.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib/utils/random.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/evolib.egg-info/dependency_links.txt +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/01_basic_usage/01_getting_started.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/01_basic_usage/02_mutation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/01_basic_usage/03_population_mutation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/01_basic_usage/04_fitness.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/02_strategies/01_step_by_step_evolution.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/02_strategies/02_mu_lambda_step.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/02_strategies/03_mu_lambda.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/02_strategies/04_flexible.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/01_history.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/02_plotting.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/03_compare_runs.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/04_exponential_decay_vs_static.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/05_adaptive_global_vs_static.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/06_adaptive_individual_vs_static.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/07_selection_comparison.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/08_selection_pressure.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/09_selection_vs_mutation_pressure.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/10_selection_stochastic_vs_deterministic.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/03_comparisons/11_crossover_comparison.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/04_function_approximation/01_polynomial_sine.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/04_function_approximation/02_sine_point_approximation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/04_function_approximation/03_approximation_with_noise.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/01_fitness_landscape_exploration.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/02_rosenbrock_surface_path.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/03_vector_control.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/04_vector_control_with_obstacles.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/05_piecewise_linear_xsys.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/05_advanced_topics/06_evolving_mutation_strength_as_a_module.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/06_netvector/01_netvector_sine_approximation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/06_netvector/02_netvector_modulated_output.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/06_netvector/03_netvector_gain_and_bias.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/01_sine_approximation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/02_sine_delay.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/04_leaky_temporal_smoothing.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/06_structural_xor.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/07_recurrent_bit_prediction.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/08_recurrent_timeseries.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/07_evonet/09_recurrent_trading.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/08_gym/01_frozen_lake.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/08_gym/02_cliff_walking.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/08_gym/03_cartpole.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/08_gym/04_lunar_lander.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/examples/08_gym/05_bipedal_walker.py +0 -0
- {evolib-0.2.0b4.dev9/examples/09_meta_learning → evolib-0.3.0/examples/99_meta_learning}/01_lamarck_linear_mapping.py +0 -0
- {evolib-0.2.0b4.dev9/examples/09_meta_learning → evolib-0.3.0/examples/99_meta_learning}/02_meta_mapping_baldwin.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/setup.cfg +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_benchmarks.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_config_loader.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_elitism_preserves_best_fitness.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_evonet_vector_io.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_initializer_net.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_mutation.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_population.py +0 -0
- {evolib-0.2.0b4.dev9 → evolib-0.3.0}/tests/test_selection.py +0 -0
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.4
|
|
2
2
|
Name: evolib
|
|
3
|
-
Version: 0.
|
|
3
|
+
Version: 0.3.0
|
|
4
4
|
Summary: A modular framework for evolutionary strategies and neuroevolution.
|
|
5
5
|
Author-email: EvoLib <evolib@dismail.de>
|
|
6
6
|
License: MIT License
|
|
@@ -25,7 +25,7 @@ License: MIT License
|
|
|
25
25
|
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
|
26
26
|
SOFTWARE.
|
|
27
27
|
|
|
28
|
-
Classifier: Development Status ::
|
|
28
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
29
29
|
Classifier: License :: OSI Approved :: MIT License
|
|
30
30
|
Classifier: Programming Language :: Python :: 3
|
|
31
31
|
Classifier: Programming Language :: Python :: 3.12
|
|
@@ -41,20 +41,29 @@ Requires-Dist: pydantic<3.0,>=2.7
|
|
|
41
41
|
Requires-Dist: graphviz>=0.20.1
|
|
42
42
|
Requires-Dist: evonet<0.2,>=0.1.0.dev5
|
|
43
43
|
Requires-Dist: matplotlib>=3.10
|
|
44
|
+
Requires-Dist: gymnasium[box2d]
|
|
45
|
+
Requires-Dist: imageio
|
|
46
|
+
Requires-Dist: pygame>=2.5
|
|
47
|
+
Requires-Dist: pillow>=10.0
|
|
44
48
|
Provides-Extra: dev
|
|
45
|
-
Requires-Dist:
|
|
49
|
+
Requires-Dist: black==25.1.0; extra == "dev"
|
|
50
|
+
Requires-Dist: isort==6.0.1; extra == "dev"
|
|
51
|
+
Requires-Dist: flake8==7.3.0; extra == "dev"
|
|
52
|
+
Requires-Dist: mypy==1.16.1; extra == "dev"
|
|
53
|
+
Requires-Dist: pytest==8.4.1; extra == "dev"
|
|
54
|
+
Requires-Dist: pytest-cov==5.0.0; extra == "dev"
|
|
55
|
+
Requires-Dist: docformatter==1.7.5; extra == "dev"
|
|
46
56
|
Requires-Dist: types-PyYAML; extra == "dev"
|
|
47
|
-
Requires-Dist:
|
|
48
|
-
Requires-Dist: gymnasium; extra == "dev"
|
|
49
|
-
Requires-Dist: imageio; extra == "dev"
|
|
50
|
-
Requires-Dist: Box2D; extra == "dev"
|
|
57
|
+
Requires-Dist: matplotlib; extra == "dev"
|
|
51
58
|
Provides-Extra: docs
|
|
52
59
|
Requires-Dist: sphinx; extra == "docs"
|
|
53
60
|
Requires-Dist: sphinx-rtd-theme; extra == "docs"
|
|
54
61
|
Requires-Dist: myst-parser; extra == "docs"
|
|
55
62
|
Provides-Extra: test
|
|
56
|
-
Requires-Dist: pytest
|
|
57
|
-
Requires-Dist: pytest-cov
|
|
63
|
+
Requires-Dist: pytest==8.4.1; extra == "test"
|
|
64
|
+
Requires-Dist: pytest-cov==5.0.0; extra == "test"
|
|
65
|
+
Provides-Extra: parallel
|
|
66
|
+
Requires-Dist: ray; extra == "parallel"
|
|
58
67
|
Dynamic: license-file
|
|
59
68
|
|
|
60
69
|
# EvoLib – A Modular Framework for Evolutionary Computation
|
|
@@ -63,7 +72,7 @@ Dynamic: license-file
|
|
|
63
72
|
[](https://github.com/EvoLib/evo-lib/actions/workflows/ci.yml)
|
|
64
73
|
[](LICENSE)
|
|
65
74
|
[](https://pypi.org/project/evolib/)
|
|
66
|
-
[](https://github.com/EvoLib/evo-lib)
|
|
67
76
|
|
|
68
77
|
<p align="center">
|
|
69
78
|
<img src="https://raw.githubusercontent.com/EvoLib/evolib/main/assets/evolib_256.png" alt="EvoLib Logo" width="256"/>
|
|
@@ -80,15 +89,14 @@ EvoLib is a lightweight and transparent framework for evolutionary computation,
|
|
|
80
89
|
- **Educational value**: examples and a clean API make it practical for illustrating evolutionary concepts.
|
|
81
90
|
- **Neuroevolution support**: evolvable neural networks with explicit topology, recurrence, delays, and structural mutation (EvoNet).
|
|
82
91
|
- **Gymnasium integration**: run [Gymnasium](https://gymnasium.farama.org) benchmarks (e.g. CartPole, LunarLander) via a simple wrapper.
|
|
92
|
+
- **EvoEnv**: build small, controllable Pygame environments for evolutionary experiments.
|
|
83
93
|
- **Parallel evaluation (optional)**: basic support for [Ray](https://www.ray.io/) to speed up fitness evaluations.
|
|
84
94
|
- **HELI (Hierarchical Evolution with Lineage Incubation)**
|
|
85
95
|
Runs short micro-evolutions ("incubations") for structure-mutated individuals, allowing new topologies to stabilize before rejoining the main population.
|
|
86
96
|
- **Type-checked**: static typing with mypy, PEP8-compliant and consistent code style.
|
|
87
97
|
|
|
88
|
-
|
|
89
|
-
> **EvoLib is currently in beta. The core API and configuration format are stable, but some features are still under development.**
|
|
90
|
-
|
|
91
98
|
---
|
|
99
|
+
|
|
92
100
|
<p align="center">
|
|
93
101
|
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/examples/05_advanced_topics/04_frames_vector_obstacles/04_vector_control_obstacles.gif" alt="Sample Plot" width="512"/>
|
|
94
102
|
</p>
|
|
@@ -97,11 +105,18 @@ EvoLib is a lightweight and transparent framework for evolutionary computation,
|
|
|
97
105
|
|
|
98
106
|
## Installation
|
|
99
107
|
|
|
108
|
+
EvoLib requires Python 3.12 or newer.
|
|
109
|
+
|
|
100
110
|
```bash
|
|
101
111
|
pip install evolib
|
|
102
112
|
```
|
|
103
113
|
|
|
104
|
-
|
|
114
|
+
Install optional Ray-based parallel evaluation with:
|
|
115
|
+
|
|
116
|
+
```bash
|
|
117
|
+
pip install "evolib[parallel]"
|
|
118
|
+
```
|
|
119
|
+
|
|
105
120
|
|
|
106
121
|
---
|
|
107
122
|
|
|
@@ -153,17 +168,33 @@ modules:
|
|
|
153
168
|
controller:
|
|
154
169
|
type: vector
|
|
155
170
|
dim: 8
|
|
156
|
-
initializer:
|
|
171
|
+
initializer: normal
|
|
157
172
|
bounds: [-1.0, 1.0]
|
|
158
173
|
mutation:
|
|
159
174
|
strategy: adaptive_individual
|
|
160
175
|
probability: 1.0
|
|
161
|
-
|
|
176
|
+
min_strength: 0.01
|
|
177
|
+
max_strength: 0.1
|
|
162
178
|
|
|
163
179
|
brain:
|
|
164
180
|
type: evonet
|
|
165
181
|
dim: [4, 6, 2]
|
|
166
182
|
activation: [linear, tanh, tanh]
|
|
183
|
+
|
|
184
|
+
connectivity:
|
|
185
|
+
recurrent: none
|
|
186
|
+
scope: adjacent
|
|
187
|
+
density: 1.0
|
|
188
|
+
|
|
189
|
+
weights:
|
|
190
|
+
initializer: uniform
|
|
191
|
+
bounds: [-1.0, 1.0]
|
|
192
|
+
|
|
193
|
+
bias:
|
|
194
|
+
initializer: normal
|
|
195
|
+
std: 0.1
|
|
196
|
+
bounds: [-0.5, 0.5]
|
|
197
|
+
|
|
167
198
|
mutation:
|
|
168
199
|
strategy: constant
|
|
169
200
|
probability: 1.0
|
|
@@ -197,7 +228,7 @@ Documentation for EvoLib is available at: 👉 https://evolib.readthedocs.io/en/
|
|
|
197
228
|
|
|
198
229
|
EvoLib is archived for long-term reproducibility on Zenodo.
|
|
199
230
|
|
|
200
|
-
**DOI:** https://doi.org/10.5281/zenodo.
|
|
231
|
+
**DOI:** https://doi.org/10.5281/zenodo.18775372
|
|
201
232
|
|
|
202
233
|
---
|
|
203
234
|
|
|
@@ -238,27 +269,17 @@ gif = env.visualize(indiv, gen=10) # render & save as GIF
|
|
|
238
269
|
|
|
239
270
|
---
|
|
240
271
|
|
|
241
|
-
##
|
|
272
|
+
## EvoEnv
|
|
242
273
|
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
In this video, agents use simple sensors to learn how to collect food while avoiding collisions with the environment.
|
|
274
|
+
EvoEnv provides small, controllable Pygame environments for
|
|
275
|
+
evolutionary experiments with EvoLib. Environments separate headless simulation,
|
|
276
|
+
controller integration, and visualization.
|
|
247
277
|
|
|
248
278
|
<p align="center">
|
|
249
|
-
|
|
279
|
+
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/examples/09_evoenv/04_collector/collector.gif" alt="EvoEnv Collector example" width="512"/>
|
|
250
280
|
</p>
|
|
251
281
|
|
|
252
|
-
|
|
253
|
-
Another prototype uses a **Flappy Bird–like 2D world**, where agents must pass through moving gaps.
|
|
254
|
-
Both the **neural controller** and the **sensors** (number, length, angle) are evolved, allowing perception and action to adapt together.
|
|
255
|
-
This illustrates how EvoLib can be applied to simple game-like environments, making the joint evolution of sensing and control directly observable.
|
|
256
|
-
|
|
257
|
-
<p align="center">
|
|
258
|
-
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/assets/flappy.gif" alt="Pygame Integration Preview" width="160"/>
|
|
259
|
-
</p>
|
|
260
|
-
|
|
261
|
-
*This video shows the best agent from the final generation rather than the full evolutionary process.*
|
|
282
|
+
👉 [Examples](https://github.com/EvoLib/evo-lib/tree/main/examples/09_evoenv/README.md)
|
|
262
283
|
|
|
263
284
|
---
|
|
264
285
|
|
|
@@ -270,7 +291,7 @@ EvoLib includes a small set of examples that illustrate the core concepts step b
|
|
|
270
291
|
2. [Strategies in Action](examples/02_strategies/03_mu_lambda.py) – (μ + λ) evolution step by step.
|
|
271
292
|
3. [Function Approximation](examples/04_function_approximation/02_sine_point_approximation.py) – evolve support points to match a sine curve.
|
|
272
293
|
4. [Evolution as Control](examples/05_advanced_topics/04_vector_control_with_obstacles.py) – evolve a controller in an environment.
|
|
273
|
-
5. [Neuroevolution with Structural Growth](examples/07_evonet/
|
|
294
|
+
5. [Neuroevolution with Structural Growth](examples/07_evonet/06_structural_xor.py) – evolve networks with growing topology.
|
|
274
295
|
|
|
275
296
|
For deeper exploration, see the [full examples directory](examples/)
|
|
276
297
|
|
|
@@ -284,11 +305,9 @@ For deeper exploration, see the [full examples directory](examples/)
|
|
|
284
305
|
- [X] Composite Parameters (multi-module individuals)
|
|
285
306
|
- [X] Neuroevolution
|
|
286
307
|
- [X] Topological Evolution (neurons, edges)
|
|
287
|
-
- [X] Ray Support for Parallel Evaluation
|
|
288
|
-
- [X]
|
|
289
|
-
- [
|
|
290
|
-
- [ ] Game Environment Integration (pygame, PettingZoo - early prototypes)
|
|
291
|
-
|
|
308
|
+
- [X] Ray Support for Parallel Evaluation
|
|
309
|
+
- [X] Gymnasium Integration
|
|
310
|
+
- [X] EvoEnv for small Pygame-based evolutionary environments
|
|
292
311
|
|
|
293
312
|
---
|
|
294
313
|
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
[](https://github.com/EvoLib/evo-lib/actions/workflows/ci.yml)
|
|
5
5
|
[](LICENSE)
|
|
6
6
|
[](https://pypi.org/project/evolib/)
|
|
7
|
-
[](https://github.com/EvoLib/evo-lib)
|
|
8
8
|
|
|
9
9
|
<p align="center">
|
|
10
10
|
<img src="https://raw.githubusercontent.com/EvoLib/evolib/main/assets/evolib_256.png" alt="EvoLib Logo" width="256"/>
|
|
@@ -21,15 +21,14 @@ EvoLib is a lightweight and transparent framework for evolutionary computation,
|
|
|
21
21
|
- **Educational value**: examples and a clean API make it practical for illustrating evolutionary concepts.
|
|
22
22
|
- **Neuroevolution support**: evolvable neural networks with explicit topology, recurrence, delays, and structural mutation (EvoNet).
|
|
23
23
|
- **Gymnasium integration**: run [Gymnasium](https://gymnasium.farama.org) benchmarks (e.g. CartPole, LunarLander) via a simple wrapper.
|
|
24
|
+
- **EvoEnv**: build small, controllable Pygame environments for evolutionary experiments.
|
|
24
25
|
- **Parallel evaluation (optional)**: basic support for [Ray](https://www.ray.io/) to speed up fitness evaluations.
|
|
25
26
|
- **HELI (Hierarchical Evolution with Lineage Incubation)**
|
|
26
27
|
Runs short micro-evolutions ("incubations") for structure-mutated individuals, allowing new topologies to stabilize before rejoining the main population.
|
|
27
28
|
- **Type-checked**: static typing with mypy, PEP8-compliant and consistent code style.
|
|
28
29
|
|
|
29
|
-
|
|
30
|
-
> **EvoLib is currently in beta. The core API and configuration format are stable, but some features are still under development.**
|
|
31
|
-
|
|
32
30
|
---
|
|
31
|
+
|
|
33
32
|
<p align="center">
|
|
34
33
|
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/examples/05_advanced_topics/04_frames_vector_obstacles/04_vector_control_obstacles.gif" alt="Sample Plot" width="512"/>
|
|
35
34
|
</p>
|
|
@@ -38,11 +37,18 @@ EvoLib is a lightweight and transparent framework for evolutionary computation,
|
|
|
38
37
|
|
|
39
38
|
## Installation
|
|
40
39
|
|
|
40
|
+
EvoLib requires Python 3.12 or newer.
|
|
41
|
+
|
|
41
42
|
```bash
|
|
42
43
|
pip install evolib
|
|
43
44
|
```
|
|
44
45
|
|
|
45
|
-
|
|
46
|
+
Install optional Ray-based parallel evaluation with:
|
|
47
|
+
|
|
48
|
+
```bash
|
|
49
|
+
pip install "evolib[parallel]"
|
|
50
|
+
```
|
|
51
|
+
|
|
46
52
|
|
|
47
53
|
---
|
|
48
54
|
|
|
@@ -94,17 +100,33 @@ modules:
|
|
|
94
100
|
controller:
|
|
95
101
|
type: vector
|
|
96
102
|
dim: 8
|
|
97
|
-
initializer:
|
|
103
|
+
initializer: normal
|
|
98
104
|
bounds: [-1.0, 1.0]
|
|
99
105
|
mutation:
|
|
100
106
|
strategy: adaptive_individual
|
|
101
107
|
probability: 1.0
|
|
102
|
-
|
|
108
|
+
min_strength: 0.01
|
|
109
|
+
max_strength: 0.1
|
|
103
110
|
|
|
104
111
|
brain:
|
|
105
112
|
type: evonet
|
|
106
113
|
dim: [4, 6, 2]
|
|
107
114
|
activation: [linear, tanh, tanh]
|
|
115
|
+
|
|
116
|
+
connectivity:
|
|
117
|
+
recurrent: none
|
|
118
|
+
scope: adjacent
|
|
119
|
+
density: 1.0
|
|
120
|
+
|
|
121
|
+
weights:
|
|
122
|
+
initializer: uniform
|
|
123
|
+
bounds: [-1.0, 1.0]
|
|
124
|
+
|
|
125
|
+
bias:
|
|
126
|
+
initializer: normal
|
|
127
|
+
std: 0.1
|
|
128
|
+
bounds: [-0.5, 0.5]
|
|
129
|
+
|
|
108
130
|
mutation:
|
|
109
131
|
strategy: constant
|
|
110
132
|
probability: 1.0
|
|
@@ -138,7 +160,7 @@ Documentation for EvoLib is available at: 👉 https://evolib.readthedocs.io/en/
|
|
|
138
160
|
|
|
139
161
|
EvoLib is archived for long-term reproducibility on Zenodo.
|
|
140
162
|
|
|
141
|
-
**DOI:** https://doi.org/10.5281/zenodo.
|
|
163
|
+
**DOI:** https://doi.org/10.5281/zenodo.18775372
|
|
142
164
|
|
|
143
165
|
---
|
|
144
166
|
|
|
@@ -179,27 +201,17 @@ gif = env.visualize(indiv, gen=10) # render & save as GIF
|
|
|
179
201
|
|
|
180
202
|
---
|
|
181
203
|
|
|
182
|
-
##
|
|
204
|
+
## EvoEnv
|
|
183
205
|
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
In this video, agents use simple sensors to learn how to collect food while avoiding collisions with the environment.
|
|
206
|
+
EvoEnv provides small, controllable Pygame environments for
|
|
207
|
+
evolutionary experiments with EvoLib. Environments separate headless simulation,
|
|
208
|
+
controller integration, and visualization.
|
|
188
209
|
|
|
189
210
|
<p align="center">
|
|
190
|
-
|
|
211
|
+
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/examples/09_evoenv/04_collector/collector.gif" alt="EvoEnv Collector example" width="512"/>
|
|
191
212
|
</p>
|
|
192
213
|
|
|
193
|
-
|
|
194
|
-
Another prototype uses a **Flappy Bird–like 2D world**, where agents must pass through moving gaps.
|
|
195
|
-
Both the **neural controller** and the **sensors** (number, length, angle) are evolved, allowing perception and action to adapt together.
|
|
196
|
-
This illustrates how EvoLib can be applied to simple game-like environments, making the joint evolution of sensing and control directly observable.
|
|
197
|
-
|
|
198
|
-
<p align="center">
|
|
199
|
-
<img src="https://raw.githubusercontent.com/EvoLib/evo-lib/main/assets/flappy.gif" alt="Pygame Integration Preview" width="160"/>
|
|
200
|
-
</p>
|
|
201
|
-
|
|
202
|
-
*This video shows the best agent from the final generation rather than the full evolutionary process.*
|
|
214
|
+
👉 [Examples](https://github.com/EvoLib/evo-lib/tree/main/examples/09_evoenv/README.md)
|
|
203
215
|
|
|
204
216
|
---
|
|
205
217
|
|
|
@@ -211,7 +223,7 @@ EvoLib includes a small set of examples that illustrate the core concepts step b
|
|
|
211
223
|
2. [Strategies in Action](examples/02_strategies/03_mu_lambda.py) – (μ + λ) evolution step by step.
|
|
212
224
|
3. [Function Approximation](examples/04_function_approximation/02_sine_point_approximation.py) – evolve support points to match a sine curve.
|
|
213
225
|
4. [Evolution as Control](examples/05_advanced_topics/04_vector_control_with_obstacles.py) – evolve a controller in an environment.
|
|
214
|
-
5. [Neuroevolution with Structural Growth](examples/07_evonet/
|
|
226
|
+
5. [Neuroevolution with Structural Growth](examples/07_evonet/06_structural_xor.py) – evolve networks with growing topology.
|
|
215
227
|
|
|
216
228
|
For deeper exploration, see the [full examples directory](examples/)
|
|
217
229
|
|
|
@@ -225,11 +237,9 @@ For deeper exploration, see the [full examples directory](examples/)
|
|
|
225
237
|
- [X] Composite Parameters (multi-module individuals)
|
|
226
238
|
- [X] Neuroevolution
|
|
227
239
|
- [X] Topological Evolution (neurons, edges)
|
|
228
|
-
- [X] Ray Support for Parallel Evaluation
|
|
229
|
-
- [X]
|
|
230
|
-
- [
|
|
231
|
-
- [ ] Game Environment Integration (pygame, PettingZoo - early prototypes)
|
|
232
|
-
|
|
240
|
+
- [X] Ray Support for Parallel Evaluation
|
|
241
|
+
- [X] Gymnasium Integration
|
|
242
|
+
- [X] EvoEnv for small Pygame-based evolutionary environments
|
|
233
243
|
|
|
234
244
|
---
|
|
235
245
|
|
|
@@ -100,7 +100,7 @@ modules:
|
|
|
100
100
|
ys:
|
|
101
101
|
type: vector
|
|
102
102
|
dim: 6
|
|
103
|
-
initializer:
|
|
103
|
+
initializer: zero
|
|
104
104
|
bounds: [-1.5, 1.5]
|
|
105
105
|
mutation:
|
|
106
106
|
strategy: constant
|
|
@@ -120,6 +120,11 @@ This configuration demonstrates EvoNet evolution: weight mutation, bias-specific
|
|
|
120
120
|
|
|
121
121
|
`dim: [2, 0, 0, 1]` starts with empty hidden layers, letting structural mutation grow nodes and edges.
|
|
122
122
|
|
|
123
|
+
Connectivity:
|
|
124
|
+
- `scope` controls which feedforward edges are allowed at initialization.
|
|
125
|
+
- `density` controls how many of those allowed edges are actually created at init.
|
|
126
|
+
- `recurrent` enables recurrent edge kinds (empty list means none).
|
|
127
|
+
|
|
123
128
|
Topology constraints:
|
|
124
129
|
- `max_neurons` and `max_connections` keep growth bounded (these are the current names; avoid older `max_nodes/max_edges`).
|
|
125
130
|
|
|
@@ -127,6 +132,8 @@ Delay:
|
|
|
127
132
|
- `delay:` initializes delays of recurrent connections at build time.
|
|
128
133
|
- `mutation.delay:` mutates delays during evolution (recurrent connections only).
|
|
129
134
|
|
|
135
|
+
|
|
136
|
+
|
|
130
137
|
```yaml
|
|
131
138
|
parent_pool_size: 20
|
|
132
139
|
offspring_pool_size: 40
|
|
@@ -145,17 +152,22 @@ modules:
|
|
|
145
152
|
type: evonet
|
|
146
153
|
dim: [2, 0, 0, 1] # hidden layers start empty
|
|
147
154
|
activation: [linear, tanh, tanh, sigmoid]
|
|
155
|
+
|
|
156
|
+
connectivity:
|
|
157
|
+
scope: crosslayer # adjacent | crosslayer
|
|
158
|
+
density: 1.0 # (0, 1]
|
|
159
|
+
recurrent: [direct] # [], [direct], [lateral], [indirect]
|
|
160
|
+
|
|
148
161
|
weights:
|
|
149
162
|
initializer: normal
|
|
150
163
|
std: 0.5
|
|
151
164
|
bounds: [-5.0, 5.0]
|
|
165
|
+
|
|
152
166
|
bias:
|
|
153
167
|
initializer: normal
|
|
154
168
|
std: 0.5
|
|
155
169
|
bounds: [-1.0, 1.0]
|
|
156
170
|
|
|
157
|
-
recurrent: direct # REQUIRED for delay to have any effect
|
|
158
|
-
|
|
159
171
|
# NOTE: Delays only apply to recurrent connections.
|
|
160
172
|
# If `recurrent` is not enabled, this block has no effect.
|
|
161
173
|
delay:
|
|
@@ -220,6 +232,13 @@ modules:
|
|
|
220
232
|
|
|
221
233
|
For expensive problems, EvoLib can evaluate individuals in parallel using Ray.
|
|
222
234
|
|
|
235
|
+
Install the optional parallel evaluation support before selecting the Ray
|
|
236
|
+
backend:
|
|
237
|
+
|
|
238
|
+
```bash
|
|
239
|
+
pip install "evolib[parallel]"
|
|
240
|
+
```
|
|
241
|
+
|
|
223
242
|
```yaml
|
|
224
243
|
parallel:
|
|
225
244
|
backend: ray # backend: none | ray
|
|
@@ -156,7 +156,7 @@ The `vector` module defines an evolvable parameter vector.
|
|
|
156
156
|
| `bounds` | `tuple[float, float]` | `[-1.0, 1.0]` | Hard clamp range applied after mutation. |
|
|
157
157
|
| `init_bounds` | `tuple[float, float] \| null` | `null` | Clamp applied only during initialization. Falls back to `bounds` if not set. |
|
|
158
158
|
| `shape` | `tuple[int, ...] \| null` | `null` | Optional explicit shape. If set, `dim = product(shape)`. Shape is retained as metadata. |
|
|
159
|
-
| `values` | `list[float] \| null` | `null` | Required for `initializer:
|
|
159
|
+
| `values` | `list[float] \| null` | `null` | Required for `initializer: fixed`. If `dim` is omitted, it is inferred from `len(values)`. |
|
|
160
160
|
| `activation` | `str \| null` | `null` | Only relevant if `structure: "net"`. |
|
|
161
161
|
| `mean` | `float \| null` | `0.0` | Mean parameter for normal-based initializers (if used by initializer). |
|
|
162
162
|
| `std` | `float \| null` | `1.0` | Standard deviation for normal-based initializers (if used by initializer). |
|
|
@@ -246,7 +246,7 @@ modules:
|
|
|
246
246
|
modules:
|
|
247
247
|
main:
|
|
248
248
|
type: vector
|
|
249
|
-
initializer:
|
|
249
|
+
initializer: fixed
|
|
250
250
|
values: [0.0, 1.0, 0.5, -0.5]
|
|
251
251
|
bounds: [-1.0, 1.0]
|
|
252
252
|
|
|
@@ -264,7 +264,7 @@ modules:
|
|
|
264
264
|
type: vector
|
|
265
265
|
structure: flat
|
|
266
266
|
dim: 6
|
|
267
|
-
initializer:
|
|
267
|
+
initializer: normal
|
|
268
268
|
mean: 0.0
|
|
269
269
|
std: 0.2
|
|
270
270
|
bounds: [-1.0, 1.0]
|
|
@@ -289,12 +289,30 @@ modules:
|
|
|
289
289
|
| `dim` | list[int] | — | Layer sizes, e.g. `[4, 0, 0, 2]`. Hidden layers can start empty (0) and grow through structural mutation. |
|
|
290
290
|
| `activation` | str \| list[str] | — | If list: activation per layer. If str: used for non-input layers; input layer is treated as linear. |
|
|
291
291
|
| `initializer` | str | default | Topology preset (e.g. `default`, `unconnected`, `identity`). Parameter initialization is configured via `weights`, `bias`, and `delay`. |
|
|
292
|
+
| `connectivity` | `dict` | — | **Required.** Defines feedforward scope/density and allowed recurrent kinds. |
|
|
292
293
|
| `weights` | dict | — | Weight init and bounds configuration (initializer, bounds, optional params). |
|
|
293
294
|
| `bias` | dict | — | Bias init and bounds configuration (initializer, bounds, optional params). |
|
|
294
295
|
| `neuron_dynamics` | list[dict] \| null | null | Optional per-layer neuron dynamics specification. Must match `len(dim)`. |
|
|
295
296
|
| `mutation` | dict \| null | null | Mutation settings for weights, biases, activations, delay, and structure. |
|
|
296
297
|
| `crossover` | dict \| null | null | Optional crossover settings (weight/bias level). |
|
|
297
298
|
|
|
299
|
+
#### Connectivity (`connectivity`)
|
|
300
|
+
|
|
301
|
+
| Field | Type | Default | Notes |
|
|
302
|
+
|------------|------------------------------|---------|------|
|
|
303
|
+
| `scope` | `"adjacent" \| "crosslayer"` | — | **Required.** Allowed feedforward edge scope at initialization. |
|
|
304
|
+
| `density` | `float` | — | **Required.** Fraction of allowed feedforward edges created at init `(0,1]`. |
|
|
305
|
+
| `recurrent`| `list[str]` | `[]` | Allowed recurrent edge kinds. Empty list means none. |
|
|
306
|
+
|
|
307
|
+
Example:
|
|
308
|
+
|
|
309
|
+
```yaml
|
|
310
|
+
connectivity:
|
|
311
|
+
scope: crosslayer
|
|
312
|
+
density: 0.5
|
|
313
|
+
recurrent: [direct]
|
|
314
|
+
```
|
|
315
|
+
|
|
298
316
|
##### weights block
|
|
299
317
|
|Parameter | Type | Default | Explanation |
|
|
300
318
|
|------------|-------|-----------|-------------|
|
|
@@ -325,8 +343,8 @@ Allowed presets:
|
|
|
325
343
|
| Initializer | Meaning (topology only) |
|
|
326
344
|
|------------------------|-------------------------|
|
|
327
345
|
| `default` | Standard EvoNet topology preset (uses `connection_scope`, `connection_density`, and `recurrent`). |
|
|
328
|
-
| `
|
|
329
|
-
| `
|
|
346
|
+
| `unconnected` | Creates neurons/layers but starts with **no connections** (use structural mutation to grow). |
|
|
347
|
+
| `identity` | Special preset intended for stable recurrent memory (may override parameters internally; see notes below). |
|
|
330
348
|
|
|
331
349
|
---
|
|
332
350
|
|
|
@@ -493,13 +511,12 @@ structural:
|
|
|
493
511
|
|
|
494
512
|
### Topology constraints
|
|
495
513
|
|
|
496
|
-
| Field
|
|
497
|
-
|
|
498
|
-
| `recurrent`
|
|
499
|
-
| `connection_scope`
|
|
500
|
-
| `
|
|
501
|
-
| `
|
|
502
|
-
| `max_connections` | int \| null | null | Maximum number of edges (`null` = unlimited). |
|
|
514
|
+
| Field | Type | Default | Description |
|
|
515
|
+
|-------------------|--------------------------------|-------------|-------------|
|
|
516
|
+
| `recurrent` | `list[str]` | `[]` | Allowed recurrent kinds for `add_connection`. Empty list means none. |
|
|
517
|
+
| `connection_scope` | `"adjacent" \| "crosslayer" \| null` | `"adjacent"` | Constraint for structural add-neuron / add-connection edge placement. |
|
|
518
|
+
| `max_neurons` | `int \| null` | `null` | Upper bound on total neurons allowed (implementation-defined counting). |
|
|
519
|
+
| `max_connections` | `int \| null` | `null` | Upper bound on total connections allowed. |
|
|
503
520
|
|
|
504
521
|
---
|
|
505
522
|
|
|
@@ -531,7 +548,7 @@ modules:
|
|
|
531
548
|
controller:
|
|
532
549
|
type: vector
|
|
533
550
|
dim: 8
|
|
534
|
-
initializer:
|
|
551
|
+
initializer: normal
|
|
535
552
|
bounds: [-1.0, 1.0]
|
|
536
553
|
mutation:
|
|
537
554
|
strategy: adaptive_individual
|
|
@@ -544,7 +561,10 @@ modules:
|
|
|
544
561
|
type: evonet
|
|
545
562
|
dim: [4, 0, 0, 2]
|
|
546
563
|
activation: [linear, tanh, tanh, tanh]
|
|
547
|
-
|
|
564
|
+
|
|
565
|
+
connectivity:
|
|
566
|
+
scope: adjacent
|
|
567
|
+
density: 1.0
|
|
548
568
|
|
|
549
569
|
delay:
|
|
550
570
|
initializer: uniform
|
|
@@ -0,0 +1,97 @@
|
|
|
1
|
+
# EvoLib
|
|
2
|
+
|
|
3
|
+
EvoLib is a framework for evolutionary computation, neuroevolution, and small
|
|
4
|
+
controlled experiments.
|
|
5
|
+
|
|
6
|
+
It uses explicit configuration and modular components. Evolutionary strategies,
|
|
7
|
+
parameter representations, operators, and evaluation environments can be
|
|
8
|
+
selected and combined separately.
|
|
9
|
+
|
|
10
|
+
## Project areas
|
|
11
|
+
|
|
12
|
+
* **Evolutionary strategies** — configurable selection, reproduction,
|
|
13
|
+
replacement, crossover, and mutation.
|
|
14
|
+
* **Parameter representations** — vectors, network vectors, and EvoNet neural
|
|
15
|
+
networks.
|
|
16
|
+
* **Neuroevolution** — evolution of weights, biases, activation functions,
|
|
17
|
+
recurrent connections, delays, and network structures.
|
|
18
|
+
* **HELI** — lineage incubation for newly mutated network structures.
|
|
19
|
+
* **Gymnasium integration** — evaluation and visualization using Gymnasium
|
|
20
|
+
environments.
|
|
21
|
+
* **EvoEnv** — small Pygame-based environments for controlled evolutionary
|
|
22
|
+
experiments and teaching examples.
|
|
23
|
+
* **Parallel evaluation** — optional Ray-based fitness evaluation.
|
|
24
|
+
|
|
25
|
+
## Start here
|
|
26
|
+
|
|
27
|
+
New users should begin with the
|
|
28
|
+
[getting started guide](getting_started.md), followed by the
|
|
29
|
+
[configuration guide](config_guide.md).
|
|
30
|
+
|
|
31
|
+
The [configuration parameter reference](config_parameter.md) lists the
|
|
32
|
+
available YAML settings. Documentation for the included Pygame-based
|
|
33
|
+
environments is available under [EvoEnv](evoenv.md).
|
|
34
|
+
|
|
35
|
+
```{toctree}
|
|
36
|
+
:maxdepth: 1
|
|
37
|
+
:hidden:
|
|
38
|
+
:caption: Guides
|
|
39
|
+
|
|
40
|
+
getting_started
|
|
41
|
+
config_guide
|
|
42
|
+
config_parameter
|
|
43
|
+
evoenv
|
|
44
|
+
```
|
|
45
|
+
|
|
46
|
+
```{toctree}
|
|
47
|
+
:maxdepth: 2
|
|
48
|
+
:hidden:
|
|
49
|
+
:caption: API – Core
|
|
50
|
+
|
|
51
|
+
api_core_population
|
|
52
|
+
api_core_individual
|
|
53
|
+
```
|
|
54
|
+
|
|
55
|
+
```{toctree}
|
|
56
|
+
:maxdepth: 1
|
|
57
|
+
:hidden:
|
|
58
|
+
:caption: API – Representations
|
|
59
|
+
|
|
60
|
+
api_representation_vector
|
|
61
|
+
api_representation_netvector
|
|
62
|
+
api_representation_evonet
|
|
63
|
+
```
|
|
64
|
+
|
|
65
|
+
```{toctree}
|
|
66
|
+
:maxdepth: 2
|
|
67
|
+
:hidden:
|
|
68
|
+
:caption: API – Operators
|
|
69
|
+
|
|
70
|
+
api_operators_strategy
|
|
71
|
+
api_operators_selection
|
|
72
|
+
api_operators_replacement
|
|
73
|
+
api_operators_reproduction
|
|
74
|
+
api_operators_mutation
|
|
75
|
+
api_operators_crossover
|
|
76
|
+
api_operators_evonet_structural_mutation
|
|
77
|
+
```
|
|
78
|
+
|
|
79
|
+
```{toctree}
|
|
80
|
+
:maxdepth: 2
|
|
81
|
+
:hidden:
|
|
82
|
+
:caption: API – I/O & Utilities
|
|
83
|
+
|
|
84
|
+
api_utils_loss_functions
|
|
85
|
+
api_utils_benchmarks
|
|
86
|
+
api_utils_plotting
|
|
87
|
+
api_utils_history_logger
|
|
88
|
+
```
|
|
89
|
+
|
|
90
|
+
```{toctree}
|
|
91
|
+
:maxdepth: 2
|
|
92
|
+
:hidden:
|
|
93
|
+
:caption: Public API
|
|
94
|
+
|
|
95
|
+
api_public_api
|
|
96
|
+
```
|
|
97
|
+
|