CN111374819B - Snore stopper, snore recognition method thereof, snore recognition device and storage medium - Google Patents

Snore stopper, snore recognition method thereof, snore recognition device and storage medium Download PDF

Info

Publication number
CN111374819B
CN111374819B CN202010183997.4A CN202010183997A CN111374819B CN 111374819 B CN111374819 B CN 111374819B CN 202010183997 A CN202010183997 A CN 202010183997A CN 111374819 B CN111374819 B CN 111374819B
Authority
CN
China
Prior art keywords
snore
acceleration
data
characteristic parameter
determining
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN202010183997.4A
Other languages
Chinese (zh)
Other versions
CN111374819A (en
Inventor
戴浩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Shenzhen Market Value Meter Technology Co ltd
Original Assignee
Shenzhen Market Value Meter Technology Co ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Shenzhen Market Value Meter Technology Co ltd filed Critical Shenzhen Market Value Meter Technology Co ltd
Priority to CN202010183997.4A priority Critical patent/CN111374819B/en
Publication of CN111374819A publication Critical patent/CN111374819A/en
Application granted granted Critical
Publication of CN111374819B publication Critical patent/CN111374819B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • AHUMAN NECESSITIES
    • A61MEDICAL OR VETERINARY SCIENCE; HYGIENE
    • A61FFILTERS IMPLANTABLE INTO BLOOD VESSELS; PROSTHESES; DEVICES PROVIDING PATENCY TO, OR PREVENTING COLLAPSING OF, TUBULAR STRUCTURES OF THE BODY, e.g. STENTS; ORTHOPAEDIC, NURSING OR CONTRACEPTIVE DEVICES; FOMENTATION; TREATMENT OR PROTECTION OF EYES OR EARS; BANDAGES, DRESSINGS OR ABSORBENT PADS; FIRST-AID KITS
    • A61F5/00Orthopaedic methods or devices for non-surgical treatment of bones or joints; Nursing devices; Anti-rape devices
    • A61F5/56Devices for preventing snoring
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/03Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the type of extracted parameters
    • G10L25/18Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the type of extracted parameters the extracted parameters being spectral information of each sub-band
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/03Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the type of extracted parameters
    • G10L25/24Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the type of extracted parameters the extracted parameters being the cepstrum
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS OR SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/48Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use
    • G10L25/51Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 specially adapted for particular use for comparison or discrimination

Abstract

The invention discloses a snore identification method, which comprises the following steps: acquiring sound data of a target object, and acquiring acceleration data about the larynx corresponding to the sound data; determining snore characteristic parameters according to the sound data, and determining vibration characteristic parameters according to the acceleration data; and when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the target object has snore. The invention also discloses a snore identifying device, a snore stopper and a readable storage medium. The invention aims to improve the accuracy of snore recognition.

Description

Snore stopper, snore recognition method thereof, snore recognition device and storage medium
Technical Field
The invention relates to the technical field of sleep appliances, in particular to a snore identifying method, a snore identifying device, a snore stopper and a readable storage medium.
Background
Snoring is a ubiquitous phenomenon of sleep. Since the snorer's airway is usually narrower than normal, it will snore while sleeping. In order to prevent snoring, a snore stopper is currently available, which judges whether snore exists in sound signals by identifying the sound signals of a user in the sleeping process, and automatically takes corresponding measures to prevent the user from snoring if the snore exists. However, the way of identifying the snore based on the sound signal is simple, some low-frequency sound signals in the environment are easily mistaken as the snore, and the identification accuracy is low.
Disclosure of Invention
The invention mainly aims to provide a snore identification method, aiming at improving the accuracy of snore identification.
In order to achieve the above object, the present invention provides a snore identifying method, which comprises the following steps:
acquiring sound data of a target object, and acquiring acceleration data about the larynx corresponding to the sound data;
determining snore characteristic parameters according to the sound data, and determining vibration characteristic parameters according to the acceleration data;
and when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the target object has snore.
Alternatively, the step of acquiring acceleration data about the larynx corresponding to the sound data comprises:
acquiring a plurality of first acceleration information about the larynx collected in a first time period and a plurality of second acceleration information about the larynx collected in a second time period as the acceleration data;
the first duration and the second duration are both located in the time period of sound data collection, and the first duration is longer than the second duration.
Alternatively, the step of determining a vibration characteristic parameter from the acceleration data comprises:
according to the sequence of the acquisition time, determining a first difference value between every two adjacent first acceleration information, and determining a second difference value between every two adjacent second acceleration information;
determining a first acceleration characteristic parameter according to a plurality of first difference values and the number of the first acceleration information, and determining a second acceleration characteristic parameter according to a plurality of second difference values and the number of the second acceleration information;
determining the vibration characteristic parameter according to the first acceleration characteristic parameter and the second acceleration characteristic parameter; and/or the presence of a gas in the atmosphere,
before the step of acquiring a plurality of first acceleration information about the larynx collected in the first time period and a plurality of second acceleration information about the larynx collected in the second time period as the acceleration data, the method further includes:
acquiring the breathing cycle of the target object, and acquiring the shortest duration of the snore of the target object;
and determining the first duration according to the breathing cycle, and determining the second duration according to the shortest duration.
Alternatively, the step of determining the vibration characteristic parameter from the first acceleration characteristic parameter and the second acceleration characteristic parameter comprises:
and taking the ratio of the first acceleration characteristic parameter to the second acceleration characteristic parameter as the vibration characteristic parameter.
Alternatively, the step of determining a snore characteristic parameter from the sound data comprises:
and determining a Mel cepstrum feature vector related to snore corresponding to the sound data, and taking the Mel cepstrum feature vector as the snore feature parameter.
Alternatively, the step of determining a mel-frequency cepstrum feature vector related to snore corresponding to the sound data as the snore feature parameter includes:
acquiring a frequency range corresponding to snore;
determining corresponding analysis parameters according to the frequency range;
and carrying out Mel cepstrum analysis on the sound data according to the analysis parameters to obtain Mel cepstrum characteristic vectors which are used as the snore characteristic parameters.
Alternatively, the analysis parameters include a pre-emphasis coefficient, a frame length, an overlapping frame length, a hamming window coefficient, a number of transform points of fourier change, a filter number, and a vector factor, the mel cepstrum analysis is performed on the sound data according to the analysis parameters to obtain the mel cepstrum feature vector, and the step of using the mel cepstrum feature vector as the snore feature parameter includes:
pre-emphasis processing is carried out on the sound data according to a pre-emphasis coefficient in the analysis parameters to obtain first data;
performing framing processing on the first data according to the frame length and the overlapping frame length in the analysis parameters to obtain second data;
windowing the second data according to the Hamming window coefficient in the analysis parameters to obtain third data;
carrying out Fourier transform processing on the third data according to the number of transform points in the analysis parameters to obtain fourth data;
and performing noise reduction filtering processing on the fourth data by adopting a corresponding Mel filter according to the number of the filters in the analysis parameters to obtain a multidimensional Mel cepstrum vector.
And weighting the multidimensional Mel cepstrum vector according to the vector factors in the analysis parameters to obtain the characteristic parameters of the Mel cepstrum.
In addition, in order to achieve the above object, the present application further provides a snore identifying device, including: the snore identification method comprises a memory, a processor and a snore identification program stored on the memory and capable of running on the processor, wherein the snore identification program realizes the steps of the snore identification method according to any one of the above items when being executed by the processor.
In addition, in order to achieve the above object, the present application also provides a snore stopper, including:
an acceleration sensor;
a microphone;
a snore intervention module;
in the snore identifying device, the acceleration sensor, the microphone and the snore intervening module are all connected with the snore identifying device.
In addition, in order to achieve the above object, the present application also proposes a readable storage medium, which stores a snore identifying program, and when the snore identifying program is executed by a processor, the snore identifying program implements the steps of the snore identifying method according to any one of the above.
The snore identification method combines sound data of a target object and acceleration data corresponding to the sound data and related to a throat, determines snore characteristic parameters according to the sound data, determines vibration characteristic parameters according to the acceleration data, and determines that the target object has snore when the snore characteristic parameters and the vibration characteristic parameters respectively reach corresponding threshold values. In the snore identification process, the snore identification is carried out by combining the acceleration data and the sound data of the throat instead of carrying out the snore identification based on single sound data, so that the snore identification result is not influenced by low-frequency noise, and the accuracy of the snore identification is improved.
Drawings
FIG. 1 is a schematic diagram of a hardware structure involved in the operation of the snore stopper according to the embodiment of the invention;
FIG. 2 is a schematic flow chart of an embodiment of the snore identifying method of the present invention;
FIG. 3 is a schematic flow chart of another embodiment of the snore identifying method of the present invention;
fig. 4 is a schematic flow chart of another embodiment of the snore identifying method of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The main solution of the embodiment of the invention is as follows: acquiring sound data of a target object, and acquiring acceleration data about the larynx corresponding to the sound data; determining snore characteristic parameters according to the sound data, and determining vibration characteristic parameters according to the acceleration data; and when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the target object has snore.
In the prior art, the snore is identified only according to the sound signals, so that some low-frequency sound signals in the environment are easily mistaken for the snore, and the identification accuracy is low.
The invention provides a solution, aiming at improving the accuracy of snore identification.
The embodiment of the invention provides a snore stopping device which is used for stopping a user wearing the snore stopping device from generating snore in a sleeping process. Specifically, the snore stopper is worn on the throat of a user.
Referring to fig. 1, the snore stopper may specifically include an acceleration sensor 1, a microphone 2 and a snore intervention module 3. The acceleration sensor 1 is specifically a three-axis acceleration sensor, and may be used to detect acceleration data of the user's throat. The microphone 2 may be used to detect voice data of the user. The snore intervening module 3 is used for preventing the user from generating snore in a mode of stimulating the sense organ of the user. For example, the snore intervention module 3 may be embodied as a radar, which may stop the user from snoring by generating vibrations.
In addition, in the embodiment of the invention, a snore identifying device 4 is also provided, which is used for identifying snore. The snore identifying device can be arranged in the snore stopping device and can also be arranged independently of the snore stopping device.
Referring to fig. 1, the snore identifying device 4 may include: a processor 1001 (e.g., a CPU) and a memory 1002. The memory 1002 may be a high-speed RAM memory or a non-volatile memory (e.g., a magnetic disk memory). The memory 1002 may alternatively be a storage device separate from the processor 1001.
The memory 1002, the acceleration sensor 1, the microphone 2 and the snore intervening module 3 are all connected with the processor 1001, and the processor 1001 can perform snore recognition based on data of all the components.
The memory 1002, which is a readable storage medium, may include a snore identification program. The processor 1001 may be configured to call the snore identifying program stored in the memory 1002 and perform the following steps in any of the following snore identifying methods.
Those skilled in the art will appreciate that the configuration of the device shown in fig. 1 is not intended to be limiting of the device and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
The embodiment of the invention also provides a snore identifying method which is used for identifying and detecting whether the user generates snore or not.
In an embodiment, referring to fig. 2, the snore identifying method includes:
step S10, acquiring sound data of a target object, and acquiring acceleration data about the larynx corresponding to the sound data;
the target object specifically refers to a user wearing the snore stopper in the throat.
The sound data is detected by a microphone in the snore stopper worn by the user, and the microphone can be controlled to collect the sound data according to a preset sampling frequency. Here, the frequency of use may be specifically 16 KHz.
The acceleration data is detected through an acceleration sensor worn in a snore stopper in the throat of a user, and the acquired acceleration data is acceleration information detected by the acceleration sensor at multiple moments in the same time period as sound data acquisition.
Step S20, snore characteristic parameters are determined according to the sound data, and vibration characteristic parameters are determined according to the acceleration data;
according to the characteristics of the snore (such as sound frequency segments, change characteristics and the like), the snore characteristics are identified and extracted from the sound data, and the extracted result is used as a snore characteristic parameter. The snore characteristic parameter extraction method can be set according to actual requirements. For example, the sound data may be compared with preset sound data having snore characteristics, and the data in the sound data that is compared with each other is used as the snore characteristic parameter. In addition, snore characteristic parameters can be extracted from the sound data in a sound characteristic extraction mode such as Mel cepstrum analysis.
The vibration characteristic parameters are specifically characteristic parameters for characterizing the throat vibration amplitude characteristics of the user. The acceleration data can be directly used as the vibration characteristic parameters, and the result after processing according to a certain rule can be used as the vibration characteristic parameters.
Step S30, when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the target object has snore.
Specific values of the first threshold and the second threshold may be specifically set according to a user type or the like. The snore characteristic parameter reaches a first threshold value, and the fact that the snore possibly exists in the sound sent by the user currently is represented; if the snore characteristic parameter is smaller than a first threshold value, representing that the snore cannot exist in the sound currently sent by the user; when the vibration characteristic parameter reaches a second threshold value, representing that the vibration caused by snoring, somntalking, talking and the like of the user exists in the throat of the user in the voice data acquisition time period; the vibration characteristic parameter is smaller than a second threshold value, and vibration caused by snoring, somntalking, talking and the like of the user does not exist in the throat of the user in the sound data acquisition time period.
Based on the above, when the snore characteristic parameter reaches the first threshold value and the vibration characteristic parameter reaches the second threshold value, the sound currently sent by the user can be considered as the snore, and other low-frequency and medium-frequency noises are not caused to generate characteristic information similar to the snore in the sound data, so that the target object can be determined to have the snore. When the snore characteristic parameter and/or the vibration characteristic parameter contains more than one characteristic quantity, the snore of the target object can be judged only if all the characteristic quantities in the snore characteristic parameter and the vibration characteristic parameter reach corresponding threshold values.
In this embodiment, a snore identifying method is provided, where sound data of a target object and acceleration data corresponding to the sound data and related to a throat are combined, a snore characteristic parameter is determined according to the sound data, a vibration characteristic parameter is determined according to the acceleration data, and when the snore characteristic parameter and the vibration characteristic parameter reach corresponding thresholds, respectively, it is determined that a snore exists in the target object. In the snore identification process, the snore identification is carried out by combining the acceleration data and the sound data of the throat instead of carrying out the snore identification based on single sound data, so that the snore identification result is not influenced by low-frequency noise, and the accuracy of the snore identification is improved.
Further, based on the above embodiment, another embodiment of the snore identification method of the present application is provided. In the present embodiment, referring to fig. 3, step S10 includes:
step S11 of acquiring sound data of a target object, acquiring a plurality of first acceleration information about the larynx acquired in a first period, and a plurality of second acceleration information about the larynx acquired in a second period as the acceleration data;
the first duration and the second duration are both located in the time period of sound data collection, and the first duration is longer than the second duration.
In the process of collecting sound data by the microphone, the acceleration sensor synchronously collects acceleration information. Specifically, a plurality of pieces of first acceleration information acquired by an acceleration sensor according to a first sampling frequency within a first duration in a sound data acquisition time period are acquired; and acquiring a plurality of pieces of second acceleration information acquired by the acceleration sensor within a second time period included in the first time period according to a second sampling frequency. And the sampling quantity corresponding to the first time length and the first sampling frequency is greater than the sampling quantity corresponding to the second time length and the second sampling frequency. The time length of the time period during which the sound data is collected is greater than or equal to the first time length.
The specific values of the first duration and the second duration can be set according to actual requirements. Specifically, before step S11, the breathing cycle of the target object may be obtained, and the shortest duration of the snore of the target object is obtained; and determining the first duration according to the breathing cycle, and determining the second duration according to the shortest duration. The breathing cycle refers to the length of time that a target subject breathes and inhales once for. The snore minimum duration refers to the length of time that the user emits the snore for the shortest duration. The breathing cycle and the shortest duration may be preset values; or may be a parameter determined according to the actual condition of the target object. Specifically, different types of target objects may correspond to different breathing cycles and shortest duration, and the breathing cycles and the shortest duration thereof may be determined according to the types of the target objects. The breathing cycle can be directly used as the first duration, and the time length after a certain time amplitude is added on the basis of the breathing cycle can also be used as the first duration. The shortest duration of snoring can be directly used as the second duration. Based on the information, the first acceleration information collected in the first time length can represent the condition of the magnitude of the laryngeal vibration of the user in the whole breathing cycle; the second acceleration information acquired in the second time period can represent the situation of the magnitude of the throat vibration amplitude of the user in the shortest time length in which snoring possibly occurs.
The breathing cycle can be obtained based on the acceleration data of the target object detected by the three-axis acceleration sensor.
Step S20 includes:
step S21, determining snore characteristic parameters according to the sound data;
step S22, according to the sequence of the acquisition time, determining a first difference value between every two adjacent first acceleration information, and determining a second difference value between every two adjacent second acceleration information;
specifically, the adjacent first acceleration information refers to two pieces of first acceleration information with adjacent acquisition time, and in a plurality of pieces of first acceleration information acquired within a first time period, according to the acquisition time, the difference value of each group of two pieces of adjacent first acceleration information is respectively determined to obtain a plurality of first difference values; the adjacent second acceleration information refers to two pieces of second acceleration information with adjacent acquisition time, and in the plurality of pieces of second acceleration information acquired within the second duration, the difference value of each group of two pieces of adjacent second acceleration information is respectively determined according to the acquisition time, so as to obtain a plurality of second difference values. It should be noted that, here, the first difference and the second difference are both absolute values.
Step S23, determining a first acceleration characteristic parameter according to a plurality of the first difference values and the number of the first acceleration information, and determining a second acceleration characteristic parameter according to a plurality of the second difference values and the number of the second acceleration information;
specifically, the number of the first acceleration information specifically refers to a sampling amount of the acceleration information acquired by the acceleration sensor within a first time period according to a first sampling frequency; the number of the second acceleration information specifically refers to a sampling amount of the acceleration information acquired by the acceleration sensor within the second time period according to the second sampling frequency.
The first acceleration characteristic parameter specifically characterizes a parameter of the acceleration change characteristic of the throat within the first time period, which may be specifically calculated according to the following equation (1):
Figure BDA0002413517850000081
the method comprises the steps of acquiring first acceleration information at two adjacent moments, acquiring second acceleration information at two adjacent moments, acquiring third acceleration information and L, wherein Long is a first acceleration characteristic parameter, v(s) is first acceleration information acquired from the first acceleration information acquired at two adjacent moments, v (s-1) is first acceleration information acquired first acceleration information at two adjacent moments, and L is the number of the first acceleration information.
The second acceleration characteristic parameter specifically represents a parameter of the acceleration change characteristic of the throat in the second duration, and the second acceleration characteristic parameter may be calculated according to the following formula (2):
Figure BDA0002413517850000091
wherein Short is a second acceleration characteristic parameter, v (S) is second acceleration information acquired later in second acceleration information acquired at two adjacent moments, v (S-1) is second acceleration information acquired earlier in the second acceleration information acquired at two adjacent moments, and S is the number of the second acceleration information.
Specifically, the first time period may be specifically 5s, the second time period may be specifically 150ms, the number of the first acceleration information is specifically 4000, and the number of the second acceleration information is specifically 120.
Step S24, determining the vibration characteristic parameter according to the first acceleration characteristic parameter and the second acceleration characteristic parameter;
in this embodiment, a ratio of the first acceleration characteristic parameter to the second acceleration characteristic parameter is used as the vibration characteristic parameter, which characterizes whether short-time sudden change occurs in throat vibration in a time period of sound data acquisition, and if the vibration characteristic parameter is large, the short-time sudden change occurs in the characterization, and if the vibration characteristic parameter is small, the short-time sudden change does not occur in the characterization.
Based on the above, when the snore characteristic parameter reaches the first threshold value, and the vibration characteristic parameter reaches the second threshold value, it indicates that the throat vibration amplitude of the user has short-time sudden change caused by snore and other sounds, and at this time, because the sound data has snore characteristics, it can be determined that the target object currently has snore; when the snore characteristic parameter reaches the first threshold value and the vibration characteristic parameter is smaller than the second threshold value, the fact that the short-time sudden change possibly caused by the snore does not exist in the current throat vibration amplitude of the user is indicated, the snore characteristic existing in the sound data is caused by middle-low frequency noise, and therefore the fact that the snore does not exist in the target object currently can be judged.
In other embodiments, the vibration characteristic parameter may be determined by combining the first acceleration characteristic parameter and the second acceleration characteristic parameter in other manners according to other characteristics of the throat vibration when the user generates snore.
Step S30, when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the target object has snore.
In this embodiment, a plurality of first acceleration information acquired at a first time duration and a plurality of second acceleration information acquired at a second time duration within a time period for acquiring sound data of a target object are acquired, and a vibration condition of a throat of the target object within the time period for generating the sound data is accurately represented based on the plurality of acceleration information acquired within different sampling periods, so that whether snore exists in current sound data can be accurately represented based on a comparison result of a determined vibration characteristic parameter and a second threshold, and then an accurate identification of whether the snore exists in the target object is realized by further combining the comparison result of the snore characteristic parameter and the first threshold, and an influence of low-frequency noise on the snore identification is avoided. The corresponding acceleration characteristic parameters are respectively determined in periods with different lengths based on the difference value of adjacent acceleration information, so that the determined acceleration characteristic parameters can accurately reflect the acceleration change caused by the throat vibration of the user in each period, and whether short-time sudden change of the throat vibration caused by the snore generated by the user exists in a time period for acquiring sound data is accurately reflected based on the two acceleration characteristic parameters, and the accuracy of snore identification is further improved.
It should be noted that the sequence of the step S21, the step S22, the step S23, and the step S24 is not limited, and the step S22, the step S23, and the step S24 may be executed simultaneously when the step S21 is executed, or the step S22, the step S23, and the step S24 may be executed before or after the step S21 is executed.
Further, based on any one of the above embodiments, another embodiment of the snore identifying method is provided. In the present embodiment, step S21 in step S20 includes:
step S210, determining a Mel cepstrum feature vector related to snore corresponding to the sound data, and taking the Mel cepstrum feature vector as the snore feature parameter.
And acquiring analysis parameters of the Mel cepstrum analysis on the snore, and performing the Mel cepstrum analysis on the sound data according to the acquired analysis parameters to acquire Mel cepstrum feature vectors as the snore feature parameters. Specifically, pre-emphasis processing, framing processing, windowing processing, Fourier transform processing and noise reduction filtering processing are sequentially performed on the sound data according to the analysis parameters to obtain multi-dimensional Mel cepstrum vectors, and Mel cepstrum feature vectors representing snore are determined according to the multi-dimensional Mel cepstrum vectors to serve as the snore feature parameters.
In order to improve accuracy of a Mel cepstrum feature vector about snore extracted from sound data, a frequency band range corresponding to the snore can be obtained, corresponding analysis parameters are determined according to a channel range, Mel cepstrum analysis is carried out on the sound data according to the analysis parameters, and the Mel cepstrum feature vector is obtained and serves as a parameter of the snore feature.
The method is different from a frequency range [82Hz, 1.2KHz ] of a voice signal, the frequency range of the snore is specifically [30Hz, 120Hz ], and analysis parameters (such as a pre-emphasis coefficient, a frame length, an overlapping frame length, a Hamming window coefficient, the number of transform points of Fourier change, the number of filters, vector factors and the like) of each processing process of the Mel cepstrum analysis can be determined based on the frequency range of the snore. Different types of users can correspond to different snore frequency band ranges (the specific types can be divided according to age, gender and the like), and the corresponding snore frequency band ranges can be obtained based on the types of the target objects to determine corresponding analysis parameters.
In this embodiment, the pre-emphasis coefficient determined based on the frequency band range of the snoring is specifically 0.92, the frame length is specifically 2048, the overlapping frame length is specifically 1024 (half of the frame length), the hamming window coefficient is specifically 0.26, the number of transform points of the fourier transform is specifically 1024, and the number of filters is specifically 40. Based on this, referring to fig. 4, step S210 may specifically include:
step S211, pre-emphasis processing is carried out on the sound data according to pre-emphasis coefficients in analysis parameters to obtain first data;
the pre-emphasis process essentially performs a high-pass filtering of the sound data according to the pre-emphasis coefficients. The microphone collects sound data according to a certain sampling frequency, so that the sound data comprises sampling values of the microphone at a plurality of sampling points corresponding to the sampling frequency, each sampling point is respectively configured with a sequence number according to the sequence of the collection time, and the difference between the sequence number of the previous sampling point and the sequence number of the next sampling point is 1. That is, in two adjacent sampling points corresponding to the audio data, the sequence number of the former sampling point is n-1, and the sequence number of the latter sampling point is n. The pre-emphasis coefficient 0.92 is close to 1, and the single-frame weight is reduced because the low-frequency processing is performed on the snore, so that the accuracy of snore identification is ensured. Specifically, the sound data is pre-emphasized by using a pre-emphasis coefficient based on the following formula (3):
Result(n)=buf(n)-EMPHASIS_FACTOR*buf(n-1)——(3);
wherein n is the serial number of the sampling points set in sequence according to the sampling time, buf (n) is the sampling value collected by the sampling point microphone with the serial number of n, EMPHASIS _ FACTOR is the pre-EMPHASIS coefficient, and Result [ n ] is the pre-EMPHASIS Result formed by the sampling values corresponding to the sampling point with the serial number of n in the sound data.
Each sampling point in the sound data is subjected to pre-emphasis according to the formula, and then the pre-emphasized result can be used as first data.
Step S212, performing framing processing on the first data according to the frame length and the overlapping frame length in the analysis parameters to obtain second data;
and performing overlapping framing processing on the first data based on the frame length and the overlapping frame length to obtain second data. The overlap frame length refers to the length of a data frame in which two adjacent frames of data have the same sound data. In the second data, each frame of sound data has a length of 2048, and the next frame of sound data contains half of the previous frame of sound data, i.e., sound data having a frame length of 1024 is the same for two adjacent frames of sound data. Here, by overlapping framing processing, continuity of sound characteristics can be ensured, thereby improving accuracy of snore recognition. The length of the overlapped frame is half of the length of the frame, and the accuracy and the efficiency of the snore recognition can be considered at the same time.
According to the time sequence of sound collection, a part of sound data can be intercepted into a frame at certain intervals. Based on the above, a plurality of sampling points adjacent to each other in the acquisition time form a sampling point set as an observation unit, which is a frame. The frame length may be specified as the number of sampling points in the set of sampling points. The sound data is framed based on the frame length 2048, each frame comprises sampling values of 2048 sampling points, a section of overlapping area between adjacent frames is an overlapping frame, the length of the overlapping frame is 1024, and then the two adjacent frames comprise 1024 sampling values of the same sampling points. Based on the rule, the pre-emphasis result of the sampling value corresponding to each sampling point in the first data is subjected to framing to obtain a result, and the result is used as second data. The second data comprises pre-emphasis results of multiple frames of data. Wherein, the sequence number of the first sample point of each frame is defined as 0, and the pre-emphasis result of the sample value of the first sample point of each frame in the second data satisfies a following relation (4):
result (0) ═ buf (0) -electrophoresis _ FACTOR @ buf [ (N/2-1], - (4) — that is, the pre-EMPHASIS Result of the first sample point in each frame timing is the same as the pre-EMPHASIS Result of the last sample point in the data of the previous frame half frame.
Step S213, windowing the second data according to the Hamming window coefficient in the analysis parameters to obtain third data;
and respectively carrying out windowing processing on the data of each frame in the second data according to the Hamming window coefficient to obtain third data. Specifically, based on the following formulas (5) and (6), windowing is performed on each frame of data in the second data by using a hamming window coefficient:
Win(n)=(1-α)-αcos(2*π*n/(N-1))——(5);
Result_w(n)=Result(n)*Win(n)——(6);
wherein N is the serial number of the sampling point, N is the frame length, and N is less than N; alpha is the Hamming window coefficient; win (n) is a window function corresponding to the sampling point with the sequence number of n in the second data; result (n) is a pre-emphasis result corresponding to the sampling point with the sequence number n in the second data; result _ w (n) is the windowing Result corresponding to the sampling point with the sequence number n in the second data.
And windowing each frame of data in the second data according to the formula and the Hamming window coefficient, and taking the obtained result as third data.
Step S214, carrying out Fourier transform processing on the third data according to the number of transform points in the analysis parameters to obtain fourth data;
and performing Fourier transform on each frame data in the third data according to the number of transform points to obtain a frequency spectrum vector group as fourth data. Specifically, based on the following formulas (7) and (8), each frame of data in the third data is subjected to fourier transform processing according to the number of transform points:
Figure BDA0002413517850000131
Figure BDA0002413517850000132
NN is the number of points of Fourier transform, and the number of the points can be half of the frame length N, namely N/2, for convenient calculation in actual operation; defining sampling points needing Fourier transform in each frame of data of the third data as frequency points; k is a serial number corresponding to each frequency point, and k < NN; j is the cumulative number of bins in front of bin k, j < k.
And taking the result obtained after each frame of data of the third data is subjected to cosine and sine Fourier transform respectively according to the mode as fourth data.
And S215, performing noise reduction filtering processing on the fourth data by adopting a corresponding Mel filter according to the number of filters in the analysis parameters to obtain a multidimensional Mel cepstrum vector.
And carrying out harmonic processing on the fourth data by adopting Mel filters with the number being equal to the number of the filters in a triangular band-pass filtering mode, and converting the combination of a filtering coefficient and a vector energy group of a frequency domain into a time domain by sound data of each frame to obtain a filtered 13-dimensional Mel cepstrum vector.
Specifically, the fourth data is processed according to the filter data based on the following formulas (9), (10) and (11) to obtain a multidimensional mel cepstrum vector:
Figure BDA0002413517850000133
Mel(m)=1125×ln(1+m/700)——(10);
Figure BDA0002413517850000134
wherein, Result _ fft _ energy (k) is the energy of each frequency point in each frame of data of the fourth data; m is the number of filters, 40 above; l is the dimension 1<l<14; mel (m) is a mel filter generated based on the number of filters; dlThen a mel-frequency cepstrum vector of dimension l.
Processing each frame of data of the fourth data based on the formula, wherein each frame of data can obtain a group of 13-dimensional Mel cepstrum vectors V ═ V0,v1,v2,…,v12]。
And S216, carrying out weighting processing on the multidimensional Mel cepstrum vector according to vector factors in analysis parameters to obtain the characteristic parameters of the Mel cepstrum.
And determining the dimension corresponding to the Mel cepstrum vector of which the frequency response performance is greater than a preset threshold value in the 13-dimensional Mel cepstrum vector, and performing weighting processing on the Mel cepstrum vector corresponding to the dimension according to a vector factor. For example, in the 13-dimensional mel-frequency cepstrum vector, if there is a good frequency response of snoring in the 3, 7, 9, and 13 dimensions, the weights corresponding to the 3, 7, 9, and 13 dimensions are set as the above-mentioned vector factors, and the weights corresponding to the other dimensions except the 3, 7, 9, and 13 dimensions are set as 0, respectively. And taking the weighted multidimensional cepstrum vector as a Mel cepstrum characteristic parameter, namely a snore characteristic parameter.
Specifically, the vector factor F of each dimension may be specifically set as:
F=[0,0,1,0,0,0,1,0,1,0,0,0,1]。
based on this, the mel-frequency cepstrum feature parameter Vprocess can be calculated by the following formula (12):
V_process=V*F——(12)
in this embodiment, the mel-frequency cepstrum feature vector of the snore corresponding to the sound data is determined and used as the snore feature parameter, which is more accurate than the way of extracting the snore features, such as direct matching with the sound feature data of the snore. The method comprises the steps of determining analysis parameters required by Mel cepstrum analysis in a frequency band range suitable for snore, sequentially performing pre-emphasis, framing processing, windowing processing, Fourier transform processing, noise reduction filtering processing and vector weighting processing on sound data based on the determined analysis parameters, realizing Mel cepstrum analysis on the sound data, and ensuring that accurate snore characteristic parameters can be obtained, so that accuracy of snore identification is further improved.
In addition, an embodiment of the present invention further provides a readable storage medium, where a snore identifying program is stored on the readable storage medium, and when being executed by a processor, the snore identifying program implements the operation steps in any of the above snore identifying methods.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or system. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or system that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
Through the above description of the embodiments, those skilled in the art will clearly understand that the method of the above embodiments can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware, but in many cases, the former is a better implementation manner. Based on such understanding, the technical solution of the present invention may be embodied in the form of a software product, which is stored in a storage medium (e.g., ROM/RAM, magnetic disk, optical disk) as described above and includes instructions for enabling a terminal device (e.g., a mobile phone, a computer, a server, an air conditioner, or a network device) to execute the method according to the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (8)

1. A snore identification method is characterized by comprising the following steps:
acquiring sound data of a target object, and acquiring acceleration data about the larynx corresponding to the sound data;
determining snore characteristic parameters according to the sound data, and determining vibration characteristic parameters according to the acceleration data;
when the snore characteristic parameter reaches a first threshold value and the vibration characteristic parameter reaches a second threshold value, determining that the snore exists in the target object;
the step of acquiring acceleration data about the larynx corresponding to the sound data includes:
acquiring a plurality of first acceleration information about the larynx collected in a first time period and a plurality of second acceleration information about the larynx collected in a second time period as the acceleration data;
wherein the first duration and the second duration are both within a time period of the sound data acquisition, and the first duration is greater than the second duration;
the step of determining a vibration characteristic parameter from the acceleration data comprises:
according to the sequence of the acquisition time, determining a first difference value between every two adjacent first acceleration information, and determining a second difference value between every two adjacent second acceleration information;
determining a first acceleration characteristic parameter according to a plurality of first difference values and the number of the first acceleration information, and determining a second acceleration characteristic parameter according to a plurality of second difference values and the number of the second acceleration information;
determining the vibration characteristic parameter according to the first acceleration characteristic parameter and the second acceleration characteristic parameter;
the step of determining the vibration characteristic parameter according to the first acceleration characteristic parameter and the second acceleration characteristic parameter comprises:
taking the ratio of the first acceleration characteristic parameter to the second acceleration characteristic parameter as the vibration characteristic parameter;
the first acceleration characteristic parameter specifically represents a parameter of the acceleration change characteristic of the throat within the first time period, and is specifically calculated according to the following formula:
Figure FDA0003335484680000021
the method comprises the following steps that Long is a first acceleration characteristic parameter, v(s) is first acceleration information acquired later in first acceleration information acquired at two adjacent moments, v (s-1) is first acceleration information acquired earlier in the first acceleration information acquired at two adjacent moments, and L is the number of the first acceleration information;
the second acceleration characteristic parameter specifically represents a parameter of the acceleration change characteristic of the throat within the second duration, and the second acceleration characteristic parameter is calculated according to the following formula:
Figure FDA0003335484680000022
wherein Short is a second acceleration characteristic parameter, v (S) is second acceleration information acquired later in second acceleration information acquired at two adjacent moments, v (S-1) is second acceleration information acquired earlier in the second acceleration information acquired at two adjacent moments, and S is the number of the second acceleration information.
2. The snore identifying method of claim 1,
before the step of acquiring a plurality of first acceleration information about the larynx collected in the first time period and a plurality of second acceleration information about the larynx collected in the second time period as the acceleration data, the method further includes:
acquiring the breathing cycle of the target object, and acquiring the shortest duration of the snore of the target object;
and determining the first duration according to the breathing cycle, and determining the second duration according to the shortest duration.
3. A snore identifying method as recited in any of claims 1 to 2, wherein the step of determining a snore characteristic parameter from the sound data comprises:
and determining a Mel cepstrum feature vector related to snore corresponding to the sound data, and taking the Mel cepstrum feature vector as the snore feature parameter.
4. The snore identifying method of claim 3, wherein said step of determining a Mel cepstral feature vector associated with said sound data with respect to snore as said snore feature parameter comprises:
acquiring a frequency range corresponding to snore;
determining corresponding analysis parameters according to the frequency range;
and carrying out Mel cepstrum analysis on the sound data according to the analysis parameters to obtain Mel cepstrum characteristic vectors which are used as the snore characteristic parameters.
5. The snore identifying method of claim 4, wherein the analysis parameters include pre-emphasis coefficients, frame lengths, overlapping frame lengths, Hamming window coefficients, transform point numbers of Fourier changes, filter numbers and vector factors, the step of performing Mel cepstrum analysis on the sound data according to the analysis parameters to obtain the Mel cepstrum feature vectors as the snore feature parameters includes:
pre-emphasis processing is carried out on the sound data according to a pre-emphasis coefficient in the analysis parameters to obtain first data;
performing framing processing on the first data according to the frame length and the overlapping frame length in the analysis parameters to obtain second data;
windowing the second data according to the Hamming window coefficient in the analysis parameters to obtain third data;
carrying out Fourier transform processing on the third data according to the number of transform points in the analysis parameters to obtain fourth data;
performing noise reduction filtering processing on the fourth data by adopting a corresponding Mel filter according to the number of filters in the analysis parameters to obtain a multidimensional Mel cepstrum vector;
and weighting the multidimensional Mel cepstrum vector according to the vector factors in the analysis parameters to obtain the characteristic parameters of the Mel cepstrum.
6. A snore identifying device, the snore identifying device comprising: a memory, a processor and a snore identifying program stored on the memory and executable on the processor, the snore identifying program when executed by the processor implementing the steps of the snore identifying method as claimed in any one of claims 1 to 5.
7. A snore stopper, characterized in that the snore stopper comprises:
an acceleration sensor;
a microphone;
a snore intervention module;
the snore identifying device of claim 6, wherein the acceleration sensor, the microphone, and the snore intervention module are all connected to the snore identifying device.
8. A readable storage medium, characterized in that the readable storage medium has stored thereon a snore identifying program, which when executed by a processor implements the steps of the snore identifying method according to any one of claims 1 to 5.
CN202010183997.4A 2020-03-16 2020-03-16 Snore stopper, snore recognition method thereof, snore recognition device and storage medium Active CN111374819B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010183997.4A CN111374819B (en) 2020-03-16 2020-03-16 Snore stopper, snore recognition method thereof, snore recognition device and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010183997.4A CN111374819B (en) 2020-03-16 2020-03-16 Snore stopper, snore recognition method thereof, snore recognition device and storage medium

Publications (2)

Publication Number Publication Date
CN111374819A CN111374819A (en) 2020-07-07
CN111374819B true CN111374819B (en) 2021-12-17

Family

ID=71215340

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010183997.4A Active CN111374819B (en) 2020-03-16 2020-03-16 Snore stopper, snore recognition method thereof, snore recognition device and storage medium

Country Status (1)

Country Link
CN (1) CN111374819B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111920390A (en) * 2020-09-15 2020-11-13 成都启英泰伦科技有限公司 Snore detection method based on embedded terminal

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017018517A (en) * 2015-07-15 2017-01-26 Tdk株式会社 Device for analyzing snoring in sleep, method for analyzing snoring in sleep, and program thereof
CN107945789A (en) * 2017-12-28 2018-04-20 努比亚技术有限公司 Audio recognition method, device and computer-readable recording medium
CN109767784A (en) * 2019-01-31 2019-05-17 龙马智芯(珠海横琴)科技有限公司 Method and device, storage medium and the processor of sound of snoring identification

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP6217003B2 (en) * 2013-05-31 2017-10-25 株式会社北電子 Terminal device, sleep behavior recording method, and sleep behavior recording program
TWI553584B (en) * 2014-10-24 2016-10-11 國立清華大學 Evaluation system, method and computer program product of relaxation state
CN106264839A (en) * 2016-08-05 2017-01-04 南通海联助眠科技产品有限公司 Intelligent snore stopping pillow
CN108618881A (en) * 2018-05-10 2018-10-09 深圳市云中飞电子有限公司 A kind of snore stopper, snore relieving method and system
CN108852289B (en) * 2018-05-10 2021-02-09 张安斌 Wearable sleep monitoring equipment based on triaxial accelerometer
CN109106164A (en) * 2018-10-09 2019-01-01 江苏和茧丝绸科技有限公司 A kind of intelligent silk quilt and preparation method thereof with sleep monitor function
CN109259733A (en) * 2018-10-25 2019-01-25 深圳和而泰智能控制股份有限公司 Apnea detection method, apparatus and detection device in a kind of sleep

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2017018517A (en) * 2015-07-15 2017-01-26 Tdk株式会社 Device for analyzing snoring in sleep, method for analyzing snoring in sleep, and program thereof
CN107945789A (en) * 2017-12-28 2018-04-20 努比亚技术有限公司 Audio recognition method, device and computer-readable recording medium
CN109767784A (en) * 2019-01-31 2019-05-17 龙马智芯(珠海横琴)科技有限公司 Method and device, storage medium and the processor of sound of snoring identification

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
Daniel S'anchez Morillo, Juan Luis Rojas Ojeda, Luis Felipe Cres.An Accelerometer-Based Device for.《IEEE TRANSACTIONS ON INFORMATION TECHNOLOGY IN BIOMEDICINE》.2010, *

Also Published As

Publication number Publication date
CN111374819A (en) 2020-07-07

Similar Documents

Publication Publication Date Title
CN106486131B (en) A kind of method and device of speech de-noising
JP4177755B2 (en) Utterance feature extraction system
US10448920B2 (en) Cough detecting methods and devices for detecting coughs
JP2019510248A (en) Voiceprint identification method, apparatus and background server
WO2019100500A1 (en) Voice signal denoising method and device
CN111816218A (en) Voice endpoint detection method, device, equipment and storage medium
JP6268717B2 (en) State estimation device, state estimation method, and computer program for state estimation
Lin et al. Automatic wheezing detection using speech recognition technique
US8834386B2 (en) Noise reduction of breathing signals
KR20060044629A (en) Isolating speech signals utilizing neural networks
WO2008041730A1 (en) Method and system for detecting wind noise
Pillos et al. A Real-Time Environmental Sound Recognition System for the Android OS.
CN108847253B (en) Vehicle model identification method, device, computer equipment and storage medium
CN109147798B (en) Speech recognition method, device, electronic equipment and readable storage medium
WO2021179717A1 (en) Speech recognition front-end processing method and apparatus, and terminal device
CN110880329A (en) Audio identification method and equipment and storage medium
CN109360585A (en) A kind of voice-activation detecting method
Zeng et al. Classifying watermelon ripeness by analysing acoustic signals using mobile devices
WO2017045429A1 (en) Audio data detection method and system and storage medium
Jaafar et al. Automatic syllables segmentation for frog identification system
CN111374819B (en) Snore stopper, snore recognition method thereof, snore recognition device and storage medium
CN106356076B (en) Voice activity detector method and apparatus based on artificial intelligence
JP2013202101A (en) Apneic state decision device, apneic state decision method, and apneic state decision program
CN111755025B (en) State detection method, device and equipment based on audio features
CN111968651A (en) WT (WT) -based voiceprint recognition method and system

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant