Next Article in Journal
Resistive Sensing of Seed Cotton Moisture Regain Based on Pressure Compensation
Next Article in Special Issue
Multivariable Coupled System Control Method Based on Deep Reinforcement Learning
Previous Article in Journal
Experimental Study on Calibration of Amplitude-Frequency Measurement Deviation for Microseismic Sensors in Coal Mines
Previous Article in Special Issue
Improved Generative Adversarial Network for Super-Resolution Reconstruction of Coal Photomicrographs
 
 
Font Type:
Arial Georgia Verdana
Font Size:
Aa Aa Aa
Line Spacing:
Column Width:
Background:
Article

Designing and Developing a Vision-Based System to Investigate the Emotional Effects of News on Short Sleep at Noon: An Experimental Case Study

by
Ata Jahangir Moshayedi
1,
Nafiz Md Imtiaz Uddin
1,
Amir Sohail Khan
1,
Jianxiong Zhu
2,* and
Mehran Emadi Andani
3,*
1
School of Information Engineering, Jiangxi University of Science and Technology, Ganzhou 341000, China
2
School of Mechanical Engineering, Southeast University, Nanjing 211189, China
3
Department of Neurosciences, Biomedicine and Movement Sciences, University of Verona, Via Casorati, 37131 Verona, Italy
*
Authors to whom correspondence should be addressed.
Sensors 2023, 23(20), 8422; https://doi.org/10.3390/s23208422
Submission received: 4 September 2023 / Revised: 21 September 2023 / Accepted: 22 September 2023 / Published: 12 October 2023

Abstract

:
Background: Sleep is a critical factor in maintaining good health, and its impact on various diseases has been recognized by scientists. Understanding sleep patterns and quality is crucial for investigating sleep-related disorders and their potential links to health conditions. The development of non-intrusive and contactless methods for analyzing sleep data is essential for accurate diagnosis and treatment. Methods: A novel system called the sleep visual analyzer (VSleep) was designed to analyze sleep movements and generate reports based on changes in body position angles. The system utilized camera data without requiring any physical contact with the body. A Python graphical user interface (GUI) section was developed to analyze body movements during sleep and present the data in an Excel format. To evaluate the effectiveness of the VSleep system, a case study was conducted. The participants’ movements during daytime naps were recorded. The study also examined the impact of different types of news (positive, neutral, and negative) on sleep patterns. Results: The system successfully detected and recorded various angles formed by participants’ bodies, providing detailed information about their sleep patterns. The results revealed distinct effects based on the news category, highlighting the potential impact of external factors on sleep quality and behaviors. Conclusions: The sleep visual analyzer (VSleep) demonstrated its efficacy in analyzing sleep-related data without the need for accessories. The VSleep system holds great potential for diagnosing and investigating sleep-related disorders. The proposed system is affordable, easy to use, portable, and a mobile application can be developed to perform the experiment and prepare the results.

1. Introduction

Sleep is a natural state of temporary unconsciousness and reduced sensory activity that occurs in animals, including humans. Sleep quality is an essential determinant of optimal physical and mental health. The restorative properties of sleep enable the body to repair and regenerate tissues, including muscle, bone, and skin [1]. Furthermore, the cerebral processes that occur during sleep, such as memory consolidation, decision making, and problem solving, are vital for cognitive function and overall well-being [2,3]. Sleep is also a critical regulator of the immune system, promoting the production of cytokines, which are instrumental in fighting infections and reducing inflammation [4]. Emotional regulation and mood enhancement are additional benefits of good sleep quality. In contrast, sub-optimal sleep quality has been linked to an elevated risk of chronic diseases such as diabetes, cardiovascular disease, and obesity [5]. In general, good sleep quality is a key factor in cognitive productivity and peak human performance, which should be an integral principle in people’s health and wellness regimes [6,7]. The quality of sleep can be influenced by a variety of factors, among which sleep position and posture play a significant role [1,2,8]. In order to effectively monitor, supervise, and analyze sleep, the implementation of appropriate designs and methodologies is indispensable. By employing suitable technologies and instruments, researchers and healthcare professionals can gather comprehensive data on sleep architecture, duration, efficiency, and the occurrence of specific sleep stages. One of the pivotal determinants that exhibits promising potential in monitoring sleep quality is the positioning adopted during sleep, which demonstrably exerts an impact on the overall quality of sleep [9]. Detection of sleep poses provides invaluable information about an individual’s posture, which can affect the quality of sleep in various ways [10]. Discomfort, pain, and snoring are common complaints associated with sleeping in inappropriate positions, which can lead to fragmented and disrupted sleep [11,12]. Moreover, movement patterns during sleep, such as tossing and turning, can also negatively impact sleep quality. Therefore, the detection of sleep poses and movements can be invaluable in providing insights into the frequency and duration of such activities, which is essential for a more comprehensive evaluation of sleep quality [13]. Therefore, it is essential to pay attention to the body’s angle during sleep and adjust it as necessary to promote optimal sleep quality and overall health [14].
Understanding sleep patterns is of paramount importance for overall health. Quality sleep serves as a vital component of physical and mental rejuvenation, fostering well-being. It significantly impacts cognitive functions, emotional stability, and mental health. Furthermore, sleep patterns play a pivotal role in maintaining physical health, including immune system function, cardiovascular well-being, and metabolic processes. Finally, they directly affect productivity, safety, and alertness, contributing to our ability to perform daily tasks effectively and preventing potential accidents.
Paying attention to the angle of the organs in humans during half-day sleep, as an essential point in order to optimize the quality of sleep and maintain proper posture, is considered the main goal of this research. An additional crucial factor to consider is the type and time of sleep, specifically circadian rhythm sleep [15]. By adhering to a regular sleep schedule that aligns with the circadian rhythm, individuals can enhance sleep quality and promote overall well-being [16]. Daytime sleep, known as napping, is a cultural practice observed in various societies globally. Some countries in Europe, the Middle East, and Africa have cultures where napping is prevalent. The practice of napping during the day is believed to improve cognitive function, productivity, and well-being and has significant cultural and social value [14]. Stress, anxiety, and other mental health conditions can interfere with sleep quality, as can certain medications and medical conditions [10]. The impact of news on human sleep has been a topic of interest in recent years as more people consume news through various media channels. It is reported that positive, negative, or neutral information can have a significant impact on sleep quality. Studies have shown that exposure to positive news before bedtime can have a calming effect on the mind and body, leading to better sleep quality and feeling more refreshed in the morning [17]. Conversely, exposure to negative news can lead to increased levels of stress and anxiety, which can interfere with sleep quality and lead to feelings of fatigue and exhaustion the next day [18]. Additionally, individual differences can also play a significant role in how news affects sleep, as some people may be more affected by negative news than others [19,20].
Recent investigations into the realm of sleep have embarked on a multifaceted exploration of human sleep patterns, underscoring the increasing significance of sleep studies in recent years. These endeavors encompass a diverse array of perspectives and methodologies, reflecting the growing recognition of the pivotal role that sleep plays in human lives. Jun et al., in their 2022 study, endeavored to procure data concerning the natural sleep patterns of individuals and the subsequent identification of distinct sleep phases. The data acquisition process encompassed an array of sleep behaviors, including nocturnal movements, snoring occurrences, and fluctuations in body temperature. In addition, the study incorporated an extensive set of environmental parameters such as ambient temperature, humidity levels, ambient luminance, carbon dioxide concentrations, and ambient acoustic conditions. These investigations were conducted on a diverse set of participants spanning a wide age range. To facilitate data collection, a technologically sophisticated smart pillow, equipped with eight pressure sensors, was employed, achieving an impressive posture discrimination accuracy range of 94–97% [21].
In the study conducted by Gaiduk et al. in 2023, their primary objective was to investigate the potential substitution of subjective sleep monitoring with data extracted from a Samsung Galaxy Watch 4, employing 166 overnight recordings as their dataset. This comprehensive inquiry centered on four critical sleep metrics, revealing that data acquired from the smartwatch exhibited a remarkable capacity to accurately estimate both the initiation and cessation of sleep, culminating in an average sleep efficiency of 89.72%. Nevertheless, a degree of variability was noted, particularly in the assessment of total sleep duration, thereby warranting prudence in contemplating its replacement. The feasibility of such substitutions hinges upon the establishment of acceptable congruence thresholds between objective and subjective measurements, a concept expounded upon in their research [22].
In parallel research conducted by Huang et al. in 2023, the introduction of the deconvolution and self-attention-based model (DCSAM) and the Gaussian noise data augmentation (GNDA) models ushered in innovative methodologies for the identification of sleep phases. This pioneering approach strategically addressed the challenges posed by skewed data distribution and minority representation of certain sleep phases, achieving an impressive accuracy rate of 90.26% and a macro F1 score of 86.51% when applied to pediatric data. Furthermore, their methodology showcased exceptional performance on the Sleep-EDFX dataset for adult subjects, thereby indicating its potential for augmenting medical applications. The central ambition of Huang et al.’s work resided in the enhancement of sleep-phase identification accuracy through the synergistic application of DCSAM with GNDA augmentation [23].
Furthermore, Boiko et al., in their 2023 study, sought to evaluate a non-invasive approach employing an accelerometer sensor for the measurement of cardiorespiratory variables during sleep. Their investigation also entailed the identification of the optimal sensor placement for precise data acquisition. Analyzing ballistocardiogram signals from 23 subjects, their findings revealed an average inaccuracy of 2.24 beats per minute (bpm) for heart rate and 1.52 respirations per minute (rpm) for respiratory rate, regardless of the sleep position. Gender-specific analysis demonstrated heart rate inaccuracies of 2.28 bpm for males and 1.41 bpm for females, and respiratory rate inaccuracies of 2.19 rpm for males and 1.30 rpm for females. These insights contribute to the understanding of the efficacy of utilizing accelerometer sensors for cardiorespiratory monitoring during sleep [24].
Lastly, in a separate 2023 investigation, Park and his colleagues introduced the customized deep sleep recommender system (CDSRS), meticulously designed to deliver personalized deep sleep services. Their methodology hinged on the application of k-means clustering to delineate distinct sleep patterns and the employment of a hybrid learning approach, seamlessly amalgamating user-based and cooperative filtering techniques. Data collection encompassed private information retrieved from handheld devices and AI motion beds, including parameters such as snoring, sleep duration, movement, and ambient noise. Noteworthy achievements were evident in CDSRS, surpassing conventional collaborative filtering (CF) and content-based filtering (CBF) models, evident through a 13.2% reduction in mean squared error (MSE) and a 14.7% enhancement in mean absolute percentage error (MAPE) in contrast to CF. This underscores the system’s efficacy in providing precise and personalized sleep recommendations, culminating in an impressive 94.2% accuracy rate [25].
According to a study by Baglioni et al. (2014), negative information, such as worrying news or stress-related information, can significantly impair sleep quality. Conversely, positive information, such as pleasant images or peaceful music, can improve sleep quality [26]. Several other studies have found similar results, suggesting that the type of information individuals receive before going to bed can have a significant impact on their sleep quality [27,28]. Understanding the effects of positive and negative reports on sleep quality can help individuals make informed decisions about their pre-sleep routines and ultimately improve their sleep quality and overall well-being. This paper aims to explore the effects of positive and negative information on sleep and provide a review of the relevant research in this area. The research contributions are listed below:
  • Developing the sleep visual analyzer (VSleep) system for non-intrusive analysis of sleep movements using vision data.
  • Conducting a case study on participants’ naps, revealing the impact of news categories on sleep patterns for the first time.
