Skip to main content

pyjpt — Joint Probability Trees

Joint Probability Trees

Joint Probability Trees (JPTs) are a formalism for learning and reasoning about joint probability distributions that is tractable for practical applications. JPTs support both symbolic and subsymbolic variables in a single hybrid model without relying on prior knowledge about variable dependencies or families of distributions.

JPT representations build on tree structures that partition the probability space into relevant subregions elicited from training data, rather than postulating a rigid dependency model prior to learning. Learning and inference scale linearly, and the tree structure enables white-box reasoning about any posterior probability P(Q|E), providing interpretable explanations for every inference result.

Installation

Install the core package from PyPI:

pip install pyjpt

Optional dependencies

Depending on your use case, install one or more optional dependency groups:

pip install pyjpt[matplotlib]   # matplotlib and graphviz plotting
pip install pyjpt[plotly]       # interactive plotly plotting
pip install pyjpt[seq]          # sequential/temporal models
pip install pyjpt[mlflow]       # MLflow experiment tracking

Multiple groups can be combined:

pip install pyjpt[matplotlib,mlflow]

Development setup

Clone the repository and install in editable mode with all development dependencies:

git clone https://github.com/joint-probability-trees/jpt-dev
cd jpt-dev
pip install -e ".[dev]"

By default, Cython extensions are compiled during installation. For development, you can skip pre-compilation and let pyximport handle on-the-fly compilation at runtime instead:

JPT_NO_CYTHON=1 pip install -e ".[dev]"

With on-the-fly compilation, changes to .pyx files are picked up automatically on the next import without requiring a rebuild.

Running tests

cd test
python -m unittest discover

Building distributions

python -m build            # sdist + wheel
python -m build --sdist    # source distribution only
python -m build --wheel    # wheel only

Documentation

The documentation is hosted on Read the Docs.

Building the documentation locally

Install the documentation dependencies:

pip install -r doc/requirements.txt

Then build the HTML documentation from the doc/ directory:

cd doc
make html

The output is written to doc/build/html/. Open doc/build/html/index.html in a browser to view it. The html target automatically cleans previous build artifacts before rebuilding.

Citation

If you use JPTs in your research, please cite:

@inproceedings{nyga23jpts,
    title     = {{Joint Probability Trees}},
    author    = {Daniel Nyga and Mareike Picklum and
                 Tom Schierenbeck and Michael Beetz},
    year      = {2023},
    booktitle = {arxiv.org},
    url       = {http://arxiv.org/abs/2302.07167}
}

Release files for pyjpt 1.3.4

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for pyjpt 1.3.4
File
pyjpt-1.3.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ x86-64 Details
pyjpt-1.3.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.11 CPython 3.11 Linux glibc 2.17+ x86-64 Details
pyjpt-1.3.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.10 CPython 3.10 Linux glibc 2.17+ x86-64 Details
pyjpt-1.3.4-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl CPython 3.9 CPython 3.9 Linux glibc 2.17+ x86-64 Details

Total release size: 53.7 MB

Release files / pyjpt-1.3.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL pyjpt-1.3.4-cp312-cp312-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 13.4 MB
Tags CPython 3.12 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
71f4e2a26b44a79b65259073208896df13da2377defc0e3a0399b5b8438b85c9
BLAKE2b-256 checksum
How to use checksums
0ba54d3b72a7d285e0e31adc507db6cabddb7d0982963453e7dd6ddb2ff008f8
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / pyjpt-1.3.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL pyjpt-1.3.4-cp311-cp311-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 13.8 MB
Tags CPython 3.11 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
0fdb7489234bc9f3a355e41e6e2e269f3e754a2979d9d7e1cc175d31934b5a50
BLAKE2b-256 checksum
How to use checksums
1a899bea008affbe14f158ac2e6f59720942e8a55bdaf993ce8f03191d69ab27
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / pyjpt-1.3.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL pyjpt-1.3.4-cp310-cp310-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 13.3 MB
Tags CPython 3.10 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
54e1f3bcc7c4ea44c44bb7731d2e475e7d71d75cdb7705d2fa57ae6492a5924b
BLAKE2b-256 checksum
How to use checksums
6fc6b6f0e10e80d067eccff7f0f160888f4694cdfc68cf63dc860cb68ba942fd
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release files / pyjpt-1.3.4-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl

Download URL pyjpt-1.3.4-cp39-cp39-manylinux2014_x86_64.manylinux_2_17_x86_64.whl
Size 13.2 MB
Tags CPython 3.9 Linux glibc 2.17+ x86-64
SHA-256 checksum
How to use checksums
9cbc2b7b19ff66abdbf0a03f6593c4ae22d690ea6294fd2f98cf64cf3d9341d0
BLAKE2b-256 checksum
How to use checksums
bbac9abdfd05bf467e9c9d28087df8bb94d1f3aa4e855a2d09455d3563df8c3b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.1.0 CPython/3.13.12

Release history Release notifications | RSS feed

This release

1.3.4 This release

4 release files

1.3.3

4 release files

1.3.2

4 release files

1.3.1

4 release files

1.1.1

4 release files

1.1.0

4 release files

1.0.3

4 release files

1.0.2

4 release files

1.0.1

4 release files

1.0.0

4 release files

0.1.41

1 release file

0.1.32

4 release files

0.1.31

4 release files

0.1.30

4 release files

0.1.29

4 release files

0.1.28

4 release files

0.1.27

4 release files

0.1.25

4 release files

0.1.22

4 release files

0.1.21

4 release files

0.1.19

4 release files

0.1.15

4 release files

0.1.14

3 release files

0.1.12

4 release files

0.1.10

1 release file

0.1.9

1 release file

0.1.8

1 release file

0.1.7

1 release file

0.0.0

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page