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.1 (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.1.tar.gz (52.0 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.1-py3-none-any.whl (14.4 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: vaesimca-0.4.1.tar.gz
  • Upload date:
  • Size: 52.0 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.1.tar.gz
Algorithm Hash digest
SHA256 dba0399be069e0d051999d141c5f242df2c895f499e34a7924d9742566363f89
MD5 4464c52848c1700fb188e96384aa24fe
BLAKE2b-256 83799dd11700d997fc22df2df9fcda5ed5194f91e32a1e126a9e04c67fe621ff

See more details on using hashes here.

File details

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

File metadata

  • Download URL: vaesimca-0.4.1-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.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e092823fb475c6d588667f4c61805ea1ff633e86019356e0878abc01d4ab69aa
MD5 eeceaceff12b368471403d97a32ed285
BLAKE2b-256 dd9bafc02b9f54981ad0e76b54339171c33fa1b1f6061858a27269a69f9e0609

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