hyrax.verbs.reduction_algorithms.tsne#
Attributes#
Classes#
TSNE reduction implementation. |
Module Contents#
- class TSNE(config: dict, reduction_results=None)[source]#
Bases:
hyrax.verbs.reduction_algorithms.algorithm_registry.ReductionAlgorithmTSNE reduction implementation.
- transform(args: dict, num_batches: int)[source]#
Fit and transform data with TSNE model.
- Parameters:
args (dict) – A dictionary containing the data to be transformed.
num_batches (int) – The total number of batches that the data is split into for transformation.
- _fit_transform_batch(batch_tuple: tuple)[source]#
Private helper to fit_transform a single batch
- Parameters:
batch_tuple (tuple()) – first element is the IDs of the batch as a numpy array second element is the inference results to transform as a numpy array with shape (batch_len, N) where N is the total number of dimensions in the inference result. Caller flattens all inference result axes for us.
- Returns:
first element is the ids of the batch as a numpy array second element is the results of running the tsne transform on the input as a numpy array.
- Return type:
tuple