Skip to content

Commit 49d76df

Browse files
committed
Added copyfile=False argument for compatybility with some versions of
AFNI.
1 parent 89f1b4c commit 49d76df

25 files changed

+98
-50
lines changed

nipype/interfaces/afni/preprocess.py

Lines changed: 48 additions & 25 deletions
Original file line numberDiff line numberDiff line change
@@ -208,7 +208,8 @@ class WarpInputSpec(AFNICommandInputSpec):
208208
argstr='%s',
209209
position=-1,
210210
mandatory=True,
211-
exists=True)
211+
exists=True,
212+
copyfile=False)
212213

213214
out_file = File(name_template="%s_warp", desc='output image file name',
214215
argstr='-prefix %s', name_source="in_file")
@@ -321,7 +322,8 @@ class AutoTcorrelateInputSpec(AFNICommandInputSpec):
321322
argstr='%s',
322323
position=-1,
323324
mandatory=True,
324-
exists=True)
325+
exists=True,
326+
copyfile=False)
325327

326328
polort = traits.Int(
327329
desc='Remove polynomical trend of order m or -1 for no detrending',
@@ -377,7 +379,8 @@ class TStatInputSpec(AFNICommandInputSpec):
377379
argstr='%s',
378380
position=-1,
379381
mandatory=True,
380-
exists=True)
382+
exists=True,
383+
copyfile=False)
381384

382385
out_file = File(name_template="%s_tstat", desc='output image file name',
383386
argstr='-prefix %s', name_source="in_file")
@@ -419,7 +422,8 @@ class DetrendInputSpec(AFNICommandInputSpec):
419422
argstr='%s',
420423
position=-1,
421424
mandatory=True,
422-
exists=True)
425+
exists=True,
426+
copyfile=False)
423427

424428
out_file = File(name_template="%s_detrend", desc='output image file name',
425429
argstr='-prefix %s', name_source="in_file")
@@ -456,7 +460,8 @@ class DespikeInputSpec(AFNICommandInputSpec):
456460
argstr='%s',
457461
position=-1,
458462
mandatory=True,
459-
exists=True)
463+
exists=True,
464+
copyfile=False)
460465

461466
out_file = File(name_template="%s_despike", desc='output image file name',
462467
argstr='-prefix %s', name_source="in_file")
@@ -490,7 +495,8 @@ class AutomaskInputSpec(AFNICommandInputSpec):
490495
argstr='%s',
491496
position=-1,
492497
mandatory=True,
493-
exists=True)
498+
exists=True,
499+
copyfile=False)
494500

495501
out_file = File(name_template="%s_mask", desc='output image file name',
496502
argstr='-prefix %s', name_source="in_file")
@@ -550,7 +556,8 @@ class VolregInputSpec(AFNICommandInputSpec):
550556
argstr='%s',
551557
position=-1,
552558
mandatory=True,
553-
exists=True)
559+
exists=True,
560+
copyfile=False)
554561
out_file = File(name_template="%s_volreg", desc='output image file name',
555562
argstr='-prefix %s', name_source="in_file")
556563

@@ -614,7 +621,8 @@ class MergeInputSpec(AFNICommandInputSpec):
614621
File(desc='input file to 3dmerge', exists=True),
615622
argstr='%s',
616623
position=-1,
617-
mandatory=True)
624+
mandatory=True,
625+
copyfile=False)
618626
out_file = File(name_template="%s_merge", desc='output image file name',
619627
argstr='-prefix %s', name_source="in_file")
620628
doall = traits.Bool(desc='apply options to all sub-bricks in dataset',
@@ -653,7 +661,8 @@ class CopyInputSpec(AFNICommandInputSpec):
653661
argstr='%s',
654662
position=-2,
655663
mandatory=True,
656-
exists=True)
664+
exists=True,
665+
copyfile=False)
657666
out_file = File(name_template="%s_copy", desc='output image file name',
658667
argstr='-prefix %s', name_source="in_file")
659668

