Skip to content

Conversation

@ilkilic
Copy link
Collaborator

@ilkilic ilkilic commented Jan 21, 2026

This PR fixes missing PSPs in MPI runs. Previously, it only created real synaptic connections when the presynaptic neuron was instantiated on the same rank, so cross-rank presynaptic sources were silently left unconnected and produced no PSPs. The fix uses ParallelContext gid-based wiring across ranks and adds a global gid mapping to support multi-pop circuits.

@codecov
Copy link

codecov bot commented Jan 21, 2026

Codecov Report

❌ Patch coverage is 92.64706% with 15 lines in your changes missing coverage. Please review.

Files with missing lines Patch % Lines
bluecellulab/circuit_simulation.py 78.33% 13 Missing ⚠️
bluecellulab/reports/writers/compartment.py 66.66% 1 Missing ⚠️
tests/test_circuit_simulation_mpi.py 99.01% 1 Missing ⚠️
Files with missing lines Coverage Δ
bluecellulab/connection.py 98.36% <100.00%> (+0.11%) ⬆️
bluecellulab/reports/manager.py 95.23% <100.00%> (ø)
bluecellulab/simulation/simulation.py 56.32% <ø> (-0.35%) ⬇️
tests/test_connection.py 100.00% <100.00%> (ø)
bluecellulab/reports/writers/compartment.py 86.02% <66.66%> (-0.80%) ⬇️
tests/test_circuit_simulation_mpi.py 99.01% <99.01%> (ø)
bluecellulab/circuit_simulation.py 85.71% <78.33%> (-0.88%) ⬇️

... and 1 file with indirect coverage changes

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@darshanmandge
Copy link
Collaborator

Thanks, @ilkilic, for locating and fixing the bug! Have you compared the results of the reports—spikes, soma, compartment—for single-core and multicore runs? The content comparison of the H5 files should confirm if the results are consistent.

Please also compare the above reports for the same simulation config with the neurodamus reports.

Copy link
Collaborator

@AurelienJaquier AurelienJaquier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

thanks, looks good to me!

@ilkilic
Copy link
Collaborator Author

ilkilic commented Jan 22, 2026

Thanks, @ilkilic, for locating and fixing the bug! Have you compared the results of the reports—spikes, soma, compartment—for single-core and multicore runs? The content comparison of the H5 files should confirm if the results are consistent.

Please also compare the above reports for the same simulation config with the neurodamus reports.

Yes, I compared spikes/soma/compartment reports for single-core vs multicore and the h5 contents are identical.

I also compared against neurodamus and results are consistent, PSPs trigger in the same cells, though not 100% identical.

Copy link
Collaborator

@darshanmandge darshanmandge left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

PSPs trigger in the same cells, though not 100% identical.

Let's fix this soon in the next PR. Thanks.

@ilkilic ilkilic merged commit 01955bb into main Jan 22, 2026
7 of 8 checks passed
@ilkilic ilkilic deleted the fix-mpi-cross-rank-synapses branch January 22, 2026 16:19
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants