morphogen.models.branching¶
Branching networks grown by space colonization: vascular trees, roots, corals.
Blood vessels, the airways of lungs, the roots and crowns of plants grow toward the
tissue or the space they serve. The space colonization algorithm (Runions, Lane and
Prusinkiewicz 2007) grows a tree toward attraction points scattered in the volume (the
cells that call for vessels, the light the crown seeks): at each step, every point
pulls the node of the tree nearest to it within the influence distance d_i; each
pulled node grows a branch of length D toward the mean direction of its points, and
the points closer to the tree than the kill distance d_k are reached and removed.
The growth stops when no point is left within reach of the tree.
The radii follow Murray’s law (1926): the radius of a vessel to the power n is the
sum of those of its branches, from tips of radius r_t: n = 3 minimizes the work
of a laminar flow and the volume of blood (Murray), n = 2 keeps the cross-section
area (the pipe model of trees, da Vinci’s rule). A root then has the radius r_t
N^(1/n) for the N tips it feeds. In a periodic box the tree grows on the torus.
- morphogen.models.branching.murray_radii(parents: ndarray, tip: float, exponent: float) ndarray[source]¶
Radius of the segment ending at each node:
tipfor the tips, and Murray’s lawr^n = sum of r_child^nabove (the parents come before their children).
- class morphogen.models.branching.BranchingNetwork(n_attractors: int = 2000, step: float = 0.02, influence: float | None = None, kill: float | None = None, roots: int = 1, root_position: str = 'face', tip_radius: float = 0.004, murray_exponent: float = 3.0, max_steps: int = 2000, axis: int = 2)[source]¶
Bases:
ModelBranching network grown toward
n_attractorsrandom points by space colonization (segments ofstep), with Murray’s law for the radii.- phases: ClassVar[dict[int, str]] = {0: 'tissue', 1: 'vessels'}¶
Meaning of the phase indices of the voxel images.
- count_label: ClassVar[str] = 'segments'¶
Objects counted by
expected_count()(fibres, spheres, cells…).
- property influence_distance: float¶
- property kill_distance: float¶
- grow(rng, size: ndarray, periodic: bool) _Tree[source]¶
Grow the trees in the box
[0, size)(on the torus ifperiodic).
- generate(domain: Domain, seed: int | SeedSequence | Generator | None = None) PrimitiveUnion[source]¶
One realization of the model in
domain.