-
Notifications
You must be signed in to change notification settings - Fork 5
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
MCNR Exception calling #27
Comments
No surprise there. This function is for raw data and doesn't expect negative or non-existent numbers. Maybe it should fail more cleanly but I don't think this is a serious bug. Ian Sent from my iPhone On 31 Mar 2016, at 12:59, ezemiron <[email protected]mailto:[email protected]> wrote: Running SIMcheck>Raw data>Modulation contrast on an image with negative pixel values, inf or NaN's produce an Exception window to pup up with the following information: (Fiji Is Just) ImageJ 2.0.0-rc-43/1.50g; Java 1.6.0_65 [64-bit]; Mac OS X 10.10.5; 1618MB of 7241MB (22%) java.lang.NumberFormatException: Infinite or NaN — |
That is what I thought. The rationale behind this is to use an aligned MCNR and create a binary mask of "trustworthy" values to overlay on to my aligned reconstructed results, excluding some results based on SIM quality not just intensity (like what happens in the modal-threshold tool). The problem arises with how the alignment software fills the 1-pixel gap between the pixels left by the alignment shift (all zeros) and the rest of the real image pixels. What it seems to do is some interpolation between these zeros and the pixels of the image to generate a 1-pixel row/column of intermediate values, possibly to avoid a hard edge?. On some datasets these pixels are positive (perhaps like a weighted average), so no MCNR problems, but for other datasets these are small negative values (no idea how they are derived) and then MCNR can't cope. E |
@ezemiron thanks for letting us know -- I will make a note to fix the issue. In the meantime, did you try adding a small offset to the pixel intensities to make them all positive? Cheers, |
Thanks, |
@ezemiron you could use ImageJ's |
Running SIMcheck>Raw data>Modulation contrast on an image with negative pixel values, inf or NaN's produce an Exception window to pup up with the following information:
(Fiji Is Just) ImageJ 2.0.0-rc-43/1.50g; Java 1.6.0_65 [64-bit]; Mac OS X 10.10.5; 1618MB of 7241MB (22%)
java.lang.NumberFormatException: Infinite or NaN
at java.math.BigDecimal.(BigDecimal.java:797)
at SIMcheck.J.d2s(J.java:111)
at SIMcheck.ResultSet.report(ResultSet.java:146)
at SIMcheck.Raw_ModContrast.run(Raw_ModContrast.java:106)
at ij.IJ.runUserPlugIn(IJ.java:212)
at ij.IJ.runPlugIn(IJ.java:176)
at ij.Executer.runCommand(Executer.java:137)
at ij.Executer.run(Executer.java:66)
at java.lang.Thread.run(Thread.java:695)
The text was updated successfully, but these errors were encountered: