Skip to main content

Simple python package to sanitize in a standard way ML-related labels.

Project description

Travis CI build SonarCloud Quality SonarCloud Maintainability Codacy Maintainability Maintainability Pypi project Pypi total project downloads

Simple python package to sanitize in a standard way ML-related labels.

How do I install this package?

As usual, just download it using pip:

pip install sanitize_ml_labels

Tests Coverage

Since some software handling coverages sometime get slightly different results, here’s three of them:

Coveralls Coverage SonarCloud Coverage Code Climate Coverate

Usage examples

So you have some kind of plot and you have some ML-related labels. Since I always rename and sanitize them the same way, I have prepared this package to always sanitize them in a standard fashion.

from sanitize_ml_labels import sanitize_ml_labels

# Example for metrics
labels = [
    "acc",
    "loss",
    "auroc",
    "lr"
]

sanitize_ml_labels(labels)

# ["Accuracy", "Loss", "AUROC", "Learning rate"]

# Example for models
labels = [
    "vanilla mlp",
    "vanilla cnn",
    "vanilla ffnn",
    "vanilla perceptron"
]

sanitize_ml_labels(labels)

# ["MLP", "CNN", "FFNN", "Perceptron"]

New features and issues

As always, for new features and issues you can either open a new issue and pull request. A pull request will always be the quicker way, but I’ll look into the issues when I get the time.

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

sanitize_ml_labels-1.0.2.tar.gz (4.6 kB view details)

Uploaded Source

File details

Details for the file sanitize_ml_labels-1.0.2.tar.gz.

File metadata

  • Download URL: sanitize_ml_labels-1.0.2.tar.gz
  • Upload date:
  • Size: 4.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.12.1 pkginfo/1.5.0.1 requests/2.22.0 setuptools/41.0.1 requests-toolbelt/0.9.1 tqdm/4.32.1 CPython/3.7.3

File hashes

Hashes for sanitize_ml_labels-1.0.2.tar.gz
Algorithm Hash digest
SHA256 8fc22e8e4270b663b5537f53f8d213f3a1e29118ce626f51730ba3ef1c12cebf
MD5 32e5748205c81e82d34227f9ed480c8e
BLAKE2b-256 e87109d85269fea4c2e02196cc4ef8bd393631f318bf84a1b61abbe78fc0ab55

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page