Measurement information.
This data structure behaves like a dictionary. It contains all metadata that is available for a recording. However, its keys are restricted to those provided by the FIF format specification, so new entries should not be manually added.
Warning
The only entries that should be manually changed by the user
are info['bads']
, info['description']
,
info['device_info']
, info['dev_head_t']
,
info['experimenter']
, info[‘helium_info’],
info['line_freq']
, info['temp']
and
info['subject_info']
. All other entries should be
considered read-only, though they can be modified by various
MNE-Python functions or methods (which have safeguards to
ensure all fields remain in sync).
Warning
This class should not be instantiated directly. To create a
measurement information structure, use
mne.create_info()
.
See also
Notes
The following parameters have a nested structure.
chs
list of dict:
- calfloat
The calibration factor to bring the channels to physical units. Used in product with
range
to scale the data read from disk.- ch_namestr
The channel name.
- coil_typeint
Coil type, e.g.
FIFFV_COIL_MEG
.- coord_frameint
The coordinate frame used, e.g.
FIFFV_COORD_HEAD
.- kindint
The kind of channel, e.g.
FIFFV_EEG_CH
.- locarray, shape (12,)
Channel location. For MEG this is the position plus the normal given by a 3x3 rotation matrix. For EEG this is the position followed by reference position (with 6 unused). The values are specified in device coordinates for MEG and in head coordinates for EEG channels, respectively.
- lognoint
Logical channel number, conventions in the usage of this number vary.
- rangefloat
The hardware-oriented part of the calibration factor. This should be only applied to the continuous raw data. Used in product with
cal
to scale data read from disk.- scannoint
Scanning order number, starting from 1.
- unitint
The unit to use, e.g.
FIFF_UNIT_T_M
.- unit_mulint
Unit multipliers, most commonly
FIFF_UNITM_NONE
.
comps
list of dict:
- ctfkindint
CTF compensation grade.
- colcalsndarray
Column calibrations.
- matdict
A named matrix dictionary (with entries “data”, “col_names”, etc.) containing the compensation matrix.
- rowcalsndarray
Row calibrations.
- save_calibratedbool
Were the compensation data saved in calibrated form.
device_info
dict:
- typestr
Device type.
- modelstr
Device model.
- serialstr
Device serial.
- sitestr
Device site.
dig
list of dict:
- kindint
The kind of channel, e.g.
FIFFV_POINT_EEG
,FIFFV_POINT_CARDINAL
.- rarray, shape (3,)
3D position in m. and coord_frame.
- identint
Number specifying the identity of the point. e.g.
FIFFV_POINT_NASION
if kind isFIFFV_POINT_CARDINAL
, or 42 if kind isFIFFV_POINT_EEG
.- coord_frameint
The coordinate frame used, e.g.
FIFFV_COORD_HEAD
.
events
list of dict:
- channelslist of int
Channel indices for the events.
- listndarray, shape (n_events * 3,)
Events in triplets as number of samples, before, after.
file_id
dict:
- versionint
FIF format version, i.e.
FIFFC_VERSION
.- machidndarray, shape (2,)
Unique machine ID, usually derived from the MAC address.
- secsint
Time in seconds.
- usecsint
Time in microseconds.
helium_info
dict:
- he_level_rawfloat
Helium level (%) before position correction.
- helium_levelfloat
Helium level (%) after position correction.
- orig_file_guidstr
Original file GUID.
- meas_datetuple of int
The helium level meas date.
hpi_meas
list of dict:
- creatorstr
Program that did the measurement.
- sfreqfloat
Sample rate.
- nchanint
Number of channels used.
- naveint
Number of averages used.
- ncoilint
Number of coils used.
- first_sampint
First sample used.
- last_sampint
Last sample used.
- hpi_coilslist of dict
Coils, containing:
- number: int
Coil number
- epochndarray
Buffer containing one epoch and channel.
- slopesndarray, shape (n_channels,)
HPI data.
- corr_coeffndarray, shape (n_channels,)
HPI curve fit correlations.
- coil_freqfloat
HPI coil excitation frequency
hpi_results
list of dict:
- dig_pointslist
Digitization points (see
dig
definition) for the HPI coils.- orderndarray, shape (ncoil,)
The determined digitization order.
- usedndarray, shape (nused,)
The indices of the used coils.
- momentsndarray, shape (ncoil, 3)
The coil moments.
- goodnessndarray, shape (ncoil,)
The goodness of fits.
- good_limitfloat
The goodness of fit limit.
- dist_limitfloat
The distance limit.
- acceptint
Whether or not the fit was accepted.
- coord_transinstance of Transformation
The resulting MEG<->head transformation.
hpi_subsystem
dict:
- ncoilint
The number of coils.
- event_channelstr
The event channel used to encode cHPI status (e.g., STI201).
- hpi_coilslist of ndarray
List of length
ncoil
, each 4-element ndarray contains the event bits used on the event channel to indicate cHPI status (using the first element of these arrays is typically sufficient).
mri_id
dict:
- versionint
FIF format version, i.e.
FIFFC_VERSION
.- machidndarray, shape (2,)
Unique machine ID, usually derived from the MAC address.
- secsint
Time in seconds.
- usecsint
Time in microseconds.
proc_history
list of dict:
- block_iddict
See
id
above.- datendarray, shape (2,)
2-element tuple of seconds and microseconds.
- experimenterstr
Name of the person who ran the program.
- creatorstr
Program that did the processing.
- max_infodict
Maxwel filtering info, can contain:
- sss_infodict
SSS processing information.
- max_st
tSSS processing information.
- sss_ctcdict
Cross-talk processing information.
- sss_caldict
Fine-calibration information.
- smartshielddict
MaxShield information. This dictionary is (always?) empty, but its presence implies that MaxShield was used during acquisition.
subject_info
dict:
- idint
Integer subject identifier.
- his_idstr
String subject identifier.
- last_namestr
Last name.
- first_namestr
First name.
- middle_namestr
Middle name.
- birthdaytuple of int
Birthday in (year, month, day) format.
- sexint
Subject sex (0=unknown, 1=male, 2=female).
- handint
Handedness (1=right, 2=left, 3=ambidextrous).
str
| None
MEG system acquisition parameters.
See mne.AcqParserFIF
for details.
str
| None
MEG system stimulus parameters.
list
of str
List of bad (noisy/broken) channels, by name. These channels will by default be ignored by many processing steps.
list
of str
The names of the channels.
list
of dict
A list of channel information dictionaries, one per channel. See Notes for more information.
str
Contains the command and arguments used to create the source space (used for source estimation).
list
of dict
CTF software gradient compensation data. See Notes for more information.
dict
| None
The transformation from 4D/CTF head coordinates to Neuromag head coordinates. This is only present in 4D/CTF data.
int
Whether a custom (=other than average) reference has been applied to the EEG data. This flag is checked by some algorithms that require an average reference to be set.
str
| None
String description of the recording.
dict
| None
The transformation from device coordinates to 4D/CTF head coordinates. This is only present in 4D/CTF data.
dict
| None
The device to head transformation.
dict
| None
Information about the acquisition device. See Notes for details.
New in version 0.19.
list
of dict
| None
The Polhemus digitization data in head coordinates. See Notes for more information.
list
of dict
Event list, sometimes extracted from the stim channels by Neuromag
systems. In general this should not be used and
mne.find_events()
should be used for event processing.
See Notes for more information.
str
| None
Name of the person that ran the experiment.
dict
| None
The FIF globally unique ID. See Notes for more information.
float
| None
Tilt angle of the gantry in degrees.
dict
| None
Information about the device helium. See Notes for details.
New in version 0.19.
float
Highpass corner frequency in Hertz. Zero indicates a DC recording.
list
of dict
HPI measurements that were taken at the start of the recording (e.g. coil frequencies). See Notes for details.
list
of dict
Head position indicator (HPI) digitization points and fit information (e.g., the resulting transform). See Notes for details.
dict
| None
Information about the HPI subsystem that was used (e.g., event channel used for cHPI measurements). See Notes for details.
int
Identifies the KIT system.
float
| None
Frequency of the power line in Hertz.
float
Lowpass corner frequency in Hertz. It is automatically set to half the sampling rate if there is otherwise no low-pass applied to the data.
True if active shielding (IAS) was active during recording.
datetime
The time (UTC) of the recording.
Changed in version 0.20: This is stored as a datetime
object
instead of a tuple of seconds/microseconds.
str
| None
Raw measurement file (used for source estimation).
dict
| None
The ID assigned to this measurement by the acquisition system or
during file conversion. Follows the same format as file_id
.
str
| None
File containing the MRI to head transformation (used for source estimation).
dict
| None
Transformation from MRI to head coordinates (used for source estimation).
dict
| None
MRI unique ID (used for source estimation).
int
Number of channels.
list
of dict
The MaxFilter processing history. See Notes for details.
int
| None
ID number of the project the experiment belongs to.
str
| None
Name of the project the experiment belongs to.
list
of Projection
List of SSP operators that operate on the data.
See mne.Projection
for details.
float
Sampling frequency in Hertz.
dict
| None
Information about the subject. See Notes for details.
None
Can be used to store temporary objects in an Info instance. It will not survive an I/O roundtrip.
New in version 0.24.
str
“UTC offset of related meas_date (sHH:MM).
New in version 0.19.
str
Working directory used when the source space was created (used for source estimation).
str
Layout of the Xplotter (Neuromag system only).
Methods
|
True if the dictionary has the specified key, else False. |
x.__getitem__(y) <==> x[y] |
|
|
Implement iter(self). |
|
Return len(self). |
|
|
|
Copy the instance. |
|
Create a new dictionary with keys from iterable and values set to value. |
|
Return the value for key if key is in the dictionary, else default. |
|
Get a list of channel type for each channel. |
Get a DigMontage from instance. |
|
|
|
|
|
(Re-)Normalize projection vectors after subselection. |
|
|
If key is not found, d is returned if given, otherwise KeyError is raised |
|
Remove and return a (key, value) pair as a 2-tuple. |
|
Set EEG/sEEG/ECoG/DBS/fNIRS channel positions and digitization points. |
|
Insert key with a value of default if key is not in the dictionary. |
|
Update method using __setitem__(). |
|
True if the dictionary has the specified key, else False.
x.__getitem__(y) <==> x[y]
Implement iter(self).
Return len(self).
The current gradient compensation grade.
Create a new dictionary with keys from iterable and values set to value.
Return the value for key if key is in the dictionary, else default.
Get a list of channel type for each channel.
str
| list
| slice
| None
Channels to include. Slices and lists of integers will be interpreted as
channel indices. In lists, channel type strings (e.g., ['meg',
'eeg']
) will pick channels of those types, channel name strings (e.g.,
['MEG0111', 'MEG2623']
will pick the given channels. Can also be the
string values “all” to pick all channels, or “data” to pick data
channels. None (default) will pick all channels. Note that channels in
info['bads']
will be included if their names or indices are
explicitly provided.
Whether to return only unique channel types. Default is False
.
Whether to ignore non-data channels. Default is False
.
list
The channel types.
Get a DigMontage from instance.
None
| str
| DigMontage
A montage containing channel positions. If a string or
DigMontage
is
specified, the existing channel information will be updated with the
channel positions from the montage. Valid strings are the names of the
built-in montages that ship with MNE-Python; you can list those via
mne.channels.get_builtin_montages()
.
If None
(default), the channel positions will be removed from the
Info
.
(Re-)Normalize projection vectors after subselection.
Applying projection after sub-selecting a set of channels that were originally used to compute the original projection vectors can be dangerous (e.g., if few channels remain, most power was in channels that are no longer picked, etc.). By default, mne will emit a warning when this is done.
This function will re-normalize projectors to use only the remaining channels, thus avoiding that warning. Only use this function if you’re confident that the projection vectors still adequately capture the original signal of interest.
Examples using normalize_proj
:
Computing source timecourses with an XFit-like multi-dipole model
If key is not found, d is returned if given, otherwise KeyError is raised
Remove and return a (key, value) pair as a 2-tuple.
Pairs are returned in LIFO (last-in, first-out) order. Raises KeyError if the dict is empty.
Set EEG/sEEG/ECoG/DBS/fNIRS channel positions and digitization points.
None
| str
| DigMontage
A montage containing channel positions. If a string or
DigMontage
is
specified, the existing channel information will be updated with the
channel positions from the montage. Valid strings are the names of the
built-in montages that ship with MNE-Python; you can list those via
mne.channels.get_builtin_montages()
.
If None
(default), the channel positions will be removed from the
Info
.
If True (default), channel name matching will be case sensitive.
New in version 0.20.
dict
Whether to use a lookup table to match unrecognized channel location names
to their known aliases. If True, uses the mapping in
mne.io.constants.CHANNEL_LOC_ALIASES
. If a dict
is passed, it
will be used instead, and should map from non-standard channel names to
names in the specified montage
. Default is False
.
New in version 0.23.
Can be 'raise'
(default) to raise an error, 'warn'
to emit a
warning, or 'ignore'
to ignore when channels have missing coordinates.
New in version 0.20.1.
str
| int
| None
Control verbosity of the logging output. If None
, use the default
verbosity level. See the logging documentation and
mne.verbose()
for details. Should only be passed as a keyword
argument.
See also
Notes
Warning
Only EEG/sEEG/ECoG/DBS/fNIRS channels can have their positions set using a montage. Other channel types (e.g., MEG channels) should have their positions defined properly using their data reading functions.
Examples using set_montage
:
Creating MNE-Python data structures from scratch
Insert key with a value of default if key is not in the dictionary.
Return the value for key if key is in the dictionary, else default.
mne.Info
#Getting started with mne.Report
Importing data from fNIRS devices
Working with CTF data: the Brainstorm auditory dataset
The Raw data structure: continuous data
Overview of artifact detection
Rejecting bad data spans and breaks
Repairing artifacts with regression
Background on projectors and projections
Extracting and visualizing subject head movement
Signal-space separation (SSS) and Maxwell filtering
Preprocessing functional near-infrared spectroscopy (fNIRS) data
Auto-generating Epochs metadata
EEG analysis - Event-Related Potentials (ERPs)
Frequency and time-frequency sensor analysis
Frequency-tagging: Basic analysis of an SSVEP/vSSR dataset
Source alignment and coordinate frames
Using an automated approach to coregistration
Head model and forward computation
EEG forward operator with a template MRI
How MNE uses FreeSurfer’s outputs
Source localization with equivalent current dipole (ECD) fit
Source localization with MNE, dSPM, sLORETA, and eLORETA
The role of dipole orientations in distributed source localization
Computing various MNE solutions
Source reconstruction using an LCMV beamformer
EEG source localization given electrode locations on an MRI
Brainstorm Elekta phantom dataset tutorial
4D Neuroimaging/BTi phantom dataset tutorial
Visualising statistical significance thresholds on EEG data
Non-parametric 1 sample cluster statistic on single trial power
Non-parametric between conditions cluster statistic on single trial power
Mass-univariate twoway repeated measures ANOVA on single trial power
Spatiotemporal permutation F-test on full sensor data
Permutation t-test on source data with spatio-temporal clustering
Repeated measures ANOVA on source data with spatio-temporal clustering
Locating intracranial electrode contacts
Sleep stage classification from polysomnography (PSG) data
Creating MNE-Python data structures from scratch
Corrupt known signal with point spread
How to use data in neural ensemble (NEO) format
Reading/Writing a noise covariance matrix
Generate simulated evoked data
Simulate raw data using subject anatomy
Generate simulated source data
Cortical Signal Suppression (CSS) for removal of cortical signals
Define target events based on time lag, plot evoked response
Identify EEG Electrodes Bridged by too much Gel
Transform EEG data using current source density (CSD)
Find MEG reference channel artifacts
Visualise NIRS artifact correction methods
Maxwell filter data with movement compensation
Annotate movement artifacts and reestimate dev_head_t
Shifting time-scale in evoked data
How to convert 3D electrode positions to a 2D image
Visualize channel over epochs as an image
Plotting EEG sensors on the scalp
Plotting topographic arrowmaps of evoked data
Whitening evoked data with a noise covariance
Plotting sensor layouts of MEG systems
Make figures more publication ready
Plot single trial activity, grouped by ROI and sorted by RT
Plot custom topographies for MEG sensors
Compute a cross-spectral density (CSD) matrix
Compute Power Spectral Density of inverse solution from single epochs
Compute power and phase lock in label of the source space
Compute source power spectral density (PSD) in a label
Compute source power spectral density (PSD) of VectorView and OPM data
Compute induced power in the source space with dSPM
Temporal whitening with AR model
Time-frequency on simulated data (Multitaper vs. Morlet vs. Stockwell)
Permutation F-test on sensor data with 1D cluster level
FDR correction on T-test on sensor data
Regression on continuous data (rER[P/F])
Permutation T-test on sensor data
Motor imagery decoding from EEG data using the Common Spatial Pattern (CSP)
Decoding in time-frequency space using Common Spatial Patterns (CSP)
Continuous Target Decoding with SPoC
Decoding sensor space data with generalization across time and conditions
Analysis of evoked response using ICA and PCA reduction techniques
Compute effect-matched-spatial filtering (EMS)
Linear classifier on sensor data with plot patterns and filters
Receptive Field Estimation and Prediction
Compute Spectro-Spatial Decomposition (SSD) spatial filters
Compute MNE-dSPM inverse solution on single epochs
Source localization with a custom inverse solver
Compute source power using DICS beamformer
Compute evoked ERS source power using DICS, LCMV beamformer, and dSPM
Compute a sparse inverse solution using the Gamma-MAP empirical Bayesian method
Compute sparse inverse solution with mixed norm: MxNE and irMxNE
Compute MNE inverse solution on evoked data with a mixed source space
Compute source power estimate by projecting the covariance with MNE
Computing source timecourses with an XFit-like multi-dipole model
Plot point-spread functions (PSFs) and cross-talk functions (CTFs)
Compute cross-talk functions for LCMV beamformers
Compute spatial resolution metrics in source space
Compute spatial resolution metrics to compare MEG with EEG+MEG
Compute MxNE with time-frequency sparse prior
Brainstorm raw (median nerve) dataset
Optically pumped magnetometer (OPM) data