Compute fine calibration from empty-room data.
Raw
The raw data to use. Should be from an empty-room recording, and all channels should be good.
int
Can be 1 or 3 (default), indicating the number of gradiometer imbalance components. Only used if gradiometers are present.
float
Time window to use for surface normal rotation in seconds. Default is 10.
int
Order of external component of spherical expansion.
Default is 2, which is lower than the default (3) for
mne.preprocessing.maxwell_filter()
because it tends to yield
more stable parameter estimates.
str
Origin of internal and external multipolar moment space in meters.
The default is 'auto'
, which means (0., 0., 0.)
when
coord_frame='meg'
, and a head-digitization-based
origin fit using fit_sphere_to_headshape()
when coord_frame='head'
. If automatic fitting fails (e.g., due
to having too few digitization points),
consider separately calling the fitting function with different
options or specifying the origin manually.
str
| None
Path to the FIF file with cross-talk correction information.
dict
| None
Dictionary with existing calibration. If provided, the magnetometer imbalances and adjusted normals will be used and only the gradiometer imbalances will be estimated (see step 2 in Notes below).
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
This algorithm proceeds in two steps, both optimizing the fit between the data and a reconstruction of the data based only on an external multipole expansion:
Estimate magnetometer normal directions and scale factors. All coils (mag and matching grad) are rotated by the adjusted normal direction.
Estimate gradiometer imbalance factors. These add point magnetometers
in just the gradiometer difference direction or in all three directions
(depending on n_imbalance
).
Magnetometer normal and coefficient estimation (1) is typically the most
time consuming step. Gradiometer imbalance parameters (2) can be
iteratively reestimated (for example, first using n_imbalance=1
then
subsequently n_imbalance=3
) by passing the previous calibration
output to the calibration
input in the second call.
MaxFilter processes at most 120 seconds of data, so consider cropping
your raw instance prior to processing. It also checks to make sure that
there were some minimal usable count
number of segments (default 5)
that were included in the estimate.
New in version 0.21.