Login  Register

Re: test cases

Posted by Gabriel Landini on Jul 31, 2014; 11:06am
URL: http://imagej.273.s1.nabble.com/test-cases-tp5008981p5008994.html

On Thursday 31 Jul 2014 11:20:32 you wrote:

> one problem is the 'blobs.gif' file - if ImageJ opens that from
> ImageJ/samples/blobs.gif via an 'open' command, the image has no inverted
> LUT (as it should have) but the same appearance, thus different pixel
> values. In that case you get 'fail' messages for every test.
>
> If it opens 'blobs.gif it via File>Open Samples, it has the correct LUT and
> pixel values. Thus, in the macro, you should have the 'blobsFile' variable
> not pointing at the location where it can fine 'blobs.gif'. As we have the
> possibility of caching sample images in ImageJ now, the macro code to
> directly read the image is obsolete anyhow.
>
> Apart from that problem, I got no error, neither with 1.49e1 nor with
> 1.49e12. (OS X 10.6.8, Java 1.6.0_65 [64-bit])

So odd..
 

> Your other error message looks strange:
> > FAIL: Smooth:   type=8bit select=all nThreads=1, single image: mean=63.34
> > expected=62.8975
> This means that the simple "Smooth" command does something wrong on your
> machine!
>
> Process>Smooth should have exactly the same result as Process>Filters>Mean
> with a radius of 1 pixel, but it uses the ImageProcessor's 'smooth' method
> instead of the RankFilters.
>
> Could you please try the two commands and see whether there is any
> difference between the results, and if so, what went wrong?

If I do smoothing and mean filter radius 1 on an image I get exactly the same
result, either for the whole image or for ROIs in them, so that seems OK, but
the the FilterTester still fails with the error above.

run("Blobs (25K)");
getStatistics(area, mean);
print ("Original mean: "+mean);
run("Smooth");
getStatistics(area, mean);
print ("Smooth mean: "+mean);
close();
run("Blobs (25K)");
run("Mean...", "radius=1");
getStatistics(area, mean);
print ("Mean mean: "+mean);
close();

gives 103.2677 for both versions of the filter.

The other errors do not appear now that I copied the two macros into the
/macros folder (so perhaps there was an old version in that folder?).

Cheers

Gabriel

--
ImageJ mailing list: http://imagej.nih.gov/ij/list.html