mne.channels.read_dig_montage(hsp=None, hpi=None, elp=None, point_names=None, unit=’auto’, fif=None, egi=None, transform=True, dev_head_t=False)[source]
Parameters: hsp : None | str | array, shape (n_points, 3) If str, this corresponds to the filename of the headshape points. This is typically used with the Polhemus FastSCAN system. If numpy.array, this corresponds to an array of positions of the headshape points in 3d. These points are assumed to be in the native digitizer space and will be rescaled according to the unit parameter. hpi : None | str | array, shape (n_hpi, 3) If str, this corresponds to the filename of Head Position Indicator (HPI) points. If numpy.array, this corresponds to an array of HPI points. These points are in device space, and are only necessary if computation of a dev_head_t by the DigMontage is required. elp : None | str | array, shape (n_fids + n_hpi, 3) If str, this corresponds to the filename of electrode position points. This is typically used with the Polhemus FastSCAN system. If numpy.array, this corresponds to an array of digitizer points in the same order. These points are assumed to be in the native digitizer space and will be rescaled according to the unit parameter. point_names : None | list A list of point names for elp (required if elp is defined). Typically this would be like: ('nasion', 'lpa', 'rpa', 'CHPI001', 'CHPI002', 'CHPI003')  unit : ‘auto’ | ‘m’ | ‘cm’ | ‘mm’ Unit of the digitizer files (hsp and elp). If not ‘m’, coordinates will be rescaled to ‘m’. Default is ‘auto’, which assumes ‘m’ for *.hsp and *.elp files and ‘mm’ for *.txt files, corresponding to the known Polhemus export formats. fif : str | None FIF file from which to read digitization locations. If str (filename), all other arguments are ignored. New in version 0.12. egi : str | None EGI MFF XML coordinates file from which to read digitization locations. If str (filename), all other arguments are ignored. New in version 0.14. transform : bool If True (default), points will be transformed to Neuromag space using DigMontage.transform_to_head(). The fidicuals (nasion, lpa, and rpa) must be specified. This is useful for points captured using a device that does not automatically convert points to Neuromag head coordinates (e.g., Polhemus FastSCAN). dev_head_t : bool If True, a Dev-to-Head transformation matrix will be added to the montage using DigMontage.compute_dev_head_t(). To get a proper dev_head_t, the hpi and the elp points must be in the same order. If False (default), no transformation will be added to the montage. montage : instance of DigMontage The digitizer montage.