connector Package

connectors Module

Mozaik connector interface.

class mozaik.connectors.__init__.Connector(model, name, source, target, parameters)

Bases: mozaik.core.BaseComponent

An abstract interface class for Connectors in mozaik. Each mozaik connector should derive from this class and implement the _connect function. The usage is: create the instance of MozaikConnector and call connect() to realize the connections.

required_parameters = {'short_term_plasticity': {'tau_psc': <type 'float'>, 'u': <type 'float'>, 'tau_rec': <type 'float'>, 'tau_fac': <type 'float'>}, 'target_synapses': <type 'str'>}
init_synaptic_mechanisms(weights=None, delays=None)
connect()
connection_field_plot_continuous(index, afferent=True, density=30)
store_connections(datastore)
class mozaik.connectors.__init__.SpecificArborization(network, source, target, connection_matrix, delay_matrix, parameters, name)

Bases: mozaik.connectors.__init__.Connector

Generic connector which gets directly list of connections as the list of quadruplets as accepted by the pyNN FromListConnector.

This connector cannot be parametrized directly via the parameter file because that does not support list of tuples.

This connector also gets rid of very weak synapses (below one-hundreth of the maximum synapse)

required_parameters = {'weight_factor': <type 'float'>}
class mozaik.connectors.__init__.SpecificProbabilisticArborization(network, source, target, connection_matrix, delay_matrix, parameters, name)

Bases: mozaik.connectors.__init__.Connector

Generic connector which gets directly list of connections as the list of quadruplets as accepted by the pyNN FromListConnector.

It interprets the weights as proportional probabilities of connectivity, and for each neuron out connections it samples num_samples of connections that actually get realized according to these weights. Each such sample connections will have weight equal to weight_factor/num_samples but note that there can be multiple connections between a pair of neurons in this sample (in which case the weights are set to the multiple of the base weights times the number of occurrences in the sample).

This connector cannot be parameterized directly via the parameter file because that does not support list of tuples.

required_parameters = {'weight_factor': <type 'float'>, 'num_samples': <type 'int'>}

connectors.fast Module

This file contains connectors that were written for speed - as a general rule they tend to use the more native pyNN or even backend specific pyNN methods.

To obtain speed they generally sacrifice ease customization.

class mozaik.connectors.fast.DistanceDependentProbabilisticArborization(model, name, source, target, parameters)

Bases: mozaik.connectors.Connector

A abstract connector that implements distance dependent connection. Each implementation just needs to implement the arborization_function and delay function. The distance input is in the ‘native’ metric of the sheets, i.e. degrees of visual field in RetinalSheet or micrometers in CorticalSheet.

required_parameters = {'map_location': <type 'str'>, 'weights': <type 'float'>}
arborization_function(distance)
delay_function(distance)
class mozaik.connectors.fast.ExponentialProbabilisticArborization(model, name, source, target, parameters)

Bases: mozaik.connectors.fast.DistanceDependentProbabilisticArborization

Distance dependent arborization with exponential fall-off of the probability, and linear spike propagation.

required_parameters = {'propagation_constant': <type 'float'>, 'arborization_constant': <type 'float'>, 'arborization_scaler': <type 'float'>}
arborization_function(distance)
delay_function(distance)
class mozaik.connectors.fast.UniformProbabilisticArborization(model, name, source, target, parameters)

Bases: mozaik.connectors.Connector

Connects source with target with equal probability between any two neurons.

required_parameters = {'delay': <type 'float'>, 'connection_probability': <type 'float'>, 'weights': <type 'float'>}
class mozaik.connectors.fast.FixedKConnector(model, name, source, target, parameters)

Bases: mozaik.connectors.Connector

Connects source with target such that each neuron will have the same number of presynaptic neurons chosen randomly.

required_parameters = {'delay': <type 'float'>, 'k': <type 'int'>, 'weights': <type 'float'>}

connectors.modular Module

class mozaik.connectors.modular.ModularConnector(network, name, source, target, parameters)

Bases: mozaik.connectors.Connector

An abstract connector than allows for mixing of various factors that can affect the connectivity.

The connector sepparates the implementation of delays from the implementation of weights.

It receives a dictionary of weight functions and a dictonary of delays functions each being an instance of ModularConnectorFunction. In both cases the list of functions is combined by using expression string which is a parameter of this class (see parameters for details).

