From b6557088c522cf0dff3fecb42b843d6f39a14733 Mon Sep 17 00:00:00 2001 From: Dimitri Papadopoulos <3234522+DimitriPapadopoulos@users.noreply.github.com> Date: Sat, 30 Sep 2023 11:56:31 +0200 Subject: [PATCH] Avoid redefining Python builtins --- spec2nii/fileiobase.py | 4 ++-- tests/test_philips_orientation_dcm_spar_new.py | 4 ++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/spec2nii/fileiobase.py b/spec2nii/fileiobase.py index bffc93f..f867708 100644 --- a/spec2nii/fileiobase.py +++ b/spec2nii/fileiobase.py @@ -421,7 +421,7 @@ def uc_from_freqscale(scale, obs, unit='ppm'): size = len(scale) if unit in ('ppm', 'hz', 'khz'): - complex = False + cplex = False min = scale.min() max = scale.max() @@ -445,7 +445,7 @@ def uc_from_freqscale(scale, obs, unit='ppm'): mesg = f'{unit} is not a supported unit.' raise ValueError(mesg) - return unit_conversion(size, complex, sw, obs, car) + return unit_conversion(size, cplex, sw, obs, car) def open_towrite(filename, overwrite=False, mode='wb'): diff --git a/tests/test_philips_orientation_dcm_spar_new.py b/tests/test_philips_orientation_dcm_spar_new.py index e18c5c1..375050e 100644 --- a/tests/test_philips_orientation_dcm_spar_new.py +++ b/tests/test_philips_orientation_dcm_spar_new.py @@ -163,12 +163,12 @@ def run_case(case, working_dir): @pytest.mark.orientation def test_dcm_spar_orientations(tmp_path): def dcm_call(x, name): - input = base_dir / x + dcm = base_dir / x run( ['spec2nii', 'philips_dcm', '-o', tmp_path, '-f', name, - input] + dcm] ) def ss_call(x, name):