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

New neuronal population model gif_pop_psc_exp #895

Merged
merged 28 commits into from Mar 14, 2018

Conversation

Projects
None yet
5 participants
@mdeger
Contributor

mdeger commented Feb 28, 2018

Tilo Schwalger (@schwalger), Hesam Setareh (@hesam-setareh) and I would like to add the model gif_pop_psc_exp to NEST by means of this pull request.

The model represents the pooled activity a population of (any number of) neurons in a single NEST node, accurately treating stochastic finite size effects. The algorithm and a range of simulations of single neuron vs. population activity are published in the journal article [1]:

Schwalger T, Deger M, Gerstner W (2017) Towards a theory of cortical columns: From spiking neurons to interacting neural populations of finite size. PLoS Comput Biol 13(4): e1005507. https://doi.org/10.1371/journal.pcbi.1005507

The model is related to the flexible single neuron model gif_psc_exp, hence the name gif_pop_psc_exp. Using this population model, one can build models of interconnected populations, etc, as discussed in [1], which can be simulated efficiently.

@mdeger

This comment has been minimized.

Show comment
Hide comment
@mdeger

mdeger Feb 28, 2018

Contributor

Somehow the travis builds are failing. As far as I can see, the problem is this:

/home/travis/build/nest/nest-simulator/models/gif_pop_psc_exp.h:315:5: error: ‘GSL_BinomialRandomDev’ in namespace ‘librandom’ does not name a type

However, I cannot reproduce this error when building on my machine. Could it be that there is a different version of GSL on the travis-CI build system? Any ideas how to proceed?

Contributor

mdeger commented Feb 28, 2018

Somehow the travis builds are failing. As far as I can see, the problem is this:

/home/travis/build/nest/nest-simulator/models/gif_pop_psc_exp.h:315:5: error: ‘GSL_BinomialRandomDev’ in namespace ‘librandom’ does not name a type

However, I cannot reproduce this error when building on my machine. Could it be that there is a different version of GSL on the travis-CI build system? Any ideas how to proceed?

@Silmathoron

This comment has been minimized.

Show comment
Hide comment
@Silmathoron

Silmathoron Mar 1, 2018

Contributor

Models that require GSL need to be registered inside the GSL guard.
The error does not occur locally because you have installed gsl; however, in the tests, we do some of them without GSL, which is where your code fails.

Contributor

Silmathoron commented Mar 1, 2018

Models that require GSL need to be registered inside the GSL guard.
The error does not occur locally because you have installed gsl; however, in the tests, we do some of them without GSL, which is where your code fails.

@terhorstd terhorstd added this to the NEST 2.16 milestone Mar 5, 2018

@hakonsbm

This looks pretty good to me, once you get the GSL guard in place. I just have a few comments, see below. Also you should PEP8ify gif_pop_psc_exp.py.

Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.h
Show outdated Hide outdated models/modelsmodule.cpp
Show outdated Hide outdated testsuite/regressiontests/issue-77.sli
Show outdated Hide outdated testsuite/unittests/test_gif_pop_psc_exp.sli
Show outdated Hide outdated testsuite/unittests/test_gif_pop_psc_exp.sli
@@ -86,6 +87,8 @@
#include "gif_psc_exp_multisynapse.h"
#include "gif_cond_exp.h"
#include "gif_cond_exp_multisynapse.h"
#include "gif_pop_psc_exp.h"

This comment has been minimized.

@heplesser

heplesser Mar 7, 2018

Contributor

Isn't this the same line as line 81?

@heplesser

heplesser Mar 7, 2018

Contributor

Isn't this the same line as line 81?

This comment has been minimized.

@mdeger

mdeger Mar 9, 2018

Contributor

Thanks. I removed line 81 instead.

@mdeger

mdeger Mar 9, 2018

Contributor

Thanks. I removed line 81 instead.

@heplesser

@mdeger Thank you for the fast response! I think you could improve performance by making local variables const; I also had a few minor other suggestions, see inline comments.

Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated pynest/examples/gif_pop_psc_exp.py
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
@hakonsbm

Thanks for the changes. You are still missing the GSL guards, so it's still failing on Travis. And I also have a few additional remarks.

Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated models/gif_pop_psc_exp.cpp
Show outdated Hide outdated pynest/examples/gif_pop_psc_exp.py
Show outdated Hide outdated pynest/examples/gif_pop_psc_exp.py
Show outdated Hide outdated pynest/examples/gif_pop_psc_exp.py
Show outdated Hide outdated testsuite/unittests/test_gif_pop_psc_exp.sli
Show outdated Hide outdated testsuite/unittests/test_gif_pop_psc_exp.sli
@mdeger

This comment has been minimized.

Show comment
Hide comment
@mdeger

mdeger Mar 9, 2018

Contributor

Thank you very much for your comments. I have just committed some changes in order to address them.

Contributor

mdeger commented Mar 9, 2018

Thank you very much for your comments. I have just committed some changes in order to address them.

@heplesser

@mdeger Thanks a lot! I just have one detail left, namely skipping GSL-dependent test using our new skip_if_without_gsl SLI function.

@hakonsbm

This comment has been minimized.

Show comment
Hide comment
@hakonsbm

hakonsbm Mar 12, 2018

Contributor

@mdeger Thank you for the changes! This looks good now.

Sorry for the erroneous comment. I have created a PR in your fork reinstating the triple quotes. As soon as you merge that, I will approve this PR.

Contributor

hakonsbm commented Mar 12, 2018

@mdeger Thank you for the changes! This looks good now.

Sorry for the erroneous comment. I have created a PR in your fork reinstating the triple quotes. As soon as you merge that, I will approve this PR.

Merge pull request #7 from hakonsbm/mdeger_gif_pop_psc_exp
Reinstated triple quotes for documentation comments

@heplesser heplesser removed the request for review from Silmathoron Mar 14, 2018

@heplesser heplesser merged commit 9230ddd into nest:master Mar 14, 2018

1 check passed

continuous-integration/travis-ci/pr The Travis CI build passed
Details
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment