Skip to content

Commit

Permalink
[BBPBGLIB-1042] GapJunctionManager: filter source target by population (
Browse files Browse the repository at this point in the history
#42)

## Context
Currently neurodamus raises an error when the connection source or
target `node_set` from multiple populations. Users should use
single-population `node_sets` in `connection_overrides`. This also
happens for `GapJunctionManager` when we have a multi-pop `node_set` for
the simulation (`circut_target`). This PR fixes that by limiting
"_src_target_filter" from the gap junction's source population so that
it belongs to a single population.


## Scope
Change in class `GapJunctionManager:__init__`

## Testing
Existing test

## Review
* [x] PR description is complete
* [x] Coding style (imports, function length, New functions, classes or
files) are good
* [ ] Unit/Scientific test added
* [ ] Updated Readme, in-code, developer documentation

---------

Co-authored-by: Fernando Pereira <fernando.pereira@epfl.ch>
  • Loading branch information
WeinaJi and ferdonline authored Oct 9, 2023
1 parent 55b958d commit 80822a4
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion neurodamus/gap_junction.py
Original file line number Diff line number Diff line change
Expand Up @@ -86,7 +86,8 @@ def __init__(self, gj_conf, target_manager, cell_manager, src_cell_manager=None,
raise ConfigurationError("Missing GapJunction 'Path' configuration")

super().__init__(gj_conf, target_manager, cell_manager, src_cell_manager, **kw)
self._src_target_filter = target_manager.get_target(cell_manager.circuit_target)
self._src_target_filter = target_manager.get_target(cell_manager.circuit_target,
src_cell_manager.population_name)

def open_synapse_file(self, synapse_file, *args, **kw):
super().open_synapse_file(synapse_file, *args, **kw)
Expand Down

0 comments on commit 80822a4

Please sign in to comment.