Skip to main content

Python tool to analyse process drifts

Project description

driftbench

Benchmarking framework for generating high-dimensional synthetic drifted data and evaluating models.

The corresponding open-access paper, Edgar Wolf and Tobias Windisch (2024), A method to benchmark high-dimensional process drift detection, describes the method in detail.

To run the benchmarks, execute:

python run_benchmarks.py

To visualize the model performance, run

import pandas as pd
import matplotlib.pyplot as plt
import seaborn as sns
import numpy as np

def plot_benchmark(df):

    fig, axes = plt.subplots(ncols=3, figsize=(15, 5))
    sns.boxplot(data=df, x="TAUC", y="Detector", hue='Data',  native_scale=True, ax=axes[0])
    sns.boxplot(data=df, x="SoftTAUC", y="Detector", hue='Data', native_scale=True, ax=axes[1])
    sns.boxplot(data=df, x="AUC", y="Detector", hue='Data', native_scale=True, ax=axes[2])
    
    for ax in axes[1:]:
        ax.legend([])
        ax.set_yticklabels([])
    
    axes[0].set_xlabel('TAUC')
    axes[1].set_xlabel('sTAUC')
    axes[2].set_xlabel('AUC')
    for ax in axes:
        ax.grid()
        ax.set_ylabel('')
    fig.tight_layout()
    
    return fig

df = pd.read_json('benchmarks.json') 
fig = plot_benchmark(df)

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

driftbench-0.0.8.tar.gz (19.5 kB view details)

Uploaded Source

Built Distribution

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

driftbench-0.0.8-py3-none-any.whl (22.5 kB view details)

Uploaded Python 3

File details

Details for the file driftbench-0.0.8.tar.gz.

File metadata

  • Download URL: driftbench-0.0.8.tar.gz
  • Upload date:
  • Size: 19.5 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for driftbench-0.0.8.tar.gz
Algorithm Hash digest
SHA256 17dfa0843605a1fa59754b7cdc7274633fb0218c527e5dcb08a226b7c907b4b1
MD5 0f08ed49c6221133fa2c09d2dca98002
BLAKE2b-256 0bff4d3fd989badab998f3b9609a98371856e198f4d343e35f8184359cebcd48

See more details on using hashes here.

File details

Details for the file driftbench-0.0.8-py3-none-any.whl.

File metadata

  • Download URL: driftbench-0.0.8-py3-none-any.whl
  • Upload date:
  • Size: 22.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.9

File hashes

Hashes for driftbench-0.0.8-py3-none-any.whl
Algorithm Hash digest
SHA256 636b2f453be9255d3ffcce5570ad54c3630da8ee3e4a0a1a6b14006a992abf67
MD5 9ccc9f430d74e3cf035d5705fe9ef41e
BLAKE2b-256 0039007ab45767ac8f1bfc88c5b2ccbc881a740e0db552e5addaa0e1e68011fa

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