Skip to content

Commit

Permalink
Ensure the TR flag is capitalize as
Browse files Browse the repository at this point in the history
expected by the cli. Ensure the tr is a float even if it comes from cli.
  • Loading branch information
wasciutto committed Jul 28, 2022
1 parent c788419 commit 859869c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 3 deletions.
5 changes: 3 additions & 2 deletions clpipe/fmri_postprocess.py
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ def fmri_postprocess(config_file=None, subjects=None, target_dir=None, target_su
if task is not None:
task_string = '-task='+task
if tr is not None:
tr_string = '-tr='+tr
tr_string = '-TR='+tr
if beta_series:
beta_series_string = '-beta_series'
if processing_stream is not None:
Expand Down Expand Up @@ -203,7 +203,8 @@ def _fmri_postprocess_image(config, file, task = None, tr=None, beta_series = Fa
image_json_path = _find_json(config, file)
with open(os.path.abspath(image_json_path), "r") as json_path:
image_json = json.load(json_path)
tr = float(image_json['RepetitionTime'])
tr = image_json['RepetitionTime']
tr = float(tr)
logging.info('TR found: ' + str(tr))
image = nib.load(file)
data = image.get_fdata()
Expand Down
2 changes: 1 addition & 1 deletion setup.py
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
from setuptools import setup, find_packages

setup(name='clpipe',
version='1.5.0.4',
version='1.5.0.5',
description='clpipe: MRI processing pipeline for high performance clusters',
url='https://github.com/cohenlabUNC/clpipe',
author='Maintainer: Teague Henry, Contributor: Will Asciutto, Contributor: Deepak Melwani',
Expand Down

0 comments on commit 859869c

Please sign in to comment.