Re: Slice Geometry efficiency

115 views
Skip to first unread message

Michael Doube

unread,
Apr 25, 2013, 12:55:13 PM4/25/13
to bonej-users-a...@googlegroups.com
Hi André,

First thing to do is some basic benchmarking: time how long it takes to do the calculation. Record also:

OS
Java version
ImageJ version
Vanilla ImageJ or Fiji
BoneJ version

ImageJ can be rolled back (Help > Update ImageJ, choose an old version from the menu)

The timing can be done with a macro, which also helps to keep the dialog options the same e.g.
//----------
startTime = getTime();

//run slice geometry here with your preferred options

elapsedTime = getTime() - startTime;

print("This run took "+elapsedTime+" ms");

//------------

How much is the difference - 10 times slower, 100 times slower?

Michael

On Thursday, 25 April 2013 17:46:44 UTC+1, André Pereira wrote:
Hey Mike!

I've been lately using BoneJ to get cross sectional Imin using the Slice Geometry function. However it seems to be highly inefficient, since I updated Fiji. The same thing happens in ImageJ (without Fiji). First I thought that it would be a problem in my computer, but it's happening in different machines now.

Is there something I should try to do?

Thanks for your attention!

Andre

André Pereira

unread,
Apr 25, 2013, 1:04:11 PM4/25/13
to bonej-users-a...@googlegroups.com
I haven't tried to complete one yet. I submitted one 10 minutes ago. Still running... Previous versions would process one image in a matter of a few seconds.

OS: Windows 7
Java version: Version 7 Update 21
Image J: 1.47n
Fiji: most recent
Bone J: 1.3.10

The last message that it shows is: "Distance ridge: creating search templates"

Thanks!

André Pereira

unread,
Apr 25, 2013, 1:06:52 PM4/25/13
to bonej-users-a...@googlegroups.com
Sorry, gave you the wrong version of Java.

$ java -version
java version "1.6.0_31"
Java(TM) SE Runtime Environment (build 1.6.0_31-b05)
Java HotSpot(TM) 64-Bit Server VM (build 20.6-b01, mixed mode)

Michael Doube

unread,
Apr 26, 2013, 4:37:03 AM4/26/13
to bonej-users-a...@googlegroups.com
Hi André,

What happens if you turn off the thickness options? Is it the 2D or 3D thickness option causing the slowdown?

Michael

Michael Doube

unread,
Apr 26, 2013, 4:45:14 AM4/26/13
to bonej-users-a...@googlegroups.com
Can't replicate here, using BoneJ 1.3.10, Java 1.6.0_45 (64-bit), (vanilla) ImageJ 1.47m, Ubuntu 12.04.

2D and 3D thickness options work as fast as normal.

André Pereira

unread,
Apr 26, 2013, 9:26:06 AM4/26/13
to bonej-users-a...@googlegroups.com
Hey Mike,

It's the 2D thickness that is causing the slow response. If I uncheck it, it becomes responsive.

Andre

Michael Doube

unread,
Apr 26, 2013, 9:36:16 AM4/26/13
to bonej-users-a...@googlegroups.com
Hi André,

Weird that this should turn up now. Thickness hasn't changed much recently:

https://github.com/mdoube/BoneJ/commits/master/src/org/doube/bonej/Thickness.java

And nor has Slice Geometry:

https://github.com/mdoube/BoneJ/commits/master/src/org/doube/bonej/SliceGeometry.java

How are your thresholds?

Michael
Reply all
Reply to author
Forward
0 new messages