Skip to main content

Discretized Interpretable Multi Layer Perceptron (DIMLP) and related algorithms

Project description

dimlpfidex build

Discretized Interpretable Multi Layer Perceptron (DIMLP) and related algorithms

Installation

pip install dimlpfidex

Contribution

Get the project code

To get the latest source code, install git and clone the repository:

$ git clone https://github.com/HES-XPLAIN/dimlpfidex.git

To download the required dependencies on your system, run:

$ git submodule init
$ git submodule update

Install C++ toolchain

Linux, macOS, Windows/WSL

Install with your package manager:

  • a C++ compiler (gcc/g++)
  • the ninja build system (ninja or ninja-build)
  • cmake

Windows

[!TIP] Consider using Windows/WSL instead.

winget install Microsoft.VisualStudio.2022.Community

The MSVC compiler is necessary for proper packaging of the bindings.

winget install Kitware.CMake

Ensure cmake.exe is accessible in the $PATH environment variable.

cmake.exe --version

[!NOTE] You will have to restart your computer for the changes to take effect.

Install Python

Install Python, version 3.9 or newer (3.11 is recommended):

  • Linux, macOS, Windows/WSL: Use your package manager to install python3 and python3-dev
  • Windows: winget install Python.Python.3.11

[!WARNING] On Windows, avoid installing Python through the Microsoft Store as the package has additional permission restrictions.

Install Python dependencies

Using pip

python -m venv .venv
source .venv/bin/activate
pip install .

[!NOTE] On Windows, use .venv\Scripts\activate instead.

Work with virtualenv

To activate the virtualenv, use the standard methods:

  • Unix: source .venv/bin/activate
  • Windows: .venv\Scripts\activate

To leave the virtualenv, use deactivate.

Add dependencies

To add new dependencies to the project, add them to the pyproject.toml file. To add them to the virtualenv, use:

pip install .

Install Pre-commit hooks

Git hooks are used to ensure quality checks are run by all developers every time before a commit.

Install with pip install pre-commit.

To enable pre-commit:

pre-commit install

Pre-commit hooks can be run manually with:

pre-commit run --all-files

Compile

Compile:

mkdir build && cd build
cmake ..
cmake --build .

[!NOTE] On Windows, you may have to use cmake -DCMAKE_PREFIX_PATH="C:\<absolute\path\to>\.venv" .. instead.

[!TIP] To speed up the compilation process, you can also add -j X with X being your number of CPU cores.

[!WARNING] If you need to rebuild the project, you must erase the content of the build/ directory.

Package

Create archives for distribution, from the root of the project:

python -m build

Documentation

Install Doxygen:

  • Linux, macOS, Windows/WSL: Use your package manager to install doxygen
  • Windows: winget install DimitriVanHeesch.Doxygen

Create the documentation:

mkdir build && cd build
cmake -DBUILD_DOCUMENTATION=ON ..
cmake --build .

The generated HTML documentation will be found in build/docs/sphinx.

Release

To publish the package on PyPI, refer to RELEASE.

Credits

