Перейти к содержанию

Quick start

After installation (pip install "cnn-neat[vision]" plus CUDA PyTorch wheels from pytorch.org).

Python

from cnn_neat import ExperimentConfig, run_single_experiment

cfg = ExperimentConfig(
    positive_class=0,
    population_size=20,
    num_generations=5,
    fitness_val_size=1000,
    seed=42,
)
evolver, history, val_loader, device = run_single_experiment(cfg)

CUDA is required by default. Artifacts land in ./runs/cifar10_binary_notebook/run_XXXX/ (run_archive.json, live_dashboard.html). CIFAR-10 is downloaded once to ./data/cifar10/.

export CNN_NEAT_DATA_ROOT=/data
export CNN_NEAT_RUNS_ROOT=/runs

CLI

python -m cnn_neat write-defaults my_run.json
python -m cnn_neat validate my_run.json
python -m cnn_neat run --config my_run.json

Copy-paste scripts: examples. Production OVA studies (scripts 06–18) ship in the git repository, not in the PyPI wheel.

The 0.1.x API is unstable. Full math and experiment protocols (Russian): the rest of this documentation site.