SlicerIGT / SlicerTrackingErrorInspector

Slicer modules for evaluating pose tracking error using a ground truth pose tracker
BSD 3-Clause "New" or "Revised" License
3 stars 1 forks source link

Delay when saving tracking error transforms #12

Open lassoan opened 8 years ago

lassoan commented 8 years ago

When loading a saved pos and orientation error .h5 TPS transform file, the transforms module shows that the number of landmarks is 0.

When a TPS transform is created by the Landmark registration module and we save and reload that, the saving works.

vinyasHarish95 commented 8 years ago

Using Slicer 4.5, it appears that the transforms are indeed saving properly (verified by checking the number of source and target landmarks) however they take a really really long time. Is there any way to speed it up? I tried saving while displaying the "warped grid" view & sampling points as well without displaying them, but did not notice an improvement.

lassoan commented 8 years ago

How long does it take? How large the resulting file is?

vinyasHarish95 commented 8 years ago

About 2 or 3 minutes to save two 40 kB files (the position and orientation transforms). Since Slicer freezes while this is happening, we do not know if the save is actually working or the program is about to crash.

lassoan commented 8 years ago

Can you send me those saved files in an email so that I can have a look?

lassoan commented 8 years ago

I’ve fixed one source of delay in the Slicer core. The fix will be available in tomorrow’s nightly build. Writing speed can probably further improved by setting transform To parent instead of transform From parent when we initialize the transform (SetAndObserveTransformToParent). Let’s make this change after all the automatic tests are in place to make sure we don’t introduce any regressions.

vinyasHarish95 commented 8 years ago

Sounds good Andras, I have updated the issue title to reflect this.

Why does changing 'from' to 'to' parent as outlined above result in a speed boost?

lassoan commented 8 years ago

Always the FromParent transform is written to file. Inversion of a TPS transform with hundreds of input points takes some time (up to a few ten seconds).