Skip to content

Commit 56d003b

Browse files
author
Laurent Guerard
committed
Fix parameter name for disable smoothing in rolling ball functions and tests
1 parent 27f4165 commit 56d003b

2 files changed

Lines changed: 8 additions & 8 deletions

File tree

src/imcflibs/imagej/processing.py

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -122,7 +122,7 @@ def apply_rollingball_bg_subtraction(
122122
rolling_ball_radius,
123123
light_background=False,
124124
sliding=False,
125-
disable_smooth=False,
125+
disable_smoothing=False,
126126
do_3d=False,
127127
):
128128
"""Perform background subtraction using a rolling ball method.
@@ -137,7 +137,7 @@ def apply_rollingball_bg_subtraction(
137137
If set to True, will treat the background as light, by default False
138138
sliding : bool, optional
139139
If set to True, will do a sliding window approach, by default False
140-
disable_smooth : bool, optional
140+
disable_smoothing : bool, optional
141141
If set to True, will disable the smoothing, by default False
142142
do_3d : bool, optional
143143
If set to True, will do a 3D filtering, by default False
@@ -153,7 +153,7 @@ def apply_rollingball_bg_subtraction(
153153
rolling_ball_radius,
154154
light_background=light_background,
155155
sliding=sliding,
156-
disable_smooth=disable_smooth,
156+
disable_smoothing=disable_smoothing,
157157
do_3d=do_3d,
158158
)
159159

@@ -169,7 +169,7 @@ def rolling_ball_options(
169169
rolling_ball_radius,
170170
light_background=False,
171171
sliding=False,
172-
disable_smooth=False,
172+
disable_smoothing=False,
173173
do_3d=False,
174174
):
175175
"""Generate the options for the "Subtract Background..." macro command.
@@ -182,7 +182,7 @@ def rolling_ball_options(
182182
If set to True, will treat the background as light, by default False
183183
sliding : bool, optional
184184
If set to True, will do a sliding window approach, by default False
185-
disable_smooth : bool, optional
185+
disable_smoothing : bool, optional
186186
If set to True, will disable the smoothing, by default False
187187
do_3d : bool, optional
188188
If set to True, will do a 3D filtering, by default False
@@ -198,7 +198,7 @@ def rolling_ball_options(
198198
parts.append("light")
199199
if sliding:
200200
parts.append("sliding")
201-
if disable_smooth:
201+
if disable_smoothing:
202202
parts.append("disable")
203203
if do_3d:
204204
parts.append("stack")

tests/test_processing.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ def test_rolling_ball_options_with_flags():
2121
12,
2222
light_background=True,
2323
sliding=True,
24-
disable=True,
24+
disable_smoothing=True,
2525
do_3d=True,
2626
)
2727
assert options == "rolling=12 light sliding disable stack"
@@ -40,7 +40,7 @@ def test_filter_options_gaussian_blur():
4040

4141
command, options = filter_options("Gaussian Blur", 5)
4242
assert command == "Gaussian Blur..."
43-
assert options == "sigma="
43+
assert options == "sigma=5 stack"
4444

4545

4646
def test_threshold_options():

0 commit comments

Comments
 (0)