The authors’ research introduces a novel system for analyzing nap sleep, which is the first of its kind. This system has the potential to serve as a diagnostic tool for sleep disorders and abnormal sleep patterns. Its application could greatly contribute to the timely identification and management of related health conditions. Moreover, the proposed system offers affordability, ease of use, portability, and the capacity to develop a mobile and remote application for conducting experiments and preparing comprehensive results to analyze napping. The remaining paper is organized in the following manner: In the second section, the design aspects of the VSleep system are elaborated upon. This includes the various components of the system and the methodology used for angle calculation based on sleep movements. This section provides detailed insights into the development and implementation of the VSleep system. The third section focuses on the case study conducted to evaluate the effectiveness of the VSleep system. This section encompasses the description of the experimental protocol, including the testing conditions and the selection of participants. This section highlights the rigorous methodology employed to ensure the validity and reliability of the study’s findings. In the fourth section, the results obtained from the case study are presented and analyzed. This section includes a comprehensive analysis of the data collected during the study, which sheds light on the performance and capabilities of the VSleep system. The results are interpreted and discussed, providing valuable insights into the sleep positions, habits, and behaviors of the participants. Finally, in the fifth section, the paper concludes by summarizing the key findings and contributions of the research study. This section highlights the significance of the VSleep system in non-intrusive and contactless sleep analysis, its potential applications in diagnosing sleep-related disorders, and its role in advancing sleep medicine. The Conclusions also addresses the implications of the study’s findings for future research and developments in the field.

2. System Design

The VSleep design is a crucial component of this study, offering vision-based sensors and algorithms for accurate sleep posture monitoring. The proposed VSleep system, which operates on vision-based technology, does not require any physical contact with the participant. It relies solely on image data and is designed to function effectively with a camera placed at a specified distance from the participant (Figure 1A), eliminating the need for any direct physical interaction.
As mentioned earlier, vision-based systems used in sleep monitoring offer valuable capabilities, but they also face several challenges. These challenges include privacy concerns, camera placement and visibility, lighting conditions, and analysis complexity. Privacy concerns arise because video analysis requires capturing and analyzing video recordings of individuals during sleep, which may not be suitable for all participants or research settings. Additionally, ensuring the optimal camera placement without obstructing the sleep environment or causing discomfort to the user can be challenging. Adequate lighting is crucial for clear video analysis, and poor lighting can affect angle measurements, potentially disrupting the natural sleep environment. Furthermore, analyzing video recordings can be time consuming and require expertise in image processing and analysis, with the potential for subjectivity and human error in manual analysis or limitations in automated analysis methods. To address these issues, this paper proposes the use of a VSleep design, which helps alleviate the analysis complexity. Additionally, the experiment encountered fewer problems related to lighting conditions, camera placement, and visibility. Overall, this suggested method shows promise in resolving three out of the four challenges associated with vision-based sleep monitoring.
The VSleep design is a crucial component of this study, offering vision-based sensors and algorithms for accurate sleep posture monitoring. It integrates input data collection for the VSleep monitoring system, which uses a simple mobile camera as a precision sensor, collects data on body angles throughout the experiment time, and applies signal processing techniques to enhance accuracy. With its user-friendly interfaces, it provides valuable insights into sleep posture patterns and their impact on sleep quality (Figure 1).
The design system, as depicted in the block diagram in Figure 1, is made up of four parts: input data collection and capture data that can be used with any camera to capture the videos; capture data storage; the VSleep graphical user interface (GUI), which contains the VSleep GUI system, demonstrates display parts, and is used for data analysis; and output and body angle stamp in video and CSV format output.These parts are described below.
As exemplified in Figure 1, the meticulously designed GUI is adorned with five discernible buttons, each endowed with specific functionalities. The “browse” button, for instance, extends an invitation to users to traverse their computer’s repository of recorded video clips in the ubiquitous mp4 format, facilitating the discernment and selection of target files or directories. Upon the invocation of the “browse” button or option, a modal dialogue or folder dialogue elegantly materializes, thereby affording users the latitude to meticulously sift through and nominate the desired file or folder. Upon finalization of this selection process, the chosen pathway or file is ordinarily rendered manifest within a textual field or as an integral constituent of the broader user interface. Conversely, the “start” button, when activated, triggers a well-defined course of action or process. In this context, the act of “starting” encompasses the initiation of a program and the instigation of a program workflow that serves the discerning purpose of delineating landmarks within the confines of the video clip. The “pause” function, on the other hand, assumes the role of transiently suspending an ongoing process or task, ushering in a momentary hiatus to ensure precision and fine-tuning of proceedings. Moreover, the “export data” function assumes a pivotal function of both preserving and facilitating the seamless transference of data from the confines of the application to external files, seamlessly adopting the universally recognized CSV file format for maximal interoperability. Lastly, the “quit” function, of monumental import, concludes the user’s interaction with the application by orchestrating an elegant exit strategy. Prudent implementation of these multifaceted functions into the designed GUI inevitably culminates in a discernible augmentation of the application’s usability and functional prowess. This augmentation fosters a heightened level of intuitiveness, thereby endearing the VSleep application to its user base and rendering it resoundingly user friendly.

2.1. Input Data Collection and Captured Data for VSleep Monitoring System

The sleep system (Figure 1) analyzes video data captured by any camera and transfers the recorded data to a user’s computer. For testing, we utilized the camera of the OnePlus 9 Pro, which includes a primary 48 MP sensor with an f/1.8 aperture lens, an ultra-wide 50 MP sensor with a distinctive freeform lens design, and a 2 MP monochrome sensor. However, it is worth noting that the sleep system is compatible with various mobile phones and video-capturing devices. It should be mentioned that the height of the body should be visible in captured images. In the tested case, considering the dimensions of the bed (238.76 cm in length, 38.1 cm in height, and 125 cm in width), the distance between the camera and the bed is fixed at 100 cm at a height of 120 cm.

