Skip to main content

Estimator for Normalized Mutual Information

Project description

NorMI: Nonparametric Normalized Mutual Information Estimator Based on $k$-NN Statistics

This software provides an extension to the Kraskov-Estimator to allow normalizing the mutual information.

The method will be published soon as:

Adaptive Entropy-Based Normalization for (High-Dimensional) Mutual Information D. Nagel, G. Diez, and G. Stock,

If you use this software package, please cite the above mentioned paper.

Features

  • Intuitive usage via module and via CI
  • Sklearn-style API for fast integration into your Python workflow
  • No magic, only a single parameter which can be optimized via cross-validation
  • Extensive documentation and detailed discussion in publication

Installation

The package is not yet published and only available directly from github

# via ssh key
python3 -m pip install git+ssh://git@github.com/moldyn/normi.git

# or via password-based login
python3 -m pip install git+https://github.com/moldyn/normi.git

Shell Completion

Using the bash, zsh or fish shell click provides an easy way to provide shell completion, checkout the docs. In the case of bash you need to add following line to your ~/.bashrc

eval "$(_NORMALIZED_MI_COMPLETE=bash_source normi)"

Usage

In general one can call the module directly by its entry point $ normi or by calling the module $ python -m normi. The latter method is preferred to ensure using the desired python environment. For enabling the shell completion, the entry point needs to be used.

CI - Usage Directly from the Command Line

The module brings a rich CI using click. Each module and submodule contains a detailed help, which can be accessed by ...

tba

Module - Inside a Python Script

from normi import NormalizedMI

# Load file
# X is np.ndarray of shape (n_samples, n_features)

nmi = NormalizedMI()
nmi.fit(X)
...

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

normi-0.1.0.tar.gz (15.9 kB view hashes)

Uploaded Source

Built Distribution

normi-0.1.0-py3-none-any.whl (12.1 kB view hashes)

Uploaded Python 3

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