-
Notifications
You must be signed in to change notification settings - Fork 11
Open
Description
Source of Problem
in osl_ephys/source_recon/batch.py
line 283-288, the following code is not wrapped within the try except block:
src_report.gen_html_page(reportdir)
src_report.gen_html_data(config, outdir, subject, reportdir, extra_funcs=extra_funcs)
if error thrown from these two functions, code could end unexpectedly.
Example of unexpected code ending
This is an example where this logic could lead to unexpected behaviour:
- In source recon step, the file
lcmv-parc-raw.fif
is generated, but code was stopped by OOM / segmentation fault / SIGINT / out of disk storage before the imagefreqbands.png
could be generated; - In the following sign flipping with another python file, when running
gen_html_data
, the key"parc_freqbands_plot"
is within data.pkl (so line 117 is an True) but the png file is non-existing, leading to the following copying throwing an error at line 119 ofosl-ephys/report/source_report.py
Solution to the problem:
Wrap osl_ephys/source_recon/batch.py
line 285-288 within a new try-except block. It is not recommended to include it into the previous large try-except, as it's a html generation problem rather than failure of the pipeline.
Metadata
Metadata
Assignees
Labels
No labels