hypertools.reduce.autoencoders.DeepAutoencoder¶
- class hypertools.reduce.autoencoders.DeepAutoencoder(n_components=2, hidden_dims=None, epochs=100, batch_size=64, lr=0.001, device='auto', random_state=None, verbose=False)[source]¶
A multi-layer autoencoder reducer with configurable depth.
- Parameters:
- n_componentsint
Latent (bottleneck) dimensionality (default: 2).
- hidden_dimsNone, int, or sequence of int
Hidden layer widths, outermost (closest to the input) first. None (default) computes 2 geometrically-spaced widths between the number of input features and n_components; a sequence sets the exact depth and widths (e.g. [64, 32, 16]).
- epochs, batch_size, lr, device, random_state, verbose
See Autoencoder.
- Attributes:
- net_torch.nn.Module or None
The fitted network.
Methods
fit(X[, y])Fit the autoencoder on X (see fit_transform); returns self.
fit_transform(X[, y])Standardize X, train a fresh network on it, and return the fitted latent codes.
get_metadata_routing()Get metadata routing of this object.
get_params([deep])Get parameters for this estimator.
inverse_transform(Z)Decode latent codes Z back to (standardization-undone) feature space.
set_inverse_transform_request(*[, Z])Configure whether metadata should be requested to be passed to the
inverse_transformmethod.set_params(**params)Set the parameters of this estimator.
transform(X)Apply the already-fitted network to (new) X, without refitting.
- __init__(n_components=2, hidden_dims=None, epochs=100, batch_size=64, lr=0.001, device='auto', random_state=None, verbose=False)[source]¶
Methods
__init__([n_components, hidden_dims, ...])fit(X[, y])Fit the autoencoder on X (see fit_transform); returns self.
fit_transform(X[, y])Standardize X, train a fresh network on it, and return the fitted latent codes.
get_metadata_routing()Get metadata routing of this object.
get_params([deep])Get parameters for this estimator.
inverse_transform(Z)Decode latent codes Z back to (standardization-undone) feature space.
set_inverse_transform_request(*[, Z])Configure whether metadata should be requested to be passed to the
inverse_transformmethod.set_params(**params)Set the parameters of this estimator.
transform(X)Apply the already-fitted network to (new) X, without refitting.
Attributes
is_fittedWhether fit/fit_transform has already been run.