deepmol.unsupervised package
Submodules
deepmol.unsupervised.base_unsupervised module
- class KMeans(**kwargs)[source]
Bases:
UnsupervisedLearn
Class to perform K-Means clustering.
Wrapper around scikit-learn K-Means. (https://scikit-learn.org/stable/modules/generated/sklearn.cluster.KMeans.html#sklearn.cluster.KMeans)
- class PCA(**kwargs)[source]
Bases:
UnsupervisedLearn
Class to perform principal component analysis (PCA).
Wrapper around scikit-learn PCA (https://scikit-learn.org/stable/modules/generated/sklearn.decomposition.PCA.html#sklearn.decomposition.PCA)
Linear dimensionality reduction using Singular Value Decomposition of the data to project it to a lower dimensional space.
- class TSNE(**kwargs)[source]
Bases:
UnsupervisedLearn
Class to perform t-distributed Stochastic Neighbor Embedding (TSNE).
Wrapper around scikit-learn TSNE (https://scikit-learn.org/stable/modules/generated/sklearn.manifold.TSNE.html#sklearn.manifold.TSNE)
It converts similarities between data points to joint probabilities and tries to minimize the Kullback-Leibler divergence between the joint probabilities of the low-dimensional embedding and the high-dimensional data.
- class UnsupervisedLearn[source]
Bases:
ABC
,Transformer
Class for unsupervised learning.
A UnsupervisedLearn sampler receives a Dataset object and performs unsupervised learning.
Subclasses need to implement a _unsupervised method to perform unsupervised learning.
- abstract plot(x_new: ndarray, path: str | None = None, **kwargs) None [source]
Plot the results of unsupervised learning.
- Parameters:
x_new (np.ndarray) – Transformed values.
path (str) – The path to save the plot.
**kwargs – Additional arguments to pass to the plot function.
- run(other_object, inplace=False, **kwargs)
Method that modifies an input object inplace or on a copy.
- Parameters:
self (object) – The class instance object.
other_object (object) – The object to apply the method to.
inplace (bool) – Whether to apply the method in place.
kwargs (dict) – Keyword arguments to pass to the method.
- Returns:
new_object – The new object.
- Return type:
object
deepmol.unsupervised.umap module
- class UMAP(parametric: bool = True, **kwargs)[source]
Bases:
UnsupervisedLearn
Class to perform Uniform Manifold Approximation and Projection (UMAP).
Wrapper around umap package. (https://github.com/lmcinnes/umap)