ComposedProfile#

class braintools.init.ComposedProfile(left, right, op, op_symbol)#

Binary operation composition of distance profiles.

Allows composing two profiles using arithmetic operations.

probability(distances)[source]#

Calculate connection probability based on distance.

Parameters:

distances (Array | ndarray | bool | number | bool | int | float | complex | Quantity) – Array of distances between neuron pairs.

Returns:

probability – Connection probabilities (values between 0 and 1).

Return type:

ndarray

weight_scaling(distances)[source]#

Calculate weight scaling factor based on distance.

Parameters:

distances (Array | ndarray | bool | number | bool | int | float | complex | Quantity) – Array of distances between neuron pairs.

Returns:

scaling – Weight scaling factors (typically between 0 and 1).

Return type:

ndarray