Hello,
For the following code, I receive a coredump (it throws and assertion from grid_layer.h) (output at the end). When not connecting 'input' to 'layer_1', everything works fine. It looks like it does not like to connect a layer to more than one target layer.
Thanks a lot in advance!
import nest
pos = nest.spatial.grid(shape = [3,3] ) input = nest.Create('iaf_psc_alpha', positions=pos)
layer_0 = nest.Create('iaf_psc_alpha', positions=pos) layer_1 = nest.Create('iaf_psc_alpha', positions=pos)
conn_neur = {'rule':'pairwise_bernoulli', 'use_on_source': True, 'mask': {'grid':{'shape':[3,3]}} }
nest.Connect(input, layer_0, conn_neur) nest.Connect(input, layer_1, conn_neur)
nest.DumpLayerConnections(input, layer_0, 'static_synapse', 'conn.txt')
The output message is:
python3: /home/neurobit/src/nest_3.3_src/nestkernel/grid_layer.h:223: nest::Position<D> nest::GridLayer<D>::lid_to_position(nest::index) const [with int D = 2; nest::index = long unsigned int]: Assertion `lid < dims_[ 0 ]' failed. [dcccluster:326996] *** Process received signal *** [dcccluster:326996] Signal: Aborted (6) [dcccluster:326996] Signal code: (-6) [dcccluster:326996] [ 0] /lib64/libpthread.so.0(+0x12c20)[0x7fb317ec0c20] [dcccluster:326996] [ 1] /lib64/libc.so.6(gsignal+0x10f)[0x7fb31739637f] [dcccluster:326996] [ 2] /lib64/libc.so.6(abort+0x127)[0x7fb317380db5] [dcccluster:326996] [ 3] /lib64/libc.so.6(+0x21c89)[0x7fb317380c89] [dcccluster:326996] [ 4] /lib64/libc.so.6(+0x2fa76)[0x7fb31738ea76] [dcccluster:326996] [ 5] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(+0x1d7783)[0x7fb2fcbf7783] [dcccluster:326996] [ 6] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZNK4nest9GridLayerILi2EE12get_positionEm+0xa)[0x7fb2fcbf779a] [dcccluster:326996] [ 7] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZN4nest5LayerILi2EE16dump_connectionsERSoSt10shared_ptrINS_14NodeCollectionEES3_INS_13AbstractLayerEERK5Token+0x525)[0x7fb2fcbfca75] [dcccluster:326996] [ 8] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZN4nest22dump_layer_connectionsERK5TokenSt10shared_ptrINS_14NodeCollectionEES5_R12lockPTRDatumISoXadL_ZN14SLIInterpreter11OstreamtypeEEEE+0x35c)[0x7fb2fcc1530c] [dcccluster:326996] [ 9] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZNK4nest10NestModule37DumpLayerConnections_os_g_g_lFunction7executeEP14SLIInterpreter+0xfc)[0x7fb2fcb491dc] [dcccluster:326996] [10] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN13FunctionDatum7executeEP14SLIInterpreter+0x2b)[0x7fb2f7c0975b] [dcccluster:326996] [11] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN14SLIInterpreter8execute_Em+0x1b2)[0x7fb2f7c06b32] [dcccluster:326996] [12] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN14SLIInterpreter7executeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0x1ea)[0x7fb2f7c06e7a] [dcccluster:326996] [13] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/pynestkernel.so(+0x38669)[0x7fb2ff200669] [dcccluster:326996] [14] /lib64/libpython3.8.so.1.0(+0x173db8)[0x7fb31846adb8] [dcccluster:326996] [15] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x976)[0x7fb3184d8406] [dcccluster:326996] [16] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x1bf)[0x7fb3184967af] [dcccluster:326996] [17] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x5da)[0x7fb3184d806a] [dcccluster:326996] [18] /lib64/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x3e7)[0x7fb3184953c7] [dcccluster:326996] [19] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x422)[0x7fb318496a12] [dcccluster:326996] [20] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x5da)[0x7fb3184d806a] [dcccluster:326996] [21] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x1bf)[0x7fb3184967af] [dcccluster:326996] [22] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x54d9)[0x7fb3184dcf69] [dcccluster:326996] [23] /lib64/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x3e7)[0x7fb3184953c7] [dcccluster:326996] [24] /lib64/libpython3.8.so.1.0(PyEval_EvalCode+0x23)[0x7fb3184965a3] [dcccluster:326996] [25] /lib64/libpython3.8.so.1.0(+0x22b09a)[0x7fb31852209a] [dcccluster:326996] [26] /lib64/libpython3.8.so.1.0(+0x250fa2)[0x7fb318547fa2] [dcccluster:326996] [27] /lib64/libpython3.8.so.1.0(+0x10312c)[0x7fb3183fa12c] [dcccluster:326996] [28] /lib64/libpython3.8.so.1.0(PyRun_SimpleFileExFlags+0x369)[0x7fb318400fe3] [dcccluster:326996] [29] /lib64/libpython3.8.so.1.0(Py_RunMain+0x2ef)[0x7fb318549b6f] [dcccluster:326996] *** End of error message ***
Hi Xavier,
The code runs fine for me with NEST 3.3, and I have not been able to reproduce the error. Could you provide some more details about the environment you use? For example, is NEST installed from a pre-built package or from source? With or without MPI? Which OS / system? Etc.
Best, Nicolai ________________________________ From: Xavier Otazu xotazu@cvc.uab.cat Sent: 26 February 2023 19:23 To: users@nest-simulator.org users@nest-simulator.org Subject: [NEST Users] Coredump with DumpLayerConnections
[Some people who received this message don't often get email from xotazu@cvc.uab.cat. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Hello,
For the following code, I receive a coredump (it throws and assertion from grid_layer.h) (output at the end). When not connecting 'input' to 'layer_1', everything works fine. It looks like it does not like to connect a layer to more than one target layer.
Thanks a lot in advance!
import nest
pos = nest.spatial.grid(shape = [3,3] ) input = nest.Create('iaf_psc_alpha', positions=pos)
layer_0 = nest.Create('iaf_psc_alpha', positions=pos) layer_1 = nest.Create('iaf_psc_alpha', positions=pos)
conn_neur = {'rule':'pairwise_bernoulli', 'use_on_source': True, 'mask': {'grid':{'shape':[3,3]}} }
nest.Connect(input, layer_0, conn_neur) nest.Connect(input, layer_1, conn_neur)
nest.DumpLayerConnections(input, layer_0, 'static_synapse', 'conn.txt')
The output message is:
python3: /home/neurobit/src/nest_3.3_src/nestkernel/grid_layer.h:223: nest::Position<D> nest::GridLayer<D>::lid_to_position(nest::index) const [with int D = 2; nest::index = long unsigned int]: Assertion `lid < dims_[ 0 ]' failed. [dcccluster:326996] *** Process received signal *** [dcccluster:326996] Signal: Aborted (6) [dcccluster:326996] Signal code: (-6) [dcccluster:326996] [ 0] /lib64/libpthread.so.0(+0x12c20)[0x7fb317ec0c20] [dcccluster:326996] [ 1] /lib64/libc.so.6(gsignal+0x10f)[0x7fb31739637f] [dcccluster:326996] [ 2] /lib64/libc.so.6(abort+0x127)[0x7fb317380db5] [dcccluster:326996] [ 3] /lib64/libc.so.6(+0x21c89)[0x7fb317380c89] [dcccluster:326996] [ 4] /lib64/libc.so.6(+0x2fa76)[0x7fb31738ea76] [dcccluster:326996] [ 5] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(+0x1d7783)[0x7fb2fcbf7783] [dcccluster:326996] [ 6] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZNK4nest9GridLayerILi2EE12get_positionEm+0xa)[0x7fb2fcbf779a] [dcccluster:326996] [ 7] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZN4nest5LayerILi2EE16dump_connectionsERSoSt10shared_ptrINS_14NodeCollectionEES3_INS_13AbstractLayerEERK5Token+0x525)[0x7fb2fcbfca75] [dcccluster:326996] [ 8] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZN4nest22dump_layer_connectionsERK5TokenSt10shared_ptrINS_14NodeCollectionEES5_R12lockPTRDatumISoXadL_ZN14SLIInterpreter11OstreamtypeEEEE+0x35c)[0x7fb2fcc1530c] [dcccluster:326996] [ 9] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libnestkernel.so(_ZNK4nest10NestModule37DumpLayerConnections_os_g_g_lFunction7executeEP14SLIInterpreter+0xfc)[0x7fb2fcb491dc] [dcccluster:326996] [10] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN13FunctionDatum7executeEP14SLIInterpreter+0x2b)[0x7fb2f7c0975b] [dcccluster:326996] [11] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN14SLIInterpreter8execute_Em+0x1b2)[0x7fb2f7c06b32] [dcccluster:326996] [12] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/../../../nest/libsli.so(_ZN14SLIInterpreter7executeERKNSt7__cxx1112basic_stringIcSt11char_traitsIcESaIcEEE+0x1ea)[0x7fb2f7c06e7a] [dcccluster:326996] [13] /home/neurobit/local/nest_3.3/lib64/python3.8/site-packages/nest/pynestkernel.so(+0x38669)[0x7fb2ff200669] [dcccluster:326996] [14] /lib64/libpython3.8.so.1.0(+0x173db8)[0x7fb31846adb8] [dcccluster:326996] [15] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x976)[0x7fb3184d8406] [dcccluster:326996] [16] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x1bf)[0x7fb3184967af] [dcccluster:326996] [17] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x5da)[0x7fb3184d806a] [dcccluster:326996] [18] /lib64/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x3e7)[0x7fb3184953c7] [dcccluster:326996] [19] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x422)[0x7fb318496a12] [dcccluster:326996] [20] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x5da)[0x7fb3184d806a] [dcccluster:326996] [21] /lib64/libpython3.8.so.1.0(_PyFunction_Vectorcall+0x1bf)[0x7fb3184967af] [dcccluster:326996] [22] /lib64/libpython3.8.so.1.0(_PyEval_EvalFrameDefault+0x54d9)[0x7fb3184dcf69] [dcccluster:326996] [23] /lib64/libpython3.8.so.1.0(_PyEval_EvalCodeWithName+0x3e7)[0x7fb3184953c7] [dcccluster:326996] [24] /lib64/libpython3.8.so.1.0(PyEval_EvalCode+0x23)[0x7fb3184965a3] [dcccluster:326996] [25] /lib64/libpython3.8.so.1.0(+0x22b09a)[0x7fb31852209a] [dcccluster:326996] [26] /lib64/libpython3.8.so.1.0(+0x250fa2)[0x7fb318547fa2] [dcccluster:326996] [27] /lib64/libpython3.8.so.1.0(+0x10312c)[0x7fb3183fa12c] [dcccluster:326996] [28] /lib64/libpython3.8.so.1.0(PyRun_SimpleFileExFlags+0x369)[0x7fb318400fe3] [dcccluster:326996] [29] /lib64/libpython3.8.so.1.0(Py_RunMain+0x2ef)[0x7fb318549b6f] [dcccluster:326996] *** End of error message *** _______________________________________________ NEST Users mailing list -- users@nest-simulator.org To unsubscribe send an email to users-leave@nest-simulator.org
Nicolay,
I avoid the problem by copying the synapse model to a new one. That is, the following code works fine for me. It is a bit convoluted to perform a copy and a rename for every connection.
Thanks a lot in advance!
Xavier
-----
import nest
pos = nest.spatial.grid(shape = [3,3] ) input = nest.Create('iaf_psc_alpha', positions=pos)
layer_0 = nest.Create('iaf_psc_alpha', positions=pos) layer_1 = nest.Create('iaf_psc_alpha', positions=pos)
conn_neur = {'rule':'pairwise_bernoulli', 'use_on_source': True, 'mask': {'grid':{'shape':[3,3]}} }
nest.CopyModel('static_synapse', 'syn_1_model') syn_0 = {'synapse_model': 'static_synapse'} syn_1 = {'synapse_model': 'syn_1_model'}
nest.Connect(input, layer_0, conn_neur, syn_0) nest.Connect(input, layer_1, conn_neur, syn_1)
nest.DumpLayerConnections(input, layer_0, 'static_synapse', 'conn.txt') nest.DumpLayerConnections(input, layer_1, 'syn_1_model', 'conn.txt')
Hi Xavier,
Thanks for the update, and it is great that you found a temporary workaround. I have been able to reproduce the bug but not locate it yet. I have created an issue for the bug here: https://github.com/nest/nest-simulator/issues/2629
Best, Nicolai ________________________________ From: Xavier Otazu xotazu@cvc.uab.cat Sent: 02 March 2023 12:07 To: users@nest-simulator.org users@nest-simulator.org Subject: [NEST Users] Re: Coredump with DumpLayerConnections
[You don't often get email from xotazu@cvc.uab.cat. Learn why this is important at https://aka.ms/LearnAboutSenderIdentification ]
Nicolay,
I avoid the problem by copying the synapse model to a new one. That is, the following code works fine for me. It is a bit convoluted to perform a copy and a rename for every connection.
Thanks a lot in advance!
Xavier
-----
import nest
pos = nest.spatial.grid(shape = [3,3] ) input = nest.Create('iaf_psc_alpha', positions=pos)
layer_0 = nest.Create('iaf_psc_alpha', positions=pos) layer_1 = nest.Create('iaf_psc_alpha', positions=pos)
conn_neur = {'rule':'pairwise_bernoulli', 'use_on_source': True, 'mask': {'grid':{'shape':[3,3]}} }
nest.CopyModel('static_synapse', 'syn_1_model') syn_0 = {'synapse_model': 'static_synapse'} syn_1 = {'synapse_model': 'syn_1_model'}
nest.Connect(input, layer_0, conn_neur, syn_0) nest.Connect(input, layer_1, conn_neur, syn_1)
nest.DumpLayerConnections(input, layer_0, 'static_synapse', 'conn.txt') nest.DumpLayerConnections(input, layer_1, 'syn_1_model', 'conn.txt') _______________________________________________ NEST Users mailing list -- users@nest-simulator.org To unsubscribe send an email to users-leave@nest-simulator.org
Hi Nicolay,
I've read on the github issue that it works for you in NEST 3.3 and Python 3.9 ... it is curious, because it fails for me (I am using Python 3.8). Anyway, I'll wait for the corrected 3.4 version :-)
Best,
Xavier
Hello Nicolai,
It was compiled with MPI (music and sionlib) from source. My python is 3.8.12
Xavier.