Skip to main content

Generalizable UMAP Implementation

Project description

NUMAP

This is the official PyTorch implementation of NUMAP from the paper "Generalizable Spectral Embedding with Applications to UMAP.

Installation

To install the package, simply use the following command:

pip install numap

Usage

The basic functionality is quite intuitive and easy to use, e.g.,

from numap import NUMAP

numap = NUMAP(n_components=2)  # n_components is the number of dimensions in the low-dimensional representation
numap.fit(X)  # X is the dataset and it should be a torch.Tensor
X_reduced = numap.transfrom(X)  # Get the low-dimensional representation of the dataset
Y_reduced = numap.transform(Y)  # Get the low-dimensional representation of a test dataset

You can read the code docs for more information and functionalities.

Running examples

In order to run the model on the moon dataset, you can either run the file, or using the command-line command:
python -m examples.reduce_moon
This will run the model on the moon dataset and plot the results.

The same can be done for the circles dataset:
python -m examples.reduce_circles

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

numap-0.1.1.tar.gz (11.5 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

numap-0.1.1-py3-none-any.whl (19.2 kB view details)

Uploaded Python 3

File details

Details for the file numap-0.1.1.tar.gz.

File metadata

  • Download URL: numap-0.1.1.tar.gz
  • Upload date:
  • Size: 11.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.9.21

File hashes

Hashes for numap-0.1.1.tar.gz
Algorithm Hash digest
SHA256 dc5277d09d836e680fe0244bbe4435585f19ae8cf08857cca5ba3ac3e994a34f
MD5 0fa31e48b5d1191015571903731cad76
BLAKE2b-256 a19b969ce259c54fa28e8d22ea31dd6be0fb5c81c12a957072a504e5f74af7eb

See more details on using hashes here.

File details

Details for the file numap-0.1.1-py3-none-any.whl.

File metadata

  • Download URL: numap-0.1.1-py3-none-any.whl
  • Upload date:
  • Size: 19.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.0.1 CPython/3.9.21

File hashes

Hashes for numap-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 80ded9cc8af312a1406004ad97adc471af227897a5e87aeb8e4a3bb7280e22ef
MD5 fc4b18fc5f0be17f5bdc989ea8b36b7d
BLAKE2b-256 b03efcbc05cc3c1a9b3d4140e6fb6cb29a4a95bb090369f1c17a03881eb4f38d

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page