Skip to main content

PyTensor-distributions

PyTensor-powered distributions

Overview

PyTensor-distributions provides a collection of core probability expressions implemented in PyTensor.

The goal of this package is to work as a unified, well tested and performant source for core probability expressions. This reduces redundancy across packages and allows other libraries to focus on providing specialized features and APIs on top of these core expressions.

The core expressions implemented in PyTensor-distributions are:

  • pdf: the probability density function of a distribution. (We use pdf for both discrete and continuous distributions)
  • cdf: the cumulative distribution function of a distribution.
  • ppf: the percent point function (inverse of cdf) of a distribution.
  • sf: the survival function (1 - cdf) of a distribution.
  • isf: the inverse survival function (inverse of sf) of a distribution.
  • logpdf: the log-probability of a distribution. (We use pdf for both discrete and continuous distributions)
  • logcdf: the log-cumulative distribution function of a distribution.
  • logsf: the log-survival function (1 - cdf) of a distribution
  • mean: the mean of a distribution.
  • mode: the mode of a distribution.
  • median: the median of a distribution.
  • var: the variance of a distribution.
  • std: the standard deviation of a distribution.
  • skewness: the skewness of a distribution.
  • kurtosis: the kurtosis of a distribution.
  • lmoments: The first lmoment is the mean, so we omit it. For the third and fourth L-moments, we use the ratios.
  • entropy: the entropy of a distribution.
  • rvs: the random variates of a distribution.

Some distributions may not have all of these expressions implemented.

The package follows a very minimal design, with one file per distribution and some utility files for common functions and tests. The core expressions are implemented as a collection of functions; no classes are used. This is on purpose, to keep the package as simple as possible and let other packages implement more structured APIs on top of these core expressions.

PyTensor-distributions is still in early development, and we are still adding more distributions and tests and working on improving robustness.

Contributions

PyTensor-distributions is a community project and welcomes contributions.

Code of Conduct

We follow the PyMC Code of Conduct

Donations

PyTensor-distributions, like other PyMC projects, is a non-profit project under the NumFOCUS umbrella. If you want to financially support PyTensor-distributions or other PyMC projects, you can donate here.

Sponsors

NumFOCUS

Release files for pytensor-distributions 0.3.0

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

Source distribution (sdist)

Source distribution for pytensor-distributions 0.3.0
File Size Uploaded
pytensor_distributions-0.3.0.tar.gz 42.1 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for pytensor-distributions 0.3.0
File Interpreter ABI Platform
pytensor_distributions-0.3.0-py3-none-any.whl Python 3 none any Details

Total release size: 110.3 kB

Release files / pytensor_distributions-0.3.0.tar.gz

Download URL pytensor_distributions-0.3.0.tar.gz
Size 42.1 kB
Tags Source
SHA-256 checksum
How to use checksums
6817696dc48e124802fc7bf4edb42b6ecd33dc80f67e2a4923f92d6242317417
BLAKE2b-256 checksum
How to use checksums
ca58aae9f4a3c17f534a57dc72eb9b3f2a145463867b38f9e8ae760b3f21ae5f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release files / pytensor_distributions-0.3.0-py3-none-any.whl

Download URL pytensor_distributions-0.3.0-py3-none-any.whl
Size 68.2 kB
Tags Python 3
SHA-256 checksum
How to use checksums
49952f169f9163f99b7b637d307abf32be54b09174b30cb96e0dabded8588c82
BLAKE2b-256 checksum
How to use checksums
786d529f2159233f99d1ebd640843dc7ea790ede794f0590740d6071b19ed220
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/7.0.0 CPython/3.13.14

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on Aug 28, 2026.

Transparency log

Release history Release notifications | RSS feed

0.3.2

2 release files

0.3.1

2 release files

This release

0.3.0 This release

2 release files

0.2.0

2 release files

0.1.3

2 release files

0.1.2

2 release files

0.1.1

2 release files

0.1.0

2 release files

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