Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Renamed list parameter to label_image in exclude_labels. #266

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
10 changes: 5 additions & 5 deletions pyclesperanto/_tier3.py
Original file line number Diff line number Diff line change
Expand Up @@ -102,7 +102,7 @@ def remove_labels(
@plugin_function
def exclude_labels(
input_image: Image,
list: Image,
label_image: Image,
output_image: Optional[Image] =None,
device: Optional[Device] =None
) -> Image:
Expand All @@ -116,7 +116,7 @@ def exclude_labels(
----------
input_image: Image

list: Image
label_image: Image

output_image: Optional[Image] (= None)

Expand All @@ -131,7 +131,7 @@ def exclude_labels(
----------
[1] https://clij.github.io/clij2-docs/reference_excludeLabels
"""
return clic._exclude_labels(device, input_image, list, output_image)
return clic._exclude_labels(device, input_image, label_image, output_image)

@plugin_function(categories=["label processing", "in assistant", "bia-bob-suggestion"])
def remove_labels_on_edges(
Expand Down Expand Up @@ -591,7 +591,7 @@ def statistics_of_background_and_labelled_pixels(
Label image to compute the statistics.
intensity: Optional[Image] (= None)
Intensity image.
device: Optional[Device] (= None)
device: Optional[Device] =None)
Device to perform the operation on.

Returns
Expand All @@ -602,4 +602,4 @@ def statistics_of_background_and_labelled_pixels(
----------
[1] https://clij.github.io/clij2-docs/reference_statisticsOfBackgroundAndLabelledPixels
"""
return clic._statistics_of_background_and_labelled_pixels(device, label, intensity)
return clic._statistics_of_background_and_labelled_pixels(device, label, intensity)
4 changes: 2 additions & 2 deletions tests/test_exclude_labels.py
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ def test_exclude_labels_2d():

flaglist = cle.push(np.asarray([[0, 0, 0, 1, 1, 0, 0, 1, 0]]).astype(np.uint32))

gpu_output = cle.exclude_labels(gpu_input, flaglist)
gpu_output = cle.exclude_labels(gpu_input, label_image=flaglist)

a = cle.pull(gpu_output)
b = cle.pull(gpu_reference)
Expand Down Expand Up @@ -82,7 +82,7 @@ def test_exclude_labels_3d():

flaglist = cle.push(np.asarray([[0, 0, 0, 1, 1, 0, 0, 1, 0]]).astype(np.uint32))

gpu_output = cle.exclude_labels(gpu_input, flaglist)
gpu_output = cle.exclude_labels(gpu_input, label_image=flaglist)

a = cle.pull(gpu_output)
b = cle.pull(gpu_reference)
Expand Down
Loading