Use ProbeGroup object instead of contact_vector property#4638
Closed
alejoe91 wants to merge 31 commits into
Closed
Use ProbeGroup object instead of contact_vector property#4638alejoe91 wants to merge 31 commits into
ProbeGroup object instead of contact_vector property#4638alejoe91 wants to merge 31 commits into
Conversation
Co-authored-by: Alessio Buccino <alejoe9187@gmail.com>
chrishalcrow
reviewed
Jul 2, 2026
| return self._annotations.get("is_filtered", False) | ||
|
|
||
| def set_probe(self, probe, group_mode="auto", in_place=False): | ||
| def reset_probe(self): |
Member
There was a problem hiding this comment.
I think a reset is when you remove then add something all at once. I would prefer something like remove_probe for this.
Member
Author
|
Closing in favor of #4465 |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Replaces #4465 (as suggested by @h-mayorquin )
After SpikeInterface/probeinterface#446, we can go all in on the use of
ProbeGroupinstead ofcontact_vector, since the use case with interleaved contacts after device channel indices slicing is handled gracefully by the new_global_contact_orderarray, stored in the probegroup dictionary.Now the
recordinghas a_probegroupattribute, which is propagated as metadata. Theprobegroup.get_slicetakes care of all metadata propagation.In this refactoring, the duplicated
locationproperty has also been dropped.Note that this implementation is alternative to what is proposed in #4553 and implemented in #4548 : here we keep a
ProbeGroupobject attached to the recording, after sorting it bydevice_channel_indices, instead of adding awiringproperty. You lose the original probe contact order, but we argue that the contacts in a probegroup do not really have a "default" order, but are rather a set of contacts that become ordered when wired (see #3498).Some additional points:
Tests for aggregation/slicing
Added more tests for aggregation/slicing behavior and metadata propagation
Fixes #4545 #4546 #4547 #4549 #4553
Tests for backward compatibility
Added a test for bakward compatibility, which saves a recording to binary/zarr with v0.104.* and reloads it with the current version to check that the probegroup is reloaded correctly.