Intelligent mattress, snoring detection method and device thereof and computer storage medium
By acquiring and filtering raw cardiac impact signals in real time and dynamically adjusting the snoring threshold, the problem of insufficient accuracy in snoring detection in existing technologies is solved, enabling precise detection and dynamic adjustment of snoring data and improving detection accuracy.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-12-08
- Publication Date
- 2026-03-10
AI Technical Summary
In existing technologies for snoring detection based on sound, the reflection and scattering of sound during propagation cause discrepancies between the snoring data collected by the device and the actual data, reducing the accuracy of snoring detection.
By acquiring the raw cardiac impact signals generated by the user in real time, the mechanical vibration is converted into an electrical signal using a piezoelectric ceramic sensor. After filtering, the snoring data is determined, and the snoring threshold is dynamically adjusted based on the snoring data to accurately determine the start and end times of snoring. The dynamic adjustment of the snoring threshold improves the detection accuracy.
It enables precise determination and dynamic adjustment of snoring data, improves the accuracy of snoring detection, and provides a reliable basis for subsequent anti-snoring intervention.
Smart Images

Figure CN121622011A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of sleep monitoring technology, and in particular to a smart mattress and its snoring detection method, device and computer storage medium. Background Technology
[0002] Snoring is an acoustic phenomenon caused by the vibration of soft tissues in the upper respiratory tract during sleep. Frequent or severe snoring can affect sleep quality, potentially leading to sleep apnea and various chronic diseases. Therefore, accurate monitoring of snoring can effectively prevent various diseases, provide a basis for anti-snoring intervention, and help users achieve a better sleep experience.
[0003] In existing technologies, snoring detection is mainly based on sound. However, due to the reflection and scattering of sound during propagation, the snoring data collected by the device may deviate from the actual snoring data, reducing the accuracy of snoring detection. Summary of the Invention
[0004] This invention provides a smart mattress and its snoring detection method, device, and computer storage medium. By accurately determining snoring data and dynamically adjusting the snoring threshold, it can effectively detect snoring data during sleep, improve the accuracy of snoring detection, and provide a basis for subsequent anti-snoring intervention.
[0005] In a first aspect, the present invention provides a snoring detection method, comprising:
[0006] Real-time acquisition of raw cardiac impact signals generated by the user;
[0007] Based on the original cardiac impact signal, snoring data is determined;
[0008] Adjust the current snoring threshold based on the snoring data;
[0009] The snoring result is determined based on the snoring data and the current snoring threshold.
[0010] Optionally, based on the original cardiac impact signal, snoring data is determined, including:
[0011] The original cardiac impact signal is filtered, and the original cardiac impact signal in the vibration signal frequency band is determined as the snoring data.
[0012] Optionally, adjusting the current snoring threshold based on the snoring data includes:
[0013] The snoring data is traversed through a preset sliding window to determine the cumulative value of the snoring data within the preset sliding window.
[0014] Determine whether the accumulated value is greater than the current snoring threshold;
[0015] If so, then during the process of traversing the snoring data with the preset sliding window, the first cumulative time when the cumulative value is greater than the snoring threshold is obtained in real time;
[0016] Determine whether the first accumulated time has reached the first preset time;
[0017] If so, the current snoring threshold is reduced by the first preset adjustment amount.
[0018] Optionally, before reducing the current snoring threshold by a first preset adjustment amount, the method further includes:
[0019] Determine whether the current snoring threshold is greater than the lower limit of the snoring threshold;
[0020] If so, then the step of reducing the current snoring threshold by a first preset adjustment amount is performed.
[0021] Optionally, before reducing the current snoring threshold by a first preset adjustment amount, the method further includes:
[0022] If the current snoring threshold is less than or equal to the lower limit of the snoring threshold, then the current snoring threshold is adjusted to the lower limit of the snoring threshold.
[0023] Optionally, adjusting the current snoring threshold based on the snoring data further includes:
[0024] If the accumulated value is less than or equal to the current snoring threshold, then during the process of traversing the snoring data with the preset sliding window, the second accumulated time when the accumulated value is less than or equal to the snoring threshold is obtained in real time;
[0025] Determine whether the second accumulated time has reached the second preset time;
[0026] If so, the current snoring threshold is increased by the second preset adjustment amount.
[0027] Optionally, before increasing the current snoring threshold by a second preset adjustment amount, the method further includes:
[0028] Determine whether the current snoring threshold is less than the upper limit of the snoring threshold;
[0029] If so, then the step of increasing the current snoring threshold by a second preset adjustment amount is performed.
[0030] Optionally, before increasing the current snoring threshold by a second preset adjustment amount, the method further includes:
[0031] If the current snoring threshold is greater than or equal to the upper limit of the snoring threshold, then the current snoring threshold is adjusted to the upper limit of the snoring threshold.
[0032] Optionally, based on the snoring data and the current snoring threshold, a snoring result is determined, including:
[0033] The snoring data is traversed through a preset sliding window to determine the cumulative value of the snoring data within the preset sliding window.
[0034] The moment when the accumulated value begins to exceed the current snoring threshold is recorded as the snoring start time, and the moment when the accumulated value begins to be less than or equal to the current snoring threshold is recorded as the snoring end time.
[0035] Determine whether the duration between the start time and end time of snoring is within a preset duration;
[0036] If so, the snoring data that traverses the time period between the start time and the end time of the snoring is taken as one set of snoring data.
[0037] Optionally, determining the snoring result based on the snoring data and the current snoring threshold further includes:
[0038] Obtain the snoring interval time between the snoring termination time of the previous snoring data and the snoring start time of the next snoring data in two consecutive snoring data sets;
[0039] Determine whether the snoring interval is less than or equal to a preset interval.
[0040] If so, then the two adjacent snoring data points are merged into one snoring data point.
[0041] Optionally, before taking a set of snoring data that iterates through the time interval between the snoring start time and the snoring end time as a single set of snoring data, the method further includes:
[0042] During the time period between the snoring start time and the snoring end time, the user's body movement data is acquired in real time.
[0043] When it is determined that the user has moved based on the body movement data, the snoring data traversed within the time period between the snoring start time and the snoring end time of the group is determined as non-snoring data.
[0044] When it is determined from the body movement data that the user has not moved, the step of taking the snoring data that traverses the time period between the start time and the end time of the snoring as a single snoring data is executed.
[0045] Secondly, the present invention provides a snoring detection device, comprising:
[0046] The signal acquisition module is used to acquire the raw cardiac impact signals generated by the user in real time;
[0047] A snoring data determination module is used to determine snoring data based on the original cardiac impact signal;
[0048] A snoring threshold adjustment module is used to adjust the current snoring threshold based on the snoring data;
[0049] The snoring result determination module is used to determine the snoring result based on the snoring data and the current snoring threshold.
[0050] Thirdly, the present invention provides a smart mattress, comprising: a mattress body, a piezoelectric ceramic sensor, and a controller;
[0051] The piezoelectric ceramic sensor is mounted on the mattress body and is used to acquire the original cardiac impact signal generated by the user in real time.
[0052] The controller is electrically connected to the piezoelectric ceramic sensor; the controller is used to perform the above-described snoring detection method.
[0053] Fourthly, the present invention provides a computer storage medium storing computer instructions, which are used to cause a controller to execute the above-described snoring detection method.
[0054] The technical solution of this invention acquires the raw cardiac impact signal generated by the user in real time, determines snoring data based on the raw cardiac impact signal, dynamically adjusts the current snoring threshold based on the snoring data, and determines the snoring result based on the snoring data and the current snoring threshold. This allows for accurate determination of snoring data and dynamic adjustment of the snoring threshold, thereby effectively detecting snoring data during the user's sleep, improving the accuracy of snoring detection, and providing a basis for subsequent anti-snoring intervention. Attached Figure Description
[0055] Figure 1 This is a flowchart illustrating a snoring detection method provided in Embodiment 1 of the present invention;
[0056] Figure 2 This is a schematic flowchart of a snoring detection method provided in Embodiment 2 of the present invention;
[0057] Figure 3 This is a flowchart illustrating a snoring detection method provided in Embodiment 3 of the present invention;
[0058] Figure 4 This is a flowchart illustrating a snoring detection method provided in Embodiment 4 of the present invention;
[0059] Figure 5This is a flowchart illustrating a snoring detection method provided in Embodiment 5 of the present invention;
[0060] Figure 6 This is a schematic flowchart of a snoring detection method provided in Embodiment Six of the present invention;
[0061] Figure 7 This is a schematic diagram of the structure of a snoring detection device provided in an embodiment of the present invention. Detailed Implementation
[0062] The present invention will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and not intended to limit it. Furthermore, it should be noted that, for ease of description, the accompanying drawings show only the parts relevant to the present invention, and not all of the structures.
[0063] The terminology used in the embodiments of this invention is for the purpose of describing specific embodiments only and is not intended to limit the invention. It should be noted that directional terms such as "upper," "lower," "left," and "right" described in the embodiments of this invention are used to describe the angles shown in the accompanying drawings and should not be construed as limiting the embodiments of this invention. Furthermore, in the context, it should be understood that when referring to an element being formed "on" or "below" another element, it can be formed not only directly on or below the other element, but also indirectly on or below it through intermediate elements. The terms "first," "second," etc., are used for descriptive purposes only and do not indicate any order, quantity, or importance, but are merely used to distinguish different components. Those skilled in the art can understand the specific meaning of the above terms in this invention based on the specific circumstances.
[0064] The term "comprising" and its variations as used in this invention are open-ended, meaning "including but not limited to". The term "based on" means "at least partially based on". The term "one embodiment" means "at least one embodiment".
[0065] It should be noted that the concepts of "first" and "second" mentioned in this invention are only used to distinguish the corresponding contents and are not used to limit the order or interdependence.
[0066] It should be noted that the terms "a" and "a plurality of" used in this invention are illustrative rather than restrictive. Those skilled in the art should understand that, unless otherwise expressly indicated in the context, they should be understood as "one or more".
[0067] Example 1
[0068] Figure 1This is a flowchart illustrating a snoring detection method provided in Embodiment 1 of the present invention. This embodiment can be used to detect a user's snoring. The method can be executed by a snoring detection device, which can be implemented in software and / or hardware, and is generally integrated into the controller provided in this embodiment of the present invention. Figure 1 As shown, snoring detection methods include:
[0069] S110: Real-time acquisition of raw cardiac impact signals generated by the user.
[0070] The original cardiac impact signal (Ballistocardiogram, BCG) refers to the vibration signal caused by the reaction force of blood flowing through blood vessels on the body during a heartbeat. The original cardiac impact signal can be acquired using a piezoelectric ceramic sensor, an electronic component that utilizes the piezoelectric effect to convert energy. When the piezoelectric ceramic inside the sensor is subjected to mechanical stress, polarization occurs, converting mechanical energy into electrical energy.
[0071] Specifically, piezoelectric ceramic sensors can be installed on the mattress body to detect snoring. When a user sleeps, physiological activities such as heartbeat, breathing, body movement, and snoring generate tiny mechanical vibrations. These mechanical vibrations are received by the piezoelectric ceramic inside the piezoelectric ceramic sensor, which converts the mechanical energy into an electrical signal and uses this signal to obtain the user's original cardiac impact signal.
[0072] It should be noted that the technical solution of this invention, in terms of the acquisition, collection, updating, analysis, processing, use, transmission, and storage of the user's original cardiac impact signals, all comply with relevant laws and regulations, are used for legitimate purposes, and do not violate public order and good morals. Necessary measures are taken to prevent unauthorized access to the user's original cardiac impact signals, thereby maintaining the security of the user's original cardiac impact signals and network security.
[0073] S120. Determine snoring data based on the original cardiac impact signal.
[0074] Specifically, the original cardiac impact signal includes composite vibration signals of multiple frequencies. By filtering out the vibration signals of interfering frequencies, the frequency signal of the snoring data is determined, and thus the snoring data is determined.
[0075] S130. Adjust the current snoring threshold based on snoring data.
[0076] Specifically, a user's snoring is not a continuous, stable vibration, but rather deeply intertwined with the breathing process: when the user inhales, the airflow rapidly passes through the narrow upper respiratory tract, resulting in a stronger impact on soft tissues and a higher amplitude vibration signal; when the user exhales, the airflow speed slows down, airway pressure decreases, and the amplitude of the vibration signal is lower. Therefore, it is necessary to dynamically adjust the snoring threshold based on real-time snoring data: appropriately lower the current snoring threshold during the inhalation phase at the beginning of snoring, and then gradually increase the current snoring threshold after the complete inhalation and exhalation cycle of this snoring has ended. By dynamically adjusting the current snoring threshold, it is ensured that a complete inhalation and exhalation process is accurately identified as a single snoring event, thereby improving the accuracy of snoring detection.
[0077] S140. Determine the snoring result based on the snoring data and the current snoring threshold.
[0078] Specifically, the snoring data determined between the start and end of a snoring episode is recorded as a complete snoring data set. This allows for the recording of snoring data while filtering out abnormal non-snoring data, ensuring that the snoring results only include genuine snoring data. By recording genuine snoring data, the snoring data is transformed into accurate snoring results.
[0079] This embodiment acquires the raw cardiac impact signal generated by the user in real time, determines snoring data based on the raw cardiac impact signal, dynamically adjusts the current snoring threshold based on the snoring data, and determines the snoring result based on the snoring data and the current snoring threshold. This allows for accurate determination of snoring data and dynamic adjustment of the snoring threshold, thereby effectively detecting snoring data during the user's sleep, improving the accuracy of snoring detection, and providing a basis for subsequent anti-snoring intervention.
[0080] Example 2
[0081] Figure 2 This is a flowchart illustrating a snoring detection method according to Embodiment 2 of the present invention. Based on the above embodiments, this embodiment provides a detailed description of the method for determining snoring data, such as... Figure 2 As shown, the snoring detection method includes:
[0082] S210: Real-time acquisition of raw cardiac impact signals generated by the user.
[0083] S220. Filter the original cardiac impact signal and determine the original cardiac impact signal in the vibration signal frequency band as snoring data.
[0084] Specifically, the filtering process for the raw cardiac impulse signal includes: denoising against 50Hz power frequency interference to filter out interference from the inherent frequency of the power grid. The cardiac impulse signal can be input into a notch filter, which will remove interference signals in the 50Hz and nearby frequency bands. Simultaneously, since the frequency band of throat vibration during snoring is mainly concentrated in the 55-120Hz range, a Butterworth bandpass filter can be used to filter out the 55-120Hz power frequency signal. After these two filtering steps, the vibration signals directly related to snoring can be separated and retained from the raw cardiac impulse signal, while interference from irrelevant vibration signals is eliminated.
[0085] It should be noted that after acquiring the raw cardiac impact signal generated by the user in real time, a period of time needs to be allowed for the acquired raw cardiac impact signal to stabilize before filtering the raw cardiac impact signal is processed to avoid interference from initial fluctuations that could affect the filtering effect.
[0086] S230. Adjust the current snoring threshold based on snoring data.
[0087] S240. Determine the snoring result based on the snoring data and the current snoring threshold.
[0088] This embodiment filters the original cardiac impact signal to identify the original cardiac impact signal within the vibration signal frequency band as snoring data, eliminating interference from irrelevant vibration signals and ensuring that subsequent processing and analysis are performed only on valid snoring data, thereby improving the accuracy of snoring detection.
[0089] Example 3
[0090] Figure 3 This is a flowchart illustrating a snoring detection method provided in Embodiment 3 of the present invention. Based on the above embodiments, this embodiment provides a detailed description of the dynamic reduction and adjustment method for the current snoring threshold, such as... Figure 3 As shown, the snoring detection method includes:
[0091] S310: Real-time acquisition of raw cardiac impact signals generated by the user.
[0092] S320. Determine snoring data based on the original cardiac impact signal.
[0093] S330. Traverse the snoring data using a preset sliding window and determine the cumulative value of the snoring data within the preset sliding window.
[0094] Specifically, the piezoelectric ceramic sensor can periodically acquire raw cardiac impact signals. Based on these periodically acquired signals, snoring data is periodically determined. These raw cardiac impact signals are continuous electrical signals, which can be divided into multiple discrete signal points within a detection cycle at a certain sampling rate. The amplitude of the electrical signal at each discrete signal point is the signal value. A fixed-size sliding window is pre-set, and the sliding window sequentially traverses each signal point of the snoring data. The signal values of each signal point within each sliding window are then summed to obtain the cumulative value of the snoring data within that sliding window. This cumulative value of the snoring data within the pre-set sliding window reflects the overall vibration intensity over a period of time.
[0095] For example, each detection cycle can be 1 second. Within each detection cycle, the sampling rate of the raw cardiac impulse signal is set to 500Hz, meaning that the continuous raw cardiac impulse signal can be discretized into 500 independent signal points per second, with each signal point corresponding to a signal point value at a discrete time node. At this time, each preset sliding window covers 500 signal points, moving sequentially along the time axis of the snoring data with a step size of 1. That is, the first sliding window includes signal points 1 to 500, the second sliding window includes signal points 2 to 501, and so on, until the sliding window covers the last signal point. Within a 1-second detection cycle, 500 preset sliding windows can be generated and traversed to achieve traversal of the entire snoring data. Finally, the summation of the 500 signal point values within each sliding window yields the cumulative value of that sliding window.
[0096] S340. Determine if the cumulative value is greater than the current snoring threshold; if so, execute S350.
[0097] The current snoring threshold is a quantitative criterion for determining whether a vibration signal constitutes snoring, which is dynamically updated in real time during the snoring detection process. The current snoring threshold is the initial snoring threshold at the start of the detection, and the initial snoring threshold can be set as the upper limit of the snoring threshold. As the detection progresses, the current snoring threshold will be adjusted in real time according to the changes in snoring data, and the current snoring threshold will be redefined after each adjustment.
[0098] Specifically, the cumulative value of snoring data within each sliding window can reflect the overall vibration intensity over a period of time: if the cumulative value of snoring data within the sliding window is greater than the current snoring threshold, it means that the vibration intensity of the signal point covered by the sliding window has reached the standard that can be identified as snoring, and it can be preliminarily considered that the user has snoring.
[0099] S350. During the process of traversing snoring data with a preset sliding window, the first cumulative time when the cumulative value is greater than the snoring threshold is obtained in real time.
[0100] Specifically, the first cumulative time refers to the duration from the moment when the cumulative value of snoring data within a sliding window is first detected to be greater than the snoring threshold until the moment when the cumulative value of snoring data within a certain sliding window is less than the snoring threshold.
[0101] S360. Determine whether the first accumulated time has reached the first preset time; if so, execute S370.
[0102] Specifically, the first preset time is used to determine the duration of the first cumulative time, avoiding excessive adjustments to the snoring threshold. For example, the first preset time can be the duration of two detection cycles, i.e., 2 seconds. By determining whether the first cumulative time reaches the first preset time, that is, whether the cumulative value of snoring data within the sliding window continuously exceeds the snoring threshold, it is possible to determine whether it is a genuine snoring event.
[0103] S370, reduce the current snoring threshold by the first preset adjustment amount.
[0104] Specifically, the first preset adjustment amount is a fixed value used to quantitatively reduce the current snoring threshold during the current dynamic adjustment process of the snoring threshold. When the first cumulative time reaches the first preset time (i.e., the duration for which the accumulated value of snoring data within the sliding window exceeds the snoring threshold is greater than the first preset time), it indicates that the user is snoring. The first preset adjustment amount is then subtracted from the current snoring threshold to obtain the adjusted current snoring threshold. This ensures that weak vibrations during the exhalation phase can be identified as snoring, guaranteeing the continuity and integrity of snoring monitoring. For example, the first preset adjustment amount can be 200.
[0105] In an optional embodiment, before reducing the current snoring threshold by a first preset adjustment amount, the method further includes: determining whether the current snoring threshold is greater than the lower limit of the snoring threshold; if so, then performing the step of reducing the current snoring threshold by the first preset adjustment amount.
[0106] In an optional embodiment, before reducing the current snoring threshold by a first preset adjustment amount, the method further includes: if the current snoring threshold is less than or equal to the lower limit of the snoring threshold, then adjusting the current snoring threshold to the lower limit of the snoring threshold.
[0107] Specifically, the lower limit of the snoring threshold is the lowest value set during snoring detection for dynamically adjusting the current snoring threshold. By setting a preset lower limit, the current snoring threshold can be prevented from continuously decreasing. By determining whether the current snoring threshold is greater than the lower limit, it can be determined whether to continue reducing the current snoring threshold: when the current snoring threshold is greater than the lower limit, it indicates that there is room for adjustment. In this case, reducing the current snoring threshold can effectively monitor subsequent weak snoring; when the current snoring threshold is less than or equal to the lower limit, the current snoring threshold is no longer reduced. If the current snoring threshold is less than or equal to the lower limit, the accumulated value of minor interference snoring data may exceed the current snoring threshold, leading to misjudging non-snoring signals as snoring. In cases where the current snoring threshold is too low, causing misjudgment of snoring, the current snoring threshold is adjusted to the lower limit to improve the accuracy of the snoring detection results.
[0108] After reducing the current snoring threshold by the first preset adjustment amount, it is also necessary to determine whether the reduced current snoring threshold is greater than the lower limit of the snoring threshold: if the reduced current snoring threshold is greater than the lower limit of the snoring threshold, then the reduced current snoring threshold is used as the current snoring threshold; if the reduced current snoring threshold is less than or equal to the lower limit of the snoring threshold, then the lower limit of the snoring threshold is used as the current snoring threshold, thereby improving the detection accuracy of snoring results.
[0109] S380. Determine the snoring result based on the snoring data and the current snoring threshold.
[0110] This embodiment determines whether the cumulative value of the sliding window is greater than the current snoring threshold and dynamically adjusts the snoring threshold accordingly. This ensures that weak snoring vibrations caused by exhalation are not missed, while also preventing false snoring detection due to an excessively low snoring threshold. This achieves continuous and accurate monitoring of snoring and improves the accuracy of snoring detection results.
[0111] Example 4
[0112] Figure 4 This is a flowchart illustrating a snoring detection method provided in Embodiment 4 of the present invention. Based on the above embodiments, this embodiment provides a detailed description of the dynamic adjustment method for increasing the current snoring threshold, such as... Figure 4 As shown, the snoring detection method includes:
[0113] S410: Real-time acquisition of raw cardiac impact signals generated by the user.
[0114] S420: Determine snoring data based on the original cardiac impact signal.
[0115] S430. Traverse the snoring data using a preset sliding window and determine the cumulative value of the snoring data within the preset sliding window.
[0116] S440: Determine if the cumulative value is greater than the current snoring threshold; if not, proceed to S450.
[0117] S450. During the process of traversing snoring data with a preset sliding window, the second cumulative time when the cumulative value is less than or equal to the snoring threshold is obtained in real time.
[0118] Specifically, the second cumulative time refers to the duration from the moment when the cumulative value of the sliding window is first detected to be less than or equal to the snoring threshold until the moment when the cumulative value of a certain sliding window is greater than the snoring threshold.
[0119] S460. Determine whether the second cumulative time has reached the second preset time; if so, execute S470.
[0120] Specifically, the second preset time is used to determine the duration of the second cumulative time, avoiding excessive adjustments to the snoring threshold. For example, the second preset time can be the duration of two detection cycles, i.e., 2 seconds. By determining whether the second cumulative time has reached the second preset time, that is, whether the cumulative value of snoring data within the sliding window is consistently less than the snoring threshold, it can be determined whether there is continuous non-snoring.
[0121] S470, Increase the current snoring threshold by the second preset adjustment amount.
[0122] Specifically, the second preset adjustment amount is a fixed value used to quantitatively increase the current snoring threshold during the current dynamic adjustment process of the snoring threshold. When the second cumulative time reaches the second preset time (i.e., the duration for which the accumulated value of snoring data within the sliding window is less than the current snoring threshold is greater than the second preset time), it indicates that the user is not snoring. In this case, the current snoring threshold is added to the first preset adjustment amount, and the sum of the two becomes the adjusted current snoring threshold. This ensures that weak vibrations during inhalation can be identified as snoring, guaranteeing the continuity and integrity of snoring monitoring. For example, the second preset adjustment amount can be 200.
[0123] In an optional embodiment, before increasing the current snoring threshold by a second preset adjustment amount, the method further includes: determining whether the current snoring threshold is less than the upper limit of the snoring threshold; if so, then performing the step of increasing the current snoring threshold by the second preset adjustment amount.
[0124] In an optional embodiment, before increasing the current snoring threshold by a second preset adjustment amount, the method further includes: if the current snoring threshold is greater than or equal to the upper limit of the snoring threshold, then adjusting the current snoring threshold to the upper limit of the snoring threshold.
[0125] Specifically, the upper limit of the snoring threshold is the highest value set for the dynamically adjusted current snoring threshold during snoring detection. By setting the upper limit, the current snoring threshold can be prevented from continuously rising. By determining whether the current snoring threshold is less than the upper limit, it can be determined whether to continue increasing the current snoring threshold: when the current snoring threshold is less than the upper limit, it indicates that there is room for the current snoring threshold to increase. In this case, increasing the current snoring threshold can effectively monitor subsequent strong snoring; when the current snoring threshold is greater than or equal to the upper limit, the current snoring threshold will not be increased further. If the current snoring threshold is greater than or equal to the upper limit, the cumulative value of the actual snoring signal will still be less than the current snoring threshold, causing actual snoring to be misjudged as not occurring, i.e., snoring is missed. In this case, the current snoring threshold is adjusted to the upper limit to improve the accuracy of the snoring detection results.
[0126] After increasing the current snoring threshold by the second preset adjustment amount, it is also necessary to determine whether the increased current snoring threshold is less than the upper limit of the snoring threshold: if the increased current snoring threshold is less than the upper limit of the snoring threshold, then the increased current snoring threshold is used as the current snoring threshold; if the increased current snoring threshold is greater than or equal to the upper limit of the snoring threshold, then the upper limit of the snoring threshold is used as the current snoring threshold, thereby improving the detection accuracy of snoring results.
[0127] S480. Determine the snoring result based on the snoring data and the current snoring threshold.
[0128] This embodiment determines whether the cumulative value of the sliding window is less than or equal to the current snoring threshold and dynamically increases and adjusts the current snoring threshold. This avoids misjudgment of snoring caused by the current snoring threshold being too low, and also prevents missed snoring caused by the current snoring threshold being too high. This achieves continuous and accurate monitoring of snoring and improves the accuracy of snoring detection results.
[0129] Example 5
[0130] Figure 5 This is a flowchart illustrating a snoring detection method provided in Embodiment 5 of the present invention. Based on the above embodiments, this embodiment provides a detailed description of the filtering of abnormal snoring data, such as... Figure 5 As shown, the snoring detection method includes:
[0131] S510: Real-time acquisition of raw cardiac impact signals generated by the user.
[0132] S520: Determine snoring data based on the original cardiac impact signal.
[0133] S530: Adjust the current snoring threshold based on snoring data.
[0134] S540. Traverse the snoring data using a preset sliding window and determine the cumulative value of the snoring data within the preset sliding window.
[0135] S550: Record the moment when the cumulative value begins to exceed the current snoring threshold as the snoring start moment, and record the moment when the cumulative value begins to be less than or equal to the current snoring threshold as the snoring end moment.
[0136] Specifically, when the cumulative value of snoring data in the sliding window first exceeds the current snoring threshold, this moment is recorded as the start time of snoring; after the start time of snoring, when the cumulative value of snoring data in the sliding window first becomes less than or equal to the current snoring threshold, this moment is recorded as the end time of snoring.
[0137] S560. Determine whether the duration between the start time and end time of a set of snoring is within the preset duration; if so, execute S570.
[0138] The preset duration refers to the effective snoring duration range set based on a large amount of physiological data on snoring. For example, the lower limit of the preset duration can be 0.5 seconds, and the upper limit of the preset duration can be 3 seconds. That is, only when the snoring duration is greater than 0.5 seconds and less than 3 seconds is it considered a complete and effective snoring.
[0139] Specifically, the validity of snoring data is determined by judging whether the duration between the start and end times of a set of snoring is within a preset time. If the duration between the start and end times of a set of snoring is less than the lower limit of the preset time, it may be a false alarm caused by signal interference; if the duration between the start and end times of a set of snoring is greater than the upper limit of the preset time, it may be a false alarm caused by an abnormality in the piezoelectric ceramic sensor.
[0140] S570. Take a set of snoring data that iterates through the time interval between the start time and the end time of snoring as a single snoring data.
[0141] Specifically, when the time between the start and end of a snoring episode is within a preset time, it indicates that the snoring data within this time period is continuous and valid, and the snoring data traversed within this time period is considered as one snoring data session.
[0142] In an optional embodiment, before taking a set of snoring data traversed between a set of snoring start times and snoring end times as a single snoring data, the method further includes: acquiring the user's body movement data in real time within a set of snoring start times and snoring end times; when it is determined from the body movement data that the user has engaged in body movement, determining the snoring data traversed within the set of snoring start times and snoring end times as non-snoring data; and when it is determined from the body movement data that the user has not engaged in body movement, performing the step of taking a set of snoring data traversed between a set of snoring start times and snoring end times as a single snoring data.
[0143] Among them, the user's body movement data refers to the vibration data of the user's turning over and limb movement during sleep. Since the frequency of the body movement data may fall into the 55-120Hz frequency band, the cumulative value of snoring data in the sliding window may exceed the current snoring threshold, resulting in a misjudgment as snoring.
[0144] Specifically, within a time period between the start and end of snoring, pressure sensors can collect the user's body movement data to determine if the user is moving. If the body movement data confirms that the user moved during this time period, it indicates that the snoring data during this period may be due to body movement. Therefore, the snoring data traversed within this time period between the start and end of snoring is classified as non-snoring data to avoid misjudgment of snoring. If the body movement data confirms that the user did not move during this time period, it indicates that the snoring data during this period is due to the user's actual snoring. In this case, the snoring data traversed within this time period between the start and end of snoring can be considered as one snoring data point.
[0145] This embodiment improves the accuracy of snoring detection results by judging whether the time between the start and end of a set of snoring is within a preset time, whether the user has moved, and whether the interval between two adjacent snoring episodes is too short.
[0146] Example 6
[0147] Figure 6 This is a flowchart illustrating a snoring detection method provided in Embodiment Six of the present invention. Based on the above embodiments, this embodiment provides a detailed explanation of merging two snoring data points with excessively short snoring intervals, such as... Figure 6 As shown, the snoring detection method includes:
[0148] S610: Real-time acquisition of raw cardiac impact signals generated by the user.
[0149] S620: Determine snoring data based on the original cardiac impact signal.
[0150] S630: Adjust the current snoring threshold based on snoring data.
[0151] S640. Traverse the snoring data using a preset sliding window and determine the cumulative value of the snoring data within the preset sliding window.
[0152] S650. Record the moment when the cumulative value begins to exceed the current snoring threshold as the snoring start time, and record the moment when the cumulative value begins to be less than or equal to the current snoring threshold as the snoring end time.
[0153] S660. Determine whether the duration between the start time and end time of a snoring episode is within the preset duration; if so, execute S670.
[0154] S670. Take a set of snoring data that iterates through the time interval between the start time and the end time of snoring as a single snoring data.
[0155] S680. Obtain the snoring interval between the snoring termination time of the previous snoring data and the snoring start time of the next snoring data in two adjacent snoring data sets.
[0156] S690. Determine whether the snoring interval is less than or equal to the preset interval; if so, execute S6110.
[0157] The preset interval time refers to the threshold for determining continuous snoring based on a large amount of physiological data on snoring. For example, the preset interval time can be 0.5 seconds, meaning that only when the snoring interval between the end time of the previous snoring data and the start time of the next snoring data is greater than 0.5 seconds will the two snoring data be regarded as two complete and valid snoring events.
[0158] S6110, merge the two adjacent snoring data into one snoring data.
[0159] Specifically, the system determines whether two snoring data points constitute two complete and valid snoring events by judging whether the snoring interval between the end time of the previous snoring data point and the start time of the next snoring data point is less than or equal to a preset interval. If the snoring interval between the end time of the previous snoring data point and the start time of the next snoring data point is less than the preset interval, it indicates that the two snoring records are essentially a split of a continuous snoring event. Therefore, these two adjacent snoring data points need to be merged into one snoring data point to avoid inflating the statistical snoring data and further improve the accuracy of snoring data detection.
[0160] This embodiment acquires and determines whether the snoring interval between the snoring termination time of the previous snoring data and the snoring start time of the next snoring data is less than or equal to a preset interval. This allows for the merging of two snoring data sets with excessively short snoring intervals, preventing the statistical snoring data from being overestimated and further improving the accuracy of snoring data detection.
[0161] Example 7
[0162] Figure 7 This is a schematic diagram of a snoring detection device provided in an embodiment of the present invention. This device can be used to detect a user's snoring. The snoring detection device can be implemented by software and / or hardware, and is generally integrated into the controller provided in this embodiment of the present invention. Figure 7 As shown, the snoring detection device includes:
[0163] Signal acquisition module 710 is used to acquire the raw cardiac impact signal generated by the user in real time;
[0164] The snoring data determination module 720 is used to determine snoring data based on the original cardiac impact signal;
[0165] The snoring threshold adjustment module 730 is used to adjust the current snoring threshold based on snoring data;
[0166] The snoring result determination module 740 is used to determine the snoring result based on snoring data and the current snoring threshold.
[0167] Optionally, the snoring data determination module 720 is specifically used to: filter the original cardiac impact signal and determine the original cardiac impact signal in the vibration signal frequency band as snoring data.
[0168] Optionally, the snoring threshold adjustment module 730 may include a cumulative value determination unit, a cumulative value judgment unit, a first cumulative time acquisition unit, a first cumulative time judgment unit, and a snoring threshold reduction unit; the cumulative value determination unit is used to traverse snoring data with a preset sliding window and determine the cumulative value of snoring data within the preset sliding window; the cumulative value judgment unit is used to determine whether the cumulative value is greater than the current snoring threshold; the first cumulative time acquisition unit is used to acquire, in real time, a first cumulative time when the cumulative value is greater than the snoring threshold during the process of traversing snoring data with a preset sliding window if the cumulative value is greater than the current snoring threshold; the first cumulative time judgment unit is used to determine whether the first cumulative time has reached a first preset time; the snoring threshold reduction unit is used to reduce the current snoring threshold by a first preset adjustment amount if the first cumulative time has reached the first preset time.
[0169] Optionally, the snoring threshold adjustment module 730 further includes a snoring threshold judgment unit; the snoring threshold judgment unit is used to determine whether the current snoring threshold is greater than the lower limit of the snoring threshold; the snoring threshold reduction unit is also used to reduce the current snoring threshold by a first preset adjustment amount when the current snoring threshold is greater than the lower limit of the snoring threshold.
[0170] Optionally, the snoring threshold adjustment module 730 also includes a snoring threshold lower limit adjustment unit, which is used to adjust the current snoring threshold to the snoring threshold lower limit if the current snoring threshold is less than or equal to the snoring threshold lower limit.
[0171] Optionally, the snoring threshold adjustment module 730 further includes a second cumulative time acquisition unit, a second cumulative time judgment unit, and a snoring threshold increase unit; the second cumulative time acquisition unit is used to acquire, in real time, a second cumulative time when the cumulative value is less than or equal to the current snoring threshold, during the process of traversing snoring data with a preset sliding window if the cumulative value is less than or equal to the current snoring threshold; the second cumulative time judgment unit is used to determine whether the second cumulative time has reached a second preset time; the snoring threshold increase unit is used to increase the current snoring threshold by a second preset adjustment amount if the second cumulative time has reached the second preset time.
[0172] Optionally, the snoring threshold adjustment module 730 further includes a snoring threshold judgment unit; the snoring threshold judgment unit is used to determine whether the current snoring threshold is less than the upper limit of the snoring threshold; the snoring threshold increase unit is also used to increase the current snoring threshold by a second preset adjustment amount when the current snoring threshold is less than the upper limit of the snoring threshold.
[0173] Optionally, the snoring threshold adjustment module 730 also includes a snoring threshold upper limit adjustment unit, which is used to adjust the current snoring threshold to the snoring threshold upper limit if the current snoring threshold is greater than or equal to the snoring threshold upper limit.
[0174] Optionally, the snoring result determination module 740 may include a cumulative value determination unit, a snoring start time and snoring end time determination unit, a snoring start time and snoring end time judgment unit, and a snoring data determination unit; the cumulative value determination unit is used to traverse the snoring data with a preset sliding window and determine the cumulative value of the snoring data within the preset sliding window; the snoring start time and snoring end time determination unit is used to record the time when the cumulative value begins to be greater than the current snoring threshold as the snoring start time, and the time when the cumulative value begins to be less than or equal to the current snoring threshold as the snoring end time; the snoring start time and snoring end time judgment unit is used to determine whether the duration between a set of snoring start times and snoring end times is within a preset duration; the snoring data determination unit is used to, if the duration between a set of snoring start times and snoring end times is within the preset duration, then take the snoring data traversed within the time period between a set of snoring start times and snoring end times as one snoring data instance.
[0175] Optionally, the snoring result determination module 740 further includes a snoring interval acquisition unit, a snoring interval judgment unit, and a snoring data merging unit; the snoring interval acquisition unit is used to acquire the snoring interval between the snoring termination time of the previous snoring data and the snoring start time of the next snoring data in two adjacent snoring data sets; the snoring interval judgment unit is used to determine whether the snoring interval is less than or equal to a preset interval; the snoring data merging unit is used to merge the two adjacent snoring data sets into one snoring data set if the snoring interval is less than or equal to the preset interval.
[0176] Optionally, the snoring result determination module 740 further includes a body movement data acquisition unit and a non-snoring data determination unit; the body movement data acquisition unit is used to acquire the user's body movement data in real time within a time period between a set of snoring start times and snoring end times; the non-snoring data determination unit is used to determine the snoring data traversed within the time period between the set of snoring start times and snoring end times as non-snoring data when it is determined from the body movement data that the user has engaged in body movement; the snoring data determination unit is also used to take the snoring data traversed within the time period between the set of snoring start times and snoring end times as a single snoring data when it is determined from the body movement data that the user has not engaged in body movement.
[0177] It is understood that, since the snoring detection device described above is capable of executing the snoring detection method in the embodiments of the present invention, those skilled in the art can understand the specific implementation and various variations of the snoring detection device in this embodiment based on the snoring detection method described in the embodiments of the present invention. Therefore, how the snoring detection device implements the snoring detection method in the embodiments of the present invention will not be described in detail here. Any device used by those skilled in the art to implement the snoring detection method in the embodiments of the present invention falls within the scope of protection of this application.
[0178] Example 8
[0179] This invention provides a smart mattress, comprising: a mattress body, a piezoelectric ceramic sensor, and a controller; the piezoelectric ceramic sensor is disposed on the mattress body and is used to acquire the original cardiac impact signal generated by the user in real time; the controller is electrically connected to the piezoelectric ceramic sensor; the controller is used to execute the snoring detection method of any embodiment of this invention.
[0180] The smart mattress provided in this embodiment can execute the snoring detection method of any embodiment of the present invention, and has a functional module for executing the snoring detection method of any embodiment of the present invention. It can achieve the effect of the snoring detection method of the above embodiments. The similarities can be referred to the above description, and will not be repeated here.
[0181] Example 9
[0182] This invention provides a computer storage medium storing computer instructions. These computer instructions are used to cause a controller to execute the snoring detection method of any embodiment of this invention, thus achieving the beneficial effects of the corresponding snoring detection method. Similarities can be found in the description above, and will not be repeated here.
[0183] In the context of this invention, a computer storage medium can be a tangible medium that may contain or store computer programs for use by or in conjunction with an instruction execution system, apparatus, or device. The computer storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof.
[0184] Note that the above description is merely a preferred embodiment of the present invention and the technical principles employed. Those skilled in the art will understand that the present invention is not limited to the specific embodiments described herein, and various obvious changes, readjustments, combinations, and substitutions can be made without departing from the scope of protection of the present invention. Therefore, although the present invention has been described in detail through the above embodiments, the present invention is not limited to the above embodiments, and may include many other equivalent embodiments without departing from the concept of the present invention, the scope of which is determined by the scope of the appended claims.
Claims
1. A snoring detection method, characterized by, The method comprises the following steps: obtaining original heart impact signals generated by a user in real time; determining snoring data according to the original heart impact signals; adjusting a current snoring threshold according to the snoring data; determining a snoring result according to the snoring data and the current snoring threshold.
2. The snoring detection method of claim 1, wherein, The step of determining snoring data according to the original heart impact signals comprises the following steps: filtering the original heart impact signals, and determining original heart impact signals in a vibration signal frequency band as the snoring data.
3. The snoring detection method of claim 1, wherein, The step of adjusting a current snoring threshold according to the snoring data comprises the following steps: traversing the snoring data with a preset sliding window, and determining a cumulative value of the snoring data in the preset sliding window; determining whether the cumulative value is greater than the current snoring threshold; if yes, obtaining a first cumulative time during which the cumulative value is greater than the snoring threshold in the process of traversing the snoring data with the preset sliding window in real time; determining whether the first cumulative time reaches a first preset time; if yes, reducing the current snoring threshold by a first preset adjustment amount.
4. The snoring detection method of claim 3, wherein, Before the step of reducing the current snoring threshold by the first preset adjustment amount, the method further comprises the following steps: determining whether the current snoring threshold is greater than a snoring threshold lower limit; if yes, performing the step of reducing the current snoring threshold by the first preset adjustment amount.
5. The snoring detection method of claim 4, wherein, Before the step of reducing the current snoring threshold by the first preset adjustment amount, the method further comprises the following steps: if the current snoring threshold is less than or equal to the snoring threshold lower limit, adjusting the current snoring threshold to the snoring threshold lower limit.
6. The snoring detection method of claim 3, wherein, The step of adjusting a current snoring threshold according to the snoring data further comprises the following steps: if the cumulative value is less than or equal to the current snoring threshold, obtaining a second cumulative time during which the cumulative value is less than or equal to the snoring threshold in the process of traversing the snoring data with the preset sliding window in real time; determining whether the second cumulative time reaches a second preset time; if yes, increasing the current snoring threshold by a second preset adjustment amount.
7. The snoring detection method of claim 6, wherein, Before the step of increasing the current snoring threshold by the second preset adjustment amount, the method further comprises the following steps: determining whether the current snoring threshold is less than a snoring threshold upper limit; if yes, performing the step of increasing the current snoring threshold by the second preset adjustment amount.
8. The snoring detection method of claim 7, wherein, Before the step of increasing the current snoring threshold by the second preset adjustment amount, the method further comprises the following steps: if the current snoring threshold is greater than or equal to the snoring threshold upper limit, adjusting the current snoring threshold to the snoring threshold upper limit.
9. The snore detection method of claim 1, wherein, The step of determining a snoring result according to the snoring data and the current snoring threshold comprises the following steps: traversing the snoring data with a preset sliding window, and determining a cumulative value of the snoring data in the preset sliding window; recording a time when the cumulative value starts to be greater than the current snoring threshold as a snoring starting time, and recording a time when the cumulative value starts to be less than or equal to the current snoring threshold as a snoring ending time; determining whether a time length between a group of the snoring starting times and the snoring ending times is within a preset time length; if yes, regarding the snoring data traversed in a time period between a group of the snoring starting times and the snoring ending times as a snoring data.
10. The snoring detection method of claim 9, wherein, The step of determining a snoring result according to the snoring data and the current snoring threshold further comprises the following steps: acquiring a snoring interval time between a snoring termination time of previous snoring data and a snoring initiation time of next snoring data in two adjacent snoring data; determining whether the snoring interval time is less than or equal to a preset interval time; if yes, merging the two adjacent snoring data as one snoring data.
11. The snore detection method of claim 9, wherein, Before the snoring data in a set of time periods between the snoring initiation time and the snoring termination time is traversed as one snoring data, further comprising: acquiring body movement data of the user in real time in a set of time periods between the snoring initiation time and the snoring termination time; when it is determined according to the body movement data that the user has body movement, determining the snoring data traversed in the set of time periods between the snoring initiation time and the snoring termination time as non-snoring data; when it is determined according to the body movement data that the user has no body movement, performing the step of traversing the snoring data in a set of time periods between the snoring initiation time and the snoring termination time as one snoring data.
12. A snore detection apparatus, characterized by, comprising: a signal acquisition module, configured to acquire original heart impact signals generated by a user in real time; a snoring data determination module, configured to determine snoring data according to the original heart impact signals; a snoring threshold adjustment module, configured to adjust a current snoring threshold according to the snoring data; a snoring result determination module, configured to determine a snoring result according to the snoring data and the current snoring threshold.
13. A smart mattress, characterized in that, comprising: a mattress body, a piezoelectric ceramic sensor and a controller; the piezoelectric ceramic sensor is arranged on the mattress body and is configured to acquire original heart impact signals generated by a user in real time; the controller is electrically connected with the piezoelectric ceramic sensor, and the controller is configured to perform the snoring detection method in any one of claims 1-11.
14. A computer storage medium, characterized in that The computer storage medium stores computer instructions, and the computer instructions are used to make the controller perform the snoring detection method in any one of claims 1-11 when the controller executes the computer instructions.
Citation Information
Patent Citations
Snore recognition method, system and device and storage medium
CN118680550A
Snore detection method, snore detection device, and bed
JP2021171290A
Apparatus for analyzing sleeping state and method of analyzing for sleeping state
KR1020180096176A
High-Sensitivity Sensors for Sensing Various Physiological Phenomena, Particularly Useful in Anti-Snoring Apparatus and Methods
US20080306396A1