@@ -443,7 +443,7 @@ class RealignUnwarpInputSpec(SPMCommandInputSpec):
443
443
traits .Either (ImageFileSPM (exists = True ),
444
444
traits .List (ImageFileSPM (exists = True ))),
445
445
field = 'data.scans' ,
446
- mandatory = True ,
446
+ mandatory = True ,
447
447
copyfile = True ,
448
448
desc = 'list of filenames to realign and unwarp' )
449
449
phase_map = File (
@@ -452,52 +452,52 @@ class RealignUnwarpInputSpec(SPMCommandInputSpec):
452
452
'behaviour, the same map will be used for all sessions' ,
453
453
copyfile = False )
454
454
quality = traits .Range (
455
- low = 0.0 ,
456
- high = 1.0 ,
455
+ low = 0.0 ,
456
+ high = 1.0 ,
457
457
field = 'eoptions.quality' ,
458
458
desc = '0.1 = fast, 1.0 = precise' )
459
459
fwhm = traits .Range (
460
- low = 0.0 ,
460
+ low = 0.0 ,
461
461
field = 'eoptions.fwhm' ,
462
462
desc = 'gaussian smoothing kernel width' )
463
463
separation = traits .Range (
464
- low = 0.0 ,
464
+ low = 0.0 ,
465
465
field = 'eoptions.sep' ,
466
466
desc = 'sampling separation in mm' )
467
467
register_to_mean = traits .Bool (
468
468
field = 'eoptions.rtm' ,
469
469
desc = 'Indicate whether realignment is done to the mean image' )
470
470
weight_img = File (
471
- exists = True ,
471
+ exists = True ,
472
472
field = 'eoptions.weight' ,
473
473
desc = 'filename of weighting image' )
474
474
interp = traits .Range (
475
- low = 0 ,
476
- high = 7 ,
475
+ low = 0 ,
476
+ high = 7 ,
477
477
field = 'eoptions.einterp' ,
478
478
desc = 'degree of b-spline used for interpolation' )
479
479
wrap = traits .List (
480
- traits .Int (),
481
- minlen = 3 ,
480
+ traits .Int (),
481
+ minlen = 3 ,
482
482
maxlen = 3 ,
483
483
field = 'eoptions.ewrap' ,
484
484
desc = 'Check if interpolation should wrap in [x,y,z]' )
485
485
est_basis_func = traits .List (
486
- traits .Int (),
487
- minlen = 2 ,
486
+ traits .Int (),
487
+ minlen = 2 ,
488
488
maxlen = 2 ,
489
489
field = 'uweoptions.basfcn' ,
490
490
desc = 'Number of basis functions to use for each dimension' )
491
491
est_reg_order = traits .Range (
492
- low = 0 ,
493
- high = 3 ,
492
+ low = 0 ,
493
+ high = 3 ,
494
494
field = 'uweoptions.regorder' ,
495
495
desc = ('This parameter determines how to balance the compromise between likelihood '
496
496
'maximization and smoothness maximization of the estimated field.' ))
497
497
est_reg_factor = traits .ListInt (
498
- [100000 ],
498
+ [100000 ],
499
499
field = 'uweoptions.lambda' ,
500
- minlen = 1 ,
500
+ minlen = 1 ,
501
501
maxlen = 1 ,
502
502
usedefault = True ,
503
503
desc = 'Regularisation factor. Default: 100000 (medium).' )
@@ -506,60 +506,60 @@ class RealignUnwarpInputSpec(SPMCommandInputSpec):
506
506
desc = ('Jacobian deformations. In theory a good idea to include them, '
507
507
' in practice a bad idea. Default: No.' ))
508
508
est_first_order_effects = traits .List (
509
- traits .Int (),
510
- minlen = 1 ,
509
+ traits .Int (),
510
+ minlen = 1 ,
511
511
maxlen = 6 ,
512
512
field = 'uweoptions.fot' ,
513
513
desc = 'First order effects should only depend on pitch and roll, i.e. [4 5]' )
514
514
est_second_order_effects = traits .List (
515
- traits .Int (),
516
- minlen = 1 ,
515
+ traits .Int (),
516
+ minlen = 1 ,
517
517
maxlen = 6 ,
518
518
field = 'uweoptions.sot' ,
519
519
desc = 'List of second order terms to model second derivatives of.' )
520
520
est_unwarp_fwhm = traits .Range (
521
- low = 0.0 ,
521
+ low = 0.0 ,
522
522
field = 'uweoptions.uwfwhm' ,
523
523
desc = 'gaussian smoothing kernel width for unwarp' )
524
524
est_re_est_mov_par = traits .Bool (
525
525
field = 'uweoptions.rem' ,
526
526
desc = 'Re-estimate movement parameters at each unwarping iteration.' )
527
527
est_num_of_iterations = traits .ListInt (
528
- [5 ],
528
+ [5 ],
529
529
field = 'uweoptions.noi' ,
530
- minlen = 1 ,
531
- maxlen = 1 ,
530
+ minlen = 1 ,
531
+ maxlen = 1 ,
532
532
usedefault = True ,
533
533
desc = 'Number of iterations.' )
534
534
est_taylor_expansion_point = traits .String (
535
- 'Average' ,
535
+ 'Average' ,
536
536
field = 'uweoptions.expround' ,
537
537
usedefault = True ,
538
538
desc = 'Point in position space to perform Taylor-expansion around.' )
539
539
reslice_which = traits .ListInt (
540
- [2 , 1 ],
540
+ [2 , 1 ],
541
541
field = 'uwroptions.uwwhich' ,
542
- minlen = 2 ,
543
- maxlen = 2 ,
542
+ minlen = 2 ,
543
+ maxlen = 2 ,
544
544
usedefault = True ,
545
545
desc = 'determines which images to reslice' )
546
546
reslice_interp = traits .Range (
547
- low = 0 ,
548
- high = 7 ,
547
+ low = 0 ,
548
+ high = 7 ,
549
549
field = 'uwroptions.rinterp' ,
550
550
desc = 'degree of b-spline used for interpolation' )
551
551
reslice_wrap = traits .List (
552
- traits .Int (),
553
- minlen = 3 ,
552
+ traits .Int (),
553
+ minlen = 3 ,
554
554
maxlen = 3 ,
555
555
field = 'uwroptions.wrap' ,
556
556
desc = 'Check if interpolation should wrap in [x,y,z]' )
557
557
reslice_mask = traits .Bool (
558
558
field = 'uwroptions.mask' ,
559
559
desc = 'True/False mask output image' )
560
560
out_prefix = traits .String (
561
- 'u' ,
562
- field = 'uwroptions.prefix' ,
561
+ 'u' ,
562
+ field = 'uwroptions.prefix' ,
563
563
usedefault = True ,
564
564
desc = 'realigned and unwarped output prefix' )
565
565
@@ -585,7 +585,7 @@ class RealignUnwarpOutputSpec(TraitedSpec):
585
585
586
586
class RealignUnwarp (SPMCommand ):
587
587
"""Use spm_uw_estimate for estimating within subject registration and unwarping
588
- of time series. Function accepts only one single field map. If in_files is a
588
+ of time series. Function accepts only one single field map. If in_files is a
589
589
list of files they will be treated as separate sessions but associated to the
590
590
same fieldmap.
591
591
@@ -617,7 +617,7 @@ def _format_arg(self, opt, spec, val):
617
617
keep4d = False ,
618
618
separate_sessions = True )
619
619
return super (RealignUnwarp , self )._format_arg (opt , spec , val )
620
-
620
+
621
621
622
622
def _parse_inputs (self , skip = ()):
623
623
@@ -630,7 +630,7 @@ def _parse_inputs(self, skip=()):
630
630
631
631
if isdefined (self .inputs .in_files ):
632
632
if isinstance (self .inputs .in_files , list ):
633
- data = [dict (scans = sess , pmscan = pmscan )
633
+ data = [dict (scans = sess , pmscan = pmscan )
634
634
for sess in spmdict ['data' ]['scans' ]]
635
635
else :
636
636
data = [dict (scans = spmdict ['data' ]['scans' ], pmscan = pmscan )]
0 commit comments