VInvertible¶
-
class
menpo.transform.base.invertible.VInvertible[source]¶ Bases:
InvertibleMix-in for
VectorizableInvertibleTransforms.Prefer this mix-in over
Invertibleif theTransformin question isVectorizableas this addsfrom_vector()variants to theInvertibleinterface. These can be tuned for performance, and are, for instance, needed by some of the machinery of fit.-
pseudoinverse()¶ The pseudoinverse of the transform - that is, the transform that results from swapping source and target, or more formally, negating the transforms parameters. If the transform has a true inverse this is returned instead.
- Type
type(self)
-
pseudoinverse_vector(vector)[source]¶ The vectorized pseudoinverse of a provided vector instance. Syntactic sugar for:
self.from_vector(vector).pseudoinverse().as_vector()
Can be much faster than the explict call as object creation can be entirely avoided in some cases.
- Parameters
vector (
(n_parameters,)ndarray) – A vectorized version ofself- Returns
pseudoinverse_vector (
(n_parameters,)ndarray) – The pseudoinverse of the vector provided
-
property
has_true_inverse¶ Trueif the pseudoinverse is an exact inverse.- Type
bool
-