We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
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
Describe the bug on pyclesperanto v0.9.1 I get an UNSUPPORTED error when executing cle.bounding_box():
cle.bounding_box()
--------------------------------------------------------------------------- RuntimeError Traceback (most recent call last) Cell In[1], [line 12](vscode-notebook-cell:?execution_count=1&line=12) [9](vscode-notebook-cell:?execution_count=1&line=9) image[240:290, 20:260] = 1 [11](vscode-notebook-cell:?execution_count=1&line=11) # measure the bounding box with pyclesperanto causes an UNSUPPORTED error ---> [12](vscode-notebook-cell:?execution_count=1&line=12) cle.bounding_box(image) [14](vscode-notebook-cell:?execution_count=1&line=14) # measure the bounding box with pyclesperanto_prototype works [15](vscode-notebook-cell:?execution_count=1&line=15) clep.bounding_box(image) # returns [20.0, 10.0, 0, 259.0, 29.0, 0] File /opt/homebrew/Caskroom/mambaforge/base/envs/vfdt/lib/python3.12/site-packages/pyclesperanto/_decorators.py:85, in plugin_function..worker_function(*args, **kwargs) 82 bound.arguments[key] = input_image.device 84 # call the decorated function ---> 85 result = function(*bound.args, **bound.kwargs) 87 # # Cast the result as an Array if it is not already 88 # if not isinstance(result, _Array): 89 # result = _Array(result) 91 return result File /opt/homebrew/Caskroom/mambaforge/base/envs/vfdt/lib/python3.12/site-packages/pyclesperanto/_tier3.py:38, in bounding_box(input_image, device) 17 """Determines the bounding box of all nonzero pixels in a binary image. The 18 positions are returned in an array of 6 values as follows: minX, minY, minZ, 19 maxX, maxY, maxZ. (...) 33 [1] https://clij.github.io/clij2-docs/reference_boundingBox 34 """ 36 from ._pyclesperanto import _bounding_box as op ---> 38 return op( 39 device=device, 40 src=input_image 41 ) RuntimeError: Build log: Compiler encountered an internal error
File /opt/homebrew/Caskroom/mambaforge/base/envs/vfdt/lib/python3.12/site-packages/pyclesperanto/_decorators.py:85, in plugin_function..worker_function(*args, **kwargs) 82 bound.arguments[key] = input_image.device 84 # call the decorated function ---> 85 result = function(*bound.args, **bound.kwargs) 87 # # Cast the result as an Array if it is not already 88 # if not isinstance(result, _Array): 89 # result = _Array(result) 91 return result
File /opt/homebrew/Caskroom/mambaforge/base/envs/vfdt/lib/python3.12/site-packages/pyclesperanto/_tier3.py:38, in bounding_box(input_image, device) 17 """Determines the bounding box of all nonzero pixels in a binary image. The 18 positions are returned in an array of 6 values as follows: minX, minY, minZ, 19 maxX, maxY, maxZ. (...) 33 [1] https://clij.github.io/clij2-docs/reference_boundingBox 34 """ 36 from ._pyclesperanto import _bounding_box as op ---> 38 return op( 39 device=device, 40 src=input_image 41 )
RuntimeError: Build log: Compiler encountered an internal error
To Reproduce
import pyclesperanto as cle import pyclesperanto_prototype as clep import numpy as np #create sample image image = np.zeros((300, 300), dtype=np.uint8) image[240:290, 20:260] = 1 #measure the bounding box with pyclesperanto causes an UNSUPPORTED error cle.bounding_box(image) #measure the bounding box with pyclesperanto_prototype works clep.bounding_box(image) # returns [20.0, 10.0, 0, 259.0, 29.0, 0]
Expected behavior in the above code snippet cle.bounding_box(image) should return [20.0, 10.0, 0, 259.0, 29.0, 0]
cle.bounding_box(image)
Configuration details:
The text was updated successfully, but these errors were encountered:
Same issue as #174 i guess. Will fix this soon and add a logic enforcement to prevent this incompatibility in future.
Thanks again Till!
Sorry, something went wrong.
clEsperanto/CLIc@c8b5f98
Successfully merging a pull request may close this issue.
Describe the bug
on pyclesperanto v0.9.1 I get an UNSUPPORTED error when executing
cle.bounding_box()
:UNSUPPORTED (log once): buildComputeProgram: cl2Metal failed
To Reproduce
Expected behavior
in the above code snippet
cle.bounding_box(image)
should return [20.0, 10.0, 0, 259.0, 29.0, 0]Configuration details:
The text was updated successfully, but these errors were encountered: