LiPNet treats the liver as a vascular transport network and asks a single question: what turns portal flow into portal pressure?
The answer is one identity. It follows from the definition of vascular resistance,
Because
All three loads equal 1 in a healthy donor. Flow and pressure therefore carry the same information only while
The derivation, the four predictions that follow from it and all the numbers are in THEORY.md.
Thirty-one groups from seventeen published series of adult living-donor liver transplantation. Every value in data/series.tsv carries its source table and page, and a provenance label.
| Series | Journal | Link |
|---|---|---|
| Troisi 2003 | Liver Transpl 2003;9(9):S36–41 | 10.1053/jlts.2003.50200 |
| Troisi 2005 | Am J Transplant 2005;5(6):1397–1404 | 10.1111/j.1600-6143.2005.00850.x |
| Yagi 2005 | Liver Transpl 2005;11(1):68–75 | 10.1002/lt.20317 |
| Yagi 2006 | Transplantation 2006;81(3):373–378 | 10.1097/01.tp.0000198122.15235.a7 |
| Yamada 2008 | Am J Transplant 2008;8(4):847–853 | 10.1111/j.1600-6143.2007.02144.x |
| Botha 2010 | Liver Transpl 2010;16(5):649–657 | 10.1002/lt.22043 |
| Ogura 2010 | Liver Transpl 2010;16(6):718–728 | 10.1002/lt.22059 |
| Ou 2010 | Transplant Proc 2010;42(3):876–878 | 10.1016/j.transproceed.2010.02.064 |
| Chan 2011 | Liver Transpl 2011;17(2):115–121 | 10.1002/lt.22034 |
| Ishizaki 2012 | Liver Transpl 2012;18(3):305–314 | 10.1002/lt.22440 |
| Vasavada 2014 | Int J Surg 2014;12(2):177–180 | 10.1016/j.ijsu.2013.12.006 |
| Wang 2014 | Surg Today 2015;45(8):979–985 | 10.1007/s00595-014-0999-9 |
| Alim 2016 | Liver Transpl 2016;22(12):1643–1648 | 10.1002/lt.24523 |
| Uemura 2016 | Surgery 2016;159(6):1623–1630 | 10.1016/j.surg.2016.01.009 |
| Kanetkar 2017 | J Clin Exp Hepatol 2017;7(3):235–246 | 10.1016/j.jceh.2017.01.114 |
| Osman 2017 | Hepatol Res 2017;47(4):293–302 | 10.1111/hepr.12727 |
| Yao 2018 | Transplantation 2018;102(4):623–631 | 10.1097/TP.0000000000002047 |
Every value in the extraction is sourced to its table and page in data/series.tsv.
A browser-based research calculator is available at:
https://danpc11.github.io/LiPNet/
The calculator runs locally in the browser.
Users can enter:
- current PVP,
- current CVP,
- expected pressure after a planned manoeuvre,
- a reference event rate or cohort-specific baseline.
The calculator returns:
-
$z_F$ , -
$z_P$ , -
$z_R$ , - the estimated odds ratio associated with a pressure change,
- an absolute risk estimate anchored to the user-provided baseline.
The slope, its interval, the per-series levels and the prediction bands all come from the same posterior, the primary analysis of the paper: the hierarchical model fitted to small-for-size syndrome or early graft dysfunction,
If a user provides a reference probability:
at pressure load:
the model uses:
The resulting curve therefore passes through the supplied clinical anchor.
A centre can estimate its own baseline using:
indices.baseline_from_rate(rate, mean_zP, beta)which computes:
alpha = logit(rate) - beta * mean(zP)
For local outcome data, the intercept can be recalibrated using:
indices.recalibrate(outcomes, zP, beta)while keeping the slope fixed.
This corresponds to recalibration-in-the-large, a standard first step in prediction-model updating.
src/model/
Network model:
- 2D and 3D vascular graphs
- optimization
- closed-form scaling
- allometric closure
src/predictions.py
Tests predictions P1-P4, with the sweep of the two
normalisation references behind zR (P2)
Output:
results/predictions.json
src/indices.py
Calculates:
- zF
- zP
- zR
- stratified models
- hierarchical models
- internal-external validation
- recalibration
src/fem/
Lobule-scale finite elements:
- anisotropic Darcy perfusion
- O2 with haemoglobin, ethanol, acetaldehyde, drug
- sinusoid/hepatocyte two-phase exchange, zonal membrane
- NO wall sub-model
- shape factor and z_R(z_F) back to the network
Output:
results/fem_*.json, results/fem_*.pdf
src/ipd/
Patient-level layer:
- Kaplan-Meier reconstruction (Guyot)
- within-group dispersion model
Output:
results/ipd_*.json
src/plots.py
Generates 19 stand-alone figures
src/build_app.py
Rebuilds the browser calculator
data/series.tsv
31 groups from 17 published clinical series
sfss_calculator.html
index.html
tests/
docs/FEM.md
docs/IPD.md
run_all.sh
Install the dependencies:
pip install -r requirements.txtRun the complete workflow:
./run_all.shThis reproduces:
- haemodynamic indices,
- predictions,
- statistical analyses,
- figures,
- calculator.
Typical runtime is approximately three minutes.
To run only the four main predictions:
python src/predictions.pyTo generate the summary prediction figure:
python src/plots.py predictionsThe model campaigns used to generate the cached tables are stored in:
src/model/
They include:
- optimized networks from 37 to 1478 lobules,
- 2D and 3D networks,
- exhaustive optimization on seven lobules,
- allometric closure.
The corresponding commands are documented in:
run_all.sh
The main clinical dataset is:
data/series.tsv
It contains raw published values.
The normalized indices are not stored as fixed results.
They are recalculated by:
src/indices.py
Each variable includes provenance information.
The *_basis columns identify whether each value was:
- reported,
- derived,
- imputed,
- defined by a threshold,
- not applicable.
Structural variables include:
centre_id,cohort_id,recruitment_start,recruitment_end,overlap_set,outflow,gradient_timing,gradient_sd,outcome_definition,outcome_horizon,modulation_strategy.
These fields are used to distinguish publications, cohorts, centres and overlapping patient populations.
Groups defined only by a clinical cut-off are excluded from the primary analysis.
Second partitions of already-counted cohorts are also excluded from the primary analysis.
They are reported separately in:
results/sensitivity.tsv
The seventeen series and their links are listed in Included clinical series above.
The network model represents a whole lobule as one edge of conductance src/fem/ opens that edge
up with a finite-element model of a single hexagonal lobule, and hands two things back.
The first is a shape factor. Comparing the computed resistance against an equal-area radial
annulus with the same permeability gives
The second is the part that is not geometric. Driving the lobule at a prescribed flow and
closing the loop shear
| 0.5 | 1 | 1.5 | 2 | 3 | 4 | |
|---|---|---|---|---|---|---|
| lobule |
1.21 | 1.00 | 0.85 | 0.74 | 0.59 | 0.56 |
With the feedback gain at zero this is identically 1, so the two models are nested.
Put back into the series, though, the effect is small. The dissipation-optimal network puts
21% of its resistance in the sinusoids, which is where the published measurements put it
too (0 in the cat and dog, 0.08 to 0.26 by micropuncture in the rabbit, a third in the
perfused rat) even though the share was never used in the optimisation. At that share a
graft at four times the donor's flow per gram reaches a measured
The same solve also puts 47% of the intralobular pressure drop in the quarter nearest the central vein, reproducing the outlet-dominated profile that Henriksen and Lassen derived in 1988 from a quite different argument.
The same solve carries oxygen with its haemoglobin-bound pool, ethanol through ADH and
CYP2E1, acetaldehyde, and a pericentrally cleared drug, either in one continuum or with the
sinusoid and the hepatocyte separated by a membrane of finite permeability. Without fitting, it reproduces a
periportal-to-pericentral
python src/fem/run_fem.py all
python tests/test_fem.pyThe derivation, the numerical traps and the limits are in docs/FEM.md.
The main clinical analysis uses aggregated group-level data.
Prediction 3 is based on five series from three centres (Cairo, Fukuoka, Kyoto), with 104 clinical events.
Only three series report the primary outcome.
Several Kyoto publications overlap in recruitment period.
These limitations reduce the amount of independent information available for estimating between-study heterogeneity.
CVP is not available in all studies.
When CVP is assumed as a constant within a study, it shifts all groups from that study by the same amount on the
This does not change the within-study slope because the study-specific intercept absorbs the shift.
It can, however, change the absolute position of the groups on the normalized pressure scale.
Because the available data are aggregated, the analysis can estimate:
- likelihood,
- deviance,
- observed-to-expected ratios,
- study-level slopes.
It cannot provide reliable individual-level measures such as:
- c-statistic,
- individual calibration curves,
- Brier score,
- decision-curve analysis.
These limitations apply mainly to Prediction 3.
Predictions 1, 2 and 4 do not depend on the hierarchical outcome model.
The calculator is therefore a research tool.
It is not a medical device and should not be used as a stand-alone tool for clinical decision-making.
LiPNet is a mechanistic framework, not an individual risk score. It gives a common normalised language for portal hyperperfusion, venous outflow reconstruction, small-for-size physiology, portal hypertension, hepatic resection and vascular obstruction, and it says which part of that language transfers between centres: the change in risk with a change in load does, the baseline risk does not.
The article associated with this repository is currently in preparation:
Vascular resistance modulates portal flow-pressure decoupling in partial liver grafts
Until a preprint is available, please cite the archived software release.
The software is archived on Zenodo. The version used in the article is v0.4.2:
DOI: 10.5281/zenodo.23656741 (this version) · 10.5281/zenodo.22861276 (all versions)
A machine-readable citation is also available in:
CITATION.cff
Source code is distributed under:
PolyForm Noncommercial 1.0.0
https://polyformproject.org/licenses/noncommercial/1.0.0
Clinical values stored in data/ remain the intellectual property of the authors of the original publications.
