cerebellar_models.connectome package

Module contents

Implementation of the BSB ConnectionStrategy for cerebellar cortex reconstructions.

Submodules

cerebellar_models.connectome.presyn_dist_strat module

Module for the utility class for postsynaptically-sorted ConnectionStrategy

class cerebellar_models.connectome.presyn_dist_strat.PresynDistStrat

Bases: InvertedRoI

Mixin class that id used for ConnectionStrategy that deal with the connections for a pre- and post-synaptic pair sorting them by the post-synaptic cell chunk.

get_region_of_interest(chunk)

Finds all the presynaptic chunks that are within a sphere of defined radius, centered on the postsynaptic chunk.

Parameters:

chunk (bsb.storage._chunks.Chunk) – Postsynaptic chunk.

Returns:

list of presynaptic chunks

Return type:

list[bsb.storage._chunks.Chunk]

radius

Radius of the sphere to filter the presynaptic chunks within it.

cerebellar_models.connectome.presyn_dist_strat.get_close_chunks(chunk, target_chunks, radius)

Look for target chunks which are less than radius away from the current one.

Parameters:
Radius:

Maximum distance from the source chunk.

Returns:

list of presynaptic chunks

Return type:

list[bsb.storage._chunks.Chunk]

cerebellar_models.connectome.to_glomerulus module

Module for the configuration node of every presynaptic cell to Glomerulus ConnectionStrategy

class cerebellar_models.connectome.to_glomerulus.ConnectomeGlomerulus(*args, _parent=None, _key=None, **kwargs)

Bases: InvertedRoI, ConnectionStrategy

BSB Connection strategy to connect a presynaptic cell to Glomeruli.

connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
abstractmethod pre_selection(presyn_pos, glom_pos)

Order presynaptic cell ids based on their respective distance to glomerulus

Parameters:
Returns:

presynaptic cell ids sorted by distance to glomerulus

Return type:

numpy.ndarray

class cerebellar_models.connectome.to_glomerulus.ConnectomeMossyGlomerulus(*args, _parent=None, _key=None, **kwargs)

Bases: ConnectomeGlomerulus

BSB Connection strategy to connect Mossy fibers to Glomeruli.

connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
get_node_name()
pre_selection(presyn_pos, glom_pos)

Order presynaptic cell ids based on their respective distance to glomerulus

Parameters:
Returns:

presynaptic cell ids sorted by distance to glomerulus

Return type:

numpy.ndarray

x_length: float

Length of the box along the x axis surrounding the glomerulus cell soma in which the presynaptic cell can be connected.

y_length: float

Length of the box along the y axis surrounding the glomerulus cell soma in which the presynaptic cell can be connected.

class cerebellar_models.connectome.to_glomerulus.ConnectomeUBCGlomerulus(*args, _parent=None, _key=None, **kwargs)

Bases: ConnectomeGlomerulus, PresynDistStrat

BSB Connection strategy to connect UBC to Glomeruli.

connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
get_node_name()
pre_selection(presyn_pos, glom_pos)

Order presynaptic cell ids based on their respective distance to glomerulus

Parameters:
Returns:

presynaptic cell ids sorted by distance to glomerulus

Return type:

numpy.ndarray

cerebellar_models.connectome.to_glomerulus.norm_exp_dist(size: int = 1, b: float = 2.0)

Normalized exponential random generator for distance based selection

Parameters:
  • size (int) – number of random to sample

  • b (float) – strength of the exponential decay.

Returns:

random numbers sampled

Return type:

numpy.ndarray

cerebellar_models.connectome.glomerulus_granule module

Module for the configuration node of the Glomerulus to Granule ConnectionStrategy

class cerebellar_models.connectome.glomerulus_granule.ConnectomeGlomerulusGranule(*args, _parent=None, _key=None, **kwargs)

Bases: InvertedRoI, ConnectionStrategy

BSB Connection strategy to connect Glomerulus to Granule cells. With a convergence value set to n, this connection guarantees that each Granule cell connects to n unique Glomerulus clusters, where each Glomerulus cluster is connected to a different Mossy fiber.

boot()
connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
convergence: float

Convergence value between Glomeruli and Granule cells. Corresponds to the mean number of Glomeruli that has a single Granule cell as target

depends_on: list[ConnectionStrategy]

The list of strategies that must run before this one.

get_node_name()
load_connections(*args, **kwargs)
pre_cell_types

Celltype used for the pre-presyn cell.

pre_glom_strats

Connection Strategies that links Pre-presyn cell to Glomeruli.

radius

Radius of the sphere to filter the presynaptic chunks within it.

exception cerebellar_models.connectome.glomerulus_granule.TooFewGlomeruliClusters(*args, **kwargs)

Bases: ConnectivityError

Error raised when too few glomerulus clusters are available for a postsynaptic cell.

cerebellar_models.connectome.glomerulus_golgi module

