Skip to main content

✂️ Fast slice finding for Machine Learning model debugging.

Project description

Sliceline is a Python library for fast slice finding for Machine Learning model debugging.

It is an implementation of SliceLine: Fast, Linear-Algebra-based Slice Finding for ML Model Debugging, from Svetlana Sagadeeva and Matthias Boehm of Graz University of Technology.

👉 Getting started

Given an input dataset X and a model error vector errors, SliceLine finds the top slices in X that identify where a ML model performs significantly worse.

You can use sliceline as follows:

from sliceline.slicefinder import Slicefinder

slice_finder = Slicefinder()

slice_finder.fit(X, errors)

print(slice_finder.top_slices_)

X_trans = slice_finder.transform(X)

We invite you to check the demo notebooks for a more thorough tutorial:

  1. Implementing Sliceline on Titanic dataset

  2. Implementing Sliceline on California housing dataset

🛠 Installation

Sliceline is intended to work with Python 3.10 or above. Installation can be done with pip:

pip install sliceline

There are wheels available for Linux, MacOS, and Windows, which means that you most probably won’t have to build Sliceline from source.

You can install the latest development version from GitHub as so:

pip install git+https://github.com/DataDome/sliceline --upgrade

Or, through SSH:

pip install git+ssh://git@github.com/datadome/sliceline.git --upgrade

👐 Contributing

Feel free to contribute in any way you like, we’re always open to new ideas and approaches.

  • Open a discussion if you have any question or enquiry whatsoever. It’s more useful to ask your question in public rather than sending us a private email. It’s also encouraged to open a discussion before contributing, so that everyone is aligned and unnecessary work is avoided.

  • Feel welcome to open an issue if you think you’ve spotted a bug or a performance issue.

Please check out the contribution guidelines if you want to bring modifications to the code base.

📝 License

Sliceline is free and open-source software licensed under the 3-clause BSD license.

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

sliceline-0.2.22.tar.gz (18.2 kB view details)

Uploaded Source

Built Distribution

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

sliceline-0.2.22-py3-none-any.whl (18.2 kB view details)

Uploaded Python 3

File details

Details for the file sliceline-0.2.22.tar.gz.

File metadata

  • Download URL: sliceline-0.2.22.tar.gz
  • Upload date:
  • Size: 18.2 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for sliceline-0.2.22.tar.gz
Algorithm Hash digest
SHA256 cae58d7d2cfb63d668ca8771db4fe89b5840d65415716369402ac6ff9e053e7e
MD5 15a8b38de8c785de2b38c9c862267cfa
BLAKE2b-256 b68a7dd094cc87cc22c973cf49dc21e9e737ec8566ab1d6db0b6cc4ceb8930d2

See more details on using hashes here.

Provenance

The following attestation bundles were made for sliceline-0.2.22.tar.gz:

Publisher: release.yml on DataDome/sliceline

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file sliceline-0.2.22-py3-none-any.whl.

File metadata

  • Download URL: sliceline-0.2.22-py3-none-any.whl
  • Upload date:
  • Size: 18.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for sliceline-0.2.22-py3-none-any.whl
Algorithm Hash digest
SHA256 4b11416bba0ab0da04affd08ed7449dd912922443c7def1ed05db9ee2c5a6131
MD5 7070fbe795e3a17b65e6f9b87bda500c
BLAKE2b-256 162ed062fd3e90ba405d4c3e6281100cb4816119ae79e3a8930ea1404bc9679b

See more details on using hashes here.

Provenance

The following attestation bundles were made for sliceline-0.2.22-py3-none-any.whl:

Publisher: release.yml on DataDome/sliceline

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

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