2.2. The Captured Data Storage

A Lenovo laptop was used with the following specifications.The PC configuration used for testing involved an NVIDIA GeForce GTX 1050 It graphics card paired with an Intel Core i7-8750H CPU @ 2.20 GHz. Notable features included support for up to an 8K display at 60 frames per second, a 90 mm fan design, and varying clock speeds. The graphics card had 4 GB of GDDR5 memory with a 128-bit interface, operating at a speed of 1752 MHz. The GPU ran at a base clock of 1291 MHz and was boosted up to 1392 MHz. Notably, the laptop exhibited a diminutive weight of 1.85 kg, rendering it highly portable and exceedingly convenient for utilization.

2.3. VSleep Graphical User Interface (VSleep GUI)

The VSleep graphical user interface (GUI) has been specifically developed for conducting human sleeping posture testing. Python (version 3.11.5), as a programming language, serves as the coding environment for designing user interfaces utilizing native elements. To facilitate the coding process, the utilization of five Python packages is imperative: OpenCV, MediaPipe, NumPy, CSV, and PyQt5. Each of these packages plays a vital role in enabling various functionalities and features of the VSleep GUI. A comprehensive overview of the responsibilities assigned to each of these packages is presented in Table 1.
The libraries mentioned in Table 1 serve as an integral component for calculating the angle and posture of the human body. At the core of the VSleep graphical user interface (GUI), the BlazePose model is employed to accurately identify and designate specific anatomical points as landmarks.
Subsequently, the angles between these landmarks are calculated, as elucidated in the subsequent sections. The angle exploration process consists of two essential elements: the landmark specifier and the angle calculation, which are comprehensively described below.

VSleep Landmark Specifier Using BlazePose Method

As mentioned before, the landmark specifier BlazePose method has already been used to specify body parts. This method is a computer vision technology developed by Google that uses deep learning algorithms to estimate the human body’s pose, including key points such as joints and limbs, from video or image input. This technology is based on the BlazeFace detection system and is designed to be lightweight and efficient, making it suitable for use on mobile devices. BlazePose has several applications, including fitness tracking, augmented reality, and virtual try-on technology. In fitness tracking, BlazePose can be used to monitor the accuracy of exercises, track progress over time, and provide feedback on form and technique. In augmented reality, BlazePose can enable realistic virtual avatars and virtual object interactions. In virtual try-on technology, BlazePose can be used to simulate how clothing or accessories would fit on a person’s body [29]. Previous research showed the capabilities and performance of BlazePose in different areas. Bazarvsky et al. (2020) [30] introduced BlazePose Full and BlazePose Lite models, which achieved accuracy rates of 84.1% (AR dataset) and 84.5% (Yoga dataset) for the Full AR dataset and 79.6% (Augmented Reality (AR) dataset) and 77.6% (Yoga dataset) for the Lite AR dataset, respectively. In another study, Mroz et al. (2021) [31] compared BlazePose to other models and found it to exhibit an average correlation of 0.88 compared to the Open Pose baseline. Min (2022) [32] proposed a BlazePose-based system for physical testing, achieving a motion recognition rate of 95.2% and a counting algorithm accuracy of 97.9%. Setiyadi et al. (2022) [33] developed a human activity detection system based on BlazePose, which demonstrated key point accuracy of 10–17% and achieved activity detection rates above 80%.
In the research conducted by S. Alsawadi et al. (2022) [34], a refined iteration of BlazePose was presented, incorporating supplementary edges to optimize spatial–temporal graph analysis. Noteworthy outcomes were observed across two distinct datasets: firstly, the Kinetics dataset showcased a commendable accuracy performance of 40.1%. Secondly, employing the cross-subject evaluation criteria on the NTU-RGB+D dataset, the proposed system achieved a notable accuracy metric of 87.59%. Overall, BlazePose’s accurate and efficient body pose estimation capabilities make it a valuable tool for a wide range of applications in computer vision and human–computer interactions [35]. Based on the available resources provided by the authors, the utilization of the BlazePose algorithm in sleep studies appears to be a novel approach regarding the chosen application, which involves analyzing body posture during sleep. The implementation of BlazePose is depicted in Figure 2. This state-of-the-art framework is designed to meticulously detect and track twelve distinctive landmarks on the human body. As depicted in Figure 2, the aforementioned twelve points encompass a comprehensive examination of the upper extremities, including the intricate structures of the shoulder region, elbows, wrist area, hips, knees, and ankles. Each of these points is meticulously assessed bilaterally, ensuring a comprehensive evaluation of both the right and left sides. A comprehensive elucidation of the BlazePose algorithm is provided in [30,31]. In this design, the angle calculation is conducted based on the landmark specified by the BlazePose model, which takes one picture and extracts key body points. Then, as shown in Figure 2C, each point is connected to another one, and it precisely infers two-dimensional human body landmarks from a single frame. The degree exploration consists of the following steps.
Obtain the landmarks: Use the BlazePose model to obtain a set of landmarks representing body parts. These landmarks are 2D coordinates (x, y) on the image or video frame. The normalized coordinates of various body landmarks detected by the MediaPipe library represent the position of specific body parts relative to the image frame.
Identify the landmarks: Locate the three specific landmarks as the angle exploration target, such as the shoulder, elbow, and wrist landmarks, named as three points (A, B, and C). Then, obtain the coordinates of the three points (A, B, and C) from the detected pose landmarks. Convert the landmark coordinates to pixel values. This is achieved by multiplying the normalized coordinates (ranging from 0 to 1) by the image dimensions (width and height). Let us denote the pixel coordinates as A ( X a , Y a ) , B ( X b , Y b ) , and C ( X c , Y c ) .
Calculate the vectors: Determine two vectors by subtracting the coordinates of the shoulder landmark from the elbow landmark ( A B ¯ ), and the coordinates of the elbow landmark from the wrist landmark ( B C ¯ ) (Equations (1) and (2)). Each vector represents the direction and magnitude between the corresponding landmarks.
A B ¯ = ( X b X a , Y b Y a )
B C ¯ = ( X c X b , Y c Y b )
Compute the dot product of two vectors: Calculate the dot product of the shoulder-to-elbow vector ( A B ¯ ) and the elbow-to-wrist vector ( B C ¯ ). The dot product measures the similarity or alignment between the vectors (Equation (3)).
D o t p r o d u c t = X A B · X B C + Y A B · Y B C
Compute the magnitudes of the vectors: Find the lengths (magnitudes) of both vectors A B ¯ and B C ¯ using the Euclidean distance formula (Equations (4) and (5)).
| | A B | | = X A B 2 + Y A B 2
| | B C | | = X B C 2 + Y B C 2
Determine the angle between two vectors: Equation (6) can be used to calculate the angle between the two vectors ( θ ) in degrees using the inverse cosine function (acos).
θ = arccos Dot Product | | A B | | × | | B C | | × 180 π

2.4. The VSleep GUI Parts and Sections

