Skip to content

Commit a17b557

Browse files
FIX: explicit in antsAI
1 parent 35c902c commit a17b557

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

nirodents/workflows/brainextraction.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -120,19 +120,20 @@ def init_rodent_brain_extraction_wf(
120120
search_factor=(2, 0.015),
121121
principal_axes=False,
122122
convergence=(10, 1e-6, 10),
123+
search_grid=(1, (1, 2, 2)),
123124
verbose=True),
124125
name='init_aff',
125126
n_procs=omp_nthreads)
126127

128+
# Tolerate missing ANTs at construction time
129+
_ants_version = Registration().version
130+
# if _ants_version and parseversion(_ants_version) >= Version('2.3.0'):
131+
# init_aff.inputs.search_grid = (1, (1, 2, 2))
132+
127133
# Initial warping of template mask to subject space
128134
warp_mask = pe.Node(ApplyTransforms(
129135
interpolation='Linear', invert_transform_flags=True), name='warp_mask')
130136

131-
# Tolerate missing ANTs at construction time
132-
_ants_version = Registration().version
133-
if _ants_version and parseversion(_ants_version) >= Version('2.3.0'):
134-
init_aff.inputs.search_grid = (1, (1, 2, 2))
135-
136137
fixed_mask_trait = 'fixed_image_mask'
137138
moving_mask_trait = 'moving_image_mask'
138139
if _ants_version and parseversion(_ants_version) >= Version('2.2.0'):

0 commit comments

Comments
 (0)