DataSinkto store results in subfolders named after
subject_id? This gives some hint, but no example.
ants.WarpImageMultiTransform()interface. The problem I'm having is that one of the input fields of this interface is supposed to be composed of multiple files (
in_fieldsinput) but as soon as I run the pipeline I get an
TypeError: unhashable type: 'list'error. How can I avoid this? Thank you so much for your help!
ants.WarpImageMultiTransform()has two mandatory inputs:
transformation_series. The first should an image (e.g., a structural or a functional) and the second a list of files representing the transformation files.
transformation_seriesand I'm using it to apply some transformations that I already have obtained from the generation of an ants template to a functional image. The problem is that to transform correctly the image I have to provide two inputs in the
transformation_seriesinput (an affine and a warp) but when I provide a list as input the workflow won't run because of the error mentioned earlier
Hello! I have a question regarding nipype - I found the c3d wrapper to be missing lots of functions such as thresholding: https://nipype.readthedocs.io/en/latest/interfaces/generated/nipype.interfaces.c3.html
Is there any way I can access all c3d functions from the nipype module? If not are there any plans to add this? Thank you!
error: ----> preproc.connect(getthresh, ('out_stat', getthreshop), threshold, 'op_string')
NameError: name 'threshold' is not defined
could you please help me out to fix the issue.
I'm working on skull stripping of brain MRI dicom images.
The following program :
from nipype.interfaces import fsl
from nilearn.plotting import plot_anat
import numpy as np
import matplotlib.pyplot as plt
def bet(in_file, frac = 0.40, robust = True):
skullstrip = fsl.BET()
in_file = in_file
skullstrip.inputs.in_file = os.path.abspath(in_file)
skullstrip.inputs.out_file = os.path.abspath(
skullstrip.inputs.frac = frac
skullstrip.inputs.robust = robust
anat_head = 'flair.nii.gz'
fracs = np.arange(0.3,0.75,0.05)
for frac in fracs:
skullstrip = bet(anat_head,frac = round(frac,2),)
getting following error :
Traceback (most recent call last):
File "fsl_bet.py", line 61, in <module>
File "/anaconda3/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 397, in run
runtime = self._run_interface(runtime)
File "/anaconda3/lib/python3.7/site-packages/nipype/interfaces/fsl/preprocess.py", line 162, in _run_interface
runtime = super(BET, self)._run_interface(runtime)
File "/anaconda3/lib/python3.7/site-packages/nipype/interfaces/base/core.py", line 781, in _run_interface
% (executable_name, runtime.hostname)
OSError: No command "bet" found on host divya-HP-ProBook-440-G3. Please check that the corresponding package is installed.
which betin the terminal that you are running the code in.