dimension_reduction module¶
Dimension reduction as a generic transformer.
The DimensionReduction
class implements the concept of dimension reduction.
See also
Classes:
|
Dimension reduction. |
- class gemseo.mlearning.transform.dimension_reduction.dimension_reduction.DimensionReduction(name='DimensionReduction', n_components=5, **parameters)[source]¶
Bases:
gemseo.mlearning.transform.transformer.Transformer
Dimension reduction.
- Attributes
name (str) – The name of the transformer.
parameters (str) – The parameters of the transformer.
- Parameters
name (str) – A name for this transformer.
n_components (int) – The number of components of the latent space.
**parameters – The parameters of the transformer.
parameters (Optional[Union[float,int,str,bool]]) –
- Return type
None
Attributes:
The number of components.
Methods:
compute_jacobian
(data)Compute Jacobian of transformer.transform().
compute_jacobian_inverse
(data)Compute Jacobian of the transformer.inverse_transform().
Duplicate the current object.
fit
(data, *args)Fit the transformer to the data.
fit_transform
(data, *args)Fit the transformer to the data and transform the data.
inverse_transform
(data)Perform an inverse transform on the data.
transform
(data)Transform the data.
- CROSSED = False¶
- compute_jacobian(data)¶
Compute Jacobian of transformer.transform().
- Parameters
data (numpy.ndarray) – The data where the Jacobian is to be computed.
- Returns
The Jacobian matrix.
- Return type
NoReturn
- compute_jacobian_inverse(data)¶
Compute Jacobian of the transformer.inverse_transform().
- Parameters
data (numpy.ndarray) – The data where the Jacobian is to be computed.
- Returns
The Jacobian matrix.
- Return type
NoReturn
- duplicate()¶
Duplicate the current object.
- Returns
A deepcopy of the current instance.
- Return type
- fit(data, *args)[source]¶
Fit the transformer to the data.
- Parameters
data (numpy.ndarray) – The data to be fitted.
data – The data to be fitted.
args (Union[float, int, str]) –
- Return type
NoReturn
- fit_transform(data, *args)¶
Fit the transformer to the data and transform the data.
- Parameters
data (numpy.ndarray) – The data to be transformed.
args (Union[float, int, str]) –
- Returns
The transformed data.
- Return type
numpy.ndarray
- inverse_transform(data)¶
Perform an inverse transform on the data.
- Parameters
data (numpy.ndarray) – The data to be inverse transformed.
- Returns
The inverse transformed data.
- Return type
NoReturn
- property n_components¶
The number of components.
- transform(data)¶
Transform the data.
- Parameters
data (numpy.ndarray) – The data to be transformed.
- Returns
The transformed data.
- Return type
NoReturn