mne-tools / mne-tools/mne-python
ENH: sEEG and ECoG sensor sizes are too large by default, should be configurable
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 3.5k
- Forks
- 1.6k
- Avg merge
- 1d 6h
- Merged PRs (30d)
- 100
Description
Describe the new feature or enhancement
The mne.viz.Brain functionality has improved a lot lately, and I have a request to make it even better. The current size of the sensors when you use brain.add_sensors() to an ECoG or sEEG visualization is quite a bit bigger than the actual sensors are in reality, which I think actually makes it difficult to appreciate where they are in space and makes them overlap in a way that is not aesthetically pleasing. I have two suggestions, one really easy, and one maybe more complex.
- I would like to suggest an overall change to the global default size for sEEG and ECoG electrodes in this visualization.
- I suggest another keyword argument to
brain.add_sensors()that would allow for adjusting the electrode size on an individual basis instead of the whole montage. This can be a nice way of showing visually the size of different effects on each electrode (for example, make the electrode bigger if it's response is larger).
Describe your proposed implementation
-
For 1, I propose to change the default size in
defaults.py* -- fordefaults['coreg']['ecog_scale']and['seeg_scale']I suggest2e-3instead of5e-3. Typically ECoG electrodes might be anywhere from 1-2.5 mm in diameter, and sEEG electrodes closer to 0.8-1mm. The spacing between contacts can vary between a few millimeters to a centimeter, so the scale of5e-3(5mm) often will make them overlap for a denser montage. I've already made this change in my own fork. -
For 2, I would add something to
add_sensors(), but I want to make sure it wouldn't break anything else, so I'm open to alternatives.
Picture attached of what the new (smaller) size looks like:
Describe possible alternatives
N/A
Additional context
No response
Contributor guide
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.
Research direction
Start in defaults.py with the coreg ecog_scale and seeg_scale settings, then inspect mne.viz.Brain.add_sensors() to understand how electrode size is currently applied. Compare the requested global defaults with the proposed per-electrode adjustment and define completion as configurable, non-overlapping ECoG and sEEG sensor sizing without breaking existing usage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- python
- Domain
- data-visualization
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100