The VSleep design comprises five notable components, namely, browser, start, pause, export, and exit, as depicted in Table 2. These components, as labeled in Figure 1, serve as integral elements of the overall system, each fulfilling specific functions and contributing to the seamless operation of the VSleep design.
As shown in Table 2, the agreement between the GUI parts enables the design to specify and extract the angle between the human body parts at the 12 points mentioned.
Algorithm 1 outlines the whole VSleep GUI, including the menu keys and angle calculation process, into the five parts mentioned in Figure 1C. The program waits for user input to select one of the available options: browse, start, pause, export, or quit. Upon launching the application, an interface window is presented. Subsequently, the tester is able to navigate to the recorded videos by selecting the ”browse” option. Upon selecting the appropriate data clip, the program proceeds to exhibit the outcome in the form of an OpenCV window, as indicated in the code. Subsequently, the data undergoes processing within the land-marking system, which comprises twelve designated points adhering to the connections specified by the BlazePose system. Subsequently, conversion to the RGB format is necessary. Verification ensues to ensure the presence of the requisite landmarks, and the corresponding land-marking angles are copied into a CSV file. This action triggers the appearance of a data capture window, which showcases the tester’s performance. Within this window, precise observations of the tester’s movements, gestures, and other relevant actions can be made. As shown in the code in the browser part, the acquired clips are extracted inside the GUI. Once a file is selected, the program proceeds to read the frames from the file. During this step, BlazePose is implemented on the clips, and the landmarks are shown on the clips. Once a subject is within the frame, the program processes it using the MediaPipe library to extract pose landmarks. The extracted pose landmarks provide the necessary information to calculate body angles based on Equations (2)–(5). Each movement in the frame will repeat the angle calculation procedure, and then the calculated body angles can be written to a CSV file for further analysis or visualization. Additionally, the program can display the body angles on the video frame itself, creating an overlay to visualize the angles in real time. All the performance results in terms of degrees for each participant are stored in a CSV file using the append mode. At each iteration, the program checks for the ”pause” option. If the user selects ”pause”, the program pauses the capturing or processing of frames until the user resumes. Exporting the data is accomplished by clicking the ”export” button located within the controller window, whereby the displayed information is directed to the control output. In the event of program delays, an automatic termination is triggered, while the tester also possesses the option to manually cease the video playback using the “quit” function within the controller.
Algorithm 1 The VSleep functions and human sleep posture detection
  procedure: Part one – Browse Mode
      Input: Detected human body
      Output: Human body angle detection
      Call System File Browser() → Await File Input from User()
      if File received then Check File Alignment()
          if File is Aligned then Data Capture(), Landmark Processing(),
  Check Landmarks (All 12 Angles), Co-ordinate Conversions(), Calculate Angles (a, b, c)
             Record in CSV(), Rendering Detection()
             if All Pose Correct then Continue the Clip()
             else
                 Restart Rendering()
             end if
          else
             Display Hide()
          end if
      else
          Notify File Retrieval Error()
      end if
  end procedure
  procedure: Part two – Start Mode (Clip Paused:)
      if User Starts then, Continue the Clip()
      else
          Return()
      end if
  end procedure
  procedure: Part three – Pause Mode (Clip Continuing:)
      if User Pause then, Pause the Clip()
      else
          Return()
      end if
  end procedure
  procedure: Part four – Export Mode
      if File is Aligned then OpenCV Open() → Console Output
      else
          Go to Browse Mode()
      end if
  end procedure
  procedure: Part five – Quit Mode (Quit Program():)
      if User Saves Session then Save Session()
      end if
      Turn off Video Playing(), Close all Windows(), Terminate Processes(), Clean up memory()
  end procedure
Similarly, the program also checks for the “quit” option. If the user selects “quit”, the program terminates. The program continues executing the selected option until the user chooses to quit, at which point the program terminates. Figure 3 shows the VSleep performance on different sample data in various postures and positions and the success of landmark and angle detection on the images.
As depicted in Algorithm 1, the system is structured into five distinct components, each serving a specific function: browse mode, start mode (clip paused), pause mode (clip continuing), export mode, and quit mode (quit program). In part one (browse mode), as the initial phase, the system patiently anticipates user input, where users employ the file browser to select a file. If the chosen file adheres to the prescribed format, the algorithm orchestrates a series of operations. These include data acquisition, landmark processing, validation of 12 distinct angles, coordinate transformations, precise angle calculations, data recording within a CSV file, and rendering detection. Successful validation of all angles permits seamless video clip continuation; any discrepancies necessitate rendering re-calibration. In the unfortunate instances of missing files or retrieval errors, the display remains concealed. After transitioning to part two (start mode), user interaction assumes paramount importance as it facilitates the resumption of a paused video clip. When the user triggers the start action, the suspended clip gracefully recommences its playback; otherwise, the procedure regresses to its previous state. Within part three (pause mode), the algorithm adeptly manages user input, specifically designed to suspend the ongoing video clip playback. Initiating the pause action halts the clip’s progression, while any other input triggers the procedure to return to its prior state. The fourth segment of the algorithm (part four—export mode) revolves around data exportation tasks. Successful alignment of the chosen file with the prescribed format prompts the activation of the OpenCV library, engendering console output. Conversely, in cases of incorrect file alignment, the system gracefully reverts to the browse mode. Finally, part five (quit mode) the final phase of the algorithm accounts for user preferences concerning session preservation before program termination. Opting to preserve the session ensures its safekeeping. Subsequently, the program conducts a series of crucial tasks, including the cessation of video playback, the closure of all active windows, the termination of running processes, and meticulous memory cleanup, ultimately culminating in the program’s conclusion.

3. Test and Experiment

To delve into the capabilities of the VSleep design and accomplish the primary objective of this research, which pertains to calculating the angle of the human body during short daytime napping, a comprehensive GUI design was implemented. This design was applied in a case study test to acquire relevant data and facilitate further in-depth analysis.

3.1. Data Collection and the Protocol

The experimental study involved a cohort of 10 participants, with a specific requirement dictating that only one participant could be tested per day. Therefore, a duration of three days was allotted for each participant’s involvement. The experiment itself was scheduled to take place between 12:00 p.m. and 2:00 p.m., although most of the tests were typically completed by around 1:00 p.m.
The experimental study involved a cohort of 10 participants, with a specific requirement dictating that only one participant could be tested per day. In this case study, a cohort of ten individuals, men ranging in age from 15 to 76 years, was randomly selected and they experimented with three different conditions on three different days. Data were collected following the protocol outlined in Figure 4.
All participants voluntarily signed a self-declaration (Appendix A), providing informed consent to participate in the study and for the utilization of their data for research purposes. In this study, the samples were selected through a random process, and no consideration was given to the history or background of the selected individuals. As a result, a total of thirty samples were obtained. Figure 4 represents the test process and protocol.
The experimental protocol (Figure 4) consisted of three distinct phases: the participants were instructed to relax and reach a calm state of mind. Before the test, the participants were seated in a chair for a duration of 5–10 min, allowing them to hydrate themselves with a glass of water. Furthermore, participants were advised to refrain from consuming tea, coffee, or alcohol on the morning of the testing days. The participants were asked to come on three different days to complete the test.
On all three days, in bed and just before sleeping, the participants were asked to read a sheet of paper containing a paragraph of news containing positive, negative, or neutral information (Appendix A.1.1). The news was randomly distributed to each participant, accompanied by instructions not to disclose its contents to other participants. On each day, one type of information was delivered to the subject to monitor the possible effect of just one small paragraph of information on sleep. The recording of sleep videos was facilitated by the placement of cameras adjacent to the participants’ beds. Several protocols were strictly adhered to during the testing phase. Participants were kept unaware of the aim of the experiment and the type of news before going to sleep. After finishing the experiment, a series of questions pertaining to sleep evaluation were posed to the participants. Three questionnaire sheets were asked to be filled out by participants after the sleeping experiment to control the situation of the test on each day (Q1), the quality of sleep in the last month (Q2), and if the participants had any sort of sleep disorder (Q3) (Appendix A). The results showed that the situation of the test did not differ for all participants across days (conditions). Moreover, none of them had sleep disorders.

3.2. Statistical Analysis

To validate the analyzed data within the established framework, the resulting outcomes are depicted in Figure 5 and Figure 6 based on the designed structure. Indices were analyzed by means of non-parametric tests due to the ordinal nature of the data or the non-normal distribution of the data. The Friedman test was used to test the indices across conditions separately for each angle. Moreover, the Friedman test was used to test the indices across angles separately in each condition. Post hoc comparisons were performed using the Wilcoxon signed-rank test to compare the conditions (negative, neutral, and positive information) separately in each angle and to compare the angles separately in each condition. The Spearman correlation was applied to find a significant correlation between different indices. The effect sizes of the significant results are reported as Kendall’s W and r for Friedman and Wilcoxon signed-rank tests, respectively [35,36]. The Bonferroni correction for multiple comparisons was applied. The level of significance was set at p < 0.050. Data are reported and represented as mean ± standard error (SE).

3.3. Results

The time duration in the three conditions was not significantly different (p = 0.741, χ 2 (2) = 0.6, W = 0.03; negative: 463.4 ± 50.1 s, neutral: 443.2 ± 57.5 s, positive: 470.8 ± 47.2 s). Analysis of the number of changes revealed a significant effect of angle for neutral (p = 0.048, χ 2 (11) = 19.778, W = 0.180) and positive (p < 0.001, χ 2 (11) = 42.518, W = 0.387) conditions. Post hoc analysis showed that for both conditions the number of changes was lower for the right hip and left hip compared to the other angles (p < 0.042, z > 2.032, r > 0.64). Instead, the effect of angle was not significant for the neutral condition (p = 0.492). Moreover, the effect of the condition was not significant (for all angles, p > 0.08).
Analysis of the maximum changes revealed a significant effect of angle for negative (p = 0.006, χ 2 (11) = 26.308, W = 0.239), neutral (p < 0.001, χ 2 (11) = 42.554, W = 0.387), and positive news conditions (p < 0.001, χ 2 (11) = 47.662, W = 0.433). Post hoc analysis showed that, for all conditions, the maximum change was lower for the ankle (right and left) and hip (right and left) compared to the other angles (p < 0.047, z > 1.988, r > 0.63). Moreover, the effect of the condition was significant on the right knee and right hip (p < 0.049) because of the lower values in the positive news condition compared to the other conditions (p < 0.039, z > 2.497, r > 0.79).
The effects of maximum stable time and minimum stable time were not significant for all conditions and angles (p > 0.143). Analysis of the correlation revealed a significant negative correlation between body weight and the number of changes in the neutral condition for all angles (p < 0.022, rho = [−0.820 −0.515]). Interestingly, in the positive news condition, the correlation between body weight and the number of changes was significant just for the lower limbs (p < 0.012, rho = [−0.929 −0.752]). In the negative condition, the correlation between body weight and the number of changes was significant just for the upper limbs (p < 0.030, rho = [−0.788 −0.682]). The other correlations were not significant (p > 0.118 for all).

