Detection of Meals and Physical Activity Events From Free-Living Data of People With Diabetes

J Diabetes Sci Technol. 2023 Nov;17(6):1482-1492. doi: 10.1177/19322968221102183. Epub 2022 Jun 15.

Abstract

Background: Predicting carbohydrate intake and physical activity in people with diabetes is crucial for improving blood glucose concentration regulation. Patterns of individual behavior can be detected from historical free-living data to predict meal and exercise times. Data collected in free-living may have missing values and forgotten manual entries. While machine learning (ML) can capture meal and exercise times, missing values, noise, and errors in data can reduce the accuracy of ML algorithms.

Methods: Two recurrent neural networks (RNNs) are developed with original and imputed data sets to assess detection accuracy of meal and exercise events. Continuous glucose monitoring (CGM) data, insulin infused from pump data, and manual meal and exercise entries from free-living data are used to predict meals, exercise, and their concurrent occurrence. They contain missing values of various lengths in time, noise, and outliers.

Results: The accuracy of RNN models range from 89.9% to 95.7% for identifying the state of event (meal, exercise, both, or neither) for various users. "No meal or exercise" state is determined with 94.58% accuracy by using the best RNN (long short-term memory [LSTM] with 1D Convolution). Detection accuracy with this RNN is 98.05% for meals, 93.42% for exercise, and 55.56% for concurrent meal-exercise events.

Conclusions: The meal and exercise times detected by the RNN models can be used to warn people for entering meal and exercise information to hybrid closed-loop automated insulin delivery systems. Reliable accuracy for event detection necessitates powerful ML and large data sets. The use of additional sensors and algorithms for detecting these events and their characteristics provides a more accurate alternative.

Keywords: automated insulin delivery; deep neural network; meal detection; physical activity detection.

Publication types

  • Research Support, Non-U.S. Gov't

MeSH terms

  • Blood Glucose
  • Blood Glucose Self-Monitoring
  • Diabetes Mellitus, Type 1*
  • Exercise
  • Humans
  • Insulin
  • Meals

Substances

  • Blood Glucose
  • Insulin