Local Constrained Translation Module

class DeformationModules.LocalConstrainedTranslations.LocalConstrainedTranslationsBase(manifold, sigma, descstr, f_support, f_vectors, coeff, label)[source]

Module generating sum of constrained translations.

__call__(points, k=0)[source]

Computes the k’th derivative of the module generated vector field at positions given by points.

Parameters
  • points (torch.Tensor) – A \(N \times d\) dimensioned tensor representing the points at which the generated vector field will be computed

  • k (int, default=0) – The order of the derivative at which the generated vector field will be computed

Returns

A tensor representing the values of the k’th derivative of the generated vector field at positions given by points. For \(k=0\), the output tensor is of shape \(N \times d\). For \(k=1\), the output tensor is of shape \(N \times d \times d\), and so on for subsequent orders.

Return type

torch.Tensor

adjoint(manifold)[source]
classmethod build(dim, nb_pts, sigma, descstr, f_support, f_vectors, coeff=1.0, gd=None, tan=None, cotan=None, label=None)[source]
property coeff
compute_geodesic_control(man)[source]

Computes the geodesic control of the deformation module on the specified manifold.

Parameters

manifold (Manifolds.BaseManifold) – Manifold on which we will compute the geodesic controls

property controls
copy()

Returns a copy of the deformation module.

cost()[source]

Computes the cost of the deformation given by the module.

Returns

The cost as a scalar tensor.

Return type

torch.Tensor

property descstr

Description string. Used by __str__().

property device
property dim
field_generator()[source]

Gives the vector field generated by the deformation module.

Returns

The vector field generated by the module

Return type

StructuredField.BaseStructuredField

fill_controls(controls)[source]
fill_controls_zero()[source]
property label

Identifier for the module.

property manifold
property sigma
to_(*args, **kwargs)[source]
DeformationModules.LocalConstrainedTranslations.LocalConstrainedTranslations(*args, backend=None, **kwargs)
DeformationModules.LocalConstrainedTranslations.LocalScaling(dim, sigma, coeff=1.0, gd=None, tan=None, cotan=None, label=None, backend=None)[source]

Generates a local scaling deformation module.

Local scaling is approximated by a local constrained translation deformation module with 3 vectors around the scaling center, pointing inwards.

Parameters
  • dim (int) – Dimension of the ambiant space the deformation module will live on.

  • sigma (float) – Kernel size of the underlying vector space

  • coeff (float) – Coefficient of the deformation module

  • gd (torch.Tensor) – Geometrical descriptor of the deformation module i.e. the scale centers

  • tan (torch.Tensor) – Tangent tensor

  • cotan (torch.Tensor) – Cotangent tensor

  • label – Optional identifier

DeformationModules.LocalConstrainedTranslations.LocalRotation(dim, sigma, coeff=1.0, gd=None, tan=None, cotan=None, label=None, backend=None)[source]

Generates a local rotation deformation module.

Local roation is approximated by a local constrained translation deformation module with 3 vectors around the scaling center, pointing tangantially.

Parameters
  • dim (int) – Dimension of the ambiant space the deformation module will live on.

  • sigma (float) – Kernel size of the underlying vector space

  • coeff (float) – Coefficient of the deformation module

  • gd (torch.Tensor) – Geometrical descriptor of the deformation module i.e. the rotation centers

  • tan (torch.Tensor) – Tangent tensor

  • cotan (torch.Tensor) – Cotangent tensor

  • label – Optional identifier

  • backend (str) – Computation backend the deformation module will