Skip to content

Commit b9f1c25

Browse files
committed
fix:doctests of new workflows
1 parent 41d0f19 commit b9f1c25

File tree

1 file changed

+20
-6
lines changed
  • nipype/workflows/dmri/preprocess

1 file changed

+20
-6
lines changed

nipype/workflows/dmri/preprocess/epi.py

Lines changed: 20 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,6 @@
11
# coding: utf-8
2+
# emacs: -*- mode: python; py-indent-offset: 4; indent-tabs-mode: nil -*-
3+
# vi: set ft=python sts=4 ts=4 sw=4 et:
24

35
import nipype.pipeline.engine as pe
46
import nipype.interfaces.utility as niu
@@ -41,8 +43,8 @@ def hmc_pipeline(name='motion_correct'):
4143
Example
4244
-------
4345
44-
>>> from nipype.workflows.dmri.fsl.epi import motion_correct
45-
>>> hmc = motion_correct()
46+
>>> from nipype.workflows.dmri.preprocess.epi import hmc_pipeline
47+
>>> hmc = hmc_pipeline()
4648
>>> hmc.inputs.inputnode.in_file = 'diffusion.nii'
4749
>>> hmc.inputs.inputnode.in_bvec = 'diffusion.bvec'
4850
>>> hmc.inputs.inputnode.in_mask = 'mask.nii'
@@ -128,15 +130,15 @@ def ecc_pipeline(name='eddy_correct'):
128130
<http://cds.ismrm.org/protected/10MProceedings/files/1644_129.pdf>`_,
129131
Proc. ISMRM 18th Annual Meeting, (2010).
130132
131-
.. [Rohde04] Rohde et al., `Comprehensive Approach for Correction of Motion and Distortion \
132-
in Diffusion-Weighted MRI \
133+
.. [Rohde04] Rohde et al., `Comprehensive Approach for Correction of Motion and Distortion
134+
in Diffusion-Weighted MRI
133135
<http://stbb.nichd.nih.gov/pdf/com_app_cor_mri04.pdf>`_, MRM 51:103-114 (2004).
134136
135137
Example
136138
-------
137139
138-
>>> from nipype.workflows.dmri.fsl.epi import eddy_correct
139-
>>> ecc = eddy_correct()
140+
>>> from nipype.workflows.dmri.preprocess.epi import ecc_pipeline
141+
>>> ecc = ecc_pipeline()
140142
>>> ecc.inputs.inputnode.in_file = 'diffusion.nii'
141143
>>> ecc.inputs.inputnode.in_bval = 'diffusion.bval'
142144
>>> ecc.inputs.inputnode.in_mask = 'mask.nii'
@@ -225,6 +227,18 @@ def sdc_fmb(name='fmb_correction',
225227
[Jenkinson03]_. Preparation of the fieldmap is performed reproducing the script in FSL
226228
`fsl_prepare_fieldmap <http://fsl.fmrib.ox.ac.uk/fsl/fslwiki/FUGUE/Guide#SIEMENS_data>`_.
227229
230+
Example
231+
-------
232+
233+
>>> from nipype.workflows.dmri.preprocess.epi import sdc_fmb
234+
>>> fmb = sdc_fmb()
235+
>>> fmb.inputs.inputnode.in_file = 'diffusion.nii'
236+
>>> fmb.inputs.inputnode.in_bval = 'diffusion.bval'
237+
>>> fmb.inputs.inputnode.in_mask = 'mask.nii'
238+
>>> fmb.inputs.inputnode.bmap_mag = 'magnitude.nii'
239+
>>> fmb.inputs.inputnode.bmap_pha = 'phase.nii'
240+
>>> fmb.run() # doctest: +SKIP
241+
228242
.. warning:: Only SIEMENS format fieldmaps are supported.
229243
230244
.. admonition:: References

0 commit comments

Comments
 (0)