Skip to main content

ML VizKit

PyPI Docs Site Python uv CI Status License: MIT

CI Docs Links Dependabot

profile logo

Reusable visualizations for inspecting, comparing, and explaining trained machine-learning models.

ML VizKit provides high-level Python functions for common machine-learning visualizations. It works with trained models, predictions, and experiment results produced by libraries such as scikit-learn.

The package does not train models, select features, choose algorithms, or make analytical decisions.

Design

  • Accept already-trained models, predictions, or completed experiment results.
  • Reuse established visualization primitives from scikit-learn when they exist.
  • Add small higher-level visualizations where the underlying libraries do not.
  • Return Matplotlib Axes objects.
  • Never call plt.show().
  • Keep analytical choices visible to the caller.
  • Keep the implementation readable and replaceable.

Install

uv add ml-vizkit

Example

from ml_vizkit import show_confusion_matrix

ax = show_confusion_matrix(y_test, y_pred)
ax.set_title("Penguin Species Classification")

The caller controls display and composition. In a script, for example:

import matplotlib.pyplot as plt

ax = show_confusion_matrix(y_test, y_pred)
plt.show()

Initial API

Classification:

  • show_decision_boundary()
  • show_confusion_matrix()
  • show_prediction_errors()
  • show_class_distribution()

Regression:

  • show_actual_vs_predicted()
  • show_residuals()

Model inspection:

  • show_feature_importance()

Experiment inspection:

  • show_train_test_split()
  • compare_splits()
  • compare_models()

Developer Command Reference

Show command reference

In a machine terminal

Open a machine terminal where you want the project:

git clone https://github.com/analytics-toolworks/ml-vizkit

cd ml-vizkit
code .

In a VS Code terminal

uv self update
uv python pin 3.14
uv python install
uv lock --upgrade
uv sync

uv run pre-commit install
uv run pre-commit autoupdate

git add -A
uv run pre-commit run --all-files
# repeat if changes were made
uv run pre-commit run --all-files

# types, tests, docs
uv run ty check
uv run python -m pytest
uv run python -m zensical build

# save progress
git add -A
git commit -m "update"
git push -u origin main

Documentation

Annotations

.annotations/annotations.md

Citation

CITATION.cff

License

MIT

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

ml_vizkit-0.0.2.tar.gz (12.7 kB view details)

Uploaded Source

Built Distribution

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

ml_vizkit-0.0.2-py3-none-any.whl (10.0 kB view details)

Uploaded Python 3

File details

Details for the file ml_vizkit-0.0.2.tar.gz.

File metadata

  • Download URL: ml_vizkit-0.0.2.tar.gz
  • Upload date:
  • Size: 12.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ml_vizkit-0.0.2.tar.gz
Algorithm Hash digest
SHA256 a64cfea6909760b7bdf4623d50f53950d20d2cf8233ab54fdf9c94aaff96012b
MD5 ccfb942f8282ce3d848cdca3e89d6732
BLAKE2b-256 6fe55ad53b522885fcf4f2a0f4c15cf7782d73b87ebf0f8b3470efecad2109b8

See more details on using hashes here.

Provenance

The following attestation bundles were made for ml_vizkit-0.0.2.tar.gz:

Publisher: release-pypi.yml on analytics-toolworks/ml-vizkit

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

File details

Details for the file ml_vizkit-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: ml_vizkit-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 10.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for ml_vizkit-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 5e87597e61a86a2fcd845d032b2ab3a67074505963eaa44ed34493a4769ccacf
MD5 e287611b8a1e3f0db39197699737f861
BLAKE2b-256 993cbb465af649099663b8e87674ea82be18c16e9036a6510d7a5ade7c7e096f

See more details on using hashes here.

Provenance

The following attestation bundles were made for ml_vizkit-0.0.2-py3-none-any.whl:

Publisher: release-pypi.yml on analytics-toolworks/ml-vizkit

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 Sentry Error logging StatusPage Status page