@@ -686,7 +695,8 @@ class FourierInputSpec(AFNICommandInputSpec):
686695
argstr='%s',
687696
position=-1,
688697
mandatory=True,
689-
exists=True)
698+
exists=True,
699+
copyfile=False)
690700
out_file = File(name_template="%s_fourier", desc='output image file name',
691701
argstr='-prefix %s', name_source="in_file")
692702
lowpass = traits.Float(desc='lowpass',
@@ -730,7 +740,8 @@ class BandpassInputSpec(AFNICommandInputSpec):
730740
argstr='%s',
731741
position=-1,
732742
mandatory=True,
733-
exists=True)
743+
exists=True,
744+
copyfile=False)
734745
out_file = File(
735746
name_template='%s_bp',
736747
desc='output file from 3dBandpass',
@@ -838,7 +849,8 @@ class ZCutUpInputSpec(AFNICommandInputSpec):
838849
argstr='%s',
839850
position=-1,
840851
mandatory=True,
841-
exists=True)
852+
exists=True,
853+
copyfile=False)
842854
out_file = File(name_template="%s_zcupup", desc='output image file name',
843855
argstr='-prefix %s', name_source="in_file")
844856
keep = traits.Str(desc='slice range to keep in output',
@@ -873,7 +885,8 @@ class AllineateInputSpec(AFNICommandInputSpec):
873885
argstr='-source %s',
874886
position=-1,
875887
mandatory=True,
876-
exists=True)
888+
exists=True,
889+
copyfile=False)
877890
reference = File(
878891
exists=True,
879892
argstr='-base %s',
@@ -1111,7 +1124,8 @@ class MaskaveInputSpec(AFNICommandInputSpec):
11111124
argstr='%s',
11121125
position=-2,
11131126
mandatory=True,
1114-
exists=True)
1127+
exists=True,
1128+
copyfile=False)
11151129
out_file = File(name_template="%s_maskave.1D", desc='output image file name',
11161130
keep_extension=True,
11171131
argstr="> %s", name_source="in_file", position=-1)
@@ -1155,7 +1169,8 @@ class SkullStripInputSpec(AFNICommandInputSpec):
11551169
argstr='-input %s',
11561170
position=1,
11571171
mandatory=True,
1158-
exists=True)
1172+
exists=True,
1173+
copyfile=False)
11591174
out_file = File(name_template="%s_skullstrip", desc='output image file name',
11601175
argstr='-prefix %s', name_source="in_file")
11611176

@@ -1188,7 +1203,8 @@ class TCatInputSpec(AFNICommandInputSpec):
11881203
desc='input file to 3dTcat',
11891204
argstr=' %s',
11901205
position=-1,
1191-
mandatory=True)
1206+
mandatory=True,
1207+
copyfile=False)
11921208
out_file = File(name_template="%s_tcat", desc='output image file name',
11931209
argstr='-prefix %s', name_source="in_file")
11941210
rlt = traits.Str(desc='options', argstr='-rlt%s', position=1)
@@ -1223,7 +1239,8 @@ class FimInputSpec(AFNICommandInputSpec):
12231239
argstr=' -input %s',
12241240
position=1,
12251241
mandatory=True,
1226-
exists=True)
1242+
exists=True,
1243+
copyfile=False)
12271244
out_file = File(name_template="%s_fim", desc='output image file name',
12281245
argstr='-bucket %s', name_source="in_file")
12291246
ideal_file = File(desc='ideal time series file name',
@@ -1269,12 +1286,14 @@ class TCorrelateInputSpec(AFNICommandInputSpec):
12691286
argstr=' %s',
12701287
position=-2,
12711288
mandatory=True,
1272-
exists=True)
1289+
exists=True,
1290+
copyfile=False)
12731291
yset = File(desc='input yset',
12741292
argstr=' %s',
12751293
position=-1,
12761294
mandatory=True,
1277-
exists=True)
1295+
exists=True,
1296+
copyfile=False)
12781297
out_file = File(name_template="%s_tcorr", desc='output image file name',
12791298
argstr='-prefix %s', name_source="xset")
12801299
pearson = traits.Bool(desc='Correlation is the normal' +
@@ -1316,7 +1335,8 @@ class TCorr1DInputSpec(AFNICommandInputSpec):
13161335
argstr = ' %s',
13171336
position = -2,
13181337
mandatory = True,
1319-
exists = True)
1338+
exists = True,
1339+
copyfile=False)
13201340
y_1d = File(desc = '1D time series file input',
13211341
argstr = ' %s',
13221342
position = -1,
@@ -1579,7 +1599,8 @@ class BlurInMaskInputSpec(AFNICommandInputSpec):
15791599
argstr='-input %s',
15801600
position=1,
15811601
mandatory=True,
1582-
exists=True)
1602+
exists=True,
1603+
copyfile=False)
15831604
out_file = File(name_template='%s_blur', desc='output to the file', argstr='-prefix %s',
15841605
name_source='in_file', position=-1)
15851606
mask = File(
@@ -1630,7 +1651,7 @@ class BlurInMask(AFNICommand):
16301651

16311652

16321653
class TCorrMapInputSpec(AFNICommandInputSpec):
1633-
in_file = File(exists=True, argstr='-input %s', mandatory=True)
1654+
in_file = File(exists=True, argstr='-input %s', mandatory=True, copyfile=False)
16341655
seeds = File(exists=True, argstr='-seed %s', xor=('seeds_width'))
16351656
mask = File(exists=True, argstr='-mask %s')
16361657
automask = traits.Bool(argstr='-automask')
@@ -1737,7 +1758,7 @@ def _format_arg(self, name, trait_spec, value):
17371758

17381759
class AutoboxInputSpec(AFNICommandInputSpec):
17391760
in_file = File(exists=True, mandatory=True, argstr='-input %s',
1740-
desc='input file')
1761+
desc='input file', copyfile=False)
17411762
padding = traits.Int(
17421763
argstr='-npad %d',
17431764
desc='Number of extra voxels to pad on each side of box')
@@ -1806,7 +1827,8 @@ class RetroicorInputSpec(AFNICommandInputSpec):
18061827
argstr='%s',
18071828
position=-1,
18081829
mandatory=True,
1809-
exists=True)
1830+
exists=True,
1831+
copyfile=False)
18101832
out_file = File(desc='output image file name', argstr='-prefix %s', mandatory=True, position=1)
18111833
card = File(desc='1D cardiac data file for cardiac correction',
18121834
argstr='-card %s',
@@ -1874,7 +1896,8 @@ class AFNItoNIFTIInputSpec(AFNICommandInputSpec):
18741896
argstr='%s',
18751897
position=-1,
18761898
mandatory=True,
1877-
exists=True)
1899+
exists=True,
1900+
copyfile=False)
18781901
out_file = File(name_template="%s.nii", desc='output image file name',
18791902
argstr='-prefix %s', name_source="in_file")
18801903
hash_files = False

