src.dimensionality_reduction

Submodules

Attributes

logger

Classes

BaseDimensionalityReduction

Base class for dimensionality reduction models.

Functions

get_dr_model(method_name[, dask_client])

Package Contents

src.dimensionality_reduction.logger
class src.dimensionality_reduction.BaseDimensionalityReduction(n_components: int = 3)

Base class for dimensionality reduction models.

Attributes:

n_componentsint

The number of dimensions to reduce the data to.

transformed_datapd.DataFrame or None

DataFrame containing the reduced dimensionality data.

Attributes:

datapd.DataFrame or None

DataFrame containing the data to be clustered.

labelspd.Series or None

Series containing the cluster labels assigned to the data.

Methods:

load_data(file_path: str) -> pd.DataFrame:

Loads a dataset from a CSV or pickle file into a pandas DataFrame.

save_labels(file_path: str):

Saves the cluster labels to a CSV or pickle file.

n_components
transformed_data = None
data = None
load_data(embedding_method_name)
scale_data(data)
save_transformed_data(dimred_method_name: str, embedding_method_name: str, reduced_data: pandas.DataFrame)
src.dimensionality_reduction.get_dr_model(method_name: str, dask_client: dask.distributed.client.Client or None = None)