neurots.astrocyte.context¶
Space colonization context data structures.
Classes
|
Store the Endfeet target points. |
|
Context class for space colonization. |
- class neurots.astrocyte.context.EndfeetTargets(coordinates)¶
Bases:
object
Store the Endfeet target points.
Endfeet targets are the 3D points that influence the growth of the targeted tree growth. A tree will grow towards these points as long as they remain active. If a point is deactivated then it will no longer affect the grower it is assigned to.
- Parameters
coordinates (numpy.ndarray) – Array of 3D points.
- points¶
The coordinates of the 3D points that represent the endfeet targets.
- Type
- active¶
A boolean mask, the same size as the number of points. A point is active when its corresponding boolean value in the active array is True.
- Type
- property active_points¶
Returns the points that are still active.
- class neurots.astrocyte.context.SpaceColonizationContext(params)¶
Bases:
object
Context class for space colonization. It includes globally available information.
- morphology_points¶
The morphology points from the entire morphology, globally available by algorithms that need access to the morphology as a whole. For example repulsion needs to have access to all the neighboring points in the morphology to calculate the repulsion from them.
- Type
- endfeet_targets¶
The targets for the targeting space colonization algorithm.
- Type
- field¶
The attraction field function that specifies how strong is the field as we approach the target. It takes a fraction which represents the ratio of distance of a point to the target over the distance from the soma to the target. That means that it will be zero when overlapping with the target and one if the point is overlapping with the soma position. It is used by the targeting space colonization algorithm to determine how much influenced the splitting direction should by the presence of the target.
- Type
Callable[float] -> float
- point_cloud¶
Seed point cloud for the space colonization queries.
- Type
- collision_handle¶
A callable function that takes a point and the segment length as input an returns if there is a collision or not. The segment length is used by probabilistic checks that scale the probability of colliding (soft collision with exponential decay from boundary distance), because it would affect the probability if a check is made every 1.0 um or every 0.1 um (10x more times).
- Type
Callable[numpy.ndarray, float] -> bool
- influence_distance(segment_length)¶
Space colonization algorithm influence distance.
Space colonization requires finding the seeds (point cloud) around points that will influence the growth direction. Influence distance is the threshold radius of the ball query to find the points to contribute.
Note
Instead of setting an absolute number it makes more sense for the influence distance to be factor multiplied by the segment length.
For more details see: http://algorithmicbotany.org/papers/colonization.egwnp2007.large.pdf
- kill_distance(segment_length)¶
Space colonization algorithm kill distance.
Space colonization requires the removal of seed points (point cloud) around the newly created points. Kill distance is the threshold radius of the ball query to find the points to remove.
Note
Instead of setting an absolute number it makes more sense for the kill distance to be factor multiplied by the segment length.
For more details see: http://algorithmicbotany.org/papers/colonization.egwnp2007.large.pdf