Page MenuHomePhabricator

Perfomance loss due to intense (time)geometry clonig
Open, LowPublic

Description

Status: currently the (time)geometry are cloned a lot; e.g. in simple reinits of the rendering scenes (i.a. for bounding box checks, worldgeometry generation, slice navigator setup...). This has a significant impact (consuming 80% of cpu time on a simple reinit) on the performance and usablity when we start to work with a lot of dynamic data sets (many volumes -> timegeometry with a lot of geometries -> significant more cloning).

This should be optimized.

Following steps/ideas

  1. Time geometries should allow to just keep one internal 3D geometry, if the 3D geometries of all time steps are equal -> This is the case in most situations and it will save a lot of cloning in dynamic cases.
  2. To savely allow #1, we should improve const correctness in TimeGeometries. The 3D geometries should only be returned as const pointers. Otherwise we could get inconsistancy in conjunction with #1, if someone alters a geometry via pointer for a specific time point in a TimeGeometry that was homogenous till then.
  3. Check for unnecessary itkNewMacros instead if itkFactorylessNewMacros in this context.
  4. Check that the DICOM loader, when it assambles the TimeGeometry, also does it efficiently (not a new geometry for each frame, as long as they are equal, but only once for all time steps.

Event Timeline

floca triaged this task as Normal priority.Mar 12 2019, 11:48 AM
floca created this task.

Befor we follow this idea any further, T26167 should be solved and performance should be checked again.

Fixing T26167 should remove a lot of cloning in context of rendering/reinit and it has less dependencies and implications than this proposed task. Thus T26167 could make the issue far less pressing and therefore substantially lower the priority of this task.

floca removed floca as the assignee of this task.Nov 28 2019, 3:12 PM
floca lowered the priority of this task from Normal to Low.

Fixing T26167 was enough for now.

Minimizing the cloning would still a good thing to do, but its not trival (=time consuming if done correctly) and not critically needed for now.

kislinsk added a project: Auto-closed.
kislinsk added a subscriber: kislinsk.

Hi there! ๐Ÿ™‚

This task was auto-closed according to our Task Lifecycle Management.
Please follow this link for more information and don't forget that you are encouraged to reasonable re-open tasks to revive them. ๐Ÿš‘

Best wishes,
The MITK devs

floca removed a project: Auto-closed.