Our data
The trained model parameters and test vectors, as downloadable files, and every result table in one place. No raw personal strap or WHOOP data, and nothing from restricted datasets.
Built from site/content/our-data.md
Everything Pulse learned from public datasets is published here: the trained model parameters, the test vectors that keep the Python and Swift versions of each model in agreement, and every result table. The files are copied from the repository at build time, so they're always the versions the app was generated from.
What is not here, on purpose:
- Raw personal data. The author's strap recordings and WHOOP history stay on the phone and the author's Mac. Where a Lab page reports a result on “your strap”, only the summary numbers are published.
- Restricted data. DREAMT is licensed for research only; it was used for a benchmark, and only its result tables appear on this site. Nothing trained on it ships, and no part of it is redistributed.
- The public datasets themselves. Get them from their sources (see Datasets); each Lab page has the commands that download and prepare them.
Model files
Each model is small enough to run on the phone (and, later, on a microcontroller): boosted trees of depth 3 stored as
flat arrays. A file named model.json is what train.py writes and what the generated Swift in
ios/WhoopKit is made from.
Irregular rhythm check
-
model.json 109 KBalgorithms/rhythm/model.json
150 gradient-boosted trees (depth 3), feature list, alert threshold and run length
sha256 959ea7c3c800d797…
-
vectors.json 4.8 KBalgorithms/rhythm/vectors.json
Test vectors: 5 RR windows from PhysioNet records → features → probability (checked by the Swift tests)
sha256 5944a144a2cb5184…
Sleep, naps and sleep stages
-
model.json 446 KBalgorithms/sleep/model.json
Three tree models (sleep, sleepMotion, stages), stage transition matrix, priors and the held-out results
sha256 9d0719a45838481e…
-
vectors.json 359 KBalgorithms/sleep/vectors.json
Test vectors: the first 2 h of one sleep-accel night (1 Hz acceleration + HR) → features → probabilities → stages
sha256 f8418a9bb0b6ff02…
Activity recognition
-
model.json 207 KBalgorithms/activity/model.json
5-class boosted trees, feature list, classes and leave-one-person-out results (incl. confusion matrix)
sha256 eb20e76c6835ed96…
-
vectors.json 27 KBalgorithms/activity/vectors.json
Test vectors: synthetic, deterministic 10 min of acceleration + HR → features → class probabilities
sha256 a82504e542e3ec83…
Recovery and illness warning
-
coefficients.json 161 Balgorithms/recovery/coefficients.json
The recovery formula's four coefficients, fitted on the author's 336 days of WHOOP history (parameters only, no data)
sha256 f47c4ff1ac2c8aa2…
-
prior.json 203 Balgorithms/recovery/prior.json
Starting weights for a user without WHOOP history, fitted on IFH-Affect (Oura readiness, 20 people)
sha256 4c4d4baf08d2ce57…
-
illness.json 5.3 KBalgorithms/recovery/illness.json
All 36 illness-warning rules compared on the Stanford COVID-19 data, with sensitivity and false alarms
sha256 c22ad30a1a9f1612…
How to use them
The tree files hold, per model, the trees as parallel arrays (feature index, threshold, left/right child, leaf
value), the learning rate and the starting score; the feature functions are in each algorithm's Python
(rhythm.py, features.py, activity_features.py). Running a vectors.json input through those features and
trees must give the stored outputs: that is exactly what the Swift tests check.
Results
The result tables below are pulled straight from each algorithm's README. Everything is held out: by recording (rhythm), by person (sleep, activity, DREAMT, HMC) or by time (recovery, fitted on the earliest 70 % of days).
Irregular rhythm check
Results (held out by recording, 5-fold)
| Window AUC | 0.994 |
| Windows at 0.7 | sensitivity 85.2 %, specificity 99.6 %, young healthy false positives 0.41 % |
| Alerts, AF recordings | 29 / 30 flagged (miss: afdb 07859, a known regular-looking AF record) |
| Alerts, healthy people | 6 false alerts in ≈ 784 h, in 2 of 112 people |
| Alerts, arrhythmia patients without AF | 1 / 41 (frequent extra beats can look irregular) |
| Your strap data, 29 Nov morning | 33 windows, median probability 0.016, no alerts |
History: a 7-feature logistic regression reached AUC 0.989 but flagged 4.8 % of young healthy windows and mistook high HRV for irregularity (median 0.34 on the user's own resting data); the trees fixed that.
Sleep, naps and sleep stages
Results (held out by person)
| Sleep vs wake, Walch (acc + HR) | AUC 0.905, accuracy 93.8 %, sleep found 98.1 %, wake found 46.3 %, kappa 0.52 |
| Detected sleep vs PSG, per night | onset error median 4 min, final wake 0 min, total sleep time 18 min (median abs.) |
| Accelerometer only, Walch | AUC 0.905: heart rate adds nothing on this dataset (the watch's HR is sparse) |
| Accelerometer only, Walch-trained → Newcastle | AUC 0.752: a different device and sleep-clinic patients |
| Accelerometer only, Newcastle held out (trained on both) | AUC 0.805, kappa 0.49; total sleep time error 74 min (patients with fragmented sleep) |
| Stages, Walch (4 classes) | see table below |
| Stages (26 nights, 4 classes) | Accuracy | Kappa | Wake / light / deep / REM found | Minutes per night, median error (wake / light / deep / REM) |
|---|---|---|---|---|
| Trees, epoch by epoch | 65.4 % | 0.368 | 37 / 80 / 47 / 44 % | |
| + Viterbi (prior weight 0.5, used) | 65.6 % | 0.405 | 31 / 74 / 59 / 55 % | 7 / 53 / 21 / 43 |
| + Viterbi, prior weight 0 / 1 | 67.1 / 59.9 % | 0.375 / 0.387 |
Context: wrist actigraphy finds sleep easily and wake poorly (published wrist models sit at 40–60 % of wake epochs found); 4-stage accuracy of 60–70 % with kappa ≈ 0.35–0.45 is what accelerometer + heart-rate wearables reach against PSG. Consumer devices, WHOOP included, are in the same range.
Your strap, 29 Nov 2026 (validate_strap.py, 18 h of records, no tuning on it): Pulse found one sleep,
09:00 → 16:32, 434 min asleep; WHOOP scored 09:20 → 16:32, 417 min. 95 % of the epochs inside WHOOP's sleep
were asleep to Pulse, 2 % of the epochs outside it, and no false sleep or nap was reported in the 10 awake hours.
Stages: Pulse wake 44 / light 240 / deep 49 / REM 119 min; WHOOP 15 / 236 / 81 / 101. The stages move with the
baseline (WHOOP's resting HR of 56 instead of the sleep's own 52.5 turned 68 min of REM into light), which is why
the app uses the same 5th-percentile baseline as training.
DREAMT (research benchmark, not shipped)
DREAMT v2.2.0 (PhysioNet, Restricted Health Data License: research use only, so nothing trained on it ships):
100 sleep-clinic patients, most with sleep apnoea, Empatica E4 on the wrist, PSG stages. Run on the aws-silo box
with dreamt.py (download from PhysioNet's S3 access point, dreamt_get.sh as the slow fallback). Held out by
person (5 folds); 4 stages with the same Viterbi pass.
| Sleep/wake AUC | Wake found | Kappa | 4 stages accuracy | Stage kappa | |
|---|---|---|---|---|---|
| Shipped model (trained on Walch), untouched | 0.834 | 46 % | 0.44 | 55 % | 0.25 |
| Retrained on DREAMT: movement + HR | 0.843 | 49 % | 0.46 | 66 % | 0.31 |
| + HRV from E4 beats | 0.838 | 49 % | 0.45 | 65 % | 0.29 |
| + skin temperature | 0.845 | 50 % | 0.47 | 66 % | 0.31 |
| + HRV + temperature | 0.839 | 50 % | 0.46 | 65 % | 0.29 |
- The shipped sleep/wake model holds up on a different wristband and a much harder population (fragmented, apnoeic sleep): AUC 0.83 against 0.90 on Walch, close to what a model trained on DREAMT itself gets (0.84).
- Stages are where the population matters: 0.25 kappa untouched vs 0.31 retrained, mostly from deep sleep, which is rare and short in these patients.
- Beat-to-beat HRV and skin temperature don't help here. The E4's beat detection is known to drop most beats during sleep and movement, and these nights are broken by apnoea events, so this says little about the WHOOP strap's much denser beat intervals. Decision: no change to the shipped models; revisit HRV features with a dataset that has clean beats (e.g. ECG-based PSG sets such as MESA/SHHS via NSRR, which are free for research too).
HMC: does clean HRV help? (CC BY 4.0, usable in a product)
Haaglanden Medisch Centrum sleep staging database v1.1 (PhysioNet open access): 151 clinical PSG nights, lab ECG,
AASM stages. R-peaks with NeuroKit2 give clean beat intervals like the strap's. No accelerometer, so these models
are heart-only; the point is the gain from HRV (hmc.py, 5 folds held out by person, same Viterbi pass).
| Heart-only model | Sleep/wake AUC | Wake found | Kappa | 4 stages accuracy | Stage kappa | Wake / light / deep / REM found |
|---|---|---|---|---|---|---|
| Heart rate only | 0.720 | 16 % | 0.20 | 53 % | 0.24 | 26 / 72 / 50 / 24 % |
| + HRV from clean beats | 0.781 | 24 % | 0.28 | 55 % | 0.30 | 34 / 70 / 51 / 33 % |
| HRV only | 0.695 | 13 % | 0.15 | 52 % | 0.23 | 23 / 70 / 48 / 27 % |
With clean beats, HRV adds a lot on top of heart rate (stage kappa +22 %, REM found 24 → 33 %, wake 26 → 34 %), unlike DREAMT's sparse E4 beats. Whether it still adds once movement is in the model needs a dataset with both (MESA via NSRR: wrist actigraphy + ECG), which is the next step; HMC's licence allows training the shipped model on it.
Activity recognition
Results (leave one person out)
| Accuracy | 92.7 %, kappa 0.896 |
| Moving vs still | 98.3 % |
| Recall | still 97 %, walk 94 %, run 65 %, cycle 77 %, other 93 % |
| Precision | still 99 %, walk 88 %, run 65 %, cycle 92 %, other 91 % |
Running is the weak class: only 26 epochs in PAMAP2, and at 1 Hz the wrist can't see stride frequency. In the app
the strap's own step counter decides walk vs run (ActivityModel.classify): sustained cadence ≥ 140 steps/min is
running, 30–140 walking (the counter never moves for fidgets, so 30+ catches stop-and-go walking), and no steps
rules both out (then cycle / other / still by the model). Cadence is the 1.5 min centred mean. Bouts
(ActivityModel.bouts) need 10 minutes, with interruptions up to 2 minutes bridged. Pulse only suggests walks,
runs and rides; "other" bouts (housework-like movement) aren't offered as workouts.
Your strap, 29 Nov 2026 (validate_strap.py)
Two walks were recorded with Start workout that day; the detector, run afterwards on the strap's records alone, found both:
| Recorded | Detected |
|---|---|
| Walk 05:51–06:33, 3,059 steps | Walk 05:52–06:32, 3,050 steps |
| Walk 17:20–17:46, 2,163 steps | Walk 17:20–17:45, 2,153 steps |
It also found two 10-minute "other" bouts (04:26 and 19:26) with no steps, which is why "other" isn't suggested.
Recovery and illness warning
There is no public dataset with "recovery" labels, so Pulse's recovery is calibrated on your own WHOOP history,
as agreed in docs/algorithms-plan.md.
uv run --with numpy python fit.py /tmp/db/pulse.sqlite # pull the database first (docs/strap-direct.md)
Formula (Metrics.recovery): 100 · sigmoid(b0 + b1·zHRV + b2·zRHR + b3·(hours asleep − 7.5)), where zHRV and
zRHR compare last night with your previous 30 nights (HRV on a log scale). It only uses things Pulse measures
itself from the strap (HRV from beat intervals during the main sleep, resting HR, time asleep), so it works when
WHOOP hasn't scored a sleep, or without WHOOP at all.
Fit: WHOOP's own nightly HRV, resting HR, time asleep and recovery, 336 days with a 30-day baseline. Fitted on the earliest 70 %, tested on the latest 101 days it never saw:
| Mean error | Correlation | Same zone (red < 34 · yellow · green ≥ 67) | |
|---|---|---|---|
| Calibrated | 7.2 points | 0.87 | 81 % |
| Previous fixed formula | 11.2 | 0.80 | 69 % |
| Always your median | 15.6 | – | 54 % |
Coefficients (all days): intercept 0.79, zHRV 0.57, zRHR −0.02, sleep 0.22 per hour. For you, HRV carries almost everything; resting HR adds nothing once HRV is known; each hour of sleep above or below 7.5 h moves the score a little.
Caveat: Pulse's HRV (median of 5-minute RMSSD over the whole sleep) isn't measured exactly like WHOOP's, but the score uses each night relative to your own recent nights, so a constant difference cancels out. Refit as Pulse's own nights build up.
Open datasets (see DATASETS.md)
Starting weights, IFH-Affect (prior.py, 20 Oura users, CC0): the same formula fitted to Oura's readiness
score with HRV and resting HR computed Pulse's way. On each person's latest 30 % of nights: mean error 4.6 points,
r 0.76 (always-median 7.2). Oura weighs resting HR far more than HRV (zHRV 0.03, zRHR −0.14, sleep 0.23). Applied to
your WHOOP history it ranks days reasonably (r 0.65) but on Oura's compressed scale (mean error 16 points), so it is
not used for you: your own WHOOP fit is better. It's kept in RecoveryModel.prior for a user without WHOOP
history.
Illness warning, Stanford COVID-19 wearables (illness.py, 120 people, 7,829 nights, 31 with a usable symptom
date). 36 rules compared (z / robust z / bpm thresholds × 1–3 nights in a row); chosen: the most sensitive rule
with at most ~1 false alarm per 3 months:
| Rule | Caught (days −7…+3 around symptoms) | False alarms |
|---|---|---|
| Resting HR > median + 2 × 1.4826·MAD of the previous 28 nights, 2 nights in a row | 39 % (12 / 31) | 0.35 per 30 nights |
| same, 1 night | 77 % | 1.8 per 30 nights (too noisy) |
| z > 1.5, 2 nights (feasibility check) | 32 % | 0.30 |
On your 343 WHOOP nights it would have fired twice (5 Jan and 5 Aug 2026). In the app: WhoopKit/IllnessWarning.swift,
posted as an "Unusual vitals" notification with not-a-diagnosis wording.
Not used for training: same-day mood/readiness questionnaires (LifeSnaps, PMData, PANAS, Welltory) track overnight physiology only weakly (within-person r ≤ 0.16), so fitting to them would fit noise.