The values returned by the ModularConnectorFunction will be considered to be in miliseconds when used for specifying delays, or the units used by pyNN for weights in case of specifying weights.

The ModularConnector then sets such computed values of weights and delays directly in the connections.

required_parameters = {'weight_expression': <type 'str'>, 'weight_functions': <class 'parameters.ParameterSet'>, 'delay_functions': <class 'parameters.ParameterSet'>, 'delay_expression': <type 'str'>}
class mozaik.connectors.modular.ModularSamplingProbabilisticConnector(network, name, source, target, parameters)

Bases: mozaik.connectors.modular.ModularConnector

ModularConnector that interprets the weights as proportional probabilities of connectivity and for each neuron out connections it samples num_samples of connections that actually get realized according to these weights. Each such sample connections will have weight equal to base_weight/num_samples but note that there can be multiple connections between a pair of neurons in this sample (in which case the weights are set to the multiple of the base weights times the number of occurrences in the sample).

required_parameters = {'base_weight': <type 'float'>, 'num_samples': <type 'int'>}
class mozaik.connectors.modular.ModularSingleWeightProbabilisticConnector(network, name, source, target, parameters)

Bases: mozaik.connectors.modular.ModularConnector

ModularConnector that interprets the weights as proportional probabilities of connectivity. The parameter connection_probability is interepreted as the average probability that two neurons will be connected in this projection. For each pair this connecter will make one random choice of connecting them (where the probability of this choice is determined as the proportional probability of the corresponding weight normalized by the connection_probability parameter). It will set each connections to the weight base_weight.

required_parameters = {'base_weight': <type 'float'>, 'connection_probability': <type 'float'>}

connectors.modular_connector_functions Module

class mozaik.connectors.modular_connector_functions.ModularConnectorFunction(source, target, parameters)

Bases: mozaik.core.ParametrizedObject

Abstract class defining the interface of nodular connector functions.

Each instance has to implement the evaluate(u) function that returns the pre-synaptic weights of neuron i.

evaluate(index)
class mozaik.connectors.modular_connector_functions.ConstantModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.ModularConnectorFunction

Triavial modular connection function assigning each connections the same weight

evaluate(index)
class mozaik.connectors.modular_connector_functions.PyNNDistributionConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.ModularConnectorFunction

ConnectorFunction which draws the values from the PyNNDistribution

required_parameters = {'pynn_distribution': <class 'mozaik.tools.distribution_parametrization.PyNNDistribution'>}
evaluate(index)
class mozaik.connectors.modular_connector_functions.DistanceDependentModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.ModularConnectorFunction

Helper abstract class to ease the definitions of purely distance dependent connector functions.

The distance is defined as the horizontal distance between the retinotopical positions of the neurons (one in source and one in destination sheet). The distane is translated into the native coordinates of the target sheet (e.g. micrometers for CorticlaSheet)!

For the special case where source = target, this coresponds to the intuitive lateral distance of the neurons.

distance_dependent_function(distance)

The is the function, dependent only on distance that each DistanceDependentModularConnectorFunction has to implement. The distance can be matrix.

evaluate(index)
class mozaik.connectors.modular_connector_functions.GaussianDecayModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.DistanceDependentModularConnectorFunction

Distance dependent arborization with gaussian fall-off of the connections: k * exp(-0.5*(distance/a)*2) / (a*sqrt(2*pi)) where a = arborization_constant, k = arborization_scaler

required_parameters = {'arborization_constant': <type 'float'>, 'arborization_scaler': <type 'float'>}
distance_dependent_function(distance)
class mozaik.connectors.modular_connector_functions.ExponentialDecayModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.DistanceDependentModularConnectorFunction

Distance dependent arborization with exponential fall-off of the connections: k * exp(-distance/a)

required_parameters = {'arborization_constant': <type 'float'>, 'arborization_scaler': <type 'float'>}
distance_dependent_function(distance)
class mozaik.connectors.modular_connector_functions.LinearModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.DistanceDependentModularConnectorFunction

Corresponds to: distance*linear_scaler + constant_scaler, where distance is in micrometers

required_parameters = {'constant_scaler': <type 'float'>, 'linear_scaler': <type 'float'>}
distance_dependent_function(distance)
class mozaik.connectors.modular_connector_functions.HyperbolicModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.DistanceDependentModularConnectorFunction

