-
Notifications
You must be signed in to change notification settings - Fork 1.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
eegbci api: allow downloading multiple subjects #12918
Conversation
mne/datasets/eegbci/eegbci.py
Outdated
subjects, | ||
runs, | ||
*, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For this I'd be tempted just to live with the misnomer subject=[...]
rather than switch to subjects=[...]
but the deprecation also won't be so terrible:
def load_data(
subjects=None,
runs=None,
*,
subject=None,
...
):
if subject is not None:
subjects = subjects
warn(..., FutureWarning)
del subject
And then you'll need to ensure that subjects
and runs
are not None, i.e., the user has actually supplied values for them (raise an error if None). Then once deprecation is complete we can remove the =None
defaults safely.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looks good, thanks @sappelhoff !
* upstream/main: eegbci api: allow downloading multiple subjects (mne-tools#12918) DOC: Document Linux desktop workaround (mne-tools#12900) Allow exporting edf where a channel contains only constant values (mne-tools#12911) Autogenerate environment.yml file from pyproject.toml (mne-tools#12914)
I would be happy to receive some guidance on how to properly deprecate the
subject
parameter, the situation seems a bit tricky to me, given the mixture of positional parameters.