Skip to main content

A PyTorch implementation of Incremental PCA

Project description

PyTorch Incremental PCA

PyPI Version License

This project provides a PyTorch implementation of the Incremental PCA algorithm, inspired by the IncrementalPCA class from scikit-learn and the repository PCAonGPU. This implementation has some shortcomings with regards to the precision of operations leading to vastly different results compared to the sklearn implemtation. The IncrementalPCA class in this repo produces outputs which are very close to the sklearn implementation with the added benefit of running on GPU.

Incremental PCA is a valuable technique for dimensionality reduction when dealing with large datasets that cannot fit entirely into memory.

Features

  • PyTorch Integration: Seamlessly use incremental PCA within your PyTorch workflows.
  • Memory Efficiency: Process large datasets incrementally without loading everything into memory at once.
  • Similar API: Familiar interface if you've used scikit-learn's IncrementalPCA.
  • Customization: Easily extend or modify the core functionality to suit your specific needs.

Installation

pip install torch-incremental-pca

Usage

import torch_incremental_pca as tip

pca = tip.IncrementalPCA(n_components=32)

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

torch_incremental_pca-0.0.17.tar.gz (14.0 kB view details)

Uploaded Source

Built Distribution

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

torch_incremental_pca-0.0.17-py3-none-any.whl (9.9 kB view details)

Uploaded Python 3

File details

Details for the file torch_incremental_pca-0.0.17.tar.gz.

File metadata

  • Download URL: torch_incremental_pca-0.0.17.tar.gz
  • Upload date:
  • Size: 14.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for torch_incremental_pca-0.0.17.tar.gz
Algorithm Hash digest
SHA256 791b31fdc65497b9c7e62b84f7dd8223858662d87dd34f875d7de024ff1f4163
MD5 a1add28a3a61203b354551d8057932d5
BLAKE2b-256 d5fe057b90555e0ba265acfedcae1d1a31969942365f2cec5de70a6d24f9f0fe

See more details on using hashes here.

File details

Details for the file torch_incremental_pca-0.0.17-py3-none-any.whl.

File metadata

File hashes

Hashes for torch_incremental_pca-0.0.17-py3-none-any.whl
Algorithm Hash digest
SHA256 c0cf67575da28eac2af2ea93a57989cfa2efaa674e2472622c70f70b41d01ec0
MD5 155208d588f612bb370029872fbcbf0f
BLAKE2b-256 d013aaa01757808b429560e08105cfd9dd9392c91e786cb1e207093fe2163da0

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