nipype/interfaces/afni/tests/test_auto_AFNItoNIFTI.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ def test_AFNItoNIFTI_inputs():
1818
environ=dict(nohash=True,
1919
usedefault=True,
2020
),
21-
in_file=dict(position=-1,
21+
in_file=dict(copyfile=False,
2222
mandatory=True,
23+
position=-1,
2324
argstr='%s',
2425
),
2526
)

nipype/interfaces/afni/tests/test_auto_Allineate.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,8 +26,9 @@ def test_Allineate_inputs():
2626
),
2727
replacebase=dict(argstr='-replacebase',
2828
),
29-
in_file=dict(position=-1,
29+
in_file=dict(copyfile=False,
3030
mandatory=True,
31+
position=-1,
3132
argstr='-source %s',
3233
),
3334
nwarp_fixdep=dict(argstr='-nwarp_fixdep%s',

nipype/interfaces/afni/tests/test_auto_AutoTcorrelate.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,9 @@ def test_AutoTcorrelate_inputs():
2727
environ=dict(nohash=True,
2828
usedefault=True,
2929
),
30-
in_file=dict(position=-1,
30+
in_file=dict(copyfile=False,
3131
mandatory=True,
32+
position=-1,
3233
argstr='%s',
3334
),
3435
terminal_output=dict(mandatory=True,

nipype/interfaces/afni/tests/test_auto_Autobox.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,7 +19,8 @@ def test_Autobox_inputs():
1919
environ=dict(nohash=True,
2020
usedefault=True,
2121
),
22-
in_file=dict(mandatory=True,
22+
in_file=dict(copyfile=False,
23+
mandatory=True,
2324
argstr='-input %s',
2425
),
2526
no_clustering=dict(argstr='-noclust',

nipype/interfaces/afni/tests/test_auto_Automask.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,8 +28,9 @@ def test_Automask_inputs():
2828
environ=dict(nohash=True,
2929
usedefault=True,
3030
),
31-
in_file=dict(position=-1,
31+
in_file=dict(copyfile=False,
3232
mandatory=True,
33+
position=-1,
3334
argstr='%s',
3435
),
3536
)

nipype/interfaces/afni/tests/test_auto_Bandpass.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -33,8 +33,9 @@ def test_Bandpass_inputs():
3333
),
3434
notrans=dict(argstr='-notrans',
3535
),
36-
in_file=dict(position=-1,
36+
in_file=dict(copyfile=False,
3737
mandatory=True,
38+
position=-1,
3839
argstr='%s',
3940
),
4041
lowpass=dict(position=-2,

nipype/interfaces/afni/tests/test_auto_BlurInMask.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -27,8 +27,9 @@ def test_BlurInMask_inputs():
2727
environ=dict(nohash=True,
2828
usedefault=True,
2929
),
30-
in_file=dict(position=1,
30+
in_file=dict(copyfile=False,
3131
mandatory=True,
32+
position=1,
3233
argstr='-input %s',
3334
),
3435
multimask=dict(argstr='-Mmask %s',

nipype/interfaces/afni/tests/test_auto_Copy.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ def test_Copy_inputs():
1818
environ=dict(nohash=True,
1919
usedefault=True,
2020
),
21-
in_file=dict(position=-2,
21+
in_file=dict(copyfile=False,
2222
mandatory=True,
23+
position=-2,
2324
argstr='%s',
2425
),
2526
)

nipype/interfaces/afni/tests/test_auto_Despike.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,9 @@ def test_Despike_inputs():
1818
environ=dict(nohash=True,
1919
usedefault=True,
2020
),
21-
in_file=dict(position=-1,
21+
in_file=dict(copyfile=False,
2222
mandatory=True,
23+
position=-1,
2324
argstr='%s',
2425
),
2526
)

0 commit comments

Comments
 (0)