Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Conversation

@chrishalcrow
Copy link
Member

@chrishalcrow chrishalcrow commented Dec 31, 2025

Would close #4261

This PR allows you to remove spikes from a unit during curation by specifying the following in your curation json file:

"discard_spikes": [
    {
        "unit_id": "u10",
        "indices": [
            56,
            57,
            59,
            60
        ]
    },
    {
        "unit_id": "u14",
        "indices": [
            123,
            321
        ]
    }
]

This new feature means that the curation format gets bumped to v3!

You can discard at the same time as merging and splitting.

Tricky bit that took me ages to think through: how to apply it to an analyzer. Decided to discard spikes at the same time as splitting. During the splitting step, we re-wrangle discard spikes into another split unit (call them "discard units") and keep track of the discard unit id. Then remove the full discard units after the splitting. This allows us to use the existing splitting machinery (including splitting extension etc) for discards - nice!

We have to do merges after splitting+discarding. This is because the spike indices change after merging. To avoid wrangling spike indices (gross!) we just do discarding first.

Tests to do:

  • test curation format
  • test v2 -> v3 update
  • test actual discarding when also splitting / merging

@chrishalcrow chrishalcrow added the curation Related to curation module label Dec 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

curation Related to curation module

Projects

None yet

Development

Successfully merging this pull request may close these issues.

Add discard_spikes/clean_spikes step in a curation v3

1 participant