correlograms with swapped indices are not mirrored versions of each other
Maintainers usually reply within 2 days
Nobody has claimed this yet.
Assessment
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Newbie friendliness
- 45/100
Research direction
Start at the sorting_analyzer.compute("correlograms") and postprocessing.compute_correlograms entry points, then reproduce the supplied symmetry check on a saved SortingAnalyzer with SpikeInterface 0.104.0. Inspect how CCG events are assigned to bins and compare swapped-index results. Done means the documented mirrored relationship holds, or the documentation accurately describes the observed behavior.
Written by the indexing model from the issue text.
Description
For correlograms computed with either sorting_analyzer.compute("correlograms") or postprocessing.compute_correlograms, correlograms[i, j, :] != correlograms[j, i, ::-1]. For both functions, ccgs were recomputed on saved SortingAnalyzers with SpikeInterface 0.104.0.
I assume this is some sort of artifact of how ccg events are assigned to bins, but the documentation for the compute_correlograms function says that the equality should be satisfied. I used the code below to test both functions with 4 different recordings, for all recordings 90+% of cross-correlograms were not perfect mirrors.
count = 0
max_diff = 0
max_diff_inds = None
for i in range(correlograms.shape[0]):
for j in range(i, correlograms.shape[0]):
if not (np.array_equal(correlograms[i, j],correlograms[j, i, ::-1])):
print(i, j, np.abs(correlograms[i, j] - correlograms[j, i, ::-1]).max())
count += 1
if max_diff < np.abs(correlograms[i, j] - correlograms[j, i, ::-1]).max():
max_diff_inds = (i, j)
max_diff = np.abs(correlograms[i, j] - correlograms[j, i, ::-1]).max()
print(count/(correlograms.shape[0]*(correlograms.shape[0]-1)/2))
print(max_diff, max_diff_inds)
Most of the differences are small (1-5 maximum difference between bins across a ccg), but for some unit pairs it can be quite large (see below)
correlograms[71, 97]
correlograms[97, 71]
- Dominant language
- Python
- Stars
- 855
- Forks
- 280
- Avg merge
- 3d 7h
- Merged PRs (30d)
- 40
Getting set up
This project ships no dev container, Dockerfile or contributing guide, so setting up is up to you: start from its README, and see our first-contribution guide for the general steps.
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from SpikeInterface/spikeinterface
-
testing
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
SpikeInterface/spikeinterface#4756 ·
Maintainers usually reply within 2 days
-
enhancement
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
SpikeInterface/spikeinterface#4510 · 2 comments ·
Maintainers usually reply within 2 days
-
GatherToNpy/Zarr could pre-allocate stores when number of spike is knownPossibly taken @samuelgarcia claimed this 4 days ago. Openperformance
Difficulty 4/5 3-5 days Newbie friendliness 55/100
SpikeInterface/spikeinterface#4787 · 1 comment · 1 assignee ·
Maintainers usually reply within 2 days
-
Difficulty 4/5 3-5 days Newbie friendliness 30/100
SpikeInterface/spikeinterface#4781 · 1 comment ·
Maintainers usually reply within 2 days
-
performance sorters
Difficulty 4/5 3-5 days Newbie friendliness 30/100
SpikeInterface/spikeinterface#4777 ·
Maintainers usually reply within 2 days
All issues in SpikeInterface/spikeinterface
Similar issues
-
adr
Difficulty 2/5 1-3 hours Newbie friendliness 72/100
kristofdegrave/homeassistant-smart-charging#1607 ·
Maintainers usually reply within 1 day
-
namespace operations
Difficulty 2/5 1-3 hours Newbie friendliness 64/100
EclipseFdn/open-vsx.org#13665 ·
Maintainers usually reply within 1 day
-
doc good first issue help wanted
Difficulty 2/5 1-3 hours Newbie friendliness 68/100
collective/icalendar#1865 · 2 comments ·
Maintainers usually reply within 1 day
-
Difficulty 2/5 1-3 hours Newbie friendliness 82/100
canonical/opentelemetry-collector-operator#409 ·
Maintainers usually reply within 1 day
-
Difficulty 1/5 Under an hour Newbie friendliness 85/100
mozilla/addons-release-tests#1243 ·
Maintainers usually reply within 1 day