Version 1.14.0.dev175+g357a25258 (development) (2026-11-12)#
Dependencies#
Updated minimum for:
Optional dependency
nibabel >= 5.3
Changes made automatically by mne[bot]. (#14405)
Updated minimum for optional dependency
h5io >= 0.2.6, which fixes arbitrary code execution when reading crafted HDF5 files with functions such asmne.read_bem_solution()andmne.time_frequency.read_tfrs()(CVE-2026-120499), by Eric Larson. (#14499)
Bugfixes#
Fix bug where plotting covariance matrices created by
mne.make_ad_hoc_cov()would raise an IndexError, by new contributor Arnav Kumar and Stefan Appelhoff. (#13582)Fix
mne.Epochs.export()producing invalid EEGLAB event latencies and dummy events after epochs were dropped, by new contributor Daria Agafonova. (#14067)Fix bug where
mne.io.RawArraykept a reference to the original data array after operations like resampling or cropping, which wasted memory, by new contributor Aditya Pandey. (#14360)Fixed bug where
mne.preprocessing.infomax()withextended=Trueandreturn_n_iter=Truealways returnedmax_iter. It now reports the number of iterations it actually performed, andmne.preprocessing.ICAstores this in then_iter_attribute, by new contributor Aslan Satary Dizaji. (#14366)Fix merging of overlapping left- and right-eye events in
mne.io.read_raw_eyelink()withfind_overlaps=Truewhen the events were not already sorted by time, by new contributor Judith Schepers and Scott Huberty. (#14383)Fix bug where
mne.coreg.Coregistration.set_info()did not clear the omitted head shape points from a previous digitization, by new contributor Badri Vishal Pandey. (#14458)Fix bug where
mne.preprocessing.compute_average_dev_head_t()averaged head rotation with squared time weights instead of linear ones, by new contributor Ziqi Chen. (#14496)Fix bug in
mne.time_frequency.psd_array_multitaper()wherenormalization="full"incorrectly scaled results by1/sfreqwhenoutput="complex", by new contributor Mark Kuang. (#14497)Prevent
average="mean"andaverage="median"being used withoutput="complex"inmne.time_frequency.psd_array_welch(), which incorrectly mixes phases across segments, by new contributor Mark Kuang. (#14498)Fix bug where
mne.viz.plot_volume_source_estimates()withmode="glass_brain"always showed absolute values, by Lau Møller Andersen. (#13989)Fix
mne.time_frequency.psd_array_welch()(and Welch-methodcompute_psd) so that good data spans shorter thann_per_segno longer raisenoverlap must be less than nperseg; such spans are now analyzed with a window shrunk to the span length (with a warning that their spectral resolution is reduced) instead of being lost, by Cedric Conday. (#14003)Make docstrings resolve properly in IDEs by fully writing them out in the Python code, by Eric Larson. (#14195)
Exclude pre-existing bad channels that are not bridged from
interpolate_bridged_electrodes()interpolation, by Deepesh Sonar. (#14287)Fix reading EEGLAB
.setfiles containing MATLAB objects (e.g.,stringordatetime) with SciPy 1.18+ when pymatreader is not installed, by Eric Larson. (#14293)Fix
mne.io.Raw.export()to EDF/BDF altering channel values for data originally read from EDF/BDF files, and add adigital_rangeparameter to allow preserving the original digital range, by Daniel McCloy. (#14296)Fix bug where
mne.beamformer.make_lcmv()would create complex rather than real filters when using NumPy 2.5, by Eric Larson. (#14300)Fix bug where right-clicking a second component in
mne.preprocessing.ICA.plot_sources()raised anIndexError, by Johannes Herforth. (#14303)Fix several problems with flat surfaces in
mne.viz.Brain: 1. They could rotate incorrectly with the arrow keys ormne.viz.Brain.show_view(), 2. lose their 2D interaction mode wheninteractionwas enabled, 3. orientation/silhouette options either did nothing or caused errors 4. triangle adjacency was calculated incorrectly, by Payam Sadeghi-Shabestari. (#14308)Fix bug where
mne.filter.notch_filter()andmne.io.Raw.notch_filter()withmethod="spectrum_fit"failed to detect and remove line noise whose frequency fell between FFT bins, and subtracted a beating artifact from neighboring bins, by Eric Larson. (#14310)Fix bug where
mne.preprocessing.oversampled_temporal_projection()andmne.preprocessing.maxwell_filter()withst_overlap=Truecould fail the constant overlap-add (COLA) check when the window had an odd number of samples, and adjust non-COLA windows to the closest COLA window when SciPy 1.16+ is installed, by Eric Larson. (#14312)Fix bug with
mne.preprocessing.interpolate_bridged_electrodes()whereinst.info["bads"]was cleared and not restored when too many electrodes were bridged together and aRuntimeErrorwas raised, by Carina Forster. (#14320)Fixed a bug where
mne.Epochs.interpolate_bads()raisedIndexErrorfor fNIRS data, because the nearest-neighbour donor assignment assumed 2-D (channels, times) data, by Kalle Mäkelä. (#14323)Fix mixed-up feature and output axes in multi-output
mne.decoding.ReceptiveFieldinverse patterns, by Daria Agafonova. (#14327)Fix bug where
mne.io.read_raw_snirf()divided landmark positions by the length unit scale instead of multiplying, placing fiducials far from the head for files not in meters, by Kalle Mäkelä. (#14354)Fix bug where Artemis123 axial gradiometers were treated as magnetometers when building SSS external bases, which made the head position estimated by
mne.io.read_raw_artemis123()(add_head_trans=True) noisier, by Eric Larson. (#14358)Fix bug where hovering over a figure containing several butterfly plots, e.g. from repeated calls to
mne.Evoked.plot()ormne.time_frequency.Spectrum.plot()withaxes, redrew the entire figure once per plot on every mouse movement, by Eric Larson. (#14368)Fix
mne.read_evokeds()failing on files that store channel information in the evoked block (as written by MNE-C), by Christoph Dinh. (#14372)Fix bug where
proj="reconstruct"inmne.Evoked.plot(),mne.Evoked.plot_topomap(), andmne.Evoked.plot_joint()ignored thesphereorigin, by Eric Larson. (#14378)Fix bug in covariance algebra where SSP projections were checked against the first covariance instead of the second covariance, by Ishaan Maheshwari. (#14387)
Fix bug where
mne.scale_mri()wrote an invalidn_paramsvalue to theMRI scaling parameters.cfgfile whenscalewas a scalar, by Christian Brodbeck. (#14389)Include pupil channels in baseline correction in
Epochs, by Aditya Pandey. (#14390)Fix
mne.Label.split()dropping vertex 0 withparts="contiguous"and failing on labels without a name, by Christoph Dinh. (#14395)Fix bug where
mne.io.read_raw_eeglab()andmne.read_epochs_eeglab()raised a false warning when setting montage with EOG channels, by Stefan Appelhoff. (#14396)mne.read_epochs()andmne.Epochs.save()no longer warn about BIDS names such assub-01_task-rest_meg.fif, by Hamza Abdelhedi. (#14398)Fix bugs with
mne.gui.coregistration()where typing in the scaled subject name field entered the text in reverse, and saving a scaled subject could crash the GUI, by Eric Larson. (#14412)Fix
Calibrationto accept array-like inputs, by Ishaan Maheshwari. (#14413)Fix
mne.io.Raw.interpolate_bads()for fNIRS data copying an arbitrary channel into bad channels when channel positions are missing, by Kalle Mäkelä. (#14416)Fix bug with
mne.preprocessing.annotate_muscle_zscore()where channels inraw.info["bads"]were included in the computation of the muscle artifact scores, by Hamza Abdelhedi. (#14418)Fix MNE-Python readers for Neuralynx recordings with gaps, following changes in Neo 0.14.6 by Scott Huberty (#14423)
Handle non-UTF-8 output gracefully in
mne.utils.run_subprocess, by Ishaan Maheshwari. (#14425)Fix
split_naming="bids"sincemne.io.Raw.save()andmne.Epochs.save()putsplitafterdesc, butsplitshould come beforedesc, by Hamza Abdelhedi. (#14434)Allow passing timezone-aware non-UTC
datetime.datetimeobjects tomne.Info.set_meas_date()and automatically setinfo["utc_offset"], by Tziona NessAiver and Ishaan Maheshwari. (#14436)Fix
mne.io.Raw.crop()withreset_first_samp=Truemisaligning annotations with the data, reading wrong data from files not preloaded, and setting a wrong first_samp on concatenated raws, by Mathieu Scheltienne. (#14439)Fix bug where
mne.Epochsandmne.EpochsArrayaccepted anevent_idmapping several names to the same event code and only raised an error on data loading or indexing, they now raise at construction, by Stefan Appelhoff. (#14445)Fix
mne.preprocessing.ICA.get_sources()assigning the wrong channel names and types toadd_channelsthat are not in the order of the instance’s channels, by Stefan Appelhoff. (#14452)Fix bug in
mne.preprocessing.regress_artifact()where passingbetascaused thepicks_artifactvalue to be passed asexcludeand the defaultpicks_artifact="eog"to be used instead, by Johannes Herforth. (#14457)Fixed several issues with readers and interpolations, by Eric Larson:
mne.io.read_raw_eximia()now returns EEG and EOG data in V instead of µV (values are now 1e-6 times what they were before)mne.io.Raw.interpolate_bads()with fNIRS channels no longer clear all ofinfo["bads"]even withreset_bads=Falsereset_bads=Truenow removes only the channels that were actually interpolated frominfo["bads"]instead of all non-excluded badsmne.io.Raw.set_montage()stores EEG digitization points in channel order (with the reference first as ident 0) instead of montage order (#14461)
Use the smooth head surface packaged with MNE-Python as
fsaverage-head.fifinmne.datasets.fetch_fsaverage()(and fix it for asubjects_dirgiven as astrthat does not exist yet), and prefer<subject>-head.fifoverouter_skin.surfas the head surface inmne.viz.plot_alignment()and the coregistration GUI, by Christian Brodbeck. (#14462)Fix bugs in exact and one-tailed 1-sample permutation tests:
n_permutations="all"inmne.stats.permutation_cluster_1samp_test(),mne.stats.spatio_temporal_cluster_1samp_test(), andmne.stats.permutation_t_test()omitted one sign flip, one-tailed 1-sample cluster tests could use the identity twice instead of the global sign flip, and one-tailedmne.stats.permutation_t_test()returned two-tailed p-values. One-tailedmne.stats.permutation_t_test()p-values are now typically about half as large, and other affected p-values can shift by one permutation, by Eric Larson and Cora Kim. (#14482)Avoid duplicate extension when saving source estimates with hemisphere tags, and support
ftype='auto'to infer format inmne.SourceEstimate.save()andmne.VolSourceEstimate.save(), by Shresth Keshari and Ishaan Maheshwari. (#14491)Fix
mne.transforms.rot_to_quat()returning wrong quaternions for some rotations near 180°, which made some MEG sensors appear rotated incorrectly in 3D plots, by Eric Larson. (#14492)Reduce memory consumption and improve execution speed in
mne.stats.permutation_t_test()by chunking permutation evaluations, by Ishaan Maheshwari. (#14494)Fix bug where saving annotations with
orig_time=Noneto CSV files corruptedorig_timeand shiftedonsetwhen loaded withmne.read_annotations(), by Ishaan Maheshwari. (#14503)Fix reading BrainVision files whose
[Comment]section contains aChannelstable without filter columns, by Clemens Brunner. (#14512)Fix
mne.io.read_raw_brainvision()classifying channels as misc when their unit is written with a Greek mu (μV), by Clemens Brunner. (#14513)
API changes by deprecation#
mne.datasets.lite_data.data_path()is deprecated and will be removed in MNE 1.15; the documentation build now serves the browser notebooks from the regular datasets, by Eric Larson. (#14157)
New features#
Add new API for cluster permutation statistics of sensor data:
mne.stats.cluster_test(), see the tutorial Group-level cluster permutation testing with formula contrasts, by Carina Forster, Sophie Herbst, new contributor Maximilien Chaumon, and Scott Huberty. (#12663)Speed up
mne.baseline.rescale()when channelpicksare specified by computing baseline statistics only on the selected channels, by new contributor Ishaan Maheshwari. (#14377)Show rejection and flat thresholds in
mne.Report.add_epochs(), by new contributor Sruthi Sureshkumar. (#14448)Add
on_drop_allparameter tomne.Epochs.drop()to control behavior when all epochs are dropped, by Shruti Bhale and Stefan Appelhoff. (#13556)Add
mne.setup_subcortical_source_space()to build aSourceSpacesfrom a triangulated surface mesh of a subcortical or cerebellar structure, either from alabelor externally-produced meshsurface, by Payam Sadeghi-Shabestari. (#14130)Add an “Open in JupyterLite” badge to the tutorials and examples that can run in the browser, by Natneal B. (#14157)
The
mne.viz.Braintrace list now shows picked labels with a short name, their number of source vertices, and the extraction mode, and the traces plot now rescales its y-axis whenever a new trace is picked, by Payam Sadeghi-Shabestari. (#14270)mne.viz.Brainnow offers'flat'surf option for subjects that have the required patch files, by Payam Sadeghi-Shabestari. (#14308)Add
set_head_sphere()method toRaw,EpochsandEvokedto store the head sphere in the.infodictionary instead of having to specify thesphereparameter for every figure that draws some form of topomap, by Marijn van Vliet (#14313)Add parameter
source_covformne.minimum_norm.make_inverse_operator(), allowing use of a custom (diagonal) source covariance matrix for the inverse solution, by Teemu Taivainen. (#14315)IDEs that display docstrings through static analysis (e.g., VS Code) now show complete docstrings for MNE-Python functions, methods, and classes, by Eric Larson. (#14316)
Add Array API support to
mne.decoding.ReceptiveFieldwith compatible scikit-learn estimators, preserving the input backend for predictions, scores, and patterns, by Daria Agafonova. (#14327)Exporting 2 GB or more of data to EEGLAB with
mne.export.export_raw()ormne.export.export_epochs()now uses the MATLAB v7.3 (HDF5) format (requires eeglabio >= 0.1.4 and h5py), by Eric Larson. (#14338)Add a
themeparameter tomne.gui.coregistration(), and use a dark default 3D background with readable dock titles, legend, and orientation axes, by Payam Sadeghi-Shabestari. (#14353)Speed up
mne.preprocessing.maxwell_filter()with head movement compensation by avoiding repeated computations when computing the SSS basis, by Eric Larson. (#14358)Add timing metadata to GIFTI files written by
mne.SourceEstimate.save_as_surface(), allowing readers to recover the original time axis, by Peter Molfese. (#14361)Add
selectableparameter tomne.time_frequency.Spectrum.plot()andmne.time_frequency.EpochsSpectrum.plot()to disable interactive features, by Eric Larson. (#14368)mne.preprocessing.ICAgained aconverged_attribute recording whether the decomposition converged or stopped atmax_iter, for all four backends. It is written to and read from-ica.fiffiles, so a truncated decomposition can be identified after the fact rather than only from a warning at fit time.mne.preprocessing.infomax()gained a matchingreturn_convergedparameter, by Aslan Satary Dizaji. (#14370)Add
mne.channels.DigMontage.drop_channels()to drop channels from a montage, by Stefan Appelhoff. (#14397)Add a toolbar (screenshot, show/hide controls, help) with keyboard shortcuts to
mne.gui.coregistration(), and show ICP fitting progress with a button (or Esc) to stop the fit early, by Payam Sadeghi-Shabestari. (#14412)Add component pagination and temporal sampling sliders for ICA source timecourses in
mne.Report.add_ica(), by Stefan Appelhoff. (#14422)Add support for higher-resolution image exports via a
scaleparameter inmne.viz.Brain.screenshot()andmne.viz.Brain.save_image(), by Ishaan Maheshwari. (#14447)Add
mne.channels.compute_interpolation_data()and support for passing precomputed interpolation data ininterpolate_bads(),interpolate_bads(), andinterpolate_bads(), by Ishaan Maheshwari. (#14455)Store parent-surface vertex numbers in the GIFTI files written by
mne.SourceEstimate.save_as_surface(), which now raises an error instead of writing misaligned data when the source estimate and source space vertices differ, by Peter Molfese. (#14510)Add support for binary file-like objects (such as
io.BytesIO) inmne.io.BaseRaw.save(), by Bruno Aristimunha. (#14516)Speed up
mne.Annotations.copy(),mne.Annotations.crop(), andmne.io.Raw.set_annotations()by about 10x for thousands of annotations, by Eric Larson. (#14518)Add support for continuous data segmentation in
mne.time_frequency.psd_array_multitaper()andmne.io.Raw.compute_psd()vian_per_seg,n_overlap, andaverageparameters, by Ishaan Maheshwari. (#14519)
Other changes#
Added a relevant reference to Frequency and time-frequency sensor analysis, by new contributor Isaac Kinley. (#14304)
Optimize time slicing order in
mne.Epochs.get_data()to avoid temporary full-array copies when subsetting, by new contributor Ishaan Maheshwari. (#14384)Optimize multidimensional indexing in
mne.Epochs.get_data()to eliminate intermediate 3D array allocations when subsetting both epochs and channels, by new contributor Ishaan Maheshwari. (#14391)Optimize multidimensional indexing in
mne.time_frequency.Spectrum.get_data()andmne.time_frequency.EpochsTFR.get_data()to eliminate intermediate array allocations, by new contributor Ishaan Maheshwari. (#14402)Fixed a typo in the filtering background tutorial, by new contributor Xuzhou Qin. (#14487)
Clarify the layout of the MEG coil orientation matrix in
info["chs"][i]["loc"]for multi-axis OPMs inmne.Info, by new contributor Thais Marchetti. (#14522)Add the setup cell that installs MNE into the browser kernel for the JupyterLite documentation, by Natneal B. (#14150)
Several usability improvements to
mne.gui.coregistration(): icons on more action buttons and polished tooltip text, a color-coded fit-quality indicator next to the HSP/MRI distance summary, by Payam Sadeghi-Shabestari. (#14285)Lock the JupyterLite browser kernel’s extra packages at build time instead of installing them from the first notebook cell, by Teon Brooks. (#14314)
Name the offending channels in warnings from
mne.preprocessing.nirs.optical_density()andmne.preprocessing.nirs.temporal_derivative_distribution_repair(), by Kalle Mäkelä. (#14326)Move the interactive time-viewer code of
mne.viz.Braininto a separate private module by Payam Sadeghi-Shabestari. (#14359)Vectorize blink interval masking in
mne.preprocessing.eyetracking.interpolate_blinks(), by Ishaan Maheshwari. (#14406)Document how
mne.preprocessing.annotate_muscle_zscore()combines channels into its score and why artifacts on only a few channels can be missed, by Hamza Abdelhedi. (#14419)Accelerate Morlet cross-spectral density calculation across channel pairs in
mne.time_frequency.csd_morlet()andmne.time_frequency.csd_array_morlet()via batched matrix multiplication, by Ishaan Maheshwari. (#14449)Accelerate electrical distance computation in
mne.preprocessing.compute_bridged_electrodes()via vectorized sample covariance, by Ishaan Maheshwari. (#14451)