CellPyLib is a Python library for working with Cellular Automata, supporting 1D and 2D automata with various rules (e.g., Rule 30, Conway's Game of Life). Current version 2.4.0 requires Python >3.6. The library is actively maintained with a focus on simulation, visualization, and analysis.
pip install cellpylibNo compatibility data collected yet for this library.
Verified import paths — ran on the pinned version, not inferred.
Initialize a 1D cellular automaton with Rule 30 and evolve it for 100 steps.
Change rule function signature from lambda n, c: ... to lambda n, c, g: ...
For 1D: init_simple(100). For 2D: init_simple((50,50)).
Install matplotlib: pip install matplotlib
Upgrade to v2.x and change 'rule' to 'apply_rule': cpl.evolve(ca, timesteps=100, apply_rule=...) or for v1.x use evolve(ca, timesteps=100, rule=...)
Use import cellpylib as cpl and then cpl.init_simple(), cpl.evolve() etc.
Ensure the rule function returns a single integer (0 or 1) per cell.
No dependency data recorded yet.