File tree Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Expand file tree Collapse file tree 1 file changed +11
-0
lines changed Original file line number Diff line number Diff line change 22
22
#
23
23
"""Nibabel-based interfaces."""
24
24
from pathlib import Path
25
+ from warnings import warn
25
26
26
27
import numpy as np
27
28
import nibabel as nb
@@ -132,10 +133,20 @@ class _BinaryDilationOutputSpec(TraitedSpec):
132
133
133
134
class BinaryDilation (SimpleInterface ):
134
135
"""Morphological binary dilation using Scipy."""
136
+ # DEPRECATED in 1.7.0
137
+ # To remove in 1.9.0
135
138
136
139
input_spec = _BinaryDilationInputSpec
137
140
output_spec = _BinaryDilationOutputSpec
138
141
142
+ def __init__ (self , from_file = None , resource_monitor = None , ** inputs ):
143
+ warn ("""\
144
+ niworkflows.interfaces.nibabel.BinaryDilation is deprecated in favor of
145
+ niworkflows.interfaces.morphology.BinaryDilation. Please validate that
146
+ interface for your use case and switch.
147
+ """ , DeprecationWarning , stacklevel = 2 )
148
+ super ().__init__ (from_file = from_file , resource_monitor = resource_monitor , ** inputs )
149
+
139
150
def _run_interface (self , runtime ):
140
151
self ._results ["out_file" ] = _dilate (
141
152
self .inputs .in_file ,
You can’t perform that action at this time.
0 commit comments