Metadata-Version: 2.4
Name: bgnx
Version: 0.0.2
Summary: BGNX: a framework for travel time prediction (early alpha: evaluation utilities).
Author: BGNX Project
License: MIT
Keywords: travel time,ETA,transportation,evaluation,machine learning
Classifier: Development Status :: 2 - Pre-Alpha
Classifier: Intended Audience :: Science/Research
Classifier: License :: OSI Approved :: MIT License
Classifier: Programming Language :: Python :: 3
Classifier: Topic :: Scientific/Engineering
Requires-Python: >=3.9
Description-Content-Type: text/markdown
License-File: LICENSE
Requires-Dist: numpy>=1.22
Requires-Dist: scipy>=1.8
Provides-Extra: torch
Requires-Dist: torch>=2.0; extra == "torch"
Dynamic: license-file

# BGNX

**BGNX** is a framework for travel time prediction, under development.

This early alpha (0.0.x) ships only general evaluation utilities. The models and the full documentation will be
released with the accompanying publications.

```bash
pip install bgnx            # metrics and paired comparison
pip install "bgnx[torch]"   # + CPU/GPU device helper
```

```python
import numpy as np
from bgnx import metrics, paired_comparison

y  = np.array([10.0, 12.5, 30.0, 7.0])    # observed durations (minutes)
pa = np.array([11.0, 12.0, 27.0, 8.0])    # model A
pb = np.array([ 9.0, 15.0, 25.0, 9.5])    # model B

print(metrics(y, pa))                     # MAE, MedAE, MAPE, MARE, RMSLE, R2, EV
print(paired_comparison(y, pa, pb))       # MAE difference (B - A), bootstrap 95% CI, Wilcoxon p-value
```

`paired_comparison` compares two models on the **same** observations: the 95% interval of the MAE difference comes
from a paired bootstrap (resampling observations), and the paired absolute errors are compared with the Wilcoxon
signed-rank test.

License: MIT.
