Skip to main content

facebookresearch

Getting Started with PPL Bench

What is PPL Bench?

PPL Bench is a new benchmark framework for evaluating probabilistic programming languages (PPLs).

Installing

  1. Download/Clone PPL Bench:

    git clone https://github.com/facebookresearch/pplbench.git

  2. Installing dependencies:

    1. Enter a virtual (or conda) environment

    2. Install PPL Bench core:

      pip install .

    3. Install PPLs that you wish to benchmark. For PPL-specific instructions, see Installing PPLs. You could also run the following command to install all PPLs that are currently supported by PPL Bench (except for Jags):

      pip install .[ppls]

Getting Started

Let's dive right in with a benchmark run of Bayesian Logistic Regression. To run this, you'll need to install PyStan (if you haven't already):

pip install pystan

Then, run PPL Bench with example config:

pplbench examples/example.json

This will create a benchmark run with two trials of Stan on the Bayesian Logistic Regression model. The results of the run are saved in the pplbench/outputs/ directory.

This is what the Predictive Log Likelihood (PLL) plot should look like: PLL plot of example run

Please see the examples/example.json file to understand the schema for specifying benchmark runs. The schema is documented in pplbench/main.py and can be printed by running the help command:

pplbench -h

A number of models is available in the pplbench/models directory and the PPL implementations are available in the pplbench/ppls directory.

Please feel free to submit pull requests to modify an existing PPL implementation or to add a new PPL or model.

Join the PPL Bench community

For more information about PPL Bench, refer to

  1. Blog post: link
  2. Paper: link

See the CONTRIBUTING.md file for how to help out.

License

This source code is licensed under the MIT license found in the LICENSE file in the root directory of this source tree.

Metadata

Release files for pplbench 0.0.1

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

Source distribution (sdist)

Source distribution for pplbench 0.0.1
File Size Uploaded Provenance Actions
pplbench-0.0.1.tar.gz 26.8 kB Without provenance Details for pplbench-0.0.1.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for pplbench 0.0.1
File Interpreter ABI Platform Actions
pplbench-0.0.1-py3-none-any.whl Python 3 none any Details for pplbench-0.0.1-py3-none-any.whl

Total release size: 74.1 kB

Release files / pplbench-0.0.1.tar.gz

Download URL pplbench-0.0.1.tar.gz
Size 26.8 kB
Tags Source
SHA-256 checksum
How to use checksums
d50991fa3f26b54e04a6c564272e771d8a4e869ce96696bafb2ce56052ac3119
BLAKE2b-256 checksum
How to use checksums
9084e45135c26564a99adf3691cb2788898d1c2ba46b7456efee362f1aec5faf
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.7.9

Release files / pplbench-0.0.1-py3-none-any.whl

Download URL pplbench-0.0.1-py3-none-any.whl
Size 47.3 kB
Tags Python 3
SHA-256 checksum
How to use checksums
6199538a6676e0e6f7e23dfd5c5a5bf8de47bb976e9bd3dc4e756ba6ef2cdf4c
BLAKE2b-256 checksum
How to use checksums
f63e21de0afb14da2c6bf4dbec0a4f658f1b573232294d63095a8bbf9dcf82a0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.2.0 pkginfo/1.6.0 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.50.2 CPython/3.7.9

Security for pplbench 0.0.1

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.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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