CurrentProj#
- class brainpy.state.CurrentProj(*prefetch, comm, out, post)#
Current-based projection.
Delivers current input to post-synaptic neurons by passing the communication output through a synaptic output module (e.g.,
COBAorCUBA) and registering it as a current input on the post-synaptic population.The update pipeline is:
Optional pre-fetch modules transform the input.
The communication module (
comm) maps pre-synaptic activity.The synaptic output module (
out) converts conductance to current and binds it to the post-synaptic neuron.
- Parameters:
*prefetch – Optional pre-fetch modules. If provided, the last element must be a
brainstate.nn.Prefetchorbrainstate.nn.PrefetchDelayAtinstance.comm (
Callable) – Communication module mapping pre-synaptic activity.out (
SynOut) – Synaptic output module that converts the communication result to post-synaptic current.post (
Dynamics) – Post-synaptic neural population.
- Raises:
TypeError – If
commis not callable,outis not aSynOut,postis not aDynamics, or the last prefetch module has an incorrect type.
See also
AlignPostProjProjection with aligned synapse dynamics.
DeltaProjDirect delta-input projection.
align_pre_projectionConvenience wrapper with pre-synaptic alignment.
Notes
The output module is immediately registered as a current input on the post-synaptic population at construction time.
Unlike
AlignPostProj, this projection does not use synapse dynamics – the communication result is directly converted to current.
Examples
>>> import brainpy >>> import brainstate >>> import saiunit as u >>> n_neurons = 100 >>> pop = brainpy.state.LIF(n_neurons, tau=10.*u.ms) >>> pop.init_state() >>> proj = brainpy.state.CurrentProj( ... comm=brainstate.nn.Linear(n_neurons, n_neurons), ... out=brainpy.state.CUBA(scale=u.volt), ... post=pop, ... )