Our test suite is using Obesity or CVD risk dataset from AravindPCoder (under CC BY-SA 4.0 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

dimlpfidex-1.0.1.tar.gz (8.7 MB view details)

Uploaded Source

Built Distributions

dimlpfidex-1.0.1-cp312-cp312-win_amd64.whl (632.6 kB view details)

Uploaded CPython 3.12 Windows x86-64

dimlpfidex-1.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (900.1 kB view details)

Uploaded CPython 3.12 manylinux: glibc 2.17+ x86-64

dimlpfidex-1.0.1-cp312-cp312-macosx_14_0_arm64.whl (921.0 kB view details)

Uploaded CPython 3.12 macOS 14.0+ ARM64

dimlpfidex-1.0.1-cp311-cp311-win_amd64.whl (632.3 kB view details)

Uploaded CPython 3.11 Windows x86-64

dimlpfidex-1.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (900.9 kB view details)

Uploaded CPython 3.11 manylinux: glibc 2.17+ x86-64

dimlpfidex-1.0.1-cp311-cp311-macosx_14_0_arm64.whl (923.1 kB view details)

Uploaded CPython 3.11 macOS 14.0+ ARM64

dimlpfidex-1.0.1-cp310-cp310-win_amd64.whl (629.3 kB view details)

Uploaded CPython 3.10 Windows x86-64

dimlpfidex-1.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (897.7 kB view details)

Uploaded CPython 3.10 manylinux: glibc 2.17+ x86-64

dimlpfidex-1.0.1-cp310-cp310-macosx_14_0_arm64.whl (920.0 kB view details)

Uploaded CPython 3.10 macOS 14.0+ ARM64

dimlpfidex-1.0.1-cp39-cp39-win_amd64.whl (629.8 kB view details)

Uploaded CPython 3.9 Windows x86-64

dimlpfidex-1.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl (898.0 kB view details)

Uploaded CPython 3.9 manylinux: glibc 2.17+ x86-64

dimlpfidex-1.0.1-cp39-cp39-macosx_14_0_arm64.whl (920.1 kB view details)

Uploaded CPython 3.9 macOS 14.0+ ARM64

File details

Details for the file dimlpfidex-1.0.1.tar.gz.

File metadata

  • Download URL: dimlpfidex-1.0.1.tar.gz
  • Upload date:
  • Size: 8.7 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.6

File hashes

Hashes for dimlpfidex-1.0.1.tar.gz
Algorithm Hash digest
SHA256 9f665eabc4b9bdd9ecd3ddcbad21b7fc2ae19a454cab30c0c8b9d4ec544257c6
MD5 29b8609aed3fc7137c46f886f36eb788
BLAKE2b-256 26ebc02e6b7acfb17ee878f3d28815b69eb8ac90165053ac9854a82bd75995fd

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp312-cp312-win_amd64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp312-cp312-win_amd64.whl
Algorithm Hash digest
SHA256 a3988e795b842534d9f1a4ac54fc906b9fbba00e16ed61cc6f08f0520ab165b4
MD5 4f18db3186b0bb7ac28bef93ff772232
BLAKE2b-256 74be17cd23508213b6ec59232c9458500b2dd29469bed2f350dc4a4eafc4fa78

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp312-cp312-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5ff0d4fb788225cc4c69e30519831bcaf7ccc7a732828f558b6783d23b4636fe
MD5 71d3b1c1e7adf0f8f18664609530d696
BLAKE2b-256 7296ceb8fd936a3e52c5ae603a33f171473c4ea94227afe2f06707aec0654433

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp312-cp312-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp312-cp312-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 e9a984b453608bb471af9bbca0387d67d8fb4e89aa8ed1b0f98c6b9ea9284236
MD5 7070aa2dab2e0badebbf2e133421228d
BLAKE2b-256 4428ed706862f91ca447ce09b97cb8eb573382e2deca400713792a9648c6da3d

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp311-cp311-win_amd64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp311-cp311-win_amd64.whl
Algorithm Hash digest
SHA256 3e39247f5cce213d409488757bebb2b3dca24f5f4c88066fab62c34a9d3a25a9
MD5 2f0a8f3c79a976c2c8de39f748b7dd7f
BLAKE2b-256 43ef985574e5ce2d57fa7b0cc6c5a3985043f24b34cb72f30015b11d16d83ce5

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp311-cp311-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 806b4e4d791700a4f8f844f9f6711e2319c3c119265dbaf94a9de7e8f07e2c37
MD5 01b66c55681f3faf741b46cddea19871
BLAKE2b-256 0a6434ef3e3353fd094483e18a066f3491f788da0f85f821bedc42892735b2f9

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp311-cp311-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp311-cp311-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 7ff39564ac93e9fe1b6f21a4f261342f91bf1de96e3d07408d12b9dcc4a0c8fb
MD5 cc056acba9cc0d6b3e92f032fee3e1c0
BLAKE2b-256 60b3a639ba443f9cff03a09c2defc7edda5ff77f954d7d7836bad077121af338

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp310-cp310-win_amd64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp310-cp310-win_amd64.whl
Algorithm Hash digest
SHA256 17702dbb39a31261ee901bc42270661b0c54dece5264371238178a55df8994be
MD5 e1d1ef5712cc01e386f4973017eb754a
BLAKE2b-256 9edffd0c5de06e8148698c8521cec3b52489b795def69a24159a11454c1c16b2

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp310-cp310-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 5f3e56911a7010237408fc9d1e5614d7811d7b67cd740be205f6f1cb289c1164
MD5 a7132f465e90dc93fd7f4842a136a86b
BLAKE2b-256 8fe2f9cf3a65bc396dc55602e3f45b718bd66099992217dcc0490d3b9f080243

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp310-cp310-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp310-cp310-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 a0bc3435e7175eebff8d7e5ccfdd15500b347b945bc8edd7f6ed296285d76790
MD5 b5252ed2bcdb1da34651ac6f27540a82
BLAKE2b-256 d294b1e9dfd25b5166e3731b296175f03f15ef43422e3c90616e58019bcdeeba

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp39-cp39-win_amd64.whl.

File metadata

  • Download URL: dimlpfidex-1.0.1-cp39-cp39-win_amd64.whl
  • Upload date:
  • Size: 629.8 kB
  • Tags: CPython 3.9, Windows x86-64
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.12.6

File hashes

Hashes for dimlpfidex-1.0.1-cp39-cp39-win_amd64.whl
Algorithm Hash digest
SHA256 0dd278e6ec96b74886ee2fe1073e00a26a933ad7e4d5a3862a948e22a8657719
MD5 b4fad90f3f7a8da33020c0c1d1120953
BLAKE2b-256 bb5ba517776703b2a4a1ce31da3e597005e574aff9f82d698f777777c502c458

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp39-cp39-manylinux_2_17_x86_64.manylinux2014_x86_64.whl
Algorithm Hash digest
SHA256 e70e6d5d1ed17909e68bef48dc926d56bdd0725d35d428dfd376af9962ddc347
MD5 6633b4f3aa888613d45414f59e55e7a9
BLAKE2b-256 da3a36baa4dd62da30480307005806c5b35826a484c1b7b94583e2ebe8a109dd

See more details on using hashes here.

File details

Details for the file dimlpfidex-1.0.1-cp39-cp39-macosx_14_0_arm64.whl.

File metadata

File hashes

Hashes for dimlpfidex-1.0.1-cp39-cp39-macosx_14_0_arm64.whl
Algorithm Hash digest
SHA256 e34c2b2a0fcec4888354076387a3cd387dca229ba66f0414b6f510913ef5f1d6
MD5 9c54e4cb18047da4303066b4a01a8a4f
BLAKE2b-256 ae5a82c77147f325bba0c6407d7a1c1ccf46b296893f74c6d37c6d9088d5305f

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