Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Resize Connector vectors when adding connection models #1003

Merged
merged 2 commits into from Aug 17, 2018

Conversation

@hakonsbm
Copy link
Contributor

@hakonsbm hakonsbm commented Aug 10, 2018

When adding connection models after NEST has been initialised, the vectors containing Connectors (which contains synapses for one particular synapse type) have to be resized, as the number of synapse types have increased. This happens when a module adds a connection model and is dynamically loaded at runtime.

Fixes #1002.

@heplesser
Copy link
Contributor

@heplesser heplesser commented Aug 11, 2018

@hakonsbm Travis seems to have had technical problems yesterday, I have restarted all failed builds.

Copy link
Contributor

@heplesser heplesser left a comment

@hakonsbm This looks good, but I have some questions: (i) There are several register_???_connection_model() methods, including for secondary connections. Do they all in the end call this register_connection_model_() method so we only need the correction here? (ii) I think the call to resize_connections() at the end of modelmodule::init() can and should be removed.

Because the Connector vectors now are resized on every call to register_connection_model()
@hakonsbm
Copy link
Contributor Author

@hakonsbm hakonsbm commented Aug 13, 2018

@heplesser All the methods end in the same register_connection_model_(). And I have removed the resize_connections() call.

Copy link
Contributor

@suku248 suku248 left a comment

Seems fine to me, too.

@heplesser heplesser merged commit 8487ac1 into nest:master Aug 17, 2018
1 check passed
1 check passed
continuous-integration/travis-ci/pr The Travis CI build passed
Details
@hakonsbm hakonsbm deleted the hakonsbm:fix_MyModule_segfault branch Aug 17, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Linked issues

Successfully merging this pull request may close these issues.

None yet

3 participants
You can’t perform that action at this time.