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

filter.dog breaks with an UnsignedByteType input and a FloatType output #291

Open
gselzer opened this issue Oct 12, 2023 · 0 comments
Open
Assignees
Labels
bug Something isn't working
Milestone

Comments

@gselzer
Copy link
Collaborator

gselzer commented Oct 12, 2023

I feel like the following should work, as a user, but it doesn't. May be an Ops issue, just filing it here because this is where I'm seeing it.

  1. Run `filter.dog(img "out"?, img "in", number "sigma1", number "sigma2", outOfBoundsFactory "fac"?) -> (img "out"?)
  2. in -> the bricks sample image
  3. 2 as sigma1
  4. 5 as sigma2
  5. Create a new image of type float32 as the output image
  6. Click Run
  7. See the following error:
java.lang.ClassCastException: net.imglib2.type.numeric.integer.UnsignedByteType cannot be cast to net.imglib2.type.numeric.real.FloatType
	at net.imglib2.type.numeric.real.FloatType.sub(FloatType.java:56)
	at net.imagej.ops.math.IIToIIOutputII$Subtract.compute(IIToIIOutputII.java:181)
	at net.imagej.ops.math.IIToIIOutputII$Subtract.compute(IIToIIOutputII.java:137)
	at net.imagej.ops.special.hybrid.BinaryHybridCI1.mutate(BinaryHybridCI1.java:61)
	at net.imagej.ops.special.hybrid.BinaryHybridCFI1.mutate(BinaryHybridCFI1.java:75)
	at net.imagej.ops.special.hybrid.BinaryHybridCI1.run(BinaryHybridCI1.java:70)
	at net.imagej.ops.special.hybrid.BinaryHybridCFI1.run(BinaryHybridCFI1.java:65)
	at net.imagej.ops.special.hybrid.BinaryHybridCFI.run(BinaryHybridCFI.java:68)
	at net.imagej.ops.special.hybrid.BinaryHybridCFI.run(BinaryHybridCFI.java:75)
	at org.scijava.command.CommandModule.run(CommandModule.java:196)
	at net.imagej.ops.OpEnvironment.run(OpEnvironment.java:960)
	at net.imagej.ops.OpEnvironment.run(OpEnvironment.java:157)
	at net.imagej.ops.filter.dog.DefaultDoG.compute(DefaultDoG.java:94)
	at net.imagej.ops.filter.dog.DefaultDoG.compute(DefaultDoG.java:54)
	at net.imagej.ops.special.chain.UHCFViaUHCF.compute(UHCFViaUHCF.java:63)
	at net.imagej.ops.filter.dog.DoGSingleSigmas.compute(DoGSingleSigmas.java:98)
	at net.imagej.ops.filter.dog.DoGSingleSigmas.compute(DoGSingleSigmas.java:54)
	at net.imagej.ops.special.hybrid.UnaryHybridCF.run(UnaryHybridCF.java:75)
	at net.imagej.ops.special.hybrid.UnaryHybridCF.run(UnaryHybridCF.java:97)
	at org.scijava.command.CommandModule.run(CommandModule.java:196)
	at net.imagej.ops.OpEnvironment.run(OpEnvironment.java:960)
	at net.imagej.ops.OpEnvironment.run(OpEnvironment.java:136)
	at net.imagej.ops.OpListingModule.run(OpListingModule.java:68)
	at org.scijava.module.ModuleRunner.run(ModuleRunner.java:165)
	at org.scijava.module.ModuleRunner.call(ModuleRunner.java:125)
	at org.scijava.module.ModuleRunner.call(ModuleRunner.java:64)
	at org.scijava.thread.DefaultThreadService.lambda$wrap$2(DefaultThreadService.java:247)
	at java.util.concurrent.FutureTask.run(FutureTask.java:266)
	at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1149)
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:624)
	at java.lang.Thread.run(Thread.java:750)
@gselzer gselzer added the bug Something isn't working label Oct 12, 2023
@gselzer gselzer added this to the 0.2.0 milestone Oct 12, 2023
@gselzer gselzer self-assigned this Oct 12, 2023
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

1 participant