Speech rate recognition method, device, equipment and readable storage medium
By extracting the fundamental pitch periodic state of the speech frame in the speech data and establishing a histogram statistics chart, the speech speed prediction is directly solved, and the recognition efficiency and accuracy are improved.
Patent Information
- Application Number
- CN202110913416.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2021-08-10
- Publication Date
- 2025-02-18
- Estimated Expiration
- 2041-08-10
AI Technical Summary
In the prior art, the accuracy of speech speed recognition is greatly affected by the noise of the speaking environment and individual pronunciation habits, resulting in a lower accuracy of the recognition results.
By extracting the pitch periodic state of the speech frame in the speech data, and establishing a histogram based on the continuous distribution of the pitch periodic state, performing speech speed prediction, and directly identifying speech speed without performing speech recognition to obtain text content.
It improves the efficiency and accuracy of speech speed recognition, reduces the calculation amount and occupation of the equipment, and avoids the problem of large amount of calculation in the speech recognition process.
Smart Images

Figure CN114283839B_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of machine learning, and in particular to a speech rate recognition method, apparatus, device and readable storage medium. Background Art
[0002] Speaking speed refers to the speed at which humans present words in a unit of time when expressing language symbols. Usually, speaking speed is related to humans' specific speaking habits, mood and environment. Speaking too fast will result in poor listening effect for the listeners, while speaking too slow will cause the listeners to spend more time listening.
[0003] In the related art, the speech rate of a specified voice signal is recognized based on the Automatic Speech Recognition (ASR) technology. That is, the specified voice signal is recognized by the ASR technology to obtain the text content, and the speech duration of the text content corresponding to the specified voice signal is determined, so that the speech rate is determined by the speech duration and the content length of the text content.
[0004] However, in this process, the recognition accuracy of ASR technology is greatly affected by the noise in the speaking environment, and different people have different pronunciation habits, which also have a certain impact on the recognition rate. As a result, when the text content recognition results are incorrect, the accuracy of the speech rate calculation results is also low. Summary of the invention
[0005] The embodiments of the present application provide a speech rate recognition method, device, equipment and readable storage medium, which can improve the accuracy of speech rate prediction results. The technical solution is as follows:
[0006] In one aspect, a method for speech rate recognition is provided, the method comprising:
[0007] Acquire voice data, wherein the voice data includes at least two voice frames;
[0008] Extracting a pitch period state of the speech frame, wherein the pitch period state is used to indicate a change in the pitch period between at least two speech frames;
[0009] Establishing a histogram corresponding to the pitch cycle state, the histogram is used to indicate the distribution of the pitch cycle state in at least two state intervals, wherein the state interval is an interval divided according to the continuous distribution of the pitch cycle state, and the state interval is divided based on the continuous distribution length of the pitch cycle state;
[0010] The speech rate prediction is performed based on the distribution of the pitch period state in the histogram to obtain the speech rate recognition result corresponding to the speech data.
[0011] On the other hand, a speech rate recognition device is provided, the device comprising:
[0012] An acquisition module, used for acquiring voice data, wherein the voice data includes at least two voice frames;
[0013] An extraction module, used for extracting the pitch period state of the speech frame, wherein the pitch period state is used for indicating the pitch period change between at least two speech frames;
[0014] An establishment module, used to establish a histogram corresponding to the pitch period state, wherein the histogram is used to indicate the distribution of the pitch period state in at least two state intervals, wherein the state interval is an interval divided according to the continuous distribution of the pitch period state, and the state interval is divided based on the continuous distribution length of the pitch period state;
[0015] The prediction module is used to predict the speech rate based on the distribution of the pitch period state in the histogram to obtain the speech rate recognition result corresponding to the speech data.
[0016] On the other hand, a computer device is provided, comprising a processor and a memory, wherein the memory stores at least one program, and the at least one program is loaded and executed by the processor to implement the speech rate recognition method as described in any of the above embodiments of the present application.
[0017] On the other hand, a computer-readable storage medium is provided, wherein at least one instruction, at least one program, a code set or an instruction set is stored in the storage medium, and the at least one instruction, the at least one program, the code set or the instruction set is loaded and executed by a processor to implement a speech rate recognition method as described in any of the above-mentioned embodiments of the present application.
[0018] On the other hand, a computer program product or a computer program is provided, the computer program product or the computer program includes computer instructions, the computer instructions are stored in a computer-readable storage medium. A processor of a computer device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the computer device executes the speech rate recognition method described in any of the above embodiments.
[0019] The beneficial effects brought by the technical solution provided by the embodiment of the present application include at least:
[0020] By extracting the fundamental pitch period state of the speech frame in the speech data and identifying the speaking speed of the speech data according to the continuous distribution of the fundamental pitch period state, there is no need to perform speech recognition on the speech data to obtain the text content, and then determine the speaking speed according to the text content, thereby improving the efficiency of speech speed recognition. Since the amount of calculation required for speech recognition is large, speech speed recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupation of the device's calculation amount. BRIEF DESCRIPTION OF THE DRAWINGS
[0021] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the description of the embodiments will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without creative work.
[0022] Figure 1 is a schematic diagram of an implementation environment provided by an exemplary embodiment of the present application;
[0023] Figure 2 is a schematic diagram of a speech rate recognition framework provided by an exemplary embodiment of the present application;
[0024] Figure 3 is a flow chart of a method for speech rate recognition provided by an exemplary embodiment of the present application;
[0025] Figure 4 is a flow chart of a method for speech rate recognition provided by another exemplary embodiment of the present application;
[0026] Figure 5 is a flow chart of a method for speech rate recognition provided by another exemplary embodiment of the present application;
[0027] Figure 6 is based on Figure 5 The structural block diagram of the speech rate recognition model provided by the illustrated embodiment;
[0028] Figure 7 It is a schematic diagram of the overall process of a speech rate recognition method provided by an exemplary embodiment of the present application;
[0029] Figure 8 is a structural block diagram of a speech rate recognition device provided by an exemplary embodiment of the present application;
[0030] Fig. 9 is a structural block diagram of a speech rate recognition device provided by another exemplary embodiment of the present application;
[0031] Fig.10 It is a structural diagram of a computer device provided by an exemplary embodiment of the present application. DETAILED DESCRIPTION
[0032] In order to make the objectives, technical solutions and advantages of the present application clearer, the implementation methods of the present application will be further described in detail below with reference to the accompanying drawings.
[0033] First, a brief introduction is given to the terms involved in the embodiments of this application:
[0034] Artificial Intelligence (AI): It is the theory, method, technology and application system that uses digital computers or machines controlled by digital computers to simulate, extend and expand human intelligence, perceive the environment, acquire knowledge and use knowledge to obtain the best results. In other words, artificial intelligence is a comprehensive technology in computer science that attempts to understand the essence of intelligence and produce a new intelligent machine that can respond in a similar way to human intelligence. Artificial intelligence is to study the design principles and implementation methods of various intelligent machines, so that machines have the functions of perception, reasoning and decision-making.
[0035] Artificial intelligence technology is a comprehensive discipline that covers a wide range of fields, including both hardware-level and software-level technologies. Basic artificial intelligence technologies generally include sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operating / interactive systems, mechatronics, and other technologies. Artificial intelligence software technologies mainly include computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning.
[0036] In the embodiments of the present application, speech processing technology is mainly involved, and speech rate prediction is performed based on speech content.
[0037] Machine Learning (ML) is a multi-disciplinary subject involving probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory and other disciplines. It specializes in studying how computers simulate or implement human learning behavior to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance. Machine learning is the core of artificial intelligence and the fundamental way to make computers intelligent. Its applications are spread across all areas of artificial intelligence. Machine learning and deep learning usually include artificial neural networks, belief networks, reinforcement learning, transfer learning, inductive learning, and teaching learning.
[0038] The key technologies of speech technology include automatic speech recognition (ASR), text to speech (TTS) and voiceprint recognition. Enabling computers to listen, see, speak and feel is the future development direction of human-computer interaction, among which speech has become one of the most promising human-computer interaction methods in the future.
[0039] Natural language processing (NLP) is an important direction in the fields of computer science and artificial intelligence. It studies various theories and methods that can achieve effective communication between people and computers using natural language. Natural language processing is a science that integrates linguistics, computer science, and mathematics. Therefore, research in this field will involve natural language, that is, the language people use in daily life, so it is closely related to the study of linguistics. Natural language processing technology usually includes text processing, semantic understanding, machine translation, robot question answering, knowledge graph and other technologies.
[0040] Pitch period: is a detection method for recording the time wavelength of pitch. Pitch period is the time of a complete wavelength of a mechanical wave. In the embodiment of the present application, the speech rate corresponding to the voice data is identified by identifying the change of pitch period.
[0041] The speech rate recognition method provided in the embodiment of the present application can be applied to a terminal or a server, and can also be implemented by the terminal and the server through data interaction, which is not limited in the embodiment of the present application. In this embodiment, the speech rate recognition method is implemented by the server as an example. Figure 1 is a schematic diagram of an implementation environment provided by an exemplary embodiment of the present application, such as Figure 1 As shown, the implementation environment includes a terminal 110 and a server 120 , wherein the terminal 110 and the server 120 are connected via a communication network 130 .
[0042] An application with a voice function is installed in the terminal 110. Schematically, the application installed in the terminal 110 has a voice recognition function, or a voice input function, or a voice playback function, etc., which is not limited in the embodiment of the present application.
[0043] After the terminal 110 sends the voice data to the server 120 , the server 120 completes the speech rate recognition process corresponding to the voice data.
[0044] First, after receiving the voice data, the server 120 first extracts the valid frames in the voice data, and obtains the pitch period state for the valid frames, thereby establishing a histogram corresponding to the pitch period state, and obtains the speech rate recognition result corresponding to the voice data according to the histogram recognition. The server 120 feeds back the speech rate recognition result to the terminal 110, so that the terminal 110 performs candidate applications based on the speech rate recognition result, such as speech rate reminder, playback speed adjustment, etc. Among them, the application method of the speech rate recognition result is described in detail in the subsequent application scenario introduction, which will not be repeated here.
[0045] The terminal includes at least one of a smart phone, a vehicle-mounted terminal, a tablet computer, a portable laptop computer, a desktop computer, a smart speaker, a smart wearable device, a smart face recognition device, and the like.
[0046] It is worth noting that the above-mentioned servers can be independent physical servers, or they can be server clusters or distributed systems composed of multiple physical servers. They can also be cloud servers that provide basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (CDN), as well as big data and artificial intelligence platforms.
[0047] Among them, cloud technology refers to a hosting technology that unifies hardware, software, network and other resources in a wide area network or local area network to realize data calculation, storage, processing and sharing. Cloud technology is a general term for network technology, information technology, integration technology, management platform technology, application technology, etc. based on the cloud computing business model. It can form a resource pool, which is used on demand and flexible and convenient. Cloud computing technology will become an important support. The background services of technical network systems require a large amount of computing and storage resources, such as video websites, picture websites and more portal websites. With the high development and application of the Internet industry, in the future, each item may have its own identification mark, which needs to be transmitted to the background system for logical processing. Data of different levels will be processed separately. All kinds of industry data need strong system backing support, which can only be achieved through cloud computing.
[0048] In some embodiments, the above-mentioned server can also be implemented as a node in a blockchain system. Blockchain is a new application mode of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, the platform product service layer, and the application service layer.
[0049] For illustration, please refer to Figure 2 , which shows a schematic diagram of a speech rate recognition framework provided by an exemplary embodiment of the present application, such as Figure 2 As shown, the overall process of the speech rate recognition framework is as follows.
[0050] For the speech signal 200 , voice activity detection 210 (VAD) is first performed on the speech signal 200 to obtain valid frames in the speech signal 200 .
[0051] For valid frames in the speech signal 200, the pitch period 220 of each frame is calculated, and the continuous accumulation corresponding to the period rising state 231, the period flat state 232 and the period falling state 233 in the pitch period 220 is determined, so as to draw a statistical result 240, that is, a histogram.
[0052] The statistical graph data corresponding to the statistical result 240 is analyzed through the deep learning network 250, and finally the speech rate prediction result 260 is obtained.
[0053] In combination with the above description, the application scenarios of the embodiments of the present application are introduced.
[0054] First, the voice message playback scenario.
[0055] In the scenario of sending and receiving voice messages, since the speech speeds corresponding to the voice messages sent by different users have independent characteristics, and even if it is the same user, the speech speeds corresponding to the voice messages sent in different sending situations also have independent characteristics, some voice messages have a slow speech speed and require a long time to listen to, while some voice messages have a very fast speech speed. In some noisy places, it is difficult to clearly receive the meaning of the voice message and it is necessary to listen repeatedly. Therefore, in the embodiment of the present application, the speech speed recognition is first performed for the voice message sent by the user, and then the playback speed is adjusted based on the speech speed recognition result, so that the voice message is played at a relatively stable speech speed to improve the clarity of the voice content.
[0056] Second, evaluation of customer service call service quality.
[0057] During the telephone service of voice customer service, if the customer service speaks too fast, the customer will not be able to clearly receive the information, and if the customer service speaks too slowly, it will cause misunderstanding of negative service. Therefore, in the embodiment of the present application, the call content during the customer service call is collected, and the speed recognition is performed on the customer service corresponding part of the call content, so as to evaluate the service quality of the customer service based on the obtained speed recognition results, and prompt the customer service whether the speed needs to be adjusted according to the speed recognition results.
[0058] It is worth noting that in the examples of the above application scenarios, the voice message playback scenario and the customer service call service quality evaluation are used as examples for illustration. The speech rate recognition method provided in this application can also be applied to other application scenarios that require speech rate recognition, and the embodiments of this application are not limited to this.
[0059] Based on the above content, the speech rate recognition method provided in the embodiment of the present application is described. Figure 3 is a flow chart of a speech rate recognition method provided by an exemplary embodiment of the present application. The method can be applied to a server or a terminal, or can be implemented by a server and a terminal together. In this embodiment, the method is applied to a server as an example for explanation. Figure 3 As shown, the method includes:
[0060] Step 301: Acquire speech data, where the speech data includes at least two speech frames.
[0061] The speech data is data to be subjected to speech rate recognition, and the speech frame is a data unit constituting the speech data.
[0062] In some embodiments, the voice data is data transmitted by the server during the terminal interaction process; or, the voice data is data sent by the terminal to the server to request speech rate recognition; or, the voice data is data stored internally in the server; or, the voice data is a specified voice segment captured from a voice file, which is not limited in the embodiments of the present application.
[0063] Illustratively, the voice data is a voice message transmitted between two clients in a social application through a server; or, the voice data is a voice signal uploaded by a terminal through a voice recording program for voice changing processing. Before performing the voice changing processing, the server first performs speech speed recognition on the voice data.
[0064] At least two voice frames are connected to form the voice data, that is, the playing effect of the voice data can be obtained by playing at least two voice frames frame by frame.
[0065] Optionally, the voice data is divided based on a preset time interval to obtain at least two voice frames corresponding to the voice data. Schematically, the voice signal is divided into multiple frames at a certain time interval, such as: every 20ms is divided into one frame to obtain at least two voice frames corresponding to the voice signal.
[0066] Step 302: extract the pitch period state of the speech frame.
[0067] The pitch period state is used to indicate the pitch period change between at least two speech frames.
[0068] The pitch period is a detection method used to record the time wavelength of the fundamental tone. The pitch period is the time of one complete wavelength of the mechanical wave.
[0069] In some embodiments, the pitch period state is extracted by a pitch period detection algorithm, wherein the pitch period detection algorithm includes: autocorrelation-based pitch period detection, cepstrum-based pitch period detection, linear predictive coding-based pitch period detection, etc. The embodiments of the present application do not limit the scheme of pitch period detection.
[0070] In some embodiments, each speech frame corresponds to a pitch period state, which is used to indicate the pitch period change of the speech frame relative to the previous frame or the previous specified frame. Schematically, the pitch period change of the speech frame relative to the previous frame is used as an example for explanation, and the pitch period state includes a period increase state and a period decrease state, wherein the period increase state is used to indicate that the current frame pitch period is greater than the previous frame pitch period, and the period decrease state is used to indicate that the current frame pitch period is less than the previous frame pitch period.
[0071] In the embodiment of the present application, the fundamental pitch period state includes a period rising state, a period flat state and a period falling state as an example for explanation, wherein the period rising state refers to a state in which the fundamental pitch period of the current speech frame is greater than the fundamental pitch period of the previous speech frame, and the difference in the fundamental pitch period reaches a preset period value; the period flat state refers to a state in which the difference between the fundamental pitch period of the current speech frame and the fundamental pitch period of the previous speech frame is less than a preset period value; the period falling state refers to a state in which the fundamental pitch period of the current speech frame is less than the fundamental pitch period of the previous speech frame, and the difference in the fundamental pitch period reaches a preset period value.
[0072] In response to the pitch period value of the i+1th speech frame being greater than the pitch period value of the i-th speech frame, and the difference reaching a preset period value, the pitch period state corresponding to the i+1th speech frame is determined to be a period-up state, where i is a positive integer; in response to the difference between the pitch period value of the i+1th speech frame and the pitch period value of the i-th speech frame being less than a preset period value, the pitch period state corresponding to the i+1th speech frame is determined to be a period-flat state; in response to the pitch period value of the i+1th speech frame being less than the pitch period value of the i-th speech frame, and the difference reaching a preset period value, the pitch period state corresponding to the i+1th speech frame is determined to be a period-down state.
[0073] Optionally, the above-mentioned voice frame can be a continuous voice frame in the voice data, or the above-mentioned voice frame is a voice frame identified as a valid frame in the voice data. In some embodiments, the voice frame is subjected to voice activity detection (VAD) to screen out valid voice frames, and the fundamental pitch period state is extracted for the valid voice frames.
[0074] Step 303: Create a histogram corresponding to the pitch period.
[0075] The histogram is used to indicate the distribution of pitch cycle states in at least two state intervals.
[0076] In some embodiments, the histogram is used to count the distribution of the pitch cycle state, and optionally, the histogram is used to count the continuity of the pitch cycle state, thereby assisting speech rate recognition according to the continuity of the pitch cycle state. Optionally, the state interval is an interval divided according to the continuous distribution of the pitch cycle state, and the state interval is divided based on the continuous distribution length of the pitch cycle state.
[0077] That is, after determining the continuous distribution length of the pitch period state in the speech data, the continuous distribution length is mapped to different state intervals in the histogram (each state interval corresponds to a value range of the continuous distribution length), thereby obtaining a histogram.
[0078] At least one continuous cumulative value of the pitch cycle state is obtained, the continuous cumulative value is used to indicate the continuous distribution of speech frames that meet the pitch cycle state in the speech data; and a histogram corresponding to the pitch cycle state is established based on the continuous cumulative value.
[0079] Illustratively, the pitch period states corresponding to 10 adjacent speech frames are 0000111122, where state "0" is a pitch period rising state, i.e., the pitch period value of the current frame is larger than that of the previous frame, state "1" is a pitch period level state, i.e., the pitch period value of the current frame is equal to or has a smaller difference than that of the previous frame, and state "2" is a pitch period falling state, i.e., the pitch period value of the current frame is smaller than that of the previous frame. Therefore, the statistical results of the 0000111122 state include: the cumulative value of continuous period rising states is 4 (four consecutive 0s), the cumulative value of continuous period level states is 4 (four consecutive 1s), and the cumulative value of continuous period falling states is 2 (two consecutive 2s).
[0080] Taking the periodic rising state in the fundamental pitch period state as an example, after the fundamental pitch period state is extracted from the speech frames in the speech data, the continuous cumulative values of the periodic rising state include: 4, 7, 6, 5, 5, 4, 2; indicating that in the fundamental pitch period state corresponding to the speech frames in the speech data, 4 consecutive speech frames, 7 consecutive speech frames, 6 consecutive speech frames, 5 consecutive speech frames, 5 consecutive speech frames, 4 consecutive speech frames and 2 consecutive speech frames are in the periodic rising state, respectively.
[0081] A histogram corresponding to the periodic rising state is constructed based on the continuous cumulative value of the periodic rising state. Optionally, a state interval distribution corresponding to the histogram is determined, and the state interval distribution is used to distinguish the distribution of the continuous cumulative value; the continuous cumulative value of the fundamental pitch period state is mapped to the state interval distribution to obtain a histogram corresponding to the fundamental pitch period state.
[0082] Optionally, the histogram includes state intervals, and the number and range of the state intervals can be pre-set. Schematically, taking the continuous cumulative value of the above-mentioned periodic rising state as an example, the histogram includes state intervals: 1-3, 3-5, 5-7, and the equal sign is on the right, then the state interval 1-3 includes 1 continuous cumulative value, that is, the length of the histogram corresponding to the state interval 1-3 corresponds to the value 1; the state interval 3-5 includes 4 continuous cumulative values, that is, the length of the histogram corresponding to the state interval 3-5 corresponds to the value 4; the state interval 5-7 includes 2 continuous cumulative values, that is, the length of the histogram corresponding to the state interval 5-7 corresponds to the value 2.
[0083] Step 304: predict the speech rate based on the distribution of the pitch period state in the histogram to obtain a speech rate recognition result corresponding to the speech data.
[0084] In some embodiments, based on the distribution of the continuous cumulative values of the pitch period state in each state interval in the histogram, the speech rate is predicted for the speech data to obtain the speech rate recognition result.
[0085] In some embodiments, the manner of performing speech rate analysis on the continuous cumulative value includes at least one of the following manners:
[0086] First, the distribution of continuous cumulative values in each state interval is analyzed through the pre-trained machine learning model to obtain the speech rate recognition result corresponding to the speech data.
[0087] Second, according to the distribution of continuous cumulative values in each state interval, the interval with the highest distribution frequency and the interval with the lowest distribution frequency are determined, so as to determine the speech rate recognition result according to the characteristics of the interval with the highest distribution frequency and the interval with the lowest distribution frequency.
[0088] Illustratively, when the interval with the highest distribution frequency in the pitch-up state is an interval with a higher cumulative value, and the interval with the highest distribution frequency in the pitch-down state is an interval with a lower cumulative value, it is determined that the speech rate recognition result corresponds to a high speech rate.
[0089] To sum up, the speech rate recognition method provided in this embodiment extracts the fundamental pitch period state of the speech frame in the speech data, and recognizes the speech rate of the speech data according to the continuous distribution of the fundamental pitch period state, without having to perform speech recognition on the speech data to obtain the text content, and then determine the speech rate according to the text content, thereby improving the efficiency of speech rate recognition. Since the amount of calculation required for speech recognition is large, speech rate recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupancy of the device's calculation amount.
[0090] In some embodiments, the pitch cycle state includes a cycle-up state, a cycle-flat state, and a cycle-down state. Figure 4 is a flow chart of a speech rate recognition method provided by another exemplary embodiment of the present application. The method can be applied to a server or a terminal, or can be implemented by a server and a terminal together. In this embodiment, the method is applied to a server as an example for explanation. Figure 4 As shown, the method includes:
[0091] Step 401: Acquire speech data, where the speech data includes at least two speech frames.
[0092] The speech data is data to be subjected to speech rate recognition, and the speech frame is a data unit constituting the speech data.
[0093] Optionally, the voice data is divided based on a preset time interval to obtain at least two voice frames corresponding to the voice data.
[0094] Step 402: extract the pitch period state of the speech frame.
[0095] The pitch period state is used to indicate the pitch period change between at least two speech frames.
[0096] In some embodiments, speech activity detection is performed on at least two speech frames to obtain valid frames in the at least two speech frames, thereby extracting the fundamental pitch period state based on the valid frames.
[0097] In some embodiments, after voice activity detection, a vad result of 1 indicates a valid voice signal, i.e., a valid frame, and a vad result of 0 indicates an invalid voice signal, i.e., an invalid frame. Invalid frames in voice activity detection are discarded, the pitch period state of valid frames is extracted, and subsequent histograms are constructed.
[0098] Step 403: In response to the pitch cycle state including the cycle-up state, obtaining at least one first continuous accumulated value of the cycle-up state.
[0099] Illustratively, after extracting the pitch period state of the speech frames in the speech data, the first continuous accumulated values of the periodic rising state include: 4, 7, 6, 5, 5, 4, 2; indicating that the pitch period state corresponding to the speech frames in the speech data includes 4 consecutive speech frames, 7 consecutive speech frames, 6 consecutive speech frames, 5 consecutive speech frames, 5 consecutive speech frames, 4 consecutive speech frames and 2 consecutive speech frames in the periodic rising state, respectively.
[0100] Step 404: in response to the pitch cycle state including the cycle flat state, obtaining at least one second continuous accumulated value of the cycle flat state.
[0101] Illustratively, after extracting the pitch period state of the speech frames in the speech data, the second continuous accumulated values of the periodic flat state include: 3, 2, 4, 5, 4, 2; indicating that the pitch period state corresponding to the speech frames in the speech data includes, in sequence, 3 consecutive speech frames, 2 consecutive speech frames, 4 consecutive speech frames, 5 consecutive speech frames, 4 consecutive speech frames and 2 consecutive speech frames as the periodic flat state.
[0102] Step 405: In response to the pitch cycle state including the cycle down state, obtaining at least one third continuous accumulated value of the cycle down state.
[0103] Schematically, after extracting the fundamental pitch period state of the speech frames in the speech data, the third consecutive accumulated values of the periodic decreasing state include: 3, 5, 4, 5; indicating that the fundamental pitch period state corresponding to the speech frames in the speech data includes 3 consecutive speech frames, 5 consecutive speech frames, 4 consecutive speech frames, and 5 consecutive speech frames in the periodic decreasing state, respectively.
[0104] Step 406: Create a histogram corresponding to the pitch cycle state based on the continuous cumulative value.
[0105] In some embodiments, histograms corresponding to the cycle rising state, the cycle flat state, and the cycle falling state are respectively established. The histogram corresponding to the cycle rising state is established based on the first continuous cumulative value; the histogram corresponding to the cycle flat state is established based on the second continuous cumulative value; and the histogram corresponding to the cycle falling state is established based on the third continuous cumulative value.
[0106] Step 407: predict the speech rate based on the distribution of the pitch period state in the histogram to obtain a speech rate recognition result corresponding to the speech data.
[0107] In some embodiments, based on the histogram corresponding to the periodic rising state, the histogram corresponding to the periodic flat state, and the histogram corresponding to the periodic falling state, the speech rate prediction is performed to obtain the speech rate recognition result. Optionally, feature data of the histogram is extracted, and the feature data is used to represent the data distribution in the histogram. Schematically, the feature data includes the corresponding number of each state interval in the histogram, that is, the statistical length corresponding to the state interval.
[0108] The speech rate is predicted through the state data to obtain the speech rate recognition result corresponding to the voice data.
[0109] To sum up, the speech rate recognition method provided in this embodiment extracts the fundamental pitch period state of the speech frame in the speech data, and recognizes the speech rate of the speech data according to the continuous distribution of the fundamental pitch period state, without having to perform speech recognition on the speech data to obtain the text content, and then determine the speech rate according to the text content, thereby improving the efficiency of speech rate recognition. Since the amount of calculation required for speech recognition is large, speech rate recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupancy of the device's calculation amount.
[0110] The method provided in this embodiment constructs corresponding histograms for the period rising state, the period flat state and the period falling state, respectively, so as to analyze the change of the fundamental pitch period state from three dimensions, thereby improving the accuracy and efficiency of the speech rate prediction result.
[0111] In an optional embodiment, the speech rate is analyzed by a speech rate recognition model. Figure 5 is a flow chart of a speech rate recognition method provided by another exemplary embodiment of the present application. The method can be applied to a server or a terminal, or can be implemented by a server and a terminal together. In this embodiment, the method is applied to a server as an example for explanation. Figure 5 As shown, the method includes:
[0112] Step 501: Acquire speech data, where the speech data includes at least two speech frames.
[0113] The speech data is data to be subjected to speech rate recognition, and the speech frame is a data unit constituting the speech data.
[0114] Optionally, the voice data is divided based on a preset time interval to obtain at least two voice frames corresponding to the voice data.
[0115] Step 502: extract the pitch period state of the speech frame.
[0116] The pitch period state is used to indicate the pitch period change between at least two speech frames.
[0117] In some embodiments, speech activity detection is performed on at least two speech frames to obtain valid frames in the at least two speech frames, thereby extracting the fundamental pitch period state based on the valid frames.
[0118] Step 503: Obtain at least one first continuous cumulative value of the periodic rising state.
[0119] The period rising state refers to a state in which the pitch period of the current speech frame is greater than the pitch period of the previous speech frame, and the pitch period difference reaches a preset period value.
[0120] Step 504: Obtain at least one second continuous cumulative value of the periodic flat state.
[0121] The period flat state refers to a state in which the difference between the pitch period of the current speech frame and the pitch period of the previous speech frame is less than a preset period value.
[0122] Step 505: Obtain at least one third continuous cumulative value of the periodic down state.
[0123] The period decreasing state is a state in which the pitch period of the current speech frame is smaller than the pitch period of the previous speech frame, and the pitch period difference reaches a preset period value.
[0124] Step 506: Create a histogram corresponding to the pitch cycle state based on the continuous cumulative value.
[0125] In some embodiments, histograms corresponding to the cycle rising state, the cycle flat state, and the cycle falling state are respectively established.
[0126] Optionally, the state interval range and the number of intervals of the histograms corresponding to the periodic rising state, the periodic flat state, and the periodic falling state are the same or different. Schematically, taking the first histogram constructed by the periodic rising state, the second histogram constructed by the periodic flat state, and the third histogram constructed by the periodic falling state as an example, the first histogram is divided into p first state intervals, the second histogram is divided into q second state intervals, and the third histogram is divided into k third state intervals, p, q, and k are all positive integers, wherein the division of the first state interval, the division of the second state interval, and the division of the third state interval are the same or different; the values of p, q, and k are the same or different.
[0127] Step 507: Obtain the number of continuous cumulative values corresponding to at least two state intervals in the histogram.
[0128] In some embodiments, after histogram analysis, the distribution of the fundamental frequency period in each histogram interval of the three states of "rising", "flat" and "falling" is obtained, and the distribution values need to be normalized in their respective histograms. For example, the number of histogram intervals in the "rising", "flat" and "falling" states are N1, N2, and N3 respectively, then a total of N1+N2+N3 data are obtained, and the values of these data are all less than 1 after normalization.
[0129] Step 508: Analyze the number of continuous cumulative values corresponding to at least two state intervals respectively through the speech rate recognition model to obtain a speech rate recognition result corresponding to the voice data.
[0130] Optionally, the above N1+N2+N3 data are input into a speech rate recognition model for prediction and finally a speech rate recognition result is obtained.
[0131] The speech rate recognition model is a deep learning model obtained by pre-training. Optionally, the training of the speech rate recognition model is implemented through sample speech data. In some embodiments, sample speech data marked with a reference speech rate is obtained, and the speech rate recognition model is used to perform speech rate recognition on the sample speech data to obtain a sample speech rate recognition result. According to the difference between the reference speech rate and the sample speech rate recognition result, the model parameters in the speech rate recognition model are adjusted.
[0132] Optionally, the speech rate recognition model includes a gated loop layer and a classification layer, wherein the gated loop layer performs data feature processing on the number of continuous cumulative values corresponding to at least two state intervals to obtain a gated loop feature; the classification layer performs speed level classification on the gated loop feature to obtain the speech rate level corresponding to the speech data as the speech rate recognition result.
[0133] In some embodiments, the evaluation of speaking speed is more inclined to be described in a quantitative manner through levels, such as 1 to 9. The larger the level value, the higher the speaking speed. Level 1 represents extremely slow speaking speed, level 5 represents normal speaking speed, and level 9 represents extremely fast speaking speed.
[0134] The speech data is classified into speech rate levels through the speech rate recognition model as the speech rate recognition result.
[0135] The speech rate recognition model can be a convolutional neural network (CNN), a deep neural network (DNN), a recurrent neural network (RNN), etc. Figure 6 FIG. 4 shows a structural block diagram of a speech rate recognition model provided by an exemplary embodiment of the present application. Figure 6 As shown, the speech rate recognition model 600 is composed of two layers of fully connected (DENSE) layers and three layers of gated recurrent units (GRU). The input of the first layer DENSE1 layer 610 is the number of continuous cumulative values corresponding to at least two state intervals, that is, the above-mentioned N1+N2+N3 floating point numbers less than 1. After being processed by the three layers of GRU layers 620, it is finally processed by the DENSE2 layer 630 through softmax processing to output the probabilities corresponding to levels 1 to 9. The final speech rate recognition takes the level with the highest probability among the probabilities corresponding to the output of the 9 levels as the final speech rate recognition result.
[0136] To sum up, the speech rate recognition method provided in this embodiment extracts the fundamental pitch period state of the speech frame in the speech data, and recognizes the speech rate of the speech data according to the continuous distribution of the fundamental pitch period state, without having to perform speech recognition on the speech data to obtain the text content, and then determine the speech rate according to the text content, thereby improving the efficiency of speech rate recognition. Since the amount of calculation required for speech recognition is large, speech rate recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupancy of the device's calculation amount.
[0137] The method provided in this embodiment analyzes the fundamental pitch period state corresponding to the speech data through the speed recognition model obtained by pre-training, and predicts the speaking rate through the interval distribution of the histogram constructed by the fundamental pitch period state, thereby improving the prediction accuracy and efficiency.
[0138] Figure 7 FIG. 1 is a schematic diagram of the overall process of a speech rate recognition method provided by another exemplary embodiment of the present application. Figure 7 As shown, the method includes the following process:
[0139] Step 701: Acquire a voice signal.
[0140] The speech signal is an audio signal to be subjected to speech rate recognition. The speech signal includes at least two speech frames, and the speech frame is a data unit constituting speech data.
[0141] Optionally, the speech signal is divided based on a preset time interval to obtain at least two speech frames corresponding to the speech data.
[0142] Step 702: Perform VAD detection on the speech signal.
[0143] After each speech frame is detected by vad, a valid speech frame is identified, that is, a speech frame with a vad result of 1 is a valid speech frame, and a speech frame with a vad result of 0 is an invalid speech frame (such as a silence or noise signal).
[0144] Step 703: Calculate the pitch period of each frame.
[0145] The pitch period detection algorithm is used to calculate the pitch period of each speech frame, such as: pitch period detection based on autocorrelation, pitch period monitoring based on cepstrum, pitch period detection based on linear predictive coding, etc.
[0146] Step 704, performing time-consuming calculations on the pitch cycle state, the flat state, and the falling state.
[0147] The pitch periods of adjacent frames are divided into three states: "rising", "flat" and "falling". The number of adjacent frames in the same state is counted to obtain the cumulative situation of continuous frames corresponding to each pitch period state as the time consumption of each state.
[0148] Step 705: histogram statistics.
[0149] These values are further analyzed through histogram statistics. The number of histogram intervals and the range values of each interval can be set according to experience. The histogram interval values and the number of intervals defined by the "rising", "flat" and "falling" states can be different. The interval division can be divided into equal intervals or unequal intervals. The distribution of the "rising" state in different intervals is obtained through histogram statistics; the same method is used to perform histogram statistical analysis on the "flat" and "falling" states. After the histogram analysis, the distribution of the fundamental frequency period in each histogram interval of the three states of "rising", "flat" and "falling" is obtained, and the distribution values are normalized in their respective histograms. For example, the number of histogram intervals in the "rising", "flat" and "falling" states are N1, N2, and N3 respectively. In this way, a total of N1+N2+N3 data are obtained, and these data values are all less than 1.
[0150] Step 706: input the statistical results into the deep learning network.
[0151] The deep learning network is a pre-trained speech rate recognition network, which is used to correspond the statistical results to the speech rate levels for speech rate prediction.
[0152] Step 707: output the speech rate recognition result.
[0153] To sum up, the speech rate recognition method provided in this embodiment extracts the fundamental pitch period state of the speech frame in the speech data, and recognizes the speech rate of the speech data according to the continuous distribution of the fundamental pitch period state, without having to perform speech recognition on the speech data to obtain the text content, and then determine the speech rate according to the text content, thereby improving the efficiency of speech rate recognition. Since the amount of calculation required for speech recognition is large, speech rate recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupancy of the device's calculation amount.
[0154] Figure 8 is a structural block diagram of a speech rate recognition device provided by an exemplary embodiment of the present application. Figure 8 As shown, the device comprises:
[0155] An acquisition module 810 is used to acquire voice data, wherein the voice data includes at least two voice frames;
[0156] An extraction module 820, configured to extract a pitch period state of the speech frame, wherein the pitch period state is used to indicate a change in the pitch period between at least two speech frames;
[0157] An establishing module 830, configured to establish a histogram corresponding to the pitch period state, wherein the histogram is used to indicate the distribution of the pitch period state in at least two state intervals;
[0158] The prediction module 840 is used to predict the speech rate based on the distribution of the pitch period state in the histogram, and obtain the speech rate recognition result corresponding to the speech data.
[0159] In an optional embodiment, the acquisition module 810 is further used to acquire at least one continuous cumulative value of the fundamental pitch period state, the continuous cumulative value is used to indicate the continuous distribution of the voice frames that meet the fundamental pitch period state in the voice data, wherein the state interval is an interval divided according to the continuous distribution of the fundamental pitch period state, and the state interval is divided based on the continuous distribution length of the fundamental pitch period state;
[0160] The establishing module 830 is further configured to establish a histogram corresponding to the pitch cycle state based on the continuous accumulated value.
[0161] In an optional embodiment, if Fig. 9 As shown, the establishment module 830 includes:
[0162] A determination unit 831 is used to determine a state interval distribution corresponding to the histogram, wherein the state interval distribution is used to distinguish the distribution of the continuous cumulative values;
[0163] The mapping unit 832 is used to map the continuous accumulated value of the pitch cycle state to the state interval distribution to obtain a histogram corresponding to the pitch cycle state.
[0164] In an optional embodiment, the pitch cycle state includes at least one of a cycle rising state, a cycle flat state and a cycle falling state;
[0165] The acquisition module 810 is further configured to acquire at least one first continuous cumulative value of the cycle rising state in response to the pitch cycle state including the cycle rising state;
[0166] The acquisition module 810 is further configured to acquire at least one second continuous accumulated value of the cycle flat state in response to the pitch cycle state including the cycle flat state;
[0167] The acquisition module 810 is further configured to acquire at least one third continuous accumulated value of the period-down state in response to the pitch period state including the period-down state.
[0168] In an optional embodiment, the device further comprises:
[0169] A determination module 850 is used to determine that the pitch period state corresponding to the i+1th speech frame is a period rising state in response to the pitch period value of the i+1th speech frame being greater than the pitch period value of the i-th speech frame, and the difference reaches a preset period value, where i is a positive integer;
[0170] The determining module 850 is configured to determine that the pitch period state corresponding to the i+1th speech frame is a period-flat state in response to the difference between the pitch period value of the i+1th speech frame and the pitch period value of the i-th speech frame being less than the preset period value;
[0171] The determination module 850 is used to determine that the pitch period state corresponding to the i+1th speech frame is a period-down state in response to the pitch period value of the i+1th speech frame being less than the pitch period value of the i-th speech frame and the difference reaches a preset period value.
[0172] In an optional embodiment, the acquisition module 810 is further used to acquire the number of continuous cumulative values corresponding to the at least two state intervals in the histogram;
[0173] The prediction module 840 is further configured to analyze the number of continuous cumulative values corresponding to the at least two state intervals respectively through a speech rate recognition model to obtain a speech rate recognition result corresponding to the speech data.
[0174] In an optional embodiment, the speech rate recognition model includes a gated recurrent layer and a classification layer;
[0175] The prediction module 840 is further configured to perform data feature processing on the number of continuous cumulative values respectively corresponding to the at least two state intervals through the gated cycle layer to obtain a gated cycle feature;
[0176] The prediction module 840 is further configured to classify the gated loop features into speed levels through the classification layer, and obtain the speech speed level corresponding to the speech data as the speech speed recognition result.
[0177] In an optional embodiment, the extraction module 820 is further used to perform speech activity detection on the at least two speech frames to obtain valid frames in the at least two speech frames; and extract the fundamental frequency period state based on the valid frames.
[0178] In an optional embodiment, the device further includes:
[0179] The division module 860 is used to divide the voice data based on a preset time interval to obtain at least two voice frames corresponding to the voice data.
[0180] In summary, the speech rate recognition device provided in this embodiment extracts the fundamental pitch period state of the speech frame in the speech data, and recognizes the speech rate of the speech data according to the continuous distribution of the fundamental pitch period state, without having to perform speech recognition on the speech data to obtain the text content, and then determine the speech rate according to the text content, thereby improving the efficiency of speech rate recognition. Since the amount of calculation required for speech recognition is large, speech rate recognition through the fundamental pitch period state can reduce the amount of calculation of the device and reduce the occupancy of the device's calculation amount.
[0181] It should be noted that the speech rate recognition device provided in the above embodiment is only illustrated by the division of the above functional modules. In actual applications, the above functions can be assigned to different functional modules as needed, that is, the internal structure of the device can be divided into different functional modules to complete all or part of the functions described above. In addition, the speech rate recognition device provided in the above embodiment belongs to the same concept as the speech rate recognition method embodiment. The specific implementation process is detailed in the method embodiment and will not be repeated here.
[0182] Fig.10 The following is a block diagram of a computer device 1000 (implemented as a mobile device in the embodiment of the present application) provided by an exemplary embodiment of the present application. The computer device 1000 may be a portable mobile terminal, such as a smart phone, a tablet computer, an MP3 player (Moving Picture Experts Group Audio Layer III), an MP4 player (Moving Picture Experts Group Audio Layer IV), a laptop computer or a desktop computer. The computer device 1000 may also be referred to as a user device, a portable terminal, a laptop terminal, a desktop terminal or other names.
[0183] Typically, the computer device 1000 includes a processor 1001 and a memory 1002 .
[0184] The processor 1001 may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor 1001 may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor 1001 may also include a main processor and a coprocessor. The main processor is a processor for processing data in an awake state, also known as a CPU (Central Processing Unit); The coprocessor is a low-power processor for processing data in a standby state. In some embodiments, the processor 1001 may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor 1001 may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.
[0185] The memory 1002 may include one or more computer-readable storage media, which may be non-transitory. The memory 1002 may also include a high-speed random access memory, and a non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In some embodiments, the non-transitory computer-readable storage medium in the memory 1002 is used to store at least one instruction, which is used to be executed by the processor 1001 to implement the speech rate recognition method provided in the method embodiment of the present application.
[0186] In some embodiments, the computer device 1000 may further optionally include: a peripheral device interface 1003 and at least one peripheral device. The processor 1001, the memory 1002 and the peripheral device interface 1003 may be connected via a bus or a signal line. Each peripheral device may be connected to the peripheral device interface 1003 via a bus, a signal line or a circuit board. Specifically, the peripheral device includes: at least one of a radio frequency circuit 1004, a display screen 1005, a camera assembly 1006, an audio circuit 1007, a positioning assembly 1008 and a power supply 1009.
[0187] The peripheral device interface 1003 may be used to connect at least one peripheral device related to I / O (Input / Output) to the processor 1001 and the memory 1002. In some embodiments, the processor 1001, the memory 1002, and the peripheral device interface 1003 are integrated on the same chip or circuit board; in some other embodiments, any one or two of the processor 1001, the memory 1002, and the peripheral device interface 1003 may be implemented on a separate chip or circuit board, which is not limited in this embodiment.
[0188] The radio frequency circuit 1004 is used to receive and transmit RF (Radio Frequency) signals, also known as electromagnetic signals. The radio frequency circuit 1004 communicates with the communication network and other communication devices through electromagnetic signals. The radio frequency circuit 1004 converts the electrical signal into an electromagnetic signal for transmission, or converts the received electromagnetic signal into an electrical signal. Optionally, the radio frequency circuit 1004 includes: an antenna system, an RF transceiver, one or more amplifiers, a tuner, an oscillator, a digital signal processor, a codec chipset, a user identity module card, etc. The radio frequency circuit 1004 can communicate with other terminals through at least one wireless communication protocol. The wireless communication protocol includes but is not limited to: the World Wide Web, a metropolitan area network, an intranet, various generations of mobile communication networks (2G, 3G, 4G and 5G), a wireless local area network and / or a WiFi (Wireless Fidelity) network. In some embodiments, the radio frequency circuit 1004 may also include circuits related to NFC (Near Field Communication), which is not limited in this application.
[0189] The display screen 1005 is used to display a UI (User Interface). The UI may include graphics, text, icons, videos, and any combination thereof. When the display screen 1005 is a touch display screen, the display screen 1005 also has the ability to collect touch signals on the surface or above the surface of the display screen 1005. The touch signal can be input to the processor 1001 as a control signal for processing. At this time, the display screen 1005 can also be used to provide virtual buttons and / or virtual keyboards, also known as soft buttons and / or soft keyboards. In some embodiments, the display screen 1005 can be one, arranged on the front panel of the computer device 1000; in other embodiments, the display screen 1005 can be at least two, respectively arranged on different surfaces of the computer device 1000 or in a folding design; in other embodiments, the display screen 1005 can be a flexible display screen, arranged on a curved surface or a folding surface of the computer device 1000. Even, the display screen 1005 can also be arranged as a non-rectangular irregular figure, that is, a special-shaped screen. The display screen 1005 can be made of materials such as LCD (Liquid Crystal Display) and OLED (Organic Light-Emitting Diode).
[0190] The camera assembly 1006 is used to capture images or videos. Optionally, the camera assembly 1006 includes a front camera and a rear camera. Typically, the front camera is arranged on the front panel of the terminal, and the rear camera is arranged on the back of the terminal. In some embodiments, there are at least two rear cameras, which are any one of a main camera, a depth of field camera, a wide-angle camera, and a telephoto camera, so as to realize the fusion of the main camera and the depth of field camera to realize the background blur function, the fusion of the main camera and the wide-angle camera to realize the panoramic shooting and VR (Virtual Reality) shooting function or other fusion shooting functions. In some embodiments, the camera assembly 1006 may also include a flash. The flash can be a monochrome temperature flash, or it can be a dual-color temperature flash. The dual-color temperature flash refers to a combination of a warm light flash and a cold light flash, which can be used for light compensation at different color temperatures.
[0191] The audio circuit 1007 may include a microphone and a speaker. The microphone is used to collect sound waves from the user and the environment, and convert the sound waves into electrical signals and input them into the processor 1001 for processing, or input them into the radio frequency circuit 1004 to achieve voice communication. For the purpose of stereo acquisition or noise reduction, there may be multiple microphones, which are respectively arranged at different parts of the computer device 1000. The microphone may also be an array microphone or an omnidirectional acquisition microphone. The speaker is used to convert the electrical signal from the processor 1001 or the radio frequency circuit 1004 into sound waves. The speaker may be a traditional film speaker or a piezoelectric ceramic speaker. When the speaker is a piezoelectric ceramic speaker, it can not only convert the electrical signal into sound waves audible to humans, but also convert the electrical signal into sound waves inaudible to humans for purposes such as ranging. In some embodiments, the audio circuit 1007 may also include a headphone jack.
[0192] The positioning component 1008 is used to locate the current geographical location of the computer device 1000 to implement navigation or LBS (Location Based Service). The positioning component 1008 can be a positioning component based on the US GPS (Global Positioning System), China's Beidou system or Russia's Galileo system.
[0193] The power supply 1009 is used to power various components in the computer device 1000. The power supply 1009 can be an alternating current, a direct current, a disposable battery, or a rechargeable battery. When the power supply 1009 includes a rechargeable battery, the rechargeable battery can be a wired rechargeable battery or a wireless rechargeable battery. A wired rechargeable battery is a battery that is charged through a wired line, and a wireless rechargeable battery is a battery that is charged through a wireless coil. The rechargeable battery can also be used to support fast charging technology.
[0194] In some embodiments, the computer device 1000 further includes one or more sensors 1010 , including but not limited to: an acceleration sensor 1011 , a gyroscope sensor 1012 , a pressure sensor 1013 , a fingerprint sensor 1014 , an optical sensor 1015 , and a proximity sensor 1016 .
[0195] The acceleration sensor 1011 can detect the magnitude of acceleration on the three coordinate axes of the coordinate system established by the computer device 1000. For example, the acceleration sensor 1011 can be used to detect the components of gravity acceleration on the three coordinate axes. The processor 1001 can control the display screen 1005 to display the user interface in a horizontal view or a vertical view according to the gravity acceleration signal collected by the acceleration sensor 1011. The acceleration sensor 1011 can also be used to collect game or user motion data.
[0196] The gyro sensor 1012 can detect the body direction and rotation angle of the computer device 1000, and the gyro sensor 1012 can cooperate with the acceleration sensor 1011 to collect the user's 3D actions on the computer device 1000. The processor 1001 can implement the following functions based on the data collected by the gyro sensor 1012: motion sensing (such as changing the UI according to the user's tilt operation), image stabilization during shooting, game control, and inertial navigation.
[0197] The pressure sensor 1013 can be set on the side frame of the computer device 1000 and / or the lower layer of the display screen 1005. When the pressure sensor 1013 is set on the side frame of the computer device 1000, it can detect the user's grip signal of the computer device 1000, and the processor 1001 performs left and right hand recognition or shortcut operations according to the grip signal collected by the pressure sensor 1013. When the pressure sensor 1013 is set on the lower layer of the display screen 1005, the processor 1001 controls the operability controls on the UI interface according to the user's pressure operation on the display screen 1005. The operability controls include at least one of a button control, a scroll bar control, an icon control, and a menu control.
[0198] The fingerprint sensor 1014 is used to collect the user's fingerprint, and the processor 1001 identifies the user's identity based on the fingerprint collected by the fingerprint sensor 1014, or the fingerprint sensor 1014 identifies the user's identity based on the collected fingerprint. When the user's identity is identified as a trusted identity, the processor 1001 authorizes the user to perform relevant sensitive operations, including unlocking the screen, viewing encrypted information, downloading software, paying, and changing settings. The fingerprint sensor 1014 can be set on the front, back, or side of the computer device 1000. When a physical button or a manufacturer logo is set on the computer device 1000, the fingerprint sensor 1014 can be integrated with the physical button or the manufacturer logo.
[0199] The optical sensor 1015 is used to collect the ambient light intensity. In one embodiment, the processor 1001 can control the display brightness of the display screen 1005 according to the ambient light intensity collected by the optical sensor 1015. Specifically, when the ambient light intensity is high, the display brightness of the display screen 1005 is increased; when the ambient light intensity is low, the display brightness of the display screen 1005 is reduced. In another embodiment, the processor 1001 can also dynamically adjust the shooting parameters of the camera assembly 1006 according to the ambient light intensity collected by the optical sensor 1015.
[0200] The proximity sensor 1016, also called a distance sensor, is usually disposed on the front panel of the computer device 1000. The proximity sensor 1016 is used to collect the distance between the user and the front of the computer device 1000. In one embodiment, when the proximity sensor 1016 detects that the distance between the user and the front of the computer device 1000 is gradually decreasing, the processor 1001 controls the display screen 1005 to switch from the screen-on state to the screen-off state; when the proximity sensor 1016 detects that the distance between the user and the front of the computer device 1000 is gradually increasing, the processor 1001 controls the display screen 1005 to switch from the screen-off state to the screen-on state.
[0201] Those skilled in the art will understand that Fig.10 The structure shown in the figure does not constitute a limitation on the computer device 1000, and the computer device 1000 may include more or less components than those shown in the figure, or combine some components, or adopt a different component arrangement.
[0202] An embodiment of the present application also provides a computer device, which includes a processor and a memory, in which at least one instruction, at least one program, a code set or an instruction set is stored, and the at least one instruction, at least one program, a code set or an instruction set is loaded and executed by the processor to implement the speech rate recognition method provided by the above-mentioned method embodiments.
[0203] An embodiment of the present application also provides a computer-readable storage medium, on which is stored at least one instruction, at least one program, code set or instruction set, and the at least one instruction, at least one program, code set or instruction set is loaded and executed by a processor to implement the speech rate recognition method provided by the above-mentioned method embodiments.
[0204] The embodiments of the present application also provide a computer program product or a computer program, which includes a computer instruction stored in a computer-readable storage medium. The processor of the computer device reads the computer instruction from the computer-readable storage medium, and the processor executes the computer instruction, so that the computer device executes the speech rate recognition method described in any of the above embodiments.
[0205] Optionally, the computer readable storage medium may include: a read-only memory (ROM), a random access memory (RAM), a solid state drive (SSD), or an optical disk. Among them, the random access memory may include a resistance random access memory (ReRAM) and a dynamic random access memory (DRAM). The serial numbers of the above embodiments of the present application are only for description and do not represent the advantages and disadvantages of the embodiments.
[0206] A person skilled in the art will understand that all or part of the steps to implement the above embodiments may be accomplished by hardware or by instructing related hardware through a program, and the program may be stored in a computer-readable storage medium, and the above-mentioned storage medium may be a read-only memory, a disk or an optical disk, etc.
[0207] The above description is only an optional embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the protection scope of the present application.
Claims
1. A speech rate recognition method, characterized in that: The method comprises: Acquire voice data, wherein the voice data includes at least two voice frames; Extracting a pitch period state of the speech frame, wherein the pitch period state is used to indicate a change in the pitch period between at least two speech frames; Establishing a histogram corresponding to the pitch cycle state, the histogram is used to indicate the distribution of the pitch cycle state in at least two state intervals, wherein the state interval is an interval divided according to the continuous distribution of the pitch cycle state, and the state interval is divided based on the continuous distribution length of the pitch cycle state; The speech rate prediction is performed based on the distribution of the pitch period state in the histogram to obtain the speech rate recognition result corresponding to the speech data.
2. The method according to claim 1, characterized in that The step of establishing a histogram corresponding to the pitch cycle state comprises: Acquire at least one continuous cumulative value of the pitch period state, wherein the continuous cumulative value is used to indicate a continuous distribution of speech frames that meet the pitch period state in the speech data; A histogram corresponding to the pitch cycle state is established based on the continuous cumulative value.
3. The method according to claim 2, characterized in that The step of establishing a histogram corresponding to the pitch cycle state based on the continuous accumulated value includes: Determine a state interval distribution corresponding to the histogram, wherein the state interval distribution is used to distinguish the distribution of the continuous cumulative values; The continuous accumulated value of the pitch cycle state is mapped to the state interval distribution to obtain a histogram corresponding to the pitch cycle state.
4. The method according to claim 2, characterized in that: The pitch period state includes at least one of a period rising state, a period flat state and a period falling state; The obtaining of the continuous cumulative value of the pitch period state comprises: In response to the pitch cycle state including the cycle rising state, acquiring at least one first continuous accumulated value of the cycle rising state; In response to the pitch cycle state including the cycle flat state, acquiring at least one second continuous accumulated value of the cycle flat state; In response to the pitch cycle state including the cycle down state, at least one third continuous accumulated value of the cycle down state is acquired.
5. The method according to claim 4, characterized in that The method further comprises: In response to the pitch period value of the i+1th speech frame being greater than the pitch period value of the i-th speech frame, and the difference reaches a preset period value, determining that the pitch period state corresponding to the i+1th speech frame is a period rising state, where i is a positive integer; In response to the difference between the pitch period value of the i+1th speech frame and the pitch period value of the i-th speech frame being less than the preset period value, determining that the pitch period state corresponding to the i+1th speech frame is a period-flat state; In response to the pitch period value of the i+1th speech frame being less than the pitch period value of the i-th speech frame, and the difference reaching a preset period value, the pitch period state corresponding to the i+1th speech frame is determined to be a period-down state.
6. The method according to any one of claims 2 to 5, characterized in that: The method of performing speech rate prediction based on the distribution of the pitch period state in the histogram to obtain a speech rate recognition result corresponding to the speech data includes: Obtaining the number of continuous cumulative values corresponding to the at least two state intervals in the histogram; The number of continuous accumulated values respectively corresponding to the at least two state intervals is analyzed by a speech rate recognition model to obtain a speech rate recognition result corresponding to the voice data.
7. The method according to claim 6, characterized in that The speech rate recognition model includes a gated recurrent layer and a classification layer; The method of analyzing the number of continuous cumulative values respectively corresponding to the at least two state intervals by using the speech rate recognition model to obtain a speech rate recognition result corresponding to the speech data includes: Performing data feature processing on the number of continuous cumulative values respectively corresponding to the at least two state intervals through the gated cycle layer to obtain a gated cycle feature; The gated loop feature is classified into speed levels through the classification layer to obtain the speech speed level corresponding to the voice data as the speech speed recognition result.
8. The method according to any one of claims 1 to 5, characterized in that: The extracting the pitch period state of the speech frame comprises: Performing voice activity detection on the at least two voice frames to obtain a valid frame in the at least two voice frames; The pitch period state is extracted based on the valid frame.
9. The method according to any one of claims 1 to 5, characterized in that: Before extracting the pitch period state of the speech frame, the method further comprises: The voice data is divided based on a preset time interval to obtain at least two voice frames corresponding to the voice data.
10. A speech rate recognition device, characterized in that: The device comprises: An acquisition module, used for acquiring voice data, wherein the voice data is data to be subjected to speech rate recognition, and the voice data includes at least two voice frames, and the voice frame is a data unit constituting the voice data; An extraction module, used for extracting the pitch period state of the speech frame, wherein the pitch period state is used for indicating the pitch period change between at least two speech frames; An establishment module, used to establish a histogram corresponding to the pitch period state, wherein the histogram is used to indicate the distribution of the pitch period state in at least two state intervals, wherein the state interval is an interval divided according to the continuous distribution of the pitch period state, and the state interval is divided based on the continuous distribution length of the pitch period state; The prediction module is used to predict the speech rate based on the distribution of the pitch period state in the histogram to obtain the speech rate recognition result corresponding to the speech data.
11. The device according to claim 10, characterized in that The acquisition module is further used to acquire at least one continuous cumulative value of the pitch period state, wherein the continuous cumulative value is used to indicate the continuous distribution of speech frames that meet the pitch period state in the speech data; The establishing module is further used to establish a histogram corresponding to the pitch cycle state based on the continuous accumulated value.
12. The device according to claim 11, characterized in that The establishment module comprises: A determination unit, used to determine a state interval distribution corresponding to the histogram, wherein the state interval distribution is used to distinguish the distribution of the continuous cumulative values; A mapping unit is used to map the continuous accumulated value of the pitch cycle state to the state interval distribution to obtain a histogram corresponding to the pitch cycle state.
13. A computer device, characterized in that: The computer device includes a processor and a memory, wherein the memory stores at least one program, and the at least one program is loaded and executed by the processor to implement the speech rate recognition method as described in any one of claims 1 to 9.
14. A computer-readable storage medium, characterized in that: The storage medium stores at least one program, and the at least one program is loaded and executed by the processor to implement the speech rate recognition method as described in any one of claims 1 to 9.
Citation Information
Patent Citations
Pitch period spectrogram method for directly displaying pitch period trajectory
CN109346105A
Voice recognition result testing method and device, computer equipment and medium
CN110556098A