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

ClassCastException from ConstantToIIOutputII #648

Open
gselzer opened this issue Oct 3, 2022 · 0 comments
Open

ClassCastException from ConstantToIIOutputII #648

gselzer opened this issue Oct 3, 2022 · 0 comments

Comments

@gselzer
Copy link
Contributor

gselzer commented Oct 3, 2022

The following script, run in Fiji, throws a ClassCastException. I couldn't find any existing issue for this.

#@OpService ops

from net.imglib2.img.array import ArrayImgs
from net.imglib2.type.numeric.real import DoubleType

input = ArrayImgs.bytes(10, 10)
output = ArrayImgs.bytes(10, 10)
value = DoubleType(10)

ops.run("math.add", output, input, value)

This is probably due to Ops' insufficient generic type reasoning during matching; ConstantToIIOutputII.Add (it's autogenerated, or I'd link it), is being satisfied despite the Ts not matching between the ByteType of the images and the DoubleType of the value.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant