https://github.com/dwoiwode/ncalib
https://github.com/dwoiwode/ncalib
Last synced: about 2 months ago
JSON representation
- Host: GitHub
- URL: https://github.com/dwoiwode/ncalib
- Owner: dwoiwode
- Created: 2025-03-11T18:18:26.000Z (9 months ago)
- Default Branch: main
- Last Pushed: 2025-08-18T21:21:18.000Z (3 months ago)
- Last Synced: 2025-09-24T01:13:32.983Z (2 months ago)
- Language: Python
- Size: 2.63 MB
- Stars: 0
- Watchers: 2
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
- awesome-neural-cellular-automata - ncalib - Modular Neural Cellular Automata library in PyTorch (Implementations / Growing Neural Cellular Automata)
README
# ncalib
A modular Python Library for handling Neural Cellular Automata.
## Features
- Modular architecture for Neural Cellular Automata
- Easy-to-use API for building and training NCA models
- Extensible framework for custom implementations
## Quickstart
### Installation
Install ncalib from PyPI using pip:
```bash
pip install ncalib
```
Some examples and loggers are using [Weights and Biases](https://wandb.ai/). To use them install the required dependencies using:
```bash
pip install ncalib[wandb]
```
### Examples
Examples are found in ``examples``. Currently there are following implementations:
- [simple_nca.py](/examples/simple_nca.py) - Original NCA reconstructing an image ([Mordvintsev et al. (2020)](https://distill.pub/2020/growing-ca/))
- [simple_classifying_mnist.py](/examples/self_classifying_mnist.py) - Self-classicying MNIST Digits ([Randazzo et al. (2020)](https://distill.pub/2020/selforg/mnist/) )
- [image_segmentation.py](/examples/image_segmentation.py)/[image_segmentation_hydra.py](/examples/image_segmentation_hydra.py) - NCA that can segment an image (with and without hydra) ([Sandler et al. (2020)](https://arxiv.org/abs/2008.04965))
- [genome_nca.py](/examples/genome_nca.py) - NCA that can be seeded with different genomes ([Stovold (2023)](https://arxiv.org/abs/2305.12971))
## Development
This project uses [uv](https://docs.astral.sh/uv/) for package management and distribution.
### Setup Development Environment
```bash
# Clone the repository
git clone https://github.com/dwoiwode/ncalib.git
cd ncalib
# Install dependencies with uv
uv sync
# Install extra dependencies
uv sync --all-extras
```
### Running Tests
Tests are run using pytest:
```bash
uv run pytest tests
```
## Contributing
Contributions are welcome! Please feel free to submit a Pull Request.
## Links
- [PyPI Package](https://pypi.org/project/ncalib/)
- [GitHub](https://github.com/dwoiwode/ncalib)
- [Issues](https://github.com/dwoiwode/ncalib/issues)