Expand description
A utility for generating images through evolution.
This crate provides utilities, as well as CLI tool called franklin-cli
for generating evolutionary art.
Generation of evolutionary art can be separated into three steps:
- mutation,
- calculating fitness and selection,
- breeding the specimens.
Usage
This example shows the minimal code for setting up the generation. All settings are set to default. Only one property it required: source image.
use franklin::{EnvironmentBuilder, ImageReader};
fn run_simulation() {
let mut environment_builder = EnvironmentBuilder::default();
let image = ImageReader::load("./example.png").unwrap();
environment_builder.set_image(image);
let environment = environment_builder.build().unwrap();
environment.run().unwrap();
}
Modules
- This module contains utilities used to breed specimens.
- This module contains utilities used to calculate the fitness of specimens.
- This module contains utilities used to mutate specimens.
Structs
- This builder provides an interface to set up the environment for generating images.
- This struct can be used to load an image from the filesystem.
Enums
- This enum specifies different options for choosing color mode.
- This enum specifies different options for choosing which images should be displayed on the screen.
- This enum specifies different options for choosing which images should be saved on the filesystem.