Skip to content

update FSL on CircleCI, fixed tests #1243

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 7 commits into from
Oct 9, 2015
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions CHANGES
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
Next Release
============
* API: Default model level for the bedpostx workflow has been set to "2" following FSL 5.0.9 lead
* ENH: New interfaces for interacting with AWS S3: S3DataSink and S3DataGrabber (https://github.com/nipy/nipype/pull/1201)

Release 0.11.0 (September 15, 2015)
Expand Down
43 changes: 34 additions & 9 deletions circle.yml
Original file line number Diff line number Diff line change
Expand Up @@ -5,52 +5,77 @@ dependencies:
- "~/examples/feeds"
- "~/mcr"
- "~/spm12"
- "~/fsl"
- "~/examples/fsl_course_data"
override:
- pip install --upgrade pip
- pip install -e .
- pip install matplotlib sphinx ipython boto
- gem install fakes3
- if [[ ! -d ~/fsl ]]; then wget "http://fsl.fmrib.ox.ac.uk/fsldownloads/fsl-5.0.9-centos6_64.tar.gz"; tar zxvf fsl-5.0.9-centos6_64.tar.gz; mv fsl ~/fsl; fi
- if [[ ! -d ~/examples/data ]]; then wget "http://tcpdiag.dl.sourceforge.net/project/nipy/nipype/nipype-0.2/nipype-tutorial.tar.bz2"; tar jxvf nipype-tutorial.tar.bz2; mkdir ~/examples; mv nipype-tutorial/* ~/examples/; fi
# we download this manually because CircleCI does not cache apt
- if [[ ! -d ~/examples/feeds ]]; then wget "http://fsl.fmrib.ox.ac.uk/fsldownloads/fsl-5.0.8-feeds.tar.gz"; tar zxvf fsl-5.0.8-feeds.tar.gz; mv feeds ~/examples/; fi
- if [[ ! -d ~/examples/fsl_course_data ]]; then wget -c "http://fsl.fmrib.ox.ac.uk/fslcourse/fdt1.tar.gz" ; wget -c "http://fsl.fmrib.ox.ac.uk/fslcourse/fdt2.tar.gz"; wget -c "http://fsl.fmrib.ox.ac.uk/fslcourse/tbss.tar.gz"; mkdir ~/examples/fsl_course_data; tar zxvf fdt1.tar.gz -C ~/examples/fsl_course_data; tar zxvf fdt2.tar.gz -C ~/examples/fsl_course_data; tar zxvf tbss.tar.gz -C ~/examples/fsl_course_data; fi
- wget -O- http://neuro.debian.net/lists/trusty.us-nh.full | sudo tee /etc/apt/sources.list.d/neurodebian.sources.list
- sudo apt-key adv --recv-keys --keyserver hkp://pgp.mit.edu:80 0xA5D32F012649A5A9
- sudo apt-get update -y; sudo apt-get install -y fsl-core fsl-atlases
- bash ~/nipype/tools/install_spm_mcr.sh
- mkdir -p ~/.nipype && echo "[logging]" > ~/.nipype/nipype.cfg && echo "workflow_level = DEBUG" >> ~/.nipype/nipype.cfg && echo "interface_level = DEBUG" >> ~/.nipype/nipype.cfg && echo "filemanip_level = DEBUG" >> ~/.nipype/nipype.cfg
test:
override:
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && nosetests --with-doctest --logging-level=DEBUG --verbosity=3:
- nosetests --with-doctest --logging-level=DEBUG --verbosity=3:
environment:
SPMMCRCMD: "$HOME/spm12/run_spm12.sh $HOME/mcr/v85/ script"
FORCE_SPMMCR: 1
FSL_COURSE_DATA: "$HOME/examples/fsl_course_data"
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"
timeout: 2600
- set -o pipefail && cd doc && make html 2>&1 | tee ~/log.txt
- cat ~/log.txt && if grep -q "ERROR" ~/log.txt; then false; else true; fi
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && python ~/nipype/tools/run_examples.py test_spm Linear workflow3d workflow4d:
- python ~/nipype/tools/run_examples.py test_spm Linear workflow3d workflow4d:
pwd: ../examples
environment:
SPMMCRCMD: "$HOME/spm12/run_spm12.sh $HOME/mcr/v85/ script"
FORCE_SPMMCR: 1
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"
timeout: 1600
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && python ~/nipype/tools/run_examples.py fmri_fsl_feeds Linear l1pipeline:
- python ~/nipype/tools/run_examples.py fmri_fsl_feeds Linear l1pipeline:
pwd: ../examples
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && python ~/nipype/tools/run_examples.py fmri_spm_dartel Linear level1 l2pipeline:
environment:
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"
- python ~/nipype/tools/run_examples.py fmri_spm_dartel Linear level1 l2pipeline:
pwd: ../examples
environment:
SPMMCRCMD: "$HOME/spm12/run_spm12.sh $HOME/mcr/v85/ script"
FORCE_SPMMCR: 1
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"
timeout: 1600
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && python ~/nipype/tools/run_examples.py fmri_fsl_reuse Linear level1_workflow:
- python ~/nipype/tools/run_examples.py fmri_fsl_reuse Linear level1_workflow:
pwd: ../examples
- . /usr/share/fsl/5.0/etc/fslconf/fsl.sh && python ~/nipype/tools/run_examples.py fmri_spm_nested Linear level1 l2pipeline:
environment:
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"
- python ~/nipype/tools/run_examples.py fmri_spm_nested Linear level1 l2pipeline:
pwd: ../examples
environment:
SPMMCRCMD: "$HOME/spm12/run_spm12.sh $HOME/mcr/v85/ script"
FORCE_SPMMCR: 1
FSLDIR: "$HOME/fsl/"
PATH: "$HOME/fsl/bin:$PATH"
LD_LIBRARY_PATH: "$HOME/fsl/lib"
FSLOUTPUTTYPE: "NIFTI_GZ"

general:
artifacts:
Expand Down
4 changes: 2 additions & 2 deletions nipype/interfaces/fsl/dti.py
Original file line number Diff line number Diff line change
Expand Up @@ -114,7 +114,7 @@ class FSLXCommandInputSpec(FSLCommandInputSpec):
n_fibres = traits.Range(
usedefault=True, low=1, default=2, argstr='--nfibres=%d',
desc=('Maximum number of fibres to fit in each voxel'), mandatory=True)
model = traits.Enum(1, 2, argstr='--model=%d',
model = traits.Enum(1, 2, 3, argstr='--model=%d',
desc=('use monoexponential (1, default, required for '
'single-shell) or multiexponential (2, multi-'
'shell) model'))
Expand Down Expand Up @@ -246,7 +246,7 @@ class BEDPOSTX5InputSpec(FSLXCommandInputSpec):
n_fibres = traits.Range(
usedefault=True, low=1, default=2, argstr='-n %d',
desc=('Maximum number of fibres to fit in each voxel'), mandatory=True)
model = traits.Enum(1, 2, argstr='-model %d',
model = traits.Enum(1, 2, 3, argstr='-model %d',
desc=('use monoexponential (1, default, required for '
'single-shell) or multiexponential (2, multi-'
'shell) model'))
Expand Down
2 changes: 1 addition & 1 deletion nipype/workflows/dmri/fsl/dti.py
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ def transpose(samples_over_fibres):


def create_bedpostx_pipeline(name='bedpostx', params={'n_fibres':2, 'fudge':1, 'burn_in':1000,
'n_jumps':1250, 'sample_every':25, 'model':1,
'n_jumps':1250, 'sample_every':25, 'model':2,
'cnlinear':True}):
"""
Creates a pipeline that does the same as bedpostx script from FSL -
Expand Down
2 changes: 2 additions & 0 deletions nipype/workflows/dmri/fsl/tests/test_dti.py
Original file line number Diff line number Diff line change
Expand Up @@ -51,6 +51,7 @@ def test_create_bedpostx_pipeline():
nipype_bedpostx.inputs.xfibres.sample_every = 1
nipype_bedpostx.inputs.xfibres.cnlinear = True
nipype_bedpostx.inputs.xfibres.seed = 0
nipype_bedpostx.inputs.xfibres.model = 2

with warnings.catch_warnings():
warnings.simplefilter("ignore")
Expand All @@ -64,6 +65,7 @@ def test_create_bedpostx_pipeline():
original_bedpostx.inputs.n_jumps = 1
original_bedpostx.inputs.sample_every = 1
original_bedpostx.inputs.seed = 0
original_bedpostx.inputs.model = 2

test_f1 = pe.Node(util.AssertEqual(), name="mean_f1_test")

Expand Down
8 changes: 4 additions & 4 deletions nipype/workflows/dmri/fsl/tests/test_tbss.py
Original file line number Diff line number Diff line change
Expand Up @@ -120,14 +120,14 @@ def _tbss_test_helper(estimate_skeleton):
os.chdir(old_dir)
shutil.rmtree(test_dir)


#this test is disabled until we figure out what is wrong with TBSS in 5.0.9
@skipif(no_fsl)
@skipif(no_fsl_course_data)
def test_tbss_est_skeleton():
def disabled_tbss_est_skeleton():
_tbss_test_helper(True)


#this test is disabled until we figure out what is wrong with TBSS in 5.0.9
@skipif(no_fsl)
@skipif(no_fsl_course_data)
def test_tbss_est_skeleton_use_precomputed_skeleton():
def disabled_tbss_est_skeleton_use_precomputed_skeleton():
_tbss_test_helper(False)