Skip to main content

RePyability

actions docs

Reliability Engineering Tools

This is a series of tools created to make an open source set of methods to be used by reliability engineers to make it more accessible for students right through to practicing professionals.

RePyability builds and analyses systems as reliability block diagrams (RBDs), taking already-fitted lifetime models (from surpyval or anything exposing sf/ff) as its components:

  • Fault trees: static fault trees (OR, AND and VOTE gates, repeated events) evaluated exactly, with cut sets, importance measures and conversion to and from block diagrams.
  • Reliability: exact system reliability, hazard and conditional survival; MTTF with confidence intervals; BX life; uncertainty intervals from uncertain (fitted) component models.
  • Importance: Birnbaum, improvement potential, RAW, RRW, criticality, Fussell–Vesely, structural importance and parameter sensitivity.
  • Live state: reliability, remaining life and importance given each component's current age, and covariate-dependent components.
  • Redundancy and dependence: cold, warm and hot standby; repeated nodes; load sharing; beta-factor and MGL common-cause groups.
  • Repairable systems: exact long-run availability, failure frequency and MUT/MDT/MTBF; simulated availability over time with criticality measures.
  • Simulation: seeded Monte-Carlo run to a tolerance, antithetic pairs, parallel runs, and comparisons of designs with common random numbers.
  • Cost, design and maintenance: exact and simulated running costs, including scheduled (age or block) preventive replacement at system level, with its intervals chosen for a cost or availability target, hidden failures found by periodic inspection, with the test intervals chosen for a PFDavg target, the total cost of ownership, optimal redundancy allocation (for the lowest total cost of a repairable system, too), reliability allocation by the classic named methods (equal and ARINC-style apportionment, minimum effort, cost-based), availability allocation to MTTF and MTTR targets, and age-replacement and overhaul policies.
import surpyval as surv
from repyability import NonRepairableRBD

rbd = NonRepairableRBD(
    [("s", "pump1"), ("s", "pump2"), ("pump1", "valve"), ("pump2", "valve"), ("valve", "t")],
    {
        "pump1": surv.Weibull.from_params([100, 2]),
        "pump2": surv.Weibull.from_params([100, 2]),
        "valve": surv.Weibull.from_params([200, 1.5]),
    },
)
rbd.sf(50)                     # 0.839: system reliability at t = 50
rbd.birnbaum_importance(50)    # which component matters most

New to reliability engineering? The documentation includes Learn, a short course that teaches system reliability from a single part's lifetime to designing and maintaining whole systems, working every idea out by hand and then with RePyability, with exercises and worked answers.

Install

RePyability can be installed via pip using the PyPI repository

pip install repyability

Documentation

The full documentation — tutorial, user guide, concepts and API reference — is hosted at derrynknife.github.io/RePyability.

It is built with MkDocs from the sources in docs/ and mkdocs.yml, and published to GitHub Pages on every push to master. To build and serve it locally:

pip install -e .[docs]
mkdocs serve            # then open http://127.0.0.1:8000

The source lives in docs/ and mkdocs.yml; start with docs/index.md.

Testing

Run the testing suite by simply executing:

pytest

or use coverage to get a coverage report:

coverage run -m pytest  # Run pytest under coverage's watch
coverage report         # Print coverage report
coverage html           # Make a html coverage report (really useful), open htmlcov/index.html

Pre-commit

TL;DR

  • Pip install pre-commit (it's in requirements_dev.txt anyways)
  • Run pre-commit install which sets up the git hook scripts
  • If you'd like, run pre-commit run --all-files to run the hooks on all files
  • When you go to commit, it will only proceed after all the hooks succeed

Why?

To ensure the good code quality and consistency it is recommended that when contributing to this repository to use the provided .pre-commit-config.yaml configuration for the Python package pre-commit (https://pre-commit.com). Upon making a commit, it checks that imports and requirements are sorted, syntax is up-to-date, code is formatted, linted, and statically type-checked, all with the same tools and configurations as one another.

Metadata

Release files for repyability 0.10.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 repyability 0.10.1
File Size Uploaded
repyability-0.10.1.tar.gz 415.0 kB Details

Built distribution (wheel)

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

Total release size: 877.6 kB

Release files / repyability-0.10.1.tar.gz

Download URL repyability-0.10.1.tar.gz
Size 415.0 kB
Tags Source
SHA-256 checksum
How to use checksums
ef720d59b068d988ffdd103086648c410db7cc3efc1b62b3d2cc6aa6741b3013
BLAKE2b-256 checksum
How to use checksums
3f8a12d128eaaf553d1ffbf52dde5c45feaf6a2896d26e6a7dcfe166cedadd18
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 Sep 29, 2026.

Transparency log

Release files / repyability-0.10.1-py3-none-any.whl

Download URL repyability-0.10.1-py3-none-any.whl
Size 462.6 kB
Tags Python 3
SHA-256 checksum
How to use checksums
4a7cd210bdb91fefb3423af3ed50b16669ce2626e4a292d0a99291a010d8131a
BLAKE2b-256 checksum
How to use checksums
6e87b4edc89ea5449fed639c14fcb2bb99c3c1b2c81cc2557387a7cfb4627dd0
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 Sep 29, 2026.

Transparency log

Release history Release notifications | RSS feed

0.13

2 release files

0.12

2 release files

0.11

2 release files

This release

0.10.1 This release

2 release files

0.10.0

2 release files

0.9.0

2 release files

0.8.0

2 release files

0.7.0

2 release files

0.6.0

2 release files

0.5.1

2 release files

0.5.0

2 release files

0.4.1

2 release files

0.4.0

2 release files

0.3.0

2 release files

0.2.0

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