nest / nest-simulator

The NEST simulator
http://www.nest-simulator.org
GNU General Public License v2.0
544 stars 370 forks source link

Review semantics of symmetric_pairwise_bernoulli #3288

Open heplesser opened 3 months ago

heplesser commented 3 months ago

The symmetric_pairwise_bernoulli connection rules prohibits autapses and requires allow_multapses==true. It also requires p < 1. These constraints are not entirely plausible. Furthermore, is p is very close to 1, each connection is created twice. Is this really what we want? If so, it should be documented more clearly.

I also seems curious that even though the rule's name explicitly includes symmetric, one still needs to pass 'make_symmetric': True in the conn_spec.

Here is a small example:

n = nest.Create('parrot_neuron', 3)
nest.Connect(n, n, {'rule': 'symmetric_pairwise_bernoulli', 'p': .999999, 
                    'allow_autapses': False, 'make_symmetric': True})
print(nest.GetConnections())

 source   target   synapse model   weight   delay 
-------- -------- --------------- -------- -------
      1        2  static_synapse    1.000   1.000
      1        3  static_synapse    1.000   1.000
      1        2  static_synapse    1.000   1.000
      1        3  static_synapse    1.000   1.000
      2        1  static_synapse    1.000   1.000
      2        1  static_synapse    1.000   1.000
      2        3  static_synapse    1.000   1.000
      2        3  static_synapse    1.000   1.000
      3        1  static_synapse    1.000   1.000
      3        2  static_synapse    1.000   1.000
      3        1  static_synapse    1.000   1.000
      3        2  static_synapse    1.000   1.000
jhnnsnk commented 3 months ago

It could also be an option to just get rid of this rule and add the flag make_symmetric to the generic pairwise Bernoulli rule with the default being False. Thinking about further generalization: Are there use cases for other rules where symmetric connections might also be useful?

github-actions[bot] commented 1 month ago

Issue automatically marked stale!