RePyability
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 inrequirements_dev.txtanyways) - Run
pre-commit installwhich sets up the git hook scripts - If you'd like, run
pre-commit run --all-filesto 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.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| repyability-0.10.0.tar.gz | 414.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| repyability-0.10.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 876.0 kB
Release files / repyability-0.10.0.tar.gz
| Download URL | repyability-0.10.0.tar.gz |
|---|---|
| Size | 414.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
83387ae0c37bd0b65577f977c065900473ec6c8c09eab934a3a314cbeb827fdc
|
|
BLAKE2b-256 checksum How to use checksums |
de7652a3e73401e1715d425b7c951c917f182473d9f3fbc238ac7b058dfce91c
|
| 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 28, 2026.
Transparency logRelease files / repyability-0.10.0-py3-none-any.whl
| Download URL | repyability-0.10.0-py3-none-any.whl |
|---|---|
| Size | 461.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
55460ae14100de40f5bf4c6c5d366328351d8c327f6cf10a3c3bdca0ab6a5b85
|
|
BLAKE2b-256 checksum How to use checksums |
578a27996f852d25016aeb9c2d8dd8ba9c9631465f88e283b10c51f0e1e8a5c7
|
| 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 28, 2026.
Transparency log