Python Scripting Manual for CompuCell3D - version 4.1.1¶
The focus of this manual is to teach you how to use Python 2 scripting language to develop complex CompuCell3D simulations.
We will assume that you have a working knowledge of Python. You do not have to be a Python guru but you should know how to write simple Python scripts that use functions, classes, dictionaries and lists. You can find decent tutorials online (e.g.
Instant Python Hacking, or Instant Python Hacking) or simply purchase a book on introductory Python programming.
- Funding
- Introduction
- Transitioning from CC3D 3.x to CC3D 4.x
- How to use Python in CompuCell3D
- Running and Debugging CC3D Simulations Using PyCharm
- Step 1 - opening CC3D code in PyCharm and configuring Python environment
- Step 2 - running CC3D simulation from PyCharm. Configuring Python Environment and PREFIX_CC3D
- Step 3 - Debugging (stepping through) CC3D simulation and exploring other PyCharm features
- Step 4 - writing steppable code with PyCharm code auto completion
- Perspective
- SteppableBasePy class
- Adding Steppable to Simulation using Twedit++
- Passing information between steppables
- Creating and Deleting Cells. Cell-Type Names
- Calculating distances in CC3D simulations.
- Looping over select cell types. Finding cell in the inventory.
- Writing data files in the simulation output directory.
- Adding plots to the simulation
- Custom Cell Attributes in Python
- Adding and managing extra fields for visualization purposes
- Automatic Tracking of Cells’ Attributes
- Field Secretion
- Chemotaxis on a cell-by-cell basis
- Steering – changing CC3DML parameters on-the-fly.
- Steering – changing Python parameters using Graphical User Interface.
- Replacing CC3DML with equivalent Python syntax
- Cell Motility. Applying force to cells.
- Setting cell membrane fluctuation ona cell-by-cell basis
- Modifying attributes of CellG object
- Controling steppable call frequency. Stopping simulation on demand or increasing maximum Monte Carlo Step.
- Building a wall (it is going to be terrific. Believe me)
- Resizing the lattice
- Changing number of Worknodes
- Iterating over cell neighbors
- Mitosis
- Dividing Clusters (aka compartmental cells)
- Changing cluster id of a cell.
- SBML Solver
- Building SBML models using Tellurium
- Building SBML models efficiently with Antimony and CellML
- Configuring Multiple Screenshots
- Parameter Scans
- Restarting Simulations
- Direct Call to CompuCell3D from Python
- Implementing Energy Functions in Python
- Appendix A
- Appendix B