Corresponds to: exp(-alpha*distance*sqrt( heta^2 + distance^2)) , where distance is in micrometers And is the best fit I could so far find to the data from: Stepanyants, A., Hirsch, J. a, Martinez, L. M., Kisvárday, Z. F., Ferecskó, A. S., & Chklovskii, D. B. (2008). Local potential connectivity in cat primary visual cortex. Cerebral cortex, 18(1), 13–28. doi:10.1093/cercor/bhm027

required_parameters = {'alpha': <type 'float'>, 'theta': <type 'float'>}
distance_dependent_function(distance)

connectors.vision Module

Vision specific connectors.

class mozaik.connectors.vision.MapDependentModularConnectorFunction(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.ModularConnectorFunction

Corresponds to: distance*linear_scaler + constant_scaler

required_parameters = {'map_location': <type 'str'>, 'periodic': <type 'bool'>, 'sigma': <type 'float'>}
evaluate(index)
class mozaik.connectors.vision.V1PushPullArborization(source, target, parameters)

Bases: mozaik.connectors.modular_connector_functions.ModularConnectorFunction

This connector function implements the standard V1 functionally specific connection rule:

Excitatory synapses are more likely on cooriented in-phase neurons Inhibitory synapses are more likely to cooriented anti-phase neurons

Notes

The push_pull_ratio parameter essentially adds constant to the probability distribution over the orientation and phase dependent connectivity probability space. The formula looks like this: push_pull_ratio + (1-push_pull_ratio) * push_pull_term. Where the push_pull_term is the term determining the pure push pull connectivity. However note that due to the Gaussian terms being 0 in infinity and the finite distances in the orientation and phase space, the push-pull connectivity effectively itself adds a constant probability to all phase and orientation combinations, and the value of this constant is dependent on the phase and orientation sigma parameters. Therefore one has to be carefull in interpreting the push_pull_ratio parameter. If the phase and/or orientation sigma parameters are rather small, it is however safe to interpret it as the ratio of connections that were drawn randomly to the number of connection drawn based on push-pull type of connectivity.

required_parameters = {'push_pull_ratio': <type 'float'>, 'phase_sigma': <type 'float'>, 'target_synapses': <type 'str'>, 'or_sigma': <type 'float'>}
evaluate(index)

mozaik.connectors.meta_connectors Package

mozaik.connectors.meta_connectors.gabor(x1, y1, x2, y2, orientation, frequency, phase, size, aspect_ratio)
class mozaik.connectors.meta_connectors.GaborConnector(network, lgn_on, lgn_off, target, parameters, name)

Bases: mozaik.core.BaseComponent

Connector that creates Gabor projections.

The individual Gabor parameters are drawn from distributions specified in the parameter set:

aspect_ratio - aspect ratio of the gabor size - the size of the gabor RFs in degrees of visual field orientation - the orientation of the gabor RFs phase - the phase of the gabor RFs frequency - the frequency of the gabor in degrees of visual field

Other parameters:

topological - should the receptive field centers vary with the
position of the given neurons in the target sheet (note positions of neurons are always stored in visual field coordinates)
probabilistic - should the weights be probabilistic or directly
proportianal to the gabor profile

delay - (ms/μm) the delay on the projections

or_map - is an orientation map supplied? or_map_location - if or_map is True where can one find the map. It

has to be a file containing a single pickled 2d numpy array

phase_map - is a phase map supplied? phase_map_location - if phase_map is True where can one find the map.

It has to be a file containing a single pickled 2d numpy array
required_parameters = {'orientation_preference': <class 'parameters.random.ParameterDist'>, 'phase_map': <type 'bool'>, 'specific_arborization': <class 'parameters.ParameterSet'>, 'topological': <type 'bool'>, 'delay': <type 'float'>, 'aspect_ratio': <class 'parameters.random.ParameterDist'>, 'frequency': <class 'parameters.random.ParameterDist'>, 'or_map_location': <type 'str'>, 'or_map': <type 'bool'>, 'phase': <class 'parameters.random.ParameterDist'>, 'probabilistic': <type 'bool'>, 'phase_map_location': <type 'str'>, 'size': <class 'parameters.random.ParameterDist'>}

Previous topic

analysis Package

Next topic

experiments Package

This Page