Skip to main content

Implementation of VAE-SIMCA one class classification method

Project description

VAESIMCA — one class classifier based on Variational Autoencoders and data driven SIMCA approach

The package vaesimca implements a method for creating one-class classification (OCC) models (also known as anomaly detectors or novelty detectors) using Variational Autoencoders (VAE). The overall idea is based on another OCC method, DD-SIMCA, and hence can be considered as a adaptation of the DD-SIMCA approach using VAE for data decomposition. The theoretical background and practical examples for the vaesimca methods are described in this paper, please use it for citation. The paper is freely available to everyone via open access option, it is recommended to read it first and then come back and try the examples from the demo notebook.

Although the method we proposed is versatile, the package implements VAESIMCA method for analysis of images. It can be installed from PyPI using pip or any other package manager compatible with PyPI, e.g.:

pip3 install vaesimca

It requires numpy, scipy, torch, torchvision, pandas, torch_lr_finder and matplotlib, which will be automatically installed as dependencies.

Getting started

Use Jupyter notebook demo.ipynb in order to get started. To run the examples from this notebook you need to download zip file with simulated dataset (it is also used for illustration of the method in the paper). Here is direct link to the archive with the dataset.

Simply download the dataset and unzip it to your working directory, where you have the notebook, and follow the guides. CSV files can be downloaded from GitHub as well.

Releases

0.4.2 (2/6/2025)

  • added possibility to load data from CSV files.
  • added learning rate finder option.
  • see demo.ipynb for all details.

0.3.7

  • fixed a bug in saving state dictionary of the best model during training loop.

Reference

A. Petersen, S. Kucheryavskiy, VAE-SIMCA — Data-driven method for building one class classifiers with variational autoencoders, Chemometrics and Intelligent Laboratory Systems, 256, 2025, 105276, DOI: 10.1016/j.chemolab.2024.105276.

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

vaesimca-0.4.2.tar.gz (51.9 MB view details)

Uploaded Source

Built Distribution

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

vaesimca-0.4.2-py3-none-any.whl (14.4 kB view details)

Uploaded Python 3

File details

Details for the file vaesimca-0.4.2.tar.gz.

File metadata

  • Download URL: vaesimca-0.4.2.tar.gz
  • Upload date:
  • Size: 51.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for vaesimca-0.4.2.tar.gz
Algorithm Hash digest
SHA256 45773c128f345b091f00f65a7708a34bfb57e5f9bf3dddc71df0a1f257931e4e
MD5 60f31c5507b2206a5d92ceccf575299b
BLAKE2b-256 16f9ac3670ab60816ba3f871c8ac660b845e33e8f14ff640068fcaf9b0c1736b

See more details on using hashes here.

File details

Details for the file vaesimca-0.4.2-py3-none-any.whl.

File metadata

  • Download URL: vaesimca-0.4.2-py3-none-any.whl
  • Upload date:
  • Size: 14.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.3

File hashes

Hashes for vaesimca-0.4.2-py3-none-any.whl
Algorithm Hash digest
SHA256 9605b17fcf96b4073d8f4c9c7722887c31b5c55bead5faf610b870f78219ba44
MD5 eaf547c96c271498b86547e0e498b9e0
BLAKE2b-256 7b7667e206c5d0e8eea06c4e65feeedf80ae7611b6157dfe3e19a429b69c0061

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