Discussion
Main Findings
We collected a heterogeneous video dataset containing instances of
single participants and multiple participants, sleeping in or simulating
twelve unique sleeping positions along with a sitting position,
differing in sleeping environments and pregnancy status (third
trimester, non-pregnant), with varying usage of pillows (head, body,
pregnancy, wedge) and bed sheets (none, thin, thick; and pattern-free,
patterned, striped, textured), both in infrared scale and colour scale
video. We trained, validated, and tested a model (SLeeP AIDePt-2) on
this dataset to detect the body positions and pillow use of a pregnant
person and their bed partner (if any) appearing in an overnight video
recording of sleep. The model best detects (high AP@0.50) pillows and
the sitting, left lateral, right lateral, and supine positions and has a
relatively low false negative rate (high recall) for these detections.
The model detects less frequently occurring positions (prone, left/right
recovery, supine thorax with left/right pelvic tilt, supine pelvis with
left/right thorax tilt) less accurately and is particularly challenged
by left/right tilt on which its performance is poorest.
Strengths and Limitations
This study describes the transition of a vision-based sleeping position
detection model in preparation for real-world use in pregnancy research.
The SLeeP AIDePt-2 model has many strengths. Notably, its real-world
deployment does not require specialised equipment and takes into account
low-lighting, bedsheets, and entry/exit events. It has learned factors
unique to pregnancy anatomy and physiology such as determination of the
pelvis position (supine, tilt, lateral, recovery) and direction (left,
right). It is trained to detect multiple participants and other objects
such as pillows in bed simultaneously, enabling it to not only account
for more natural occurrences and frequencies of sleeping positions but
also more natural sleeping contexts, behaviours, objects, and
environments. Prone sleeping in late pregnancy has never been reported
in the literature as naturally occurring and, as such, we believe it is
exceedingly rare. However, we observed in our real-world dataset that
prone sleeping is common in non-pregnant adults. SLeeP AIDePt-2 is
trained to detect this. Compared to our previous
work,5SLeeP AIDePt-2 is built on an expanded dataset containing a total of 52
participants (39 pregnant, 13 bed partners), including fifteen
additional sleeping environments with no restrictions on bedsheets
(thickness or patterns) and pillows.
This study has some limitations. While the real-world dataset contains
many possible naturally occurring sleeping positions, SLeeP AIDePt-2
does not account for naturally occurring sleeping positions other than
the twelve that we predefined. The overall sample size on which SLeeP
AIDePt-2 is trained, particularly the real-world dataset, is small and
could benefit from further increases in the number of participants, bed
partners, and sleeping environments. The performance of SLeeP AIDePt-2
is sensitive to camera placement. Finally, we did not train SLeeP
AIDePt-2 to detect household pets, which could impact sleeping
position.13,14See Appendix C for further details.
Interpretation
Despite the current model (SLeeP AIDePt-2) being tested on a more
challenging test set than our previous model (SLeeP AIDePt-1) (seeAppendix C ), it significantly outperformed SLeeP AIDePt-1 for
the left lateral, supine, and right lateral positions with AP@0.50’s of
0.89 (vs. 0.72), 0.82 (vs. 0.68), and 0.84 (vs. 0.64), respectively. In
contrast, for almost all other positions (except sitting and supine
pelvis with right thorax tilt), SLeeP AIDePt-2 performed slightly worse
than SLeeP AIDePt-1. The explanation for this difference lies in the
underlying datasets. The frequencies of occurrence of the sleeping
positions in the controlled-setting dataset on which SLeeP AIDePt-1 was
built were approximately equal (Figure 1 ); however, this was
not so for the sleeping positions in the real-world dataset because
people do not spend equal time sleeping in every possible position but,
instead, shift between their two or three most comfortable positions. As
such, despite our efforts to mitigate class imbalance during training,
SLeeP AIDePt-2 is biassed to best detect the most frequent naturally
occurring sleeping positions in pregnancy and in non-pregnant adults,
which are left lateral, supine, and right lateral.
Our results are comparable to those from other vision-based sleeping
position models in non-pregnant
adults.15–20Both Li et
al,19and Mohammadi et
al,17used video recordings from a home-surveillance camera, leveraged
controlled-setting data, accounted for bed sheets, and used a similar
training methodology to us. Li et al, also combined real-world data with
their controlled-setting data, as we did, to build their
model.19Unfortunately, Li et al, did not present their model’s performance
results in a format that can be compared to ours (see Appendix
C ); however, comparing our model to Mohammadi et al,’s model, which was
trained and validated on approximately 10,000 frames, we calculated
their average recall (sensitivity) in the presence of bed sheets to be
0.64 (standard deviation 0.10), which is similar to ours (0.66, standard
deviation 0.20). Beyond this, direct comparison of SLeeP AIDePt-2 to
other vision-based models and position sensors is challenging because,
as far as we are aware, no other measurement tool accounts for the
positions of the pelvis and thorax simultaneously.