ANNarchy 5.0.0
  • ANNarchy
  • Installation
  • Tutorial
  • Manual
  • Notebooks
  • Reference

  • ANNarchy
  • Core components
    • Network
    • Population
    • Projection
    • Monitor
    • PopulationView
    • Dendrite
  • Neuron and Synapse models
    • Neuron
    • Synapse
    • Parameter
    • Variable
    • Creating
    • Pruning
    • Constant
  • Neuron models
    • LeakyIntegrator
    • Izhikevich
    • IF_curr_exp
    • IF_cond_exp
    • IF_curr_alpha
    • IF_cond_alpha
    • HH_cond_exp
    • EIF_cond_alpha_isfa_ista
    • EIF_cond_exp_isfa_ista
  • Synapse models
    • Hebb
    • Oja
    • IBCM
    • STP
    • STDP
  • Inputs
    • InputArray
    • TimedArray
    • PoissonPopulation
    • TimedPoissonPopulation
    • SpikeSourceArray
    • HomogeneousCorrelatedSpikeTrains
    • CurrentInjection
    • DecodingProjection
    • ImagePopulation
    • VideoPopulation
  • Random Distributions
    • Uniform
    • DiscreteUniform
    • Normal
    • LogNormal
    • Exponential
    • Gamma
    • Binomial
  • Functions
    • add_function
    • functions
  • Callbacks
    • every
  • Utilities
    • report
    • timeit
    • sparse_random_matrix
    • sparse_delays_from_weights
    • magic_network
  • Convolution
    • Convolution
    • Pooling
    • Transpose
    • Copy
  • BOLD monitoring
    • BoldMonitor
    • BoldModel
    • balloon_RN
    • balloon_RL
    • balloon_CN
    • balloon_CL
    • balloon_maith2021
    • balloon_two_inputs
  • Tensorboard logging
    • Logger
  • ANN-to-SNN conversion
    • ANNtoSNNConverter
  • DEPRECATED Top-level API
    • setup
    • compile
    • clear
    • reset
    • set_seed
    • get_population
    • get_projection
    • populations
    • projections
    • monitors
    • simulate
    • simulate_until
    • step
    • enable_learning
    • disable_learning
    • get_time
    • set_time
    • get_current_step
    • set_current_step
    • dt
    • save
    • load
    • save_parameters
    • load_parameters
    • callbacks_enabled
    • disable_callbacks
    • enable_callbacks
    • clear_all_callbacks

On this page

  • Dendrite
    • Attributes
    • Methods
      • synapse
      • set
      • get
      • receptive_field
      • create_synapse
      • create_synapses
      • prune_synapse
      • prune_synapses

Dendrite

Dendrite(self, proj, post_rank, idx)

Sub-group of a Projection for a single post-synaptic neuron.

It can not be created directly, only through a call to Projection.dendrite(rank):

dendrite = proj.dendrite(6)

Attributes

Name Description
post_rank Rank of the post-synaptic neuron.
proj Parent projection.
size Number of synapses reaching the post-synaptic neuron.
pre_ranks List of ranks of pre-synaptic neurons.
synapses Iteratively returns the synapses corresponding to this dendrite.

Methods

Name Description
synapse Returns the synapse coming from the corresponding presynaptic neuron.
set Sets the value of a parameter/variable on all synapses in the dendrite.
get Returns the value of a parameter/variable.
receptive_field Returns the given variable as a receptive field.
create_synapse Creates a single synapse for this dendrite with the given pre-synaptic neuron.
create_synapses Creates a set of synapses for this dendrite with the given pre-synaptic neurons.
prune_synapse Removes the synapse with the given pre-synaptic neuron from the dendrite.
prune_synapses Removes the synapses which belong to the provided pre-synaptic neurons from the dendrite.

synapse

synapse(pos)

Returns the synapse coming from the corresponding presynaptic neuron.

Parameters

Name Type Description Default
pos int | tuple[int] can be either the rank or the coordinates of the presynaptic neuron required

set

set(value)

Sets the value of a parameter/variable on all synapses in the dendrite.

dendrite.set( { 'tau' : 20, 'w'= Uniform(0.0, 1.0) } )

Parameters

Name Type Description Default
value dict a dictionary containing the parameter/variable names as keys. required

get

get(name)

Returns the value of a parameter/variable.

dendrite.get('w')

Parameters

Name Type Description Default
name str name of the parameter/variable. required

receptive_field

receptive_field(variable='w', fill=0.0)

Returns the given variable as a receptive field.

A numpy array of the same geometry as the pre-synaptic population is returned. Non-existing synapses are replaced by zeros (or the value fill).

Parameters

Name Type Description Default
variable str name of the variable (default = ‘w’) 'w'
fill float value to use when a synapse does not exist (default: 0.0). 0.0

create_synapse

create_synapse(rank, w=0.0, delay=0)

Creates a single synapse for this dendrite with the given pre-synaptic neuron.

The configuration key 'structural_plasticity' must be set to True before compile() for this method to work.

net = ann.Network()
net.config(structural_plasticity=True)
net.compile()

try:
    proj.dendrite(10).create_synapse(rank=20, w=0.1, delay=0.0)
except Exception as e:
    print(e)

If the synapse already exists, an error is thrown, so make sure to catch the exception.

Parameters

Name Type Description Default
rank int rank of the pre-synaptic neuron required
w float synaptic weight. 0.0
delay float synaptic delay in milliseconds that should be a multiple of dt. 0

create_synapses

create_synapses(ranks, weights=None, delays=None)

Creates a set of synapses for this dendrite with the given pre-synaptic neurons.

The configuration key 'structural_plasticity' must be set to True before compile() for this method to work.

net = ann.Network()
net.config(structural_plasticity=True)
net.compile()

try:
    proj.dendrite(10).create_synapses(ranks=[20, 30, 40], weights=0.1, delay=0.0)
except Exception as e:
    print(e)

If the synapses already exist, an error is thrown, so make sure to catch the exception.

Parameters

Name Type Description Default
ranks list[int] list of ranks for the pre-synaptic neurons. required
weights float | list[float] list of synaptic weights (default: 0.0). None
delays float | list[float] list of synaptic delays (default = dt). None

prune_synapse

prune_synapse(rank)

Removes the synapse with the given pre-synaptic neuron from the dendrite.

The configuration key 'structural_plasticity' must be set to True before compile() for this method to work.

net = ann.Network()
net.config(structural_plasticity=True)
net.compile()

try:
    proj.dendrite(10).prune_synapse(rank=20)
except Exception as e:
    print(e)

If the synapse does not exist, an error is thrown, so make sure to catch the exception.

Parameters

Name Type Description Default
rank int rank of the pre-synaptic neuron required

prune_synapses

prune_synapses(ranks)

Removes the synapses which belong to the provided pre-synaptic neurons from the dendrite.

The configuration key 'structural_plasticity' must be set to True before compile() for this method to work.

net = ann.Network()
net.config(structural_plasticity=True)
net.compile()

try:
    proj.dendrite(10).prune_synapses(ranks=[20, 30, 40])
except Exception as e:
    print(e)

If the synapses do not exist, an error is thrown, so make sure to catch the exception.

Parameters

Name Type Description Default
ranks list[int] list of ranks of the pre-synaptic neurons. required
PopulationView
Neuron
 

Copyright Julien Vitay, Helge Ülo Dinkelbach, Fred Hamker