Module for the configuration node of the Glomerulus to Golgi ConnectionStrategy

class cerebellar_models.connectome.glomerulus_golgi.ConnectomeGlomerulusGolgi(*args, _parent=None, _key=None, **kwargs)

Bases: PresynDistStrat, ConnectionStrategy

BSB Connection strategy to connect Glomerulus to Golgi cells.

connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
get_node_name()

cerebellar_models.connectome.golgi_glomerulus module

Module for the configuration node of the Golgi to Glomerulus ConnectionStrategy

class cerebellar_models.connectome.golgi_glomerulus.ConnectomeGolgiGlomerulus(*args, _parent=None, _key=None, **kwargs)

Bases: ConnectionStrategy

BSB Connection strategy to connect Golgi cells to postsynaptic cells through Glomeruli. With a divergence value set to n, this connection guarantees that each golgi cell connects to all postsynaptic cells that are themselves connected to n unique Glomerulus.

boot()
connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
depends_on: list[ConnectionStrategy]

The list of strategies that must run before this one.

divergence: float

Divergence value between Golgi cells and Glomeruli. Corresponds to the mean number of Glomeruli targeted by a single Golgi cell

get_node_name()
glom_cell_types

Cell types used for the Glomeruli.

glom_post_strats

Connection Strategies that links Glomeruli to the postsynaptic cells.

load_connections(*args, **kwargs)
radius: float

Radius of the sphere surrounding the Golgi cell soma in which glomeruli can be connected.

cerebellar_models.connectome.glomerulus_ubc module

Module for the configuration node of the Glomerulus to UBC ConnectionStrategy

class cerebellar_models.connectome.glomerulus_ubc.ConnectomeGlomerulusUBC(*args, _parent=None, _key=None, **kwargs)

Bases: PresynDistStrat, ConnectionStrategy

BSB Connection strategy to connect any type of Glomerulus to UBC cells.

boot()
connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
get_node_name()
ratios_ubc: dict[str, float]

Dictionary that links a postsynaptic celltype name to the ratios of the presynaptic UBC population that connects to it.

cerebellar_models.connectome.io_molecular module

Module for the configuration node of the IO to molecular layer interneurons (MLI) ConnectionStrategy

class cerebellar_models.connectome.io_molecular.ConnectomeIO_MLI(*args, _parent=None, _key=None, **kwargs)

Bases: NotParallel, ConnectionStrategy

BSB Connection strategy to connect IO cells to molecular layer interneurons (MLI) cells through PC. IO cells which are connected to a PC should also connect to all the MLIs connected to this PC.

boot()
connect(pre, post)

Central method of each connection strategy. Given a pair of HemitypeCollection (one for each connection side), should connect cell population using the scaffold’s (available as self.scaffold) bsb.core.Scaffold.connect_cells() method.

Parameters:
depends_on: list[ConnectionStrategy]

The list of strategies that must run before this one.

get_node_name()
get_region_of_interest(**kwargs)

Returns the list of chunks containing the potential postsynaptic neurons, based on a chunk containing the presynaptic neurons.

Parameters:

chunk (bsb.storage._chunks.Chunk) – Presynaptic chunk

Returns:

List of postsynaptic chunks

Return type:

list[bsb.storage._chunks.Chunk]

io_pc_connectivity

Connection Strategy that links IO to PC.

load_connectivity_set(connection_strat, cell_type)

Load the connection locations from a connection strategy that connects the provided cell type to PC.

Parameters:
Returns:

A tuple containing: - an array of the presynaptic cell_type connection locations, - an array of the postsynaptic pc connection locations

load_hemitype_connections(strategies, hemitype)

Load the connection locations for all the MLI to PC strategies. Will only keep one connection location information for each unique pair of MLI-PC.

Parameters:
Returns:

A tuple containing: - an array of the presynaptic connection locations - an array of the postsynaptic connection locations - an array of the placement set indexes

mli_pc_connectivity

List of Connection Strategies that links MLI to PC.

pre_cell_pc

Celltype used for to represent PC.

queue(pool: bsb.services.pool.JobPool)

Get the queued jobs of all the strategies we depend on.

param pool: pool where the jobs will be queued type pool: bsb.services.pool.JobPool

Parameters:

pool (bsb.services.pool.JobPool)

cerebellar_models.connectome.io_purkinje module

Module for the configuration node of the IO to purkinje cells AfterConnectivityHook

class cerebellar_models.connectome.io_purkinje.DuplicateSynapses(*args, _parent=None, _key=None, **kwargs)

Bases: AfterConnectivityHook

BSB postprocessing to duplicate connections from a connection strategy into multiple synapses per pair.

conn_strategy: ConnectionStrategy

Connection Strategy to on which to apply the postprocessing.

contacts

Number or distribution determining the amount of synaptic contacts one cell will form on another

get_node_name()
postprocess()