Login  Register

Re: ImageJ benchmarks

Posted by ctrueden on Feb 07, 2008; 9:02pm
URL: http://imagej.273.s1.nabble.com/Re-ImageJ-benchmarks-tp3697260p3697261.html

Hi Gabriel,

Thanks for the macro. The ImageJ documentation wiki site is acting up for me
right now, but I will add it to the FAQ page (with Joachim Wesner's
correction) once it works again.

Cheers,
Curtis

On Feb 7, 2008 6:58 AM, Gabriel Landini <[hidden email]> wrote:

> Curtis wrote:
> > I thought it was worthwhile to preserve these numbers in some form, so I
> > created a FAQ entry on the wiki:
> >
>
> http://imagejdocu.tudor.lu/imagej-documentation-wiki/faq/are-there-performance-statistics-to-compare-against-my-system
>
> > If you create a better benchmark, it should be easy enough to update the
> >information there, too.
>
> I do not have a "better" benchmark, but running this macro gives almost
> all
> the info necessary to fill the FAQ (it runs 10 times and gives the best
> and
> worst times).
> The worst time tends to be the first one, I guess that this is because of
> the
> classes loading.
>
> Fell free to add it to the wiki page if you think it is useful.
>
> Regards,
>
> Gabriel
>
>
> //---------------------8<---------------------
> // benchmark test macro
> //
> print("- - - ");
> run("Mandrill (70K)");
> print("ImageJ: "+getVersion());
> print("OS : "+getInfo("os.name")+" "+getInfo("os.version"));
> print("Java: "+getInfo("java.vm.version")+" "+ getInfo("java.vm.vendor"));
>
> best=100000;
> worst=-1;
>
> for(i=0;i<10;i++){
>  selectWindow("baboon.jpg");
>  run("Duplicate...", "title=test");
>  t=getTime();
>  run("Benchmark ");
>  thisrun= getTime()-t;
>  if (thisrun<best) best=thisrun;
>  if (thisrun>worst) worst=thisrun;
>  close();
> }
> print("Benchmark best: "+best/1000);
> print("Benchmark worst: "+worst/1000);
>
> selectWindow("baboon.jpg");
> close();
> //---------------------8<---------------------
>