Skip to content

Increase Composition Performance #3

@jzwar

Description

@jzwar

This is already a TODO in Compose

In the multi-dimensional case the composition is performed by multiplying the precomputed Basis functions to the control points T of thee deformation function C = T_{ijk...} Bi Bj Bk ....
Currently this is done by looping over all i j k ... which is very inefficient, as many splines Products are computed multiple times. If the product can be organized as follows, the computational cost can significantly be reduced.

for i:
    for j:
        Bij = Bi * Bj
        for k:
            Bijk = Bij * Bk
            for l:
              [...]

In this example for every k -- (k-1) fewer spline products are computed as Bij can be reused for every iteration of k. This effect becomes more important for parametric dimensions of the deformation function.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions