Transitioning sleeping position detection in late pregnancy using computer vision from controlled to real-world settings: an observational study

Sci Rep. 2024 Jul 29;14(1):17380. doi: 10.1038/s41598-024-68472-x.

Abstract

Sleeping on the back after 28 weeks of pregnancy has recently been associated with giving birth to a small-for-gestational-age infant and late stillbirth, but whether a causal relationship exists is currently unknown and difficult to study prospectively. This study was conducted to build a computer vision model that can automatically detect sleeping position in pregnancy under real-world conditions. Real-world overnight video recordings were collected from an ongoing, Canada-wide, prospective, four-night, home sleep apnea study and controlled-setting video recordings were used from a previous study. Images were extracted from the videos and body positions were annotated. Five-fold cross validation was used to train, validate, and test a model using state-of-the-art deep convolutional neural networks. The dataset contained 39 pregnant participants, 13 bed partners, 12,930 images, and 47,001 annotations. The model was trained to detect pillows, twelve sleeping positions, and a sitting position in both the pregnant person and their bed partner simultaneously. The model significantly outperformed a previous similar model for the three most commonly occurring natural sleeping positions in pregnant and non-pregnant adults, with an 82-to-89% average probability of correctly detecting them and a 15-to-19% chance of failing to detect them when any one of them is present.

Publication types

  • Observational Study

MeSH terms

  • Adult
  • Female
  • Humans
  • Neural Networks, Computer
  • Posture / physiology
  • Pregnancy
  • Prospective Studies
  • Sleep* / physiology
  • Video Recording

Grants and funding