Skip to main content

Useful utility functions for evaluation of ML

Project description

ddplt

Useful utility functions for evaluation of ML.

Motivation: The main motivation behind this package is to create a single place where the utility functions for ML projects are located. These functions represent the best I was able to scrape from various tutorials or offical documentation on the web.

Confusion matrix

This function prints and plots the confusion matrix.

The code:

import numpy as np
from ddplt import plot_confusion_matrix

y_test = np.array([0, 0, 1, 1, 2, 0])
y_pred = np.array([0, 1, 1, 2, 2, 0])
class_names = np.array(['hip', 'hop', 'pop'])
ax, cm = plot_confusion_matrix(y_test, y_pred, class_names)

will create a plot like: conf_matrix

Learning curve

Create plot showing performance evaluation for different sizes of training data. The method should accept:

  • existing Axes
  • performance measure (e.g. accuracy, MSE, precision, recall, etc.)
  • ...

ROC curve

Plot showing Receiver Operating Characteristics of a predictor.

Correlation heatmap

Grid where each square has a color denoting strength of a correlation between predictors. You can choose between Pearson and Spearman correlation coefficient, the result is shown inside the square.

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

ddplt-0.0.2.dev2.tar.gz (2.8 kB view details)

Uploaded Source

Built Distributions

ddplt-0.0.2.dev2-py3.6.egg (3.1 kB view details)

Uploaded Source

ddplt-0.0.2.dev2-py3-none-any.whl (15.5 kB view details)

Uploaded Python 3

File details

Details for the file ddplt-0.0.2.dev2.tar.gz.

File metadata

  • Download URL: ddplt-0.0.2.dev2.tar.gz
  • Upload date:
  • Size: 2.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 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 ddplt-0.0.2.dev2.tar.gz
Algorithm Hash digest
SHA256 34992fa28f2707c28e5b6a8f49f10eb7a5a87275f37c24a70132867b6e5b8c4b
MD5 c112a2ee72f14a0c86757ef785fe218b
BLAKE2b-256 ade0a753fad51b2b4ead8aabff2f9ed63215ff7a035e15433ccc50a467c83f85

See more details on using hashes here.

File details

Details for the file ddplt-0.0.2.dev2-py3.6.egg.

File metadata

  • Download URL: ddplt-0.0.2.dev2-py3.6.egg
  • Upload date:
  • Size: 3.1 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 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 ddplt-0.0.2.dev2-py3.6.egg
Algorithm Hash digest
SHA256 46e476db61c8a759224350ad915e1f2026f994f1d81fc3bc454962bb644ba030
MD5 093bdfd9e7415888f49e54c13ceef601
BLAKE2b-256 7e608d92a4bf70490b96f2ac0c43936c718a3dbf62a0bfa04560cbb35869c739

See more details on using hashes here.

File details

Details for the file ddplt-0.0.2.dev2-py3-none-any.whl.

File metadata

  • Download URL: ddplt-0.0.2.dev2-py3-none-any.whl
  • Upload date:
  • Size: 15.5 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/1.13.0 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 ddplt-0.0.2.dev2-py3-none-any.whl
Algorithm Hash digest
SHA256 c2f8fa1c4b6910c8281959416c87239de57892a27313320866cec88ba0df895f
MD5 aa50c17376f2c807a7affd81c00cfec5
BLAKE2b-256 f30fe33979e7bc5a1118abeae162dd6e59a703f884f09bd71e05ef299e079be5

See more details on using hashes here.

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