4. Discussion and Conclusions

Understanding and prioritizing healthy sleep patterns is crucial because sleep is the foundation upon which our physical, cognitive, emotional, and overall well-being rest. Neglecting sleep can have far-reaching consequences, while prioritizing it can lead to improved quality of life and longevity.
Identifying sleep patterns is of paramount importance for overall health. Quality sleep serves as a vital component of physical and mental rejuvenation, fostering well-being. It significantly impacts cognitive functions, emotional stability, and mental health. Furthermore, sleep patterns play a pivotal role in maintaining physical health, including immune system function, cardiovascular well-being, and metabolic processes. Finally, they directly affect productivity, safety, and alertness, contributing to our ability to perform daily tasks effectively and preventing potential accidents.
This study incorporated image analysis using BlazePose, a novel approach called VSleep for sleep analysis, alongside a set of questions focusing on individuals’ habits and experiences following exposure to three different types of news: positive, negative, and neutral. VSleep’s primary objective was to develop a portable, contactless system for analyzing daytime sleep patterns. Sleep movement analysis is used to diagnose sleep disorders, assess sleep quality, and monitor treatment efficacy. It is valuable in both clinical settings and research, aiding in understanding sleep patterns and their impact on health. Additionally, it is used in consumer sleep-tracking devices and can benefit elderly care and pediatrics.
This research work provides an overview of the formation of human body angles while lying down, elucidating the associated alterations with the aid of a computer vision system. The purpose of this study is to conduct a data analysis of the internal position (angular position) changes in the human body during sleep. The study employs a two-fold approach: firstly, to assess the functionality and performance of the proposed system in detecting the 12 key movement points of participants during daytime sleep; and secondly, to investigate the impact of daytime news exposure on sleep, offering valuable insights for psychological research and analysis.
In all image-processing-based vision systems, two critical challenges commonly emerge. The first challenge revolves around concealed points, or “hidden points”, denoting elements that elude the camera’s line of sight due to their specific positioning angles. In this design, meticulous attention has been paid to camera placement, ensuring an optimal angle that encompasses all potential human movements, especially in a supine position. However, scenarios involving extreme rotational angles, such as when one sleeps with a hand covering the face, pose a limitation for detection, a constraint not easily overcome even by vision systems boasting a substantial camera array. The second challenge pertains to low-light environments, where adequate illumination becomes indispensable. In such instances, a system equipped with infrared becomes a requisite. Regrettably, the designed system does not incorporate ultraviolet lighting due to its impact on the sampling time, a compromise that was considered carefully during the system’s development.
In the neutral condition, body weight and body movement frequency had a correlation, as reported in the results. We can interpret this as body weight having an impact on insomnia, meaning that the higher the body weight, the lower the insomnia [37]. On the other hand, insomnia is correlated with body movement frequency; the higher the insomnia, the higher the body movement frequency [38]. However, positive and negative information affects the upper and lower limbs differently, destroying this correlation. The positive information has a sort of relaxation effect on the hands [39]; consequently, the upper limbs lose the correlation between movement frequency and body weight. Instead, the negative information causes a sort of anxiety. When one suffers from anxiety, the body is filled with adrenaline, a hormone that gives the body a tremendous amount of energy and leads to physical agitation, causing the hands and legs to shake. Financial anxiety has more effects on the legs [40]; consequently, the lower limbs lose the correlation between movement frequency and body weight. Here, we presented a comprehensive computer-vision-based sleep monitoring system that is non-intrusive and non-contact, negating the need for participants to wear cameras, wearable gadgets, or any other accessories.
In summary, this research has the following objectives:
  • Analyzing Sleep Patterns: The primary objective of this study is to analyze sleep patterns by monitoring body angle alterations during sleep using a computer vision system.
  • Data Analysis: The study aims to conduct a detailed data analysis of changes in internal body position (angular position) during sleep.
  • Insomnia Correlation: Investigating the correlation between body weight and body movement frequency in relation to insomnia is a key focus, aiming to understand how these factors influence sleep quality.
  • Impact of News: The study explores how exposure to positive and negative news affects the movements of upper and lower limbs during sleep.
  • Non-Intrusive Sleep Monitoring: Introducing a non-intrusive and non-contact computer-vision-based sleep monitoring system that eliminates the need for participants to wear any devices.
  • Applications of the System: The research aims to identify potential applications for the proposed sleep monitoring system under different conditions.
Outcomes:
  • The study reveals insights into the relationship between body weight, body movement frequency, and insomnia during sleep.
  • It identifies distinct effects of positive and negative news on upper and lower limb movements during sleep.
  • The proposed non-intrusive sleep monitoring system offers cost effectiveness, user friendliness, and portability, with the potential for mobile application development.
  • The research emphasizes the importance of understanding sleep patterns for overall health.
  • The study paves the way for improved diagnostics and personalized treatments for sleep-related disorders.
Moreover, we showed a possible application of the proposed system to monitor and evaluate sleep in different conditions.
Given the lack of prior knowledge regarding the participants’ medical histories, obtaining a more precise assessment of their health status would necessitate consultation with a medical professional. This step is delineated as part of the subsequent phases of this research and is a focus of future work. We should mention that the participants did not report any history of mental or neurophysiological disease. Moreover, the scores of the questionnaires confirmed that they had no sleep disorder or problem. Future studies with a higher number of participants and different conditions can be performed with the proposed system. The findings of the case study emphasized the importance of understanding sleep patterns and their impact on health. The comprehensive analysis provided by the VSleep system contributes to advancing knowledge in the field of sleep medicine. Further research and development of non-intrusive sleep analysis methods hold promise for improving diagnostic techniques and personalized treatment approaches for sleep-related disorders. The sleep visual analyzer (VSleep) demonstrated its efficacy in analyzing sleep-related data without the need for accessories. Therefore, the VSleep system opens a new door to easier diagnosis and the investigation of sleep-related disorders. The proposed system is cost effective, user friendly, portable, and has the capability to create a mobile application for conducting experiments and generating results.
The low number of subjects is one of the limitations of this study. In future work, with a high number of subjects, in addition to having more reliable results, it will be possible to investigate the effects of gender (male, female), age (young, middle-aged, old), and education (high school, university).

Author Contributions

Conceptualization, A.J.M. and M.E.A.; methodology, A.J.M. and M.E.A.; software, A.J.M. and M.E.A.; validation, A.J.M. and M.E.A.; formal analysis, A.J.M. and M.E.A.; investigation, A.J.M., M.E.A., N.M.I.U., A.S.K. and J.Z.; resources, A.J.M., M.E.A., N.M.I.U., A.S.K. and J.Z.; data creation, A.J.M., M.E.A. and J.Z; writing—original draft preparation, A.J.M., M.E.A., N.M.I.U. and A.S.K.; writing—review and editing, A.J.M., M.E.A., A.S.K. and J.Z.; visualization, A.J.M., M.E.A. and N.M.I.U.; supervision, A.J.M., M.E.A. and J.Z.; project administration, A.J.M., M.E.A., N.M.I.U., A.S.K. and J.Z.; funding acquisition, J.Z. All authors have read and agreed to the published version of the manuscript.

Funding

This study was supported by “University-Industry Collaborative Education Program by Ministry of Education“, with nos. 220903844181929 and 3502002207. This study was also supported by the National Natural Science Foundation of Jiangsu Province, with nos. BK20221456, and by Company Project, with no. H202310419.

Institutional Review Board Statement

Not applicable.

Informed Consent Statement

Not applicable.

Data Availability Statement

The data are available upon request.

Acknowledgments

