From de1a470e888c35c095886891ca212e78bd4c45aa Mon Sep 17 00:00:00 2001 From: Yaroslav Halchenko Date: Fri, 3 Mar 2023 12:48:48 -0500 Subject: [PATCH] Log exception (as error) if we fail to obtain affine in convertall --- heudiconv/heuristics/convertall.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/heudiconv/heuristics/convertall.py b/heudiconv/heuristics/convertall.py index 6187b344..4ed125d8 100644 --- a/heudiconv/heuristics/convertall.py +++ b/heudiconv/heuristics/convertall.py @@ -1,5 +1,8 @@ +import logging import os +lgr = logging.getLogger('heudiconv') + def create_key(template, outtype=('nii.gz',), annotation_classes=None): if template is None or not template: @@ -16,6 +19,7 @@ def custom_seqinfo(series_files, wrapper, **kw): try: affine = wrapper.affine.tostring() except WrapperError: + lgr.exception("Errored out while obtaining/converting affine") affine = None return affine, series_files[0]