pybemobil.preproc.make_report#
- pybemobil.preproc.make_report(raw_pre_ica, raw_clean, ica, ic_labels, dipoles, residuals, trans, bad_ch_dict, *, fname_out=None, event_id=None, thresh=0.7, step_timings=None, tier2=None, pre_hook_description=None, pre_hook_source=None, ica_annots=None, raw_source=None)[source]#
Build and return an mne.Report for EEGPreprocessor outputs.
- Parameters:
- raw_pre_ica
mne.io.BaseRaw The data ICA was fitted on (every step except ICA). Used for the montage, annotations, events, and all ICA plots.
- raw_clean
mne.io.BaseRaw The fully processed recording.
- ica
mne.preprocessing.ICA The ICA of the run; an unfitted ICA (
fit_ica=False) skips the ICA sections.- ic_labels
dict ICLabel output (
"labels"and"y_pred_proba"), seecompute_ica().- dipoles
list One
mne.Dipole(orNone) per IC, seefit_dipoles_on_ica(); empty if no dipoles were fitted.- residuals
list Residual field of each dipole fit, aligned with dipoles.
- trans
mne.transforms.Transform|None Head-to-MRI transform used for the dipole fits.
- bad_ch_dict
dict Output of
get_bad_chs().- fname_out
str|Path|None The pipeline’s fname_out: used for the report title and to save figures to the
"figures"folder ofget_derivative_paths().- event_id
dict|None Event names and codes for the ERP sections;
Noneskips them.- thresh
float ICLabel threshold, shown in the ICLabel section.
- step_timings
listofdict|None Duration of each pipeline step (
"name"and"duration_s"), shown as a table.- tier2
dict|None Tier-2 streams from
MultimodalRecording(kept at native rate, not merged intoraw). Each stream is plotted as a decimated envelope with timestamp gaps shaded.- pre_hook_description
str|None Short description of what the pre-hook did, recorded in the report.
- pre_hook_source
str|None Source code of the pre-hook callable, shown in a collapsible block.
- ica_annots
mne.Annotations|None Annotations present on the data at the time ICA was fitted (i.e. after bad-channel detection and break annotation, but before ICA). Used to plot a timeline of BAD_* segments that were excluded from the ICA fit.
- raw_source
mne.io.BaseRaw|None The recording exactly as it was passed to the pipeline, before any processing (no renaming, line-noise removal, filtering or re-referencing). Its traces and PSD are shown next to
raw cleanso the effect of the full pipeline is visible. IfNone(e.g. when rebuilding a report from cached outputs and the BIDS raw cannot be found),raw_pre_icais shown instead.
- raw_pre_ica
- Returns:
- report
mne.Report The report; save it with
mne.Report.save().
- report
- Parameters:
- Return type: