symphony-dt 2.0.0__tar.gz
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- symphony_dt-2.0.0/.gitignore +30 -0
- symphony_dt-2.0.0/CHANGELOG.md +27 -0
- symphony_dt-2.0.0/CITATION.cff +24 -0
- symphony_dt-2.0.0/LICENSE +28 -0
- symphony_dt-2.0.0/PKG-INFO +166 -0
- symphony_dt-2.0.0/README.md +83 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/CHANGELOG.md +48 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/CITATION.cff +35 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/LICENSE +177 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/README.md +247 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/notebooks/explorer/README.md +59 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/pyproject.toml +107 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/slurm/README.md +25 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_aggregate_all.py +34 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_aggregate_forecast_one_step.py +61 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_backend_detect.py +24 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_bootstrap_stability.py +15 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_bounded_likelihood.py +71 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_cli_version.py +11 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_clinical_event_tables.py +84 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_conditioning_numpyro_optional.py +39 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_config.py +24 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_coverage_aliases.py +142 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_crps.py +10 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_cv_splits.py +24 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_diagnostics_eval.py +24 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_dynamics_batch.py +20 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_dynamics_monotone.py +23 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_evaluation_metrics.py +34 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_explain_stability.py +8 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_extract_draws.py +13 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_forecast_horizon_locf.py +23 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_global_uq_subsample.py +47 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_inference_store.py +22 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_lcond_real_injected.py +30 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_math_core.py +15 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_notebook_ingest.py +22 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_numpyro_optional.py +13 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_nuts_cli_smoke.py +6 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_nuts_pipeline_synthetic.py +39 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_observation_model.py +56 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_omics_pipeline.py +65 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_parity_check.py +11 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_personalization_gating.py +64 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_posterior_forecast_smoke.py +71 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_ppc_pit.py +16 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_rng_streams.py +16 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_schema_contracts.py +21 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_sharding.py +21 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_states_tables.py +27 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_stratified_eval.py +26 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_subset_clinical.py +21 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_synthetic_quickstart.py +71 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_tau_conf_command.py +171 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_tau_conf_selection.py +38 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_transitions_and_clusters.py +26 -0
- symphony_dt-2.0.0/STALE_20261106T074328Z_v1/tests/test_truncnorm.py +23 -0
- symphony_dt-2.0.0/pyproject.toml +119 -0
- symphony_dt-2.0.0/src/symphony_dt/__init__.py +61 -0
- symphony_dt-2.0.0/src/symphony_dt/__main__.py +5 -0
- symphony_dt-2.0.0/src/symphony_dt/_about.py +53 -0
- symphony_dt-2.0.0/src/symphony_dt/_version.py +3 -0
- symphony_dt-2.0.0/src/symphony_dt/calibration/__init__.py +40 -0
- symphony_dt-2.0.0/src/symphony_dt/calibration/ppc.py +114 -0
- symphony_dt-2.0.0/src/symphony_dt/calibration/sbc.py +385 -0
- symphony_dt-2.0.0/src/symphony_dt/cli.py +347 -0
- symphony_dt-2.0.0/src/symphony_dt/config.py +101 -0
- symphony_dt-2.0.0/src/symphony_dt/constants.py +84 -0
- symphony_dt-2.0.0/src/symphony_dt/data/__init__.py +66 -0
- symphony_dt-2.0.0/src/symphony_dt/data/dataset.py +335 -0
- symphony_dt-2.0.0/src/symphony_dt/data/envelope.py +184 -0
- symphony_dt-2.0.0/src/symphony_dt/data/harmonise.py +113 -0
- symphony_dt-2.0.0/src/symphony_dt/data/instruments.py +140 -0
- symphony_dt-2.0.0/src/symphony_dt/data/simulate.py +505 -0
- symphony_dt-2.0.0/src/symphony_dt/data/stan_data.py +426 -0
- symphony_dt-2.0.0/src/symphony_dt/diagnostics.py +424 -0
- symphony_dt-2.0.0/src/symphony_dt/errors.py +57 -0
- symphony_dt-2.0.0/src/symphony_dt/evaluate/__init__.py +61 -0
- symphony_dt-2.0.0/src/symphony_dt/evaluate/metrics.py +308 -0
- symphony_dt-2.0.0/src/symphony_dt/evaluate/scoring.py +625 -0
- symphony_dt-2.0.0/src/symphony_dt/evaluate/spec.py +210 -0
- symphony_dt-2.0.0/src/symphony_dt/fit.py +282 -0
- symphony_dt-2.0.0/src/symphony_dt/forecast.py +683 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/__init__.py +35 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/cards.py +85 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/manifest.py +212 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/provenance.py +135 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/reproduce.py +69 -0
- symphony_dt-2.0.0/src/symphony_dt/governance/tripod.py +120 -0
- symphony_dt-2.0.0/src/symphony_dt/io/__init__.py +33 -0
- symphony_dt-2.0.0/src/symphony_dt/io/adapters.py +198 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mapping.py +339 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/fhir.yaml +21 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/generic_long.yaml +17 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/omop.yaml +19 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/ppmi.yaml +26 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/sdtm.yaml +18 -0
- symphony_dt-2.0.0/src/symphony_dt/io/mappings/wide.yaml +15 -0
- symphony_dt-2.0.0/src/symphony_dt/io/posterior.py +32 -0
- symphony_dt-2.0.0/src/symphony_dt/io/tabular.py +155 -0
- symphony_dt-2.0.0/src/symphony_dt/labels.py +89 -0
- symphony_dt-2.0.0/src/symphony_dt/models/__init__.py +233 -0
- symphony_dt-2.0.0/src/symphony_dt/models/pd_v2/__init__.py +55 -0
- symphony_dt-2.0.0/src/symphony_dt/models/pd_v2/card.md +93 -0
- symphony_dt-2.0.0/src/symphony_dt/models/pd_v2/conditional.stan +198 -0
- symphony_dt-2.0.0/src/symphony_dt/models/pd_v2/forecast_gq.stan +176 -0
- symphony_dt-2.0.0/src/symphony_dt/models/pd_v2/model.stan +289 -0
- symphony_dt-2.0.0/src/symphony_dt/plots.py +253 -0
- symphony_dt-2.0.0/src/symphony_dt/py.typed +0 -0
- symphony_dt-2.0.0/src/symphony_dt/report.py +115 -0
- symphony_dt-2.0.0/tests/__init__.py +0 -0
- symphony_dt-2.0.0/tests/conftest.py +36 -0
- symphony_dt-2.0.0/tests/data/golden/PROVENANCE.json +25 -0
- symphony_dt-2.0.0/tests/data/golden/fold1_scores.json +1628 -0
- symphony_dt-2.0.0/tests/data/golden/fold1_target_scores.csv +162 -0
- symphony_dt-2.0.0/tests/data/golden/fold2_scores.json +1628 -0
- symphony_dt-2.0.0/tests/data/golden/fold2_target_scores.csv +152 -0
- symphony_dt-2.0.0/tests/data/golden/fold3_scores.json +1628 -0
- symphony_dt-2.0.0/tests/data/golden/fold3_target_scores.csv +156 -0
- symphony_dt-2.0.0/tests/data/golden/pooled_scores.json +2146 -0
- symphony_dt-2.0.0/tests/data/golden/sbc_functions.json +1 -0
- symphony_dt-2.0.0/tests/data/golden/simulate_replicate.json +1 -0
- symphony_dt-2.0.0/tests/data/golden/stan_data_build.json +1 -0
- symphony_dt-2.0.0/tests/golden/__init__.py +0 -0
- symphony_dt-2.0.0/tests/golden/cases.py +145 -0
- symphony_dt-2.0.0/tests/golden/generate.py +164 -0
- symphony_dt-2.0.0/tests/golden/stubs/covariate_manifest.py +14 -0
- symphony_dt-2.0.0/tests/golden/stubs/fold_guard.py +25 -0
- symphony_dt-2.0.0/tests/golden/stubs/paths.py +16 -0
- symphony_dt-2.0.0/tests/golden/test_golden.py +206 -0
- symphony_dt-2.0.0/tests/test_calibration.py +98 -0
- symphony_dt-2.0.0/tests/test_data.py +269 -0
- symphony_dt-2.0.0/tests/test_diagnostics.py +110 -0
- symphony_dt-2.0.0/tests/test_docs.py +31 -0
- symphony_dt-2.0.0/tests/test_evaluate.py +204 -0
- symphony_dt-2.0.0/tests/test_forecast.py +149 -0
- symphony_dt-2.0.0/tests/test_governance.py +118 -0
- symphony_dt-2.0.0/tests/test_io.py +242 -0
- symphony_dt-2.0.0/tests/test_package.py +197 -0
- symphony_dt-2.0.0/tests/test_privacy_gate.py +30 -0
- symphony_dt-2.0.0/tests/test_slow.py +139 -0
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
# environments and caches
|
|
2
|
+
.venv/
|
|
3
|
+
.cmdstan/
|
|
4
|
+
__pycache__/
|
|
5
|
+
*.py[cod]
|
|
6
|
+
.pytest_cache/
|
|
7
|
+
.mypy_cache/
|
|
8
|
+
.ruff_cache/
|
|
9
|
+
.hypothesis/
|
|
10
|
+
.coverage
|
|
11
|
+
coverage.xml
|
|
12
|
+
htmlcov/
|
|
13
|
+
dist/
|
|
14
|
+
build/
|
|
15
|
+
site/
|
|
16
|
+
*.egg-info/
|
|
17
|
+
# Stan build products
|
|
18
|
+
src/symphony_dt/models/**/model
|
|
19
|
+
src/symphony_dt/models/**/forecast_gq
|
|
20
|
+
src/symphony_dt/models/**/conditional
|
|
21
|
+
src/symphony_dt/models/**/*.hpp
|
|
22
|
+
*.o
|
|
23
|
+
# run outputs
|
|
24
|
+
runs/
|
|
25
|
+
symphony_runs/
|
|
26
|
+
.DS_Store
|
|
27
|
+
|
|
28
|
+
# tutorial outputs
|
|
29
|
+
docs/tutorials/tutorial_*/
|
|
30
|
+
docs/coverage-badge.json
|
|
@@ -0,0 +1,27 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
All notable changes are recorded here. The project follows semantic versioning.
|
|
4
|
+
|
|
5
|
+
## [2.0.0] - 2026-11-06
|
|
6
|
+
|
|
7
|
+
A complete rewrite. Version 1 is preserved on the `v1` branch and the `v1.0-preprint` tag.
|
|
8
|
+
|
|
9
|
+
### Added
|
|
10
|
+
- pd_v2, the SYMPHONY v2 model of record, byte-identical to the study and checked by sha256 at import.
|
|
11
|
+
- `TwinDataset`, the canonical long-format data model, with coded validation errors and fingerprints.
|
|
12
|
+
- Instrument registry, validity envelope, harmonisation hooks and unit conversion.
|
|
13
|
+
- Readers and writers for CSV, TSV, Parquet, Excel, Arrow and polars; netCDF posteriors.
|
|
14
|
+
- Adapters with YAML mappings: wide tables, a generic long layout, OMOP CDM, HL7 FHIR R4, CDISC SDTM and the
|
|
15
|
+
PPMI download layout.
|
|
16
|
+
- The Stan data builder and the simulator, ported with golden tests against the study code.
|
|
17
|
+
- `fit()` with chain-level checkpoint and resume, run manifests and ArviZ output.
|
|
18
|
+
- The study's convergence gates with logged overrides.
|
|
19
|
+
- Exact-route forecasting with a generated-quantities program, and an experimental fast route.
|
|
20
|
+
- The scoring code of record (coverage, CRPS, LOCF, LMM by EM, events, bootstrap, strata), golden-tested.
|
|
21
|
+
- SBC toolkit with Bonferroni and Benjamini-Hochberg judges; posterior predictive checks.
|
|
22
|
+
- Governance: manifests, provenance, pre-registration freezes, deviation records, model and data cards,
|
|
23
|
+
TRIPOD+AI helper, reproduction command and HTML reports.
|
|
24
|
+
- `symphony-dt` command line, documentation site, tutorials and logo.
|
|
25
|
+
|
|
26
|
+
### Changed
|
|
27
|
+
- Licence from Apache-2.0 (v1) to BSD-3-Clause.
|
|
@@ -0,0 +1,24 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: "If you use this software, please cite it as below."
|
|
3
|
+
title: "symphony-dt: Bayesian digital twins of Parkinson's disease progression"
|
|
4
|
+
abstract: >-
|
|
5
|
+
A toolkit for building, checking, calibrating, forecasting with and auditing Bayesian hierarchical
|
|
6
|
+
state-space digital twins on longitudinal clinical cohorts, with the frozen SYMPHONY v2 model of
|
|
7
|
+
Parkinson's disease progression.
|
|
8
|
+
type: software
|
|
9
|
+
authors:
|
|
10
|
+
- family-names: Hemedan
|
|
11
|
+
given-names: Ahmed
|
|
12
|
+
version: 2.0.0
|
|
13
|
+
date-released: 2026-11-06
|
|
14
|
+
license: BSD-3-Clause
|
|
15
|
+
repository-code: "https://github.com/a7med7emedan/symphony-dt"
|
|
16
|
+
url: "https://a7med7emedan.github.io/symphony-dt/"
|
|
17
|
+
keywords:
|
|
18
|
+
- bayesian
|
|
19
|
+
- digital-twin
|
|
20
|
+
- parkinsons-disease
|
|
21
|
+
- stan
|
|
22
|
+
- uncertainty-quantification
|
|
23
|
+
- clinical-prediction
|
|
24
|
+
- reproducibility
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
BSD 3-Clause License
|
|
2
|
+
|
|
3
|
+
Copyright (c) 2026, Ahmed Hemedan
|
|
4
|
+
|
|
5
|
+
Redistribution and use in source and binary forms, with or without
|
|
6
|
+
modification, are permitted provided that the following conditions are met:
|
|
7
|
+
|
|
8
|
+
1. Redistributions of source code must retain the above copyright notice, this
|
|
9
|
+
list of conditions and the following disclaimer.
|
|
10
|
+
|
|
11
|
+
2. Redistributions in binary form must reproduce the above copyright notice,
|
|
12
|
+
this list of conditions and the following disclaimer in the documentation
|
|
13
|
+
and/or other materials provided with the distribution.
|
|
14
|
+
|
|
15
|
+
3. Neither the name of the copyright holder nor the names of its
|
|
16
|
+
contributors may be used to endorse or promote products derived from
|
|
17
|
+
this software without specific prior written permission.
|
|
18
|
+
|
|
19
|
+
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
20
|
+
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
21
|
+
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
|
22
|
+
DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
|
23
|
+
FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
|
24
|
+
DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
|
25
|
+
SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
|
26
|
+
CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
|
27
|
+
OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
|
28
|
+
OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
|
@@ -0,0 +1,166 @@
|
|
|
1
|
+
Metadata-Version: 2.5
|
|
2
|
+
Name: symphony-dt
|
|
3
|
+
Version: 2.0.0
|
|
4
|
+
Summary: Bayesian hierarchical state-space digital twins for longitudinal clinical cohorts, with the SYMPHONY v2 Parkinson's disease model.
|
|
5
|
+
Project-URL: Homepage, https://a7med7emedan.github.io/symphony-dt/
|
|
6
|
+
Project-URL: Documentation, https://a7med7emedan.github.io/symphony-dt/
|
|
7
|
+
Project-URL: Repository, https://github.com/a7med7emedan/symphony-dt
|
|
8
|
+
Project-URL: Issues, https://github.com/a7med7emedan/symphony-dt/issues
|
|
9
|
+
Project-URL: Changelog, https://github.com/a7med7emedan/symphony-dt/blob/main/CHANGELOG.md
|
|
10
|
+
Author: Ahmed Hemedan
|
|
11
|
+
Maintainer: Ahmed Hemedan
|
|
12
|
+
License-Expression: BSD-3-Clause
|
|
13
|
+
License-File: LICENSE
|
|
14
|
+
Keywords: bayesian,clinical-prediction,digital-twin,parkinsons-disease,reproducibility,stan,state-space-model,uncertainty-quantification
|
|
15
|
+
Classifier: Development Status :: 5 - Production/Stable
|
|
16
|
+
Classifier: Intended Audience :: Science/Research
|
|
17
|
+
Classifier: Operating System :: MacOS
|
|
18
|
+
Classifier: Operating System :: POSIX :: Linux
|
|
19
|
+
Classifier: Programming Language :: Python :: 3
|
|
20
|
+
Classifier: Programming Language :: Python :: 3.11
|
|
21
|
+
Classifier: Programming Language :: Python :: 3.12
|
|
22
|
+
Classifier: Programming Language :: Python :: 3.13
|
|
23
|
+
Classifier: Topic :: Scientific/Engineering :: Information Analysis
|
|
24
|
+
Classifier: Topic :: Scientific/Engineering :: Medical Science Apps.
|
|
25
|
+
Classifier: Typing :: Typed
|
|
26
|
+
Requires-Python: >=3.11
|
|
27
|
+
Requires-Dist: arviz>=0.18
|
|
28
|
+
Requires-Dist: cmdstanpy>=1.2
|
|
29
|
+
Requires-Dist: matplotlib>=3.8
|
|
30
|
+
Requires-Dist: numpy>=1.26
|
|
31
|
+
Requires-Dist: pandas>=2.1
|
|
32
|
+
Requires-Dist: pydantic>=2.5
|
|
33
|
+
Requires-Dist: pyyaml>=6.0
|
|
34
|
+
Requires-Dist: rich>=13.0
|
|
35
|
+
Requires-Dist: scipy>=1.11
|
|
36
|
+
Requires-Dist: typer>=0.12
|
|
37
|
+
Requires-Dist: xarray>=2023.10
|
|
38
|
+
Provides-Extra: dev
|
|
39
|
+
Requires-Dist: build>=1.2; extra == 'dev'
|
|
40
|
+
Requires-Dist: h5netcdf>=1.3; extra == 'dev'
|
|
41
|
+
Requires-Dist: h5py>=3.10; extra == 'dev'
|
|
42
|
+
Requires-Dist: hypothesis>=6.100; extra == 'dev'
|
|
43
|
+
Requires-Dist: ipykernel>=6; extra == 'dev'
|
|
44
|
+
Requires-Dist: mkdocs-jupyter>=0.24; extra == 'dev'
|
|
45
|
+
Requires-Dist: mkdocs-material>=9.5; extra == 'dev'
|
|
46
|
+
Requires-Dist: mkdocstrings[python]>=0.25; extra == 'dev'
|
|
47
|
+
Requires-Dist: mypy>=1.10; extra == 'dev'
|
|
48
|
+
Requires-Dist: nbconvert>=7; extra == 'dev'
|
|
49
|
+
Requires-Dist: openpyxl>=3.1; extra == 'dev'
|
|
50
|
+
Requires-Dist: pandas-stubs; extra == 'dev'
|
|
51
|
+
Requires-Dist: polars>=0.20; extra == 'dev'
|
|
52
|
+
Requires-Dist: pre-commit>=3.7; extra == 'dev'
|
|
53
|
+
Requires-Dist: properscoring>=0.1; extra == 'dev'
|
|
54
|
+
Requires-Dist: pyarrow>=14; extra == 'dev'
|
|
55
|
+
Requires-Dist: pytest-cov>=5; extra == 'dev'
|
|
56
|
+
Requires-Dist: pytest>=8; extra == 'dev'
|
|
57
|
+
Requires-Dist: ruff>=0.6; extra == 'dev'
|
|
58
|
+
Requires-Dist: twine>=5; extra == 'dev'
|
|
59
|
+
Requires-Dist: types-pyyaml; extra == 'dev'
|
|
60
|
+
Provides-Extra: docs
|
|
61
|
+
Requires-Dist: ipykernel>=6; extra == 'docs'
|
|
62
|
+
Requires-Dist: mkdocs-jupyter>=0.24; extra == 'docs'
|
|
63
|
+
Requires-Dist: mkdocs-material>=9.5; extra == 'docs'
|
|
64
|
+
Requires-Dist: mkdocstrings[python]>=0.25; extra == 'docs'
|
|
65
|
+
Requires-Dist: nbconvert>=7; extra == 'docs'
|
|
66
|
+
Provides-Extra: io
|
|
67
|
+
Requires-Dist: h5netcdf>=1.3; extra == 'io'
|
|
68
|
+
Requires-Dist: h5py>=3.10; extra == 'io'
|
|
69
|
+
Requires-Dist: openpyxl>=3.1; extra == 'io'
|
|
70
|
+
Requires-Dist: polars>=0.20; extra == 'io'
|
|
71
|
+
Requires-Dist: pyarrow>=14; extra == 'io'
|
|
72
|
+
Provides-Extra: test
|
|
73
|
+
Requires-Dist: h5netcdf>=1.3; extra == 'test'
|
|
74
|
+
Requires-Dist: h5py>=3.10; extra == 'test'
|
|
75
|
+
Requires-Dist: hypothesis>=6.100; extra == 'test'
|
|
76
|
+
Requires-Dist: openpyxl>=3.1; extra == 'test'
|
|
77
|
+
Requires-Dist: polars>=0.20; extra == 'test'
|
|
78
|
+
Requires-Dist: properscoring>=0.1; extra == 'test'
|
|
79
|
+
Requires-Dist: pyarrow>=14; extra == 'test'
|
|
80
|
+
Requires-Dist: pytest-cov>=5; extra == 'test'
|
|
81
|
+
Requires-Dist: pytest>=8; extra == 'test'
|
|
82
|
+
Description-Content-Type: text/markdown
|
|
83
|
+
|
|
84
|
+
<p align="center">
|
|
85
|
+
<picture>
|
|
86
|
+
<source media="(prefers-color-scheme: dark)" srcset="docs/assets/logo/symphony-dt-dark.svg">
|
|
87
|
+
<img src="docs/assets/logo/symphony-dt-light.svg" alt="symphony-dt logo" width="180">
|
|
88
|
+
</picture>
|
|
89
|
+
</p>
|
|
90
|
+
|
|
91
|
+
<h1 align="center">symphony-dt</h1>
|
|
92
|
+
|
|
93
|
+
<p align="center">Bayesian hierarchical state-space digital twins for longitudinal clinical cohorts.</p>
|
|
94
|
+
|
|
95
|
+
<p align="center">
|
|
96
|
+
<a href="https://pypi.org/project/symphony-dt/"><img src="https://img.shields.io/pypi/v/symphony-dt.svg" alt="PyPI"></a>
|
|
97
|
+
<a href="https://pypi.org/project/symphony-dt/"><img src="https://img.shields.io/pypi/pyversions/symphony-dt.svg" alt="Python versions"></a>
|
|
98
|
+
<a href="https://github.com/a7med7emedan/symphony-dt/actions/workflows/ci.yml"><img src="https://github.com/a7med7emedan/symphony-dt/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
|
|
99
|
+
<a href="https://a7med7emedan.github.io/symphony-dt/"><img src="https://img.shields.io/endpoint?url=https://a7med7emedan.github.io/symphony-dt/coverage-badge.json" alt="Coverage"></a>
|
|
100
|
+
<a href="https://a7med7emedan.github.io/symphony-dt/"><img src="https://github.com/a7med7emedan/symphony-dt/actions/workflows/docs.yml/badge.svg" alt="Docs"></a>
|
|
101
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/licence-BSD--3--Clause-blue.svg" alt="Licence"></a>
|
|
102
|
+
</p>
|
|
103
|
+
|
|
104
|
+
symphony-dt builds, checks, calibrates, forecasts with and audits Bayesian digital twins of longitudinal clinical
|
|
105
|
+
cohorts. It ships **pd_v2**, the frozen model of the SYMPHONY v2 study of Parkinson's disease progression. pd_v2
|
|
106
|
+
follows MDS-UPDRS Part III, MoCA and SCOPA-AUT over time, in Stan, driven from Python with cmdstanpy.
|
|
107
|
+
|
|
108
|
+
**Developed by Ahmed Hemedan.** Validation manuscript in preparation.
|
|
109
|
+
|
|
110
|
+
## Install
|
|
111
|
+
|
|
112
|
+
```bash
|
|
113
|
+
pip install "symphony-dt[io]"
|
|
114
|
+
python -m cmdstanpy.install_cmdstan --version 2.39.0
|
|
115
|
+
symphony-dt check --compile
|
|
116
|
+
```
|
|
117
|
+
|
|
118
|
+
## A ten-line example
|
|
119
|
+
|
|
120
|
+
```python
|
|
121
|
+
import numpy as np
|
|
122
|
+
from symphony_dt.data import simulate_cohort
|
|
123
|
+
from symphony_dt.fit import fit
|
|
124
|
+
from symphony_dt.forecast import split_at_anchor, forecast_exact
|
|
125
|
+
|
|
126
|
+
cohort = simulate_cohort(60, seed=1) # synthetic data only
|
|
127
|
+
split = split_at_anchor(cohort.stan_data, list(range(0, 60, 4)), anchor_years=2.0)
|
|
128
|
+
result = fit(split.fit, chains=4, iter_warmup=1000, iter_sampling=1000, output_dir="run")
|
|
129
|
+
print("\n".join(result.gates().summary_lines())) # the study's convergence gates
|
|
130
|
+
forecast = forecast_exact(result, split, total_keep=400)
|
|
131
|
+
print(forecast.interval(0.95).head())
|
|
132
|
+
```
|
|
133
|
+
|
|
134
|
+
## What it does
|
|
135
|
+
|
|
136
|
+
- A validated, long-format data model with a design-envelope check. Adapters read wide tables, OMOP CDM, HL7 FHIR
|
|
137
|
+
R4, CDISC SDTM and the PPMI download layout.
|
|
138
|
+
- The pd_v2 model of record, byte-identical to the study and checked by sha256 at import.
|
|
139
|
+
- Fitting with chain-level resume, and the study's convergence gates fixed in one place.
|
|
140
|
+
- Exact forecasts by the study's design, and an experimental fast route for new participants.
|
|
141
|
+
- The scoring code of record: interval coverage, CRPS, LOCF and mixed-model baselines, events, bootstrap.
|
|
142
|
+
- Simulation-based calibration with explicit multiplicity control, and posterior predictive checks.
|
|
143
|
+
- Run manifests, data fingerprints, pre-registration freezes, PROV provenance, model and data cards.
|
|
144
|
+
|
|
145
|
+
Every public function carries a validation label: VALIDATED, TESTED or EXPERIMENTAL. See the
|
|
146
|
+
[documentation](https://a7med7emedan.github.io/symphony-dt/).
|
|
147
|
+
|
|
148
|
+
## Governance
|
|
149
|
+
|
|
150
|
+
> **No participant data ship with this package, and none may be added.** Tests, examples and tutorials use the
|
|
151
|
+
> package's own simulator. A privacy gate runs before every commit and in CI. The model was developed on PPMI data
|
|
152
|
+
> under the PPMI data use agreement; obtain PPMI data yourself from PPMI. No PPMI-derived result appears here until
|
|
153
|
+
> the validation manuscript is published. The twin's forecasts are associational: no causal, treatment or
|
|
154
|
+
> deployment claim is made. See [GOVERNANCE.md](GOVERNANCE.md).
|
|
155
|
+
|
|
156
|
+
## Citation
|
|
157
|
+
|
|
158
|
+
> Hemedan A. symphony-dt: Bayesian digital twins of Parkinson's disease progression, version 2.0.0.
|
|
159
|
+
> https://github.com/a7med7emedan/symphony-dt
|
|
160
|
+
|
|
161
|
+
See [CITATION.cff](CITATION.cff).
|
|
162
|
+
|
|
163
|
+
## Licence
|
|
164
|
+
|
|
165
|
+
BSD-3-Clause, copyright Ahmed Hemedan. Version 1 remains on the `v1` branch and the `v1.0-preprint` tag under its
|
|
166
|
+
original Apache-2.0 licence.
|
|
@@ -0,0 +1,83 @@
|
|
|
1
|
+
<p align="center">
|
|
2
|
+
<picture>
|
|
3
|
+
<source media="(prefers-color-scheme: dark)" srcset="docs/assets/logo/symphony-dt-dark.svg">
|
|
4
|
+
<img src="docs/assets/logo/symphony-dt-light.svg" alt="symphony-dt logo" width="180">
|
|
5
|
+
</picture>
|
|
6
|
+
</p>
|
|
7
|
+
|
|
8
|
+
<h1 align="center">symphony-dt</h1>
|
|
9
|
+
|
|
10
|
+
<p align="center">Bayesian hierarchical state-space digital twins for longitudinal clinical cohorts.</p>
|
|
11
|
+
|
|
12
|
+
<p align="center">
|
|
13
|
+
<a href="https://pypi.org/project/symphony-dt/"><img src="https://img.shields.io/pypi/v/symphony-dt.svg" alt="PyPI"></a>
|
|
14
|
+
<a href="https://pypi.org/project/symphony-dt/"><img src="https://img.shields.io/pypi/pyversions/symphony-dt.svg" alt="Python versions"></a>
|
|
15
|
+
<a href="https://github.com/a7med7emedan/symphony-dt/actions/workflows/ci.yml"><img src="https://github.com/a7med7emedan/symphony-dt/actions/workflows/ci.yml/badge.svg" alt="CI"></a>
|
|
16
|
+
<a href="https://a7med7emedan.github.io/symphony-dt/"><img src="https://img.shields.io/endpoint?url=https://a7med7emedan.github.io/symphony-dt/coverage-badge.json" alt="Coverage"></a>
|
|
17
|
+
<a href="https://a7med7emedan.github.io/symphony-dt/"><img src="https://github.com/a7med7emedan/symphony-dt/actions/workflows/docs.yml/badge.svg" alt="Docs"></a>
|
|
18
|
+
<a href="LICENSE"><img src="https://img.shields.io/badge/licence-BSD--3--Clause-blue.svg" alt="Licence"></a>
|
|
19
|
+
</p>
|
|
20
|
+
|
|
21
|
+
symphony-dt builds, checks, calibrates, forecasts with and audits Bayesian digital twins of longitudinal clinical
|
|
22
|
+
cohorts. It ships **pd_v2**, the frozen model of the SYMPHONY v2 study of Parkinson's disease progression. pd_v2
|
|
23
|
+
follows MDS-UPDRS Part III, MoCA and SCOPA-AUT over time, in Stan, driven from Python with cmdstanpy.
|
|
24
|
+
|
|
25
|
+
**Developed by Ahmed Hemedan.** Validation manuscript in preparation.
|
|
26
|
+
|
|
27
|
+
## Install
|
|
28
|
+
|
|
29
|
+
```bash
|
|
30
|
+
pip install "symphony-dt[io]"
|
|
31
|
+
python -m cmdstanpy.install_cmdstan --version 2.39.0
|
|
32
|
+
symphony-dt check --compile
|
|
33
|
+
```
|
|
34
|
+
|
|
35
|
+
## A ten-line example
|
|
36
|
+
|
|
37
|
+
```python
|
|
38
|
+
import numpy as np
|
|
39
|
+
from symphony_dt.data import simulate_cohort
|
|
40
|
+
from symphony_dt.fit import fit
|
|
41
|
+
from symphony_dt.forecast import split_at_anchor, forecast_exact
|
|
42
|
+
|
|
43
|
+
cohort = simulate_cohort(60, seed=1) # synthetic data only
|
|
44
|
+
split = split_at_anchor(cohort.stan_data, list(range(0, 60, 4)), anchor_years=2.0)
|
|
45
|
+
result = fit(split.fit, chains=4, iter_warmup=1000, iter_sampling=1000, output_dir="run")
|
|
46
|
+
print("\n".join(result.gates().summary_lines())) # the study's convergence gates
|
|
47
|
+
forecast = forecast_exact(result, split, total_keep=400)
|
|
48
|
+
print(forecast.interval(0.95).head())
|
|
49
|
+
```
|
|
50
|
+
|
|
51
|
+
## What it does
|
|
52
|
+
|
|
53
|
+
- A validated, long-format data model with a design-envelope check. Adapters read wide tables, OMOP CDM, HL7 FHIR
|
|
54
|
+
R4, CDISC SDTM and the PPMI download layout.
|
|
55
|
+
- The pd_v2 model of record, byte-identical to the study and checked by sha256 at import.
|
|
56
|
+
- Fitting with chain-level resume, and the study's convergence gates fixed in one place.
|
|
57
|
+
- Exact forecasts by the study's design, and an experimental fast route for new participants.
|
|
58
|
+
- The scoring code of record: interval coverage, CRPS, LOCF and mixed-model baselines, events, bootstrap.
|
|
59
|
+
- Simulation-based calibration with explicit multiplicity control, and posterior predictive checks.
|
|
60
|
+
- Run manifests, data fingerprints, pre-registration freezes, PROV provenance, model and data cards.
|
|
61
|
+
|
|
62
|
+
Every public function carries a validation label: VALIDATED, TESTED or EXPERIMENTAL. See the
|
|
63
|
+
[documentation](https://a7med7emedan.github.io/symphony-dt/).
|
|
64
|
+
|
|
65
|
+
## Governance
|
|
66
|
+
|
|
67
|
+
> **No participant data ship with this package, and none may be added.** Tests, examples and tutorials use the
|
|
68
|
+
> package's own simulator. A privacy gate runs before every commit and in CI. The model was developed on PPMI data
|
|
69
|
+
> under the PPMI data use agreement; obtain PPMI data yourself from PPMI. No PPMI-derived result appears here until
|
|
70
|
+
> the validation manuscript is published. The twin's forecasts are associational: no causal, treatment or
|
|
71
|
+
> deployment claim is made. See [GOVERNANCE.md](GOVERNANCE.md).
|
|
72
|
+
|
|
73
|
+
## Citation
|
|
74
|
+
|
|
75
|
+
> Hemedan A. symphony-dt: Bayesian digital twins of Parkinson's disease progression, version 2.0.0.
|
|
76
|
+
> https://github.com/a7med7emedan/symphony-dt
|
|
77
|
+
|
|
78
|
+
See [CITATION.cff](CITATION.cff).
|
|
79
|
+
|
|
80
|
+
## Licence
|
|
81
|
+
|
|
82
|
+
BSD-3-Clause, copyright Ahmed Hemedan. Version 1 remains on the `v1` branch and the `v1.0-preprint` tag under its
|
|
83
|
+
original Apache-2.0 licence.
|
|
@@ -0,0 +1,48 @@
|
|
|
1
|
+
# Changelog
|
|
2
|
+
|
|
3
|
+
## Unreleased
|
|
4
|
+
|
|
5
|
+
### Fixed
|
|
6
|
+
- The NumPyro scaffold and conditioning models now use the truncated Gaussian likelihood of the Methods. Before, they scored clipped scores under an untruncated Normal, which understated the density near each scale's floor and ceiling. Posterior draws change as a result.
|
|
7
|
+
- Missing endpoints are replaced by a safe value before scoring and then masked, so they contribute neither log density nor NaN gradients.
|
|
8
|
+
- Conditioning used `log1p(exp(z))` for the softplus drive, which overflows for large `z`. It now uses the stable form, matching the scaffold.
|
|
9
|
+
- `symphony_dt.__version__` reported 0.1.0 while the package was 0.2.0. It is now read from the installed package metadata.
|
|
10
|
+
- README equations used `\operatorname`, which GitHub's maths renderer rejects, so they showed as red error boxes. They now use `\mathrm`.
|
|
11
|
+
- `select_tau_conf` targeted 95% coverage while every engine produces central 90% intervals. The target is now 0.90. Missing target scores are skipped rather than counted as misses.
|
|
12
|
+
|
|
13
|
+
### Changed
|
|
14
|
+
- Coverage columns are renamed to `cov90_updrs3`, `cov90_moca`, `cov90_scopa` and `cov90_overall`, matching the central 90% interval (5th to 95th percentile) they score. The values are unchanged: numbers reported as `cov95_*` by 0.2.0 and earlier are 90% coverage.
|
|
15
|
+
- **Deprecated:** `cov95_*` is still written alongside `cov90_*`, with identical values, for one release and will then be removed. The `evaluation_coverage` contract, `parity-check`, `aggregate-all` and `aggregate-evaluation` accept either name, so old and new run directories can be merged. `parity-check` warns when a table or notebook uses only the old names.
|
|
16
|
+
- `nuts forecast --tau-conf` has no silent default any more. Without it or `--tau-conf-json`, 1.0 is used and a warning says that gating rule 3 is inactive.
|
|
17
|
+
- The `tau_conf` grid diagnostics are keyed `cov90_le_*` (were `cov95_le_*`).
|
|
18
|
+
|
|
19
|
+
### Added
|
|
20
|
+
- `symphony-dt nuts select-tau-conf`: computes Delta and the one-step 90% interval for each training-fold anchor from the conditioning outputs, selects `tau_conf`, and writes it with the coverage and fraction kept at every grid point to JSON.
|
|
21
|
+
- `nuts forecast --tau-conf-json` reads that file. Posterior forecasts gain a `delta_iqr` column with the latent uncertainty that rule 3 compares with `tau_conf`.
|
|
22
|
+
- `ColumnRule.aliases` in the schema contracts, an `evaluation_coverage` contract checked by `parity-check`, and coverage column references in notebook introspection.
|
|
23
|
+
- Tests for the coverage aliases, and for `select-tau-conf` and `--tau-conf-json` on quickstart data.
|
|
24
|
+
- `symphony-dt --version`, and help text for the top-level command and the `nuts` group.
|
|
25
|
+
- Chains run in parallel only when JAX has one device per chain, otherwise sequentially, without a warning.
|
|
26
|
+
- Tests for the bounded likelihood against the closed-form truncated normal density, and for the version flag.
|
|
27
|
+
- Logo, wordmark and method figure under `docs/assets/`. The logo is a tulip, the Parkinson's disease symbol, whose right half is a digital twin drawn as posterior samples. Logo and wordmark adapt to dark mode.
|
|
28
|
+
- `codemeta.json`, a richer `CITATION.cff` abstract, and expanded package keywords and project links.
|
|
29
|
+
|
|
30
|
+
## 0.2.0
|
|
31
|
+
|
|
32
|
+
### Fixed
|
|
33
|
+
- `nuts forecast` no longer crashes on every conditioned run. NumPyro only records divergences by default, so `accept_prob` was never collected, its mean was `None`, and the gate raised `TypeError`. Conditioning now requests `accept_prob` (draws are unchanged), and the gate treats any missing or non-finite diagnostic as a failed run instead of crashing.
|
|
34
|
+
- Conditioning `diagnostics.json` could contain bare `NaN`, which is not valid JSON. Non-finite values are now written as `null`.
|
|
35
|
+
- Removed three unused patch modules and a hard-coded local input path from `configs/config.demo.yaml`.
|
|
36
|
+
|
|
37
|
+
### Added
|
|
38
|
+
- `symphony-dt synth`: synthetic, PPMI-shaped input tables. Every value is invented.
|
|
39
|
+
- `symphony-dt quickstart`: synthetic data, demo run and parity check in one command.
|
|
40
|
+
- `symphony-dt run --input-dir`: override the configured input directory per run.
|
|
41
|
+
- `aggregate-all` warns when shard runs are mixed with demo or full runs.
|
|
42
|
+
- Dockerfile (non-root, code only, optional NumPyro/JAX), `.dockerignore`.
|
|
43
|
+
- GitHub Actions CI: lint, tests on Python 3.10 to 3.12, inference extras, synthetic end-to-end, Docker build and run.
|
|
44
|
+
- End-to-end NUTS test on synthetic data, quickstart and diagnostics tests.
|
|
45
|
+
- Results explorer notebook unpacked into `notebooks/explorer/`. The results bundle is opt-in via `SYMPHONY_BUNDLE_GDRIVE_ID` instead of a hard-coded file ID.
|
|
46
|
+
|
|
47
|
+
## 0.1.0
|
|
48
|
+
- Initial pipeline: demo, full and shard modes, aggregation, parity checks, optional NumPyro inference.
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
cff-version: 1.2.0
|
|
2
|
+
message: "If you use this software, please cite it as below."
|
|
3
|
+
title: "symphony-dt: SYMPHONY clinic-updated digital twin for Parkinson's disease"
|
|
4
|
+
type: software
|
|
5
|
+
authors:
|
|
6
|
+
- family-names: Hemedan
|
|
7
|
+
given-names: Ahmed
|
|
8
|
+
version: 0.2.0
|
|
9
|
+
license: Apache-2.0
|
|
10
|
+
repository-code: "https://github.com/a7med7emedan/symphony-dt"
|
|
11
|
+
abstract: >-
|
|
12
|
+
symphony-dt is a reproducible Python package for a clinic-updated Bayesian
|
|
13
|
+
digital twin of Parkinson's disease. Three latent domain states (motor,
|
|
14
|
+
cognitive, autonomic) evolve under monotone stochastic dynamics with a sparse
|
|
15
|
+
cross-domain coupling and a hierarchical per-patient progression drive. A
|
|
16
|
+
bounded, truncated Gaussian observation model links them to MDS-UPDRS Part III,
|
|
17
|
+
MoCA and SCOPA-AUT. A global posterior is fitted by NUTS, conditioned per
|
|
18
|
+
patient, and propagated into multi-horizon forecasts and clinical event risk
|
|
19
|
+
curves behind confidence gating rules.
|
|
20
|
+
keywords:
|
|
21
|
+
- digital twin
|
|
22
|
+
- Parkinson's disease
|
|
23
|
+
- Bayesian inference
|
|
24
|
+
- hierarchical model
|
|
25
|
+
- state space model
|
|
26
|
+
- stochastic dynamics
|
|
27
|
+
- NUTS
|
|
28
|
+
- NumPyro
|
|
29
|
+
- JAX
|
|
30
|
+
- posterior predictive
|
|
31
|
+
- uncertainty quantification
|
|
32
|
+
- calibration
|
|
33
|
+
- clinical forecasting
|
|
34
|
+
- PPMI
|
|
35
|
+
- reproducibility
|
|
@@ -0,0 +1,177 @@
|
|
|
1
|
+
Apache License
|
|
2
|
+
Version 2.0, January 2004
|
|
3
|
+
http://www.apache.org/licenses/
|
|
4
|
+
|
|
5
|
+
TERMS AND CONDITIONS FOR USE, REPRODUCTION, AND DISTRIBUTION
|
|
6
|
+
|
|
7
|
+
1. Definitions.
|
|
8
|
+
|
|
9
|
+
"License" shall mean the terms and conditions for use, reproduction,
|
|
10
|
+
and distribution as defined by Sections 1 through 9 of this document.
|
|
11
|
+
|
|
12
|
+
"Licensor" shall mean the copyright owner or entity authorized by
|
|
13
|
+
the copyright owner that is granting the License.
|
|
14
|
+
|
|
15
|
+
"Legal Entity" shall mean the union of the acting entity and all
|
|
16
|
+
other entities that control, are controlled by, or are under common
|
|
17
|
+
control with that entity. For the purposes of this definition,
|
|
18
|
+
"control" means (i) the power, direct or indirect, to cause the
|
|
19
|
+
direction or management of such entity, whether by contract or
|
|
20
|
+
otherwise, or (ii) ownership of fifty percent (50%) or more of the
|
|
21
|
+
outstanding shares, or (iii) beneficial ownership of such entity.
|
|
22
|
+
|
|
23
|
+
"You" (or "Your") shall mean an individual or Legal Entity
|
|
24
|
+
exercising permissions granted by this License.
|
|
25
|
+
|
|
26
|
+
"Source" form shall mean the preferred form for making modifications,
|
|
27
|
+
including but not limited to software source code, documentation
|
|
28
|
+
source, and configuration files.
|
|
29
|
+
|
|
30
|
+
"Object" form shall mean any form resulting from mechanical
|
|
31
|
+
transformation or translation of a Source form, including but
|
|
32
|
+
not limited to compiled object code, generated documentation,
|
|
33
|
+
and conversions to other media types.
|
|
34
|
+
|
|
35
|
+
"Work" shall mean the work of authorship, whether in Source or
|
|
36
|
+
Object form, made available under the License, as indicated by a
|
|
37
|
+
copyright notice that is included in or attached to the work
|
|
38
|
+
(an example is provided in the Appendix below).
|
|
39
|
+
|
|
40
|
+
"Derivative Works" shall mean any work, whether in Source or Object
|
|
41
|
+
form, that is based on (or derived from) the Work and for which the
|
|
42
|
+
editorial revisions, annotations, elaborations, or other modifications
|
|
43
|
+
represent, as a whole, an original work of authorship. For the purposes
|
|
44
|
+
of this License, Derivative Works shall not include works that remain
|
|
45
|
+
separable from, or merely link (or bind by name) to the interfaces of,
|
|
46
|
+
the Work and Derivative Works thereof.
|
|
47
|
+
|
|
48
|
+
"Contribution" shall mean any work of authorship, including
|
|
49
|
+
the original version of the Work and any modifications or additions
|
|
50
|
+
to that Work or Derivative Works thereof, that is intentionally
|
|
51
|
+
submitted to Licensor for inclusion in the Work by the copyright owner
|
|
52
|
+
or by an individual or Legal Entity authorized to submit on behalf of
|
|
53
|
+
the copyright owner. For the purposes of this definition, "submitted"
|
|
54
|
+
means any form of electronic, verbal, or written communication sent
|
|
55
|
+
to the Licensor or its representatives, including but not limited to
|
|
56
|
+
communication on electronic mailing lists, source code control systems,
|
|
57
|
+
and issue tracking systems that are managed by, or on behalf of, the
|
|
58
|
+
Licensor for the purpose of discussing and improving the Work, but
|
|
59
|
+
excluding communication that is conspicuously marked or otherwise
|
|
60
|
+
designated in writing by the copyright owner as "Not a Contribution."
|
|
61
|
+
|
|
62
|
+
"Contributor" shall mean Licensor and any individual or Legal Entity
|
|
63
|
+
on behalf of whom a Contribution has been received by Licensor and
|
|
64
|
+
subsequently incorporated within the Work.
|
|
65
|
+
|
|
66
|
+
2. Grant of Copyright License. Subject to the terms and conditions of
|
|
67
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
68
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
69
|
+
copyright license to reproduce, prepare Derivative Works of,
|
|
70
|
+
publicly display, publicly perform, sublicense, and distribute the
|
|
71
|
+
Work and such Derivative Works in Source or Object form.
|
|
72
|
+
|
|
73
|
+
3. Grant of Patent License. Subject to the terms and conditions of
|
|
74
|
+
this License, each Contributor hereby grants to You a perpetual,
|
|
75
|
+
worldwide, non-exclusive, no-charge, royalty-free, irrevocable
|
|
76
|
+
(except as stated in this section) patent license to make, have made,
|
|
77
|
+
use, offer to sell, sell, import, and otherwise transfer the Work,
|
|
78
|
+
where such license applies only to those patent claims licensable
|
|
79
|
+
by such Contributor that are necessarily infringed by their
|
|
80
|
+
Contribution(s) alone or by combination of their Contribution(s)
|
|
81
|
+
with the Work to which such Contribution(s) was submitted. If You
|
|
82
|
+
institute patent litigation against any entity (including a
|
|
83
|
+
cross-claim or counterclaim in a lawsuit) alleging that the Work
|
|
84
|
+
or a Contribution incorporated within the Work constitutes direct
|
|
85
|
+
or contributory patent infringement, then any patent licenses
|
|
86
|
+
granted to You under this License for that Work shall terminate
|
|
87
|
+
as of the date such litigation is filed.
|
|
88
|
+
|
|
89
|
+
4. Redistribution. You may reproduce and distribute copies of the
|
|
90
|
+
Work or Derivative Works thereof in any medium, with or without
|
|
91
|
+
modifications, and in Source or Object form, provided that You
|
|
92
|
+
meet the following conditions:
|
|
93
|
+
|
|
94
|
+
(a) You must give any other recipients of the Work or
|
|
95
|
+
Derivative Works a copy of this License; and
|
|
96
|
+
|
|
97
|
+
(b) You must cause any modified files to carry prominent notices
|
|
98
|
+
stating that You changed the files; and
|
|
99
|
+
|
|
100
|
+
(c) You must retain, in the Source form of any Derivative Works
|
|
101
|
+
that You distribute, all copyright, patent, trademark, and
|
|
102
|
+
attribution notices from the Source form of the Work,
|
|
103
|
+
excluding those notices that do not pertain to any part of
|
|
104
|
+
the Derivative Works; and
|
|
105
|
+
|
|
106
|
+
(d) If the Work includes a "NOTICE" text file as part of its
|
|
107
|
+
distribution, then any Derivative Works that You distribute must
|
|
108
|
+
include a readable copy of the attribution notices contained
|
|
109
|
+
within such NOTICE file, excluding those notices that do not
|
|
110
|
+
pertain to any part of the Derivative Works, in at least one
|
|
111
|
+
of the following places: within a NOTICE text file distributed
|
|
112
|
+
as part of the Derivative Works; within the Source form or
|
|
113
|
+
documentation, if provided along with the Derivative Works; or,
|
|
114
|
+
within a display generated by the Derivative Works, if and
|
|
115
|
+
wherever such third-party notices normally appear. The contents
|
|
116
|
+
of the NOTICE file are for informational purposes only and
|
|
117
|
+
do not modify the License. You may add Your own attribution
|
|
118
|
+
notices within Derivative Works that You distribute, alongside
|
|
119
|
+
or as an addendum to the NOTICE text from the Work, provided
|
|
120
|
+
that such additional attribution notices cannot be construed
|
|
121
|
+
as modifying the License.
|
|
122
|
+
|
|
123
|
+
You may add Your own copyright statement to Your modifications and
|
|
124
|
+
may provide additional or different license terms and conditions
|
|
125
|
+
for use, reproduction, or distribution of Your modifications, or
|
|
126
|
+
for any such Derivative Works as a whole, provided Your use,
|
|
127
|
+
reproduction, and distribution of the Work otherwise complies with
|
|
128
|
+
the conditions stated in this License.
|
|
129
|
+
|
|
130
|
+
5. Submission of Contributions. Unless You explicitly state otherwise,
|
|
131
|
+
any Contribution intentionally submitted for inclusion in the Work
|
|
132
|
+
by You to the Licensor shall be under the terms and conditions of
|
|
133
|
+
this License, without any additional terms or conditions.
|
|
134
|
+
Notwithstanding the above, nothing herein shall supersede or modify
|
|
135
|
+
the terms of any separate license agreement you may have executed
|
|
136
|
+
with Licensor regarding such Contributions.
|
|
137
|
+
|
|
138
|
+
6. Trademarks. This License does not grant permission to use the trade
|
|
139
|
+
names, trademarks, service marks, or product names of the Licensor,
|
|
140
|
+
except as required for reasonable and customary use in describing the
|
|
141
|
+
origin of the Work and reproducing the content of the NOTICE file.
|
|
142
|
+
|
|
143
|
+
7. Disclaimer of Warranty. Unless required by applicable law or
|
|
144
|
+
agreed to in writing, Licensor provides the Work (and each
|
|
145
|
+
Contributor provides its Contributions) on an "AS IS" BASIS,
|
|
146
|
+
WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or
|
|
147
|
+
implied, including, without limitation, any warranties or conditions
|
|
148
|
+
of TITLE, NON-INFRINGEMENT, MERCHANTABILITY, or FITNESS FOR A
|
|
149
|
+
PARTICULAR PURPOSE. You are solely responsible for determining the
|
|
150
|
+
appropriateness of using or redistributing the Work and assume any
|
|
151
|
+
risks associated with Your exercise of permissions under this License.
|
|
152
|
+
|
|
153
|
+
8. Limitation of Liability. In no event and under no legal theory,
|
|
154
|
+
whether in tort (including negligence), contract, or otherwise,
|
|
155
|
+
unless required by applicable law (such as deliberate and grossly
|
|
156
|
+
negligent acts) or agreed to in writing, shall any Contributor be
|
|
157
|
+
liable to You for damages, including any direct, indirect, special,
|
|
158
|
+
incidental, or consequential damages of any character arising as a
|
|
159
|
+
result of this License or out of the use or inability to use the
|
|
160
|
+
Work (including but not limited to damages for loss of goodwill,
|
|
161
|
+
work stoppage, computer failure or malfunction, or any and all
|
|
162
|
+
other commercial damages or losses), even if such Contributor
|
|
163
|
+
has been advised of the possibility of such damages.
|
|
164
|
+
|
|
165
|
+
9. Accepting Warranty or Additional Liability. While redistributing
|
|
166
|
+
the Work or Derivative Works thereof, You may choose to offer,
|
|
167
|
+
and charge a fee for, acceptance of support, warranty, indemnity,
|
|
168
|
+
or other liability obligations and/or rights consistent with this
|
|
169
|
+
License. However, in accepting such obligations, You may act only
|
|
170
|
+
on Your own behalf and on Your sole responsibility, not on behalf
|
|
171
|
+
of any other Contributor, and only if You agree to indemnify,
|
|
172
|
+
defend, and hold each Contributor harmless for any liability
|
|
173
|
+
incurred by, or claims asserted against, such Contributor by reason
|
|
174
|
+
of your accepting any such warranty or additional liability.
|
|
175
|
+
|
|
176
|
+
END OF TERMS AND CONDITIONS
|
|
177
|
+
|