Shortcomings in the Evaluation of Blood Glucose Forecasting

Jung Min Lee, Rodica Pop-Busui, Joyce M. Lee, Jesper Fleischer, Jenna WiensIEEE Trans. Biomedical Engineering 2024 · DOI

Abstract

Most artificial pancreas systems require a blood glucose (BG) forecasting model that captures the dynamics of the human metabolic system. Machine learning researchers typically train these models by optimizing for metrics such as root mean squared error (RMSE). However, we found that when combined with a standard controller, models that minimize RMSE do not necessarily yield a higher percent time-in-range (%TIR). We compared the predictive accuracy and control performance of two forecasters: a machine learning-based model that minimizes RMSE (LSTM) and a rule-based model (Loop). Despite achieving RMSE comparable to state-of-the-art (RMSE 15.24mg/dL at 30min), LSTM only achieved 24.35% (IQR 22.35-25.61) TIR. While Loop’s prediction accuracy was worse (RMSE 19.50mg/dL at 30min, p < 0.05), it achieved higher TIR: 34.20% (IQR 31.25-41.02). Thus, the standard approach to evaluating BG forecasters could lead to poor model selection with respect to improving closed-loop control.

Introduction

Artificial Pancreas (AP) systems rely on forecasting models to predict future blood glucose (BG) levels and adjust insulin delivery accordingly. Currently, the machine learning community evaluates these models using standard statistical metrics, most notably Root Mean Squared Error (RMSE). The underlying assumption is that a model with a lower RMSE is a "better" model and will lead to better clinical outcomes for patients with Type 1 Diabetes (T1D). However, this research demonstrates that this assumption is flawed: in a closed-loop system, the causal reason for a prediction matters as much as the prediction itself.

Methodology

The researchers compared two distinct forecasting approaches:

  1. LSTM (Long Short-Term Memory): A standard recurrent neural network optimized to minimize Mean Squared Error (MSE), representing the "black-box" machine learning approach.
  2. Loop: A rule-based forecaster used in the "DIY" artificial pancreas community. It uses explicit physiological models to calculate the separate effects of insulin-on-board and carbohydrates-on-board.

To test these, they used a Model Predictive Control (MPC) algorithm on both simulated data (UVA/Padova T1D simulator) and real-world data (OhioT1DM dataset).

The Conflation Trap

A striking finding of the study is that the LSTM "conflates" variables. Because insulin and meals often occur together in training data, the LSTM learns their combined effect but fails to distinguish their individual directions.

Sensitivity analysis showing the predicted change in blood glucose when only insulin is administered. The LSTM fails to capture the expected drop compared to the Oracle and Loop models.

As shown in the figure above, when given only insulin, the LSTM predicted a trajectory that mimicked a tandem insulin/carb event, failing to show the expected sharp drop in BG. This misunderstanding of causality led the controller to make poor dosing decisions, resulting in massive amounts of "Time-Below-Range" (hypoglycemia).

Quantitative Results

The quantitative gap between statistical accuracy and clinical performance was stark. While the LSTM was more "accurate" by ~4 mg/dL in terms of RMSE, it performed significantly worse in a clinical context.

Detailed performance metrics for Oracle, LSTM, and Loop models, comparing RMSE against clinical control performance (%TIR, %TBR, %TAR).
Metric (30 min horizon) LSTM (ML-based) Loop (Rule-based)
RMSE 15.24 mg/dL (Better) 19.50 mg/dL
Time-in-Range (%TIR) 24.35% 34.20% (Better)
Time-Below-Range (%TBR) 73.91% (Dangerous) 0.00% (Safe)

As detailed in the results, the LSTM-based controller resulted in patients spending nearly 74% of their time in a hypoglycemic state. The rule-based Loop model, despite having higher statistical error, was more "clinically accurate" because its architecture explicitly separates the physics of insulin and carbohydrates.

Conclusion

Chasing lower RMSE is not enough to build a safe artificial pancreas. The paper concludes with a call to action for the ML community: we need new evaluation metrics that specifically measure a model's ability to distinguish the independent effects of carbohydrates and insulin. Simply optimizing for statistical error can lead to models that are accurate on average but dangerous in practice.

Summary updated

BibTeX
@article{lee2024shortcomings,
  author = {Jung Min Lee and Rodica Pop-Busui and Joyce M. Lee and Jesper Fleischer and Jenna Wiens},
  title = {{Shortcomings in the Evaluation of Blood Glucose Forecasting}},
  journal = {IEEE Trans. Biomedical Engineering},
  year = {2024},
  doi = {10.1109/tbme.2024.3424665},
}

Loading related content...

Figure