The authors would like to thank RARL (Robotic Automation Research Lab, School of Information Engineering, Jiangxi University of Science and Technology, No. 86, Hongqi Ave., Ganzhou 341000, China.

Conflicts of Interest

The authors declare no conflict of interest.

Appendix A

Appendix A.1. Self Declaration

*Notice: This form should sign by each participant before first test For participant.
According to the provisions of the test, I hereby express my consent by participating in this research and presenting the information obtained in the journals and scientific circles from the said test without mentioning my name and I will not have any complaints in this regard in the future.
Participant Name/date/signature.

Appendix A.1.1. Used Questions

(*Notice: All questions should be printed and shared with the participants. Additionally, please kindly request that participants refrain from sharing the questions with others.)
Table A1. Participants Sleep Survey (Q1). Participant’s habits survey.
Table A1. Participants Sleep Survey (Q1). Participant’s habits survey.
No.QuestionNoYes
1Did you smoke this morning?01
2Did you smoke within the past two hours?01
3Did you drink coffee, tea, or alcohol this morning? If yes, which one, how much, and when?Tea, 10:00 a.m.
4Did you use any medicine this morning? If yes, what, and when?01
5Did you get up early today?01
6Did you do exercises in the morning? If yes, how many minutes and what types?01
7Do you usually nap? If yes, at what time and how many minutes?01
8At what time did you get up today?6:30 a.m.
Table A2. Sleep Quality Assessment (Q3): PSQI. Sleep survey results: sleep quality within the previous month (A: not during the past month, B: less than once a week, C: once or twice a week, D: three or more times a week, VG: very good, FG: fairly good, FB: fairly bad, VB: very bad).
Table A2. Sleep Quality Assessment (Q3): PSQI. Sleep survey results: sleep quality within the previous month (A: not during the past month, B: less than once a week, C: once or twice a week, D: three or more times a week, VG: very good, FG: fairly good, FB: fairly bad, VB: very bad).
No.Sleep Quality Assessment (PSQI) Form 2
1When have you usually gone to bed?
2How long (in minutes) has it taken you to fall asleep each night?
3What time have you usually gotten up in the morning?
44A: How many hours of actual sleep did you get at night?
4B: How many hours were you in bed?
ABCD
5A: During the past month, how often you had trouble sleeping because you cannot get to sleep within 30 min?0123
55B: During the past month, how often you had trouble sleeping because you wake up in the middle of the night or early morning?0123
5C: During the past month, how often you had trouble sleeping because you have to get up to use the bathroom?0123
5D: During the past month, how often you had trouble sleeping because you cannot breathe comfortably?0123
5E: During the past month, how often you had trouble sleeping because you cough or snore loudly?0123
5F: During the past month, how often you had trouble sleeping because you feel too cold?0123
5G: During the past month, how often you had trouble sleeping because you feel too hot?0123
5H: During the past month, how often you had trouble sleeping because you have bad dreams?0123
5I: During the past month, how often you had trouble sleeping because you because of pain?0123
5J: During the past month, how often you had trouble sleeping because you other reasons, please describe, including how often you have had trouble sleeping because of this reason(s)0123
6During the past month, how often have you taken medicine (prescribed or “over the counter”) to help you sleep?0123
7During the past month, how often have you had trouble staying awake while driving, eating meals, or engaging in social activity?0123
8During the past month, how much of a problem has it been for you to keep up enthusiasm to get things done?0123
9During the past month, how would you rate your sleep quality overall?VG (0)FG (1)FB (2)VB (3)
Table A3. Sleep Problems Scale (Q4): Sleep Disorder Monitor. Assessment results (A: never, B: rarely, C: sometimes, D: mostly, E: always).
Table A3. Sleep Problems Scale (Q4): Sleep Disorder Monitor. Assessment results (A: never, B: rarely, C: sometimes, D: mostly, E: always).
No.QuestionABCDE
1Do you have trouble falling asleep?01234
2Do you have trouble staying asleep?01234
3Do you take anything to help you sleep?01234
4Do you use alcohol to help you sleep?01234
5Do you have any medical conditions that disrupt your sleep?01234
6Have you lost interest in hobbies or activities?01234
7Do you feel sad, irritable, or hopeless?01234
8Do you feel nervous or worried?01234
9Do you think something is wrong with your body?01234
10Are you a shift worker, or is your sleep schedule irregular?01234
11Are your legs restless and/or uncomfortable before bed?01234
12Have you been told that you are restless or that you kick your legs in your sleep?01234
13Do you have any unusual behaviors or movements during sleep?01234
14Do you snore?01234
15Has anyone said that you stop breathing, gasp, snort, or choke in your sleep?01234
16Do you have difficulty staying awake during the day?01234

Appendix A.1.2. The Fake News Text

*Notice: all the news should print before experiments and should not disclose to participant before the experiment, also should request them to not discuss about news after experiment to others, both texts are copied from news article discussing the fuel prices in Bangladesh.
  • Fake Negative News
    News topic:
    Record increase in fuel prices
    Staff reporter: Nafiz Amir
    Saturday, 6 September 2022, 12:00 a.m.
    Last updated on: Saturday, 6 September 2022, 06:32 a.m.
    The government last night hiked fuel prices by 51.7%, the highest price in the country’s history, adding to the woes of ordinary people already struggling to cope with rising living costs. According to the new prices that were applied from 12:00 a.m. today, one liter of octane now costs 135 TRY, which is 51.7% higher than the previous rate of 89 TRY. In the press release of the Ministry of Power, Energy and Mineral Resources, stating that the prices have been announced with the increase in fuel prices in international markets, each liter of gasoline now costs 130 trons, which has increased by 44 trons or 51.1%. Much higher than that in Bangladesh. The price of each liter of diesel and kerosene has increased from 80 trons to 114 trons. Bangladesh Petroleum Corporation (BPC) made a loss of 8,014.51 trn from February to July by selling fuel at low prices, a press release said. According to this organization, due to the increase in fuel prices in international markets, many countries, including India, have already increased fuel prices. In Kolkata, diesel was sold at Rs 92.76 (114.09 crores) per liter, and petrol at Rs 106.03 (130.42 crores) per liter. Concern about fuel smuggling abroad was another reason for this increase. The highest increase in history since the country’s independence comes at a time when people are already struggling to cope with rising prices of essential items.With the release of this news, hundreds of people gathered at gas stations across the country in the hope of buying fuel before the new rates are implemented. But the officials stopped the fuel sales station and caused the anger of the people. Following these protests, a young child was killed in a public gathering and at least 50 people were injured.
  • Fake Positive News
    News topic: Record low fuel prices
    Staff reporter: Nafiz Amir
    Saturday, 6 September 2022, 12:00 a.m.
    Last updated on: Saturday, 6 September 2022, 06:32 a.m.
    Last night, the government reduced the price of fuel by 51.7%, which is the lowest price in the history of this country, and this price reduction will reduce the economic problems of the people and make public food cheaper. According to the new prices that were applied from 12:00 a.m. today, one liter of octane now costs 13.5 TRY, which is 51.7% less than the previous rate of 89 TRY. In the press release of the Ministry of Power, Energy, and Mineral Resources, stating that the reduction in prices has been announced following the reduction in fuel prices in international markets, and this price reduction in Bangladesh will probably follow. The price of each liter of diesel and kerosene has decreased from 80 trons to 20 trons. The press release stated that Bangladesh Petroleum Company (BPC) wants to further reduce fuel prices for the greater welfare of the people. According to this organization, due to the decrease in fuel prices in international markets, many countries, including India, have already reduced fuel prices. With the publication of this news, hundreds of people rejoiced at gas stations across the country and thanked the government for its price reduction policies in a rally.

References

  1. Moshayedi, A.J.; Hosseinzadeh, M.; Joshi, B.P.; Emadi Andani, M. Recognition System for Ergonomic Mattress and Pillow: Design and Fabrication. IETE J. Res. 2023, 1–19. [Google Scholar] [CrossRef]
  2. Hulst, R.Y.; Gorter, J.W.; Voorman, J.M.; Kolk, E.; Van Der Vossen, S. Sleep problems in children with cerebral palsy and their parents. Dev. Med. Child. Neurol. 2021, 63, 1344–1350. [Google Scholar] [CrossRef] [PubMed]
  3. Besedovsky, L.; Lange, T.; Haack, M. Das Schlaf-Immun-Übersprechen in Gesundheit und Krankheit. Physiol. Rev. 2019, 99, 1325–1380. [Google Scholar] [CrossRef]
  4. Fabbri, M.; Beracci, A.; Martoni, M.; Meneo, D.; Tonetti, L.; Natale, V. Measuring subjective sleep quality: A review. Int. J. Environ. Res. Public. Health 2021, 18, 1082. [Google Scholar] [CrossRef] [PubMed]
  5. Lian, Y.; Yuan, Q.; Wang, G.; Tang, F. Association between sleep quality and metabolic syndrome: A sys-tematic review and meta-analysis. Psychiatry Res. 2019, 274, 66–74. [Google Scholar] [CrossRef]
  6. Qiu, D.; Yu, Y.; Li, R.-Q.; Li, Y.-L.; Xiao, S.-Y. Prevalence of sleep disturbances in Chinese healthcare professionals: A systematic review and meta-analysis. Sleep Med. 2020, 67, 258–266. [Google Scholar] [CrossRef] [PubMed]
  7. Chow, C.M. Sleep Hygiene Practices: Where to Now? Hygiene 2020, 2, 146–151. [Google Scholar] [CrossRef]
  8. Irwin, M.R. Sleep and inflammation: Partners in sickness and in health. Nat. Rev. Immunol. 2019, 19, 702–715. [Google Scholar] [CrossRef]
  9. Kukwa, W.; Lis, T.; Łaba, J.; Mitchell, R.B.; Młyńczak, M. Sleep Position Detection with a Wireless Au-dio-Motion Sensor—A Validation Study. Diagnostics 2022, 12, 1195. [Google Scholar] [CrossRef]
  10. Macher, S.; Herster, C.; Holter, M.; Moritz, M.; Matzhold, E.M.; Stojakovic, T.; Pieber, T.R.; Schlenke, P.; Drexler, C.; Amrein, K. The effect of parenteral or oral iron supplementation on fatigue, sleep, quality of life and restless legs syndrome in iron-deficient blood donors: A secondary analysis of the IronWoMan RCT. Nutrients 2020, 12, 1313. [Google Scholar] [CrossRef]
  11. Kang, K.T.; Weng, W.C.; Lee, C.H.; Hsiao, T.Y.; Lee, P.L.; Lee, Y.L.; Hsu, W.C. Detection of pediatric obstructive sleep apnea syndrome: History or anatomical findings? Sleep Med. 2015, 16, 617–624. [Google Scholar] [CrossRef] [PubMed]
  12. Radwan, A.; Ashton, N.; Gates, T.; Kilmer, A.; VanFleet, M. Effect of different pillow designs on promoting sleep comfort, quality, and spinal alignment: A systematic review. Eur. J. Integr. Med. 2021, 42, 101269. [Google Scholar] [CrossRef]
  13. Szeto, G.P.; Tsang, S.M.; Dai, J.; Madeleine, P. A field study on spinal postures and postural variations during smartphone use among university students. Appl. Ergon. 2020, 88, 103183. [Google Scholar] [CrossRef] [PubMed]
  14. Bafkar, O.; Cajas, J.C.; Calmet, H.; Houzeaux, G.; Rosengarten, G.; Lester, D.; Nguyen, V.; Gulizia, S.; Cole, I.S. Impact of sleeping position, gravitational force and effective tissue stiffness on obstructive sleep apnoea. J. Biomech. 2020, 104, 109715. [Google Scholar] [CrossRef]
  15. Yang, Y.; Li, W.; Ma, T.J.; Zhang, L.; Hall, B.J.; Ungvari, G.S.; Xiang, Y.T. Prevalence of poor sleep quality in perinatal and postnatal women: A comprehensive meta-analysis of observational studies. Front. Psychiatry 2020, 11, 161. [Google Scholar] [CrossRef] [PubMed]
  16. Gaspar, L.S.; Hesse, J.; Yalçin, M.; Santos, B.; Carvalhas-Almeida, C.; Ferreira, M.; Moita, J.; Relógio, A.; Cavadas, C.; Álvaro, A.R. Long-term continuous positive airway pressure treatment ameliorates biological clock dis-ruptions in obstructive sleep apnea. EBioMedicine 2021, 65, 103248. [Google Scholar] [CrossRef] [PubMed]
  17. Wang, C.; Bangdiwala, S.I.; Rangarajan, S.; Lear, S.A.; AlHabib, K.F.; Mohan, V.; Teo, K.; Poirier, P.; Tse, L.A.; Liu, Z.; et al. Association of estimated sleep duration and naps with mortality and cardiovascular events: A study of 116 632 people from 21 countries. Eur. Heart J. 2019, 40, 1620–1629. [Google Scholar] [CrossRef]
  18. Reid, A.; Bloxham, A.; Carr, M.; van Rijn, E.; Basoudan, N.; Tulip, C.; Blagrove, M. Effects of sleep on positive, negative and neutral valenced story and image memory. Br. J. Psychol. 2022, 113, 777–797. [Google Scholar] [CrossRef]
  19. Pilcher, J.J.; Callan, C.; Posey, J.L. Sleep deprivation affects reactivity to positive but not negative stimuli. J. Psychosom. Res. 2015, 79, 657–662. [Google Scholar] [CrossRef]
  20. Okano, K.; Kaczmarzyk, J.R.; Dave, N.; Gabrieli, J.D.; Grossman, J.C. Sleep quality, duration, and con-sistency are associated with better academic performance in college students. NPJ Sci. Learn. 2019, 4, 16. [Google Scholar] [CrossRef]
  21. Jun, W.H.; Kim, H.J.; Hong, Y.S. Sleep pattern analysis in unconstrained and unconscious state. Sensors 2022, 22, 9296. [Google Scholar] [CrossRef]
  22. Gaiduk, M.; Seepold, R.; Martínez Madrid, N.; Ortega, J.A. Assessing the feasibility of replacing subjective questionnaire-based sleep measurement with an objective approach using a Smartwatch. Sensors 2023, 23, 6145. [Google Scholar] [CrossRef] [PubMed]
  23. Huang, X.; Shirahama, K.; Irshad, M.T.; Nisar, M.A.; Piet, A.; Grzegorzek, M. Sleep Stage Classification in Children Using Self-Attention and Gaussian Noise Data Augmentation. Sensors 2023, 23, 3446. [Google Scholar] [CrossRef] [PubMed]
  24. Boiko, A.; Gaiduk, M.; Scherz, W.D.; Gentili, A.; Conti, M.; Orcioni, S.; Seepold, R. Monitoring of cardi-orespiratory parameters during sleep using a special holder for the accelerometer sensor. Sensors 2023, 23, 5351. [Google Scholar] [CrossRef]
  25. Park, J.H.; Lee, J.D. A Customized Deep Sleep Recommender System Using Hybrid Deep Learning. Sensors 2023, 23, 6670. [Google Scholar] [CrossRef]
  26. Baglioni, C.; Spiegelhalder, K.; Regen, W.; Feige, B.; Nissen, C.; Lombardo, C.; Violani, C.; Hennig, J.; Riemann, D. Insomnia disorder is associated with increased amygdala reactivity to insomnia-related stimuli. Sleep 2014, 37, 1907–1917. [Google Scholar] [CrossRef] [PubMed]
  27. Spira, A.P.; Chen-Edinboro, L.P.; Wu, M.N.; Yaffe, K. Impact of sleep on the risk of cognitive decline and dementia. Curr. Opin. Psychiatry 2014, 27, 478. [Google Scholar] [CrossRef]
  28. Pillai, V.; Drake, C.L. Sleep and repetitive thought: The role of rumination and worry in sleep disturbance. Sleep Affect. 2015, 201–225. [Google Scholar] [CrossRef]
  29. Jagtap, R.; Zanzane, M.; Patil, R. Yoga pose detection using machine learning. Int. Res. J. Mod. Eng. Technol. Sci. 2023, 5, 2582–5208. [Google Scholar]
  30. Bazarevsky, V.; Grishchenko, I.; Raveendran, K.; Zhu, T.; Zhang, F.; Grundmann, M. Blazepose: On-device realtime body pose tracking. arXiv 2020, arXiv:2006.10204. [Google Scholar]
  31. Mroz, S.; Baddour, N.; McGuirk, C.; Juneau, P.; Tu, A.; Cheung, K.; Lemaire, E. Comparing the quality of human pose estimation with blazepose or openpose. In Proceedings of the 4th International Conference on Bio-Engineering for Smart Technologies (BioSMART 2021), Paris, France, 8–10 December 2021; pp. 1–4. [Google Scholar]
  32. Min, Z. Human Body Pose Intelligent Estimation Based on BlazePose. In Proceedings of the 2022 IEEE International Conference on Electrical Engineering, Big Data and Algorithms (EEBDA), Changchun, China, 25–27 February 2022; pp. 150–153. [Google Scholar]
  33. Setiyadi, S.; Mukhtar, H.; Cahyadi, W.A.; Lee, C.-C.; Hong, W.-T. Human Activity Detection Employing Full-Type 2D Blazepose Estimation with LSTM. In Proceedings of the 2022 IEEE Asia Pacific Conference on Wireless and Mobile (APWiMob), Bandung, Indonesia, 9–10 December 2022; pp. 1–7. [Google Scholar]
  34. Alsawadi, M.S.; El-Kenawy, E.-S.M.; Rio, M. Using BlazePose on Spatial Temporal Graph Convolutional Networks for Action Recognition. Comput. Mater. Contin. 2022, 74, 19–36. [Google Scholar] [CrossRef]
  35. Tomczak, A.; Tomczak, E. The need to report effect size estimates revisited. Overv. Some Recomm. Meas. Eff. Size. Trends Sport. Sci. 2014, 1, 19–25. [Google Scholar]
  36. Ban, H.J.; Kim, S.C.; Seo, J.; Kang, H.B.; Choi, J.K. Genetic and Metabolic Characterization of Insomnia. PLoS ONE 2011, 6, e18455. [Google Scholar] [CrossRef] [PubMed]
  37. Grishchenko, I.; Bazarevsky, V.; Zanfir, A.; Bazavan, E.G.; Zanfir, M.; Yee, R. BlazePose GHUM Holistic: Re-al-time 3D Human Landmarks and Pose Estimation. arXiv 2022, arXiv:2206.11678. [Google Scholar]
  38. Chang, L.; Lu, J.; Wang, J.; Chen, X.; Fang, D.; Tang, Z.; Nurmi, P.; Wang, Z. SleepGuard: Capturing rich sleep information using smartwatch sensing data. ACM Interact. Mob. Wearable Ubiquitous Technol. 2018, 2, 1–34. [Google Scholar] [CrossRef]
  39. Hsiao, R.-S.; Chen, T.-X.; Bitew, M.A.; Kao, C.-H.; Li, T.-Y. Sleeping posture recognition using fuzzy c-means algorithm. Biomed. Eng. Online 2018, 17, 157. [Google Scholar] [CrossRef]
  40. Chirakanphaisarn, N.; Ganmol, P. The sleeping positions that affect the heartbeat signal for normal subjects. In Proceedings of the 2021 International Conference on Engineering and Emerging Technologies (ICEET), Istanbul, Turkey, 27–28 October 2021; pp. 1–6. [Google Scholar]
Figure 1. VSleep block diagram and parts. (A) Input data collection and capture; (B) capture data storage; (C) the VSleep graphical user interface (GUI); and (D) output and body angle stamp on video and CSV format output.
Figure 1. VSleep block diagram and parts. (A) Input data collection and capture; (B) capture data storage; (C) the VSleep graphical user interface (GUI); and (D) output and body angle stamp on video and CSV format output.
Sensors 23 08422 g001
Figure 2. BlazePose topology and performance. (A) The twelve detected points on a human body (1. left shoulder, 2. right shoulder, 3. left elbow, 4. right elbow, 5. left wrist, 6. right wrist, 7. left hip, 8. right hip, 9. left knee, 10. right knee, 11. left ankle, 12. right ankle). (B) The VSleep design detected point. (C) One sample of angle measurement with VSleep.
Figure 2. BlazePose topology and performance. (A) The twelve detected points on a human body (1. left shoulder, 2. right shoulder, 3. left elbow, 4. right elbow, 5. left wrist, 6. right wrist, 7. left hip, 8. right hip, 9. left knee, 10. right knee, 11. left ankle, 12. right ankle). (B) The VSleep design detected point. (C) One sample of angle measurement with VSleep.
Sensors 23 08422 g002
Figure 3. VSleep system’s performance in angle detection across participants in different sleep positions, including those on their back (A,C,F), right side (B,D,E), is illustrated by blue points indicating successful detection points.
Figure 3. VSleep system’s performance in angle detection across participants in different sleep positions, including those on their back (A,C,F), right side (B,D,E), is illustrated by blue points indicating successful detection points.
Sensors 23 08422 g003
Figure 4. The experimental test protocol.
Figure 4. The experimental test protocol.
Sensors 23 08422 g004
Figure 5. Number of changes in three conditions for all angles. KR: knee right, KL: knee left, ANR: ankle right, ANL: ankle left, HR: hip right, HL: hip left, ELR: elbow right, ELL: elbow left, SHR: shoulder right, SHL: shoulder left, WR: wrist right, WL: wrist left.
Figure 5. Number of changes in three conditions for all angles. KR: knee right, KL: knee left, ANR: ankle right, ANL: ankle left, HR: hip right, HL: hip left, ELR: elbow right, ELL: elbow left, SHR: shoulder right, SHL: shoulder left, WR: wrist right, WL: wrist left.
Sensors 23 08422 g005
Figure 6. Maximum angle changes in three conditions for all angles. KR: knee right, KL: knee left, ANR: ankle right, ANL: ankle left, HR: hip right, HL: hip left, ELR: elbow right, ELL: elbow left, SHR: shoulder right, SHL: shoulder left, WR: wrist right, WL: wrist left.
Figure 6. Maximum angle changes in three conditions for all angles. KR: knee right, KL: knee left, ANR: ankle right, ANL: ankle left, HR: hip right, HL: hip left, ELR: elbow right, ELL: elbow left, SHR: shoulder right, SHL: shoulder left, WR: wrist right, WL: wrist left.
Sensors 23 08422 g006
Table 1. GUI packages used in VSleep.
Table 1. GUI packages used in VSleep.
Library NameAim and Duty
OpenCVAim: Empower computer vision applications with an efficient, open-source framework.
Duty: To encapsulate, the process involves acquiring data, detecting object pose, and displaying values during object motion.
MediaPipeAim: Pose estimation
Duty: Execute the BlazePose model to identify landmarks, utilizing its versatile, cross-platform framework renowned for providing robust, pre-constructed solutions tailored to computer vision tasks.
NumPyAim: Degree calculation
Duty: Calculate object degrees by using the cosine function.
CSVAim: Export the data
Duty: Record the angular displacements of the object’s movements within a CSV file.
PyQt5Aim: Enables the use of the Qt framework and graphical user interfaces
Duty: Facilitate diverse capabilities such as data export, pause, and system exit options.
Table 2. The VSleep graphical user interface (GUI) sections and parts.
Table 2. The VSleep graphical user interface (GUI) sections and parts.
Label: NamePurpose and Duty
A: LoadPurpose: Loading the captured video.
Duty: When this option is clicked, the data-capturing window will appear.
B: PerformancePurpose: Performance monitoring.
Duty: After selecting the ’A’ option, the performance will be displayed.
C: PausePurpose: To pause the system.
Duty: Whilst the performance output persists on the screen, it is feasible to interrupt it using the designated ’C’ button if a pause is requisite.
D: SavePurpose: Data storage.
Duty: Within this GUI system, data are accumulated through an appending process, maintaining this mode when engaged within the OpenCV window environment.
E: ExitPurpose: Exiting the GUI.
Duty: In the event that the evaluator desires to terminate the program, they can simply click on this button to effectuate the program’s closure.
Disclaimer/Publisher’s Note: The statements, opinions and data contained in all publications are solely those of the individual author(s) and contributor(s) and not of MDPI and/or the editor(s). MDPI and/or the editor(s) disclaim responsibility for any injury to people or property resulting from any ideas, methods, instructions or products referred to in the content.

Share and Cite

MDPI and ACS Style

Moshayedi, A.J.; Uddin, N.M.I.; Khan, A.S.; Zhu, J.; Emadi Andani, M. Designing and Developing a Vision-Based System to Investigate the Emotional Effects of News on Short Sleep at Noon: An Experimental Case Study. Sensors 2023, 23, 8422. https://doi.org/10.3390/s23208422

AMA Style

Moshayedi AJ, Uddin NMI, Khan AS, Zhu J, Emadi Andani M. Designing and Developing a Vision-Based System to Investigate the Emotional Effects of News on Short Sleep at Noon: An Experimental Case Study. Sensors. 2023; 23(20):8422. https://doi.org/10.3390/s23208422

Chicago/Turabian Style

Moshayedi, Ata Jahangir, Nafiz Md Imtiaz Uddin, Amir Sohail Khan, Jianxiong Zhu, and Mehran Emadi Andani. 2023. "Designing and Developing a Vision-Based System to Investigate the Emotional Effects of News on Short Sleep at Noon: An Experimental Case Study" Sensors 23, no. 20: 8422. https://doi.org/10.3390/s23208422

Note that from the first issue of 2016, this journal uses article numbers instead of page numbers. See further details here.

Article Metrics

Back to TopTop