braincell.morph module#

braincell.morph provides diverse tools for morphology processing, enabling the representation and manipulation of neuronal structures.

Morphology Representation#

MorphoBranch

A tree-local branch node bound to exactly one Morpho owner.

MorphoEdge

A directed edge between two morphology branches.

MorphoMetric

Snapshot of whole-morphology metrics.

Helpers#

braincell.morph.branch_class_for_type(branch_type)[source]#

Return the Branch subclass for the given type string.

Parameters:

branch_type (str) – One of the allowed branch type strings (e.g. "soma", "dendrite", "axon").

Returns:

The corresponding subclass.

Return type:

type[Branch]

Raises:

ValueError – If branch_type is not a recognised branch type.