Method, device, equipment and medium for establishing speech synthesis corpus

By segmenting, identifying and filtering speech data, and extracting fundamental frequency values ​​for clustering, the problem of poor phonetic consistency and inconsistent timbre style of speech text is solved, and the data quality of speech synthesis model training is improved.

CN113362800BActive Publication Date: 2024-09-20SHENZHEN UNISOUND INFORMATION TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110616148.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-06-02
Publication Date
2024-09-20
Estimated Expiration
2041-06-02

AI Technical Summary

Technical Problem

Existing corpus recording has high cost, long cycle, and difficulty, and the quality of speech data obtained directly from web crawling cannot meet the requirements of speech synthesis model training, resulting in poor consistency of phonetic pronunciation and inconsistent timbre and style of speech text.

Method used

By obtaining the speech data, segmenting the corpus, identifying the text, filtering the text, extracting the fundamental frequency value, calculating the sentence-level fundamental frequency mean and variance, the clustering results divide the corpus into k libraries to ensure the consistency of speech style and timbre.

Benefits of technology

It improves the accuracy of text recognition, ensures the consistency of voice style and timbre, and meets the data quality requirements for speech synthesis model training.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113362800B
    Figure CN113362800B
Patent Text Reader

Abstract

The present invention relates to a method, device, equipment and medium for establishing a speech synthesis corpus, the method comprising: obtaining a first text and speech data corresponding to the first text; segmenting the speech data to obtain a segmented corpus; obtaining a second text by segmenting the corpus; comparing the second text with the first text, and screening to obtain a screened text; determining a screened audio according to the screened text; extracting the fundamental frequency value of the screened audio; calculating the mean and variance of the fundamental frequency value; clustering the mean and variance to obtain a clustering result; and dividing the screened text and its corresponding speech data into k corpora according to the clustering result. In the embodiment of the present application, the method of first segmentation and then recognition is adopted to improve the accuracy of text recognition, and the first text obtained is used as a reference to remove recognition errors; because the fundamental frequency has a strong correlation with the voice style and timbre, the sentence-level fundamental frequency mean variance is used for classification, which effectively ensures the consistency of the voice style and timbre within the class.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of corpus, and in particular to a method, device, equipment and medium for establishing a speech synthesis corpus. Background Art

[0002] At present, corpus recording has problems such as high cost, long production cycle and great difficulty. However, directly using the voice data crawled from the Internet contains a large amount of data that does not meet the data quality requirements for synthetic model training. The current common method of automatically building a voice library is to perform speech recognition on the crawled voice to obtain the recognized text, and then cut the voice into short sentences that meet the length requirements according to the recognized text, and finally use the cut audio and corresponding text as the corpus in the corpus.

[0003] A qualified corpus for training speech synthesis models usually needs to meet the following requirements: 1. The speech and text need to have a high degree of consistency between words and sounds; 2. All speech of the same speaker must be consistent in terms of timbre, style, sound quality and other phonetic indicators; 3. The length of each speech must be kept within a certain range of words and cannot be too long or too short. However, due to the errors in the recognition model of the above method, the content of requirement 1 cannot be effectively guaranteed. At the same time, the method cannot be used to evaluate the linguistic stability of the speech, resulting in the failure to meet the content of requirement 2. Summary of the invention

[0004] The present invention provides a method, device, equipment and medium for establishing a speech synthesis corpus, which can solve the technical problems of poor consistency of pronunciation of speech text, poor consistency in timbre, style and sound quality.

[0005] The technical solution of the present invention to solve the above technical problems is as follows:

[0006] In a first aspect, an embodiment of the present invention provides a method for establishing a speech synthesis corpus, comprising: obtaining a first text and speech data corresponding to the first text; segmenting the speech data to obtain a segmented corpus; identifying the segmented corpus to obtain a second text; comparing the second text with the first text, and filtering to obtain a filtered text; determining a filtered audio based on the filtered text; extracting a fundamental frequency value of the filtered audio; calculating a mean and variance of the sentence-level fundamental frequency values; clustering the mean and variance to obtain a clustering result; and dividing the filtered text and its corresponding speech data into k corpora based on the clustering result.

[0007] In some embodiments, in the above method, segmenting the speech data to obtain segmented corpus includes:

[0008] The speech data is segmented using a speech activity detection algorithm to obtain segmented corpus.

[0009] In some embodiments, in the above method, comparing the second text with the first text and filtering to obtain the filtered text includes:

[0010] Filter based on the number of words and accuracy of the comparison.

[0011] In some embodiments, the above method further comprises:

[0012] The k corpora are distinguished by using different style-ids.

[0013] In some embodiments, the method of identifying the segmented corpus to obtain the second text includes: using automatic speech recognition technology to identify the segmented corpus to obtain the second text.

[0014] In the second aspect, an embodiment of the present invention also provides a device for establishing a speech synthesis corpus, including: an acquisition module: used to acquire a first text and speech data corresponding to the first text; a segmentation module: used to segment the speech data to obtain a segmented corpus; a recognition module: used to recognize the segmented corpus to obtain a second text; a comparison module: used to compare the second text with the first text, and filter to obtain a filtered text; a determination module: used to determine a filtered audio based on the filtered text; an extraction module: used to extract the fundamental frequency value of the filtered audio; a calculation module: used to calculate the mean and variance of the sentence-level fundamental frequency value; a clustering module: used to cluster the mean and variance to obtain a clustering result; a classification module: based on the clustering result, the filtered text and its corresponding speech data are classified to obtain k corpora.

[0015] In some embodiments, the segmentation module in the above device segments the speech data to obtain segmented corpus, including:

[0016] The speech data is segmented using a speech activity detection algorithm to obtain segmented corpus.

[0017] In some embodiments, the comparison module is further used to:

[0018] The filtered text is obtained by filtering according to the number of compared words and accuracy.

[0019] In a third aspect, an embodiment of the present invention further provides an electronic device, including: a processor and a memory;

[0020] The processor is used to execute any of the above-mentioned methods for establishing a speech synthesis corpus by calling the program or instruction stored in the memory.

[0021] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a program or instruction, wherein the program or instruction enables a computer to execute any one of the methods for establishing a speech synthesis corpus as described above.

[0022] The beneficial effects of the present invention are: obtaining a first text and speech data corresponding to the first text; segmenting the speech data to obtain a segmented corpus; identifying the segmented corpus to obtain a second text; comparing the second text with the first text, and screening to obtain a screened text; determining a screened audio according to the screened text; extracting the fundamental frequency value of the screened audio; calculating the mean and variance of the fundamental frequency value; clustering the mean and variance to obtain a clustering result; and dividing the screened text and its corresponding speech data into k corpora according to the clustering result. The first aspect of the method for establishing a corpus in the present application adopts a method of segmentation before recognition, which can improve the accuracy of text recognition, and uses the first text obtained as a reference to compare with the second text to remove recognition errors, thereby further improving the accuracy of text recognition; secondly, since the fundamental frequency has a strong correlation with the voice style and timbre, the use of the sentence-level fundamental frequency mean variance for classification can effectively ensure the consistency of the voice style and timbre within the class. BRIEF DESCRIPTION OF THE DRAWINGS

[0023] Figure 1 A method for establishing a speech synthesis corpus provided in an embodiment of the present invention;

[0024] Figure 2 A device for establishing a speech synthesis corpus provided by an embodiment of the present invention;

[0025] Figure 3 A schematic block diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0026] The principles and features of the present invention are described below in conjunction with the accompanying drawings. The examples given are only used to explain the present invention and are not used to limit the scope of the present invention.

[0027] In order to more clearly understand the above-mentioned purpose, features and advantages of the present application, the present disclosure is further described in detail below in conjunction with the accompanying drawings and examples. It is to be understood that the described embodiments are part of the embodiments of the present disclosure, rather than all of the embodiments. The specific embodiments described herein are merely used to explain the present disclosure, rather than to limit the present application. Based on the described embodiments of the present application, all other embodiments obtained by those of ordinary skill in the art belong to the scope of protection of the present application.

[0028] It should be noted that, in this document, relational terms such as “first” and “second” are merely used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any actual relationship or order between these entities or operations.

[0029] Figure 1 A method for establishing a speech synthesis corpus is provided in an embodiment of the present invention.

[0030] First, combining Figure 1 The embodiment of the present invention provides a method for establishing a speech synthesis corpus, comprising the following nine steps S101, S102, S103, S104, S105, S106, S107, S108 and S109:

[0031] S101: Acquire a first text and voice data corresponding to the first text.

[0032] Specifically, in an embodiment of the present application, the first text and the voice data corresponding to the first text may be audio books, news broadcasts, etc., and the acquisition method may be crawling. For example, if the first text is "I am Chinese", the voice data corresponding to the first text is the voice data corresponding to "I am Chinese".

[0033] S102: Segment the speech data to obtain segmented corpus.

[0034] Specifically, in the embodiment of the present application, the speech data is segmented to obtain segmented corpus. A long speech can be segmented into multiple short speech segments according to its silent segments. The multiple short speech segments are the segmented corpus. The long speech is segmented into multiple short speech segments. Audio with a sentence length of 5 to 25 words is more suitable for model training, providing corpus for model training.

[0035] S103: Identify the segmented corpus to obtain a second text.

[0036] Specifically, in the embodiment of the present application, if the segmented corpus is the voice of "I love China", the voice of "I love China" is recognized to obtain the text of "I love China".

[0037] S104: Compare the second text with the first text, and filter to obtain a filter text.

[0038] Specifically, in the embodiment of the present application, if the second text is "I love China" and the first text is "I am Chinese", the comparison module compares the second text with reference to the first text. The first text has 5 words, and the accuracy of the second text is 3 / 5=60%, 60% is lower than 90%. In the specific application process, 90% is just an example. It can be specifically set to filter out "I love China" to obtain the filtered text. For example, if the second text is "I love China" and the first text is "I love China", the first text has 4 words, and the accuracy of the second text is 4 / 4=100%, so the second text "I love China" will not be filtered out.

[0039] S105: Determine the filtered audio according to the filtered text.

[0040] Specifically, in the embodiment of the present application, after filtering out texts that do not meet the word count and accuracy requirements, filtered texts are obtained. Each filtered text corresponds to an audio, so filtering the text is also filtering the audio.

[0041] S106: Extracting the fundamental frequency value of the filtered audio.

[0042] For example, the base frequency sequence extracted from the audio 0001.wav is 200, 200, ..., 200.

[0043] S107: Calculate the mean and variance of the sentence-level fundamental frequency values.

[0044] Exemplarily, the fundamental frequency sequence is 200, 200, ..., 200, and the calculated mean and variance of the sentence-level fundamental frequency are 200 and 1, respectively.

[0045] S108: clustering means and variances to obtain clustering results.

[0046] For example, for example, there are three audios: 0001.wav, 0002.wav, 0003.wav, and the corresponding fundamental frequency values ​​have mean and variance groups of [200,1], [100,10], and [201,1.1]. After clustering, two clustering results will be obtained: A: [200,1], [201,1.1]; B: [100,10].

[0047] S109: Divide the screened text and its corresponding voice data into k corpora according to the clustering result.

[0048] Specifically, if the clustering result is 2, the screened text and its corresponding speech data are divided into two corpora. Corpus A contains audio 0001.wav, 0003.wav and its corresponding text; Corpus B contains 0002.wav and its corresponding text.

[0049] It should be understood that the first aspect of the method for establishing a corpus in the present application adopts a method of first segmentation and then recognition, which can improve the accuracy of text recognition, and use the obtained first text as a reference to compare with the second text to eliminate recognition errors, thereby further improving the accuracy of text recognition; on the second aspect, since the fundamental frequency has a strong correlation with the speech style and timbre, the use of sentence-level fundamental frequency mean variance for classification can effectively ensure the consistency of speech style and timbre within the class.

[0050] In some embodiments, in the above method, segmenting the speech data to obtain segmented corpus includes:

[0051] The speech data is segmented using a speech activity detection algorithm to obtain segmented corpus.

[0052] Specifically, in the embodiment of the present application, a long speech is segmented into multiple short speech segments according to its silence segments through the voice activity detection algorithm VAD, that is, segmented into segmented corpora.

[0053] In some embodiments, in the above method, comparing the second text with the first text and filtering to obtain the filtered text includes:

[0054] Filter based on the number of words and accuracy of the comparison.

[0055] Specifically, if the second text is "I love China" and the first text is "I am Chinese", the first text is compared with the second text. The first text has 5 words, and the accuracy of the second text is 3 / 5=60%, which is lower than 90%. In the specific application process, 90% is just an example. It can be specifically set to filter out "I love China" to obtain the filtered text. For example, if the second text is "I love China" and the first text is "I love China", the first text has 4 words, and the accuracy of the second text is 4 / 4=100%, so the second text "I love China" will not be filtered out.

[0056] In some embodiments, the above method further comprises:

[0057] The k corpora are distinguished by using different style-ids.

[0058] Specifically, based on the above content, the prefix 01 is added to the audio names in category A as their style-id, that is: 010001.wav, 010003.wav; the prefix 02 in category B, that is: 020002.wav, so that the two language libraries can be distinguished during the training process. Since the two language libraries are clustered and distinguished by fundamental frequency, and according to the above description, fundamental frequency and style are strongly correlated, when the training is completed, the prefix style-id is the configuration bit that controls the type of model synthesis style, and information other than style-id, such as text content and speech rate, cannot be classified by fundamental frequency mean variance. Since all language libraries are mixed for training together, this information will be shared during the training process, so that the training model can not only distinguish different style-ids, but also fully share information other than style-id.

[0059] In some embodiments, the method of identifying the segmented corpus to obtain the second text includes: using automatic speech recognition technology to identify the segmented corpus to obtain the second text.

[0060] Specifically, in the embodiment of the present invention, the segmented corpus is recognized by using the automatic speech recognition technology ASR to obtain the second text, ie, the recognized text of the segmented corpus.

[0061] Figure 2A device for establishing a speech synthesis corpus is provided in an embodiment of the present invention.

[0062] Second, combining Figure 2 The embodiment of the present invention further provides a device for establishing a speech synthesis corpus, comprising:

[0063] Acquisition module 201: used to acquire a first text and voice data corresponding to the first text.

[0064] Specifically, in an embodiment of the present application, the first text and the voice data corresponding to the first text may be an audio book, a news broadcast, etc., which are acquired through the acquisition module 201. For example, if the first text is "I am Chinese", the voice data corresponding to the first text is the voice data corresponding to "I am Chinese".

[0065] Segmentation module 202: used to segment speech data to obtain segmented corpus.

[0066] Specifically, in the embodiment of the present application, the segmentation module 202 segments the speech data to obtain segmented corpus, which can be a long speech, divided into multiple short speech segments according to its silent segments. The multiple short speech segments are the segmented corpus. The long speech is segmented into multiple short speech segments, mainly audio with a sentence length of 5 to 25 words is more suitable for model training, providing corpus for model training.

[0067] Recognition module 203: used to recognize and segment the corpus to obtain a second text.

[0068] Specifically, in the embodiment of the present application, if the segmented corpus is the voice of "I love China", the recognition module 203 recognizes the voice of "I love China" to obtain the text of "I love China".

[0069] Comparison module 204: used for comparing the second text with the first text, and filtering to obtain a filtered text.

[0070] Specifically, in the embodiment of the present application, if the second text is "I love China" and the first text is "I am Chinese", the comparison module 204 compares the second text with reference to the first text. The first text has 5 characters, and the accuracy of the second text is 3 / 5=60%, which is lower than 90%. In the specific application process, 90% is just an example. It can be specifically set to filter out "I love China" to obtain the filtered text. For example, if the second text is "I love China" and the first text is "I love China", the first text has 4 characters, and the accuracy of the second text is 4 / 4=100%, so the second text "I love China" will not be filtered out.

[0071] Determination module 205: Determine the filtered audio according to the filtered text.

[0072] Specifically, in an embodiment of the present application, after filtering out texts that do not meet the word count and accuracy requirements, filtered texts are obtained. Each filtered text corresponds to an audio. The determination module 205 determines the filtered audio based on the filtered text, so filtering the text is also filtering the audio.

[0073] Extraction module 206: used to extract the fundamental frequency value of the filtered audio.

[0074] Exemplarily, the extraction module 206 extracts a baseband sequence of 200, 200, ..., 200 from the audio 0001.wav.

[0075] Calculation module 207: used to calculate the mean and variance of the sentence-level fundamental frequency value.

[0076] Exemplarily, the fundamental frequency sequence is 200, 200, ..., 200, and the calculation module 207 calculates the mean and variance of the sentence-level fundamental frequency to be 200 and 1 respectively.

[0077] Clustering module 208: used to cluster means and variances to obtain clustering results.

[0078] For example, there are three audios: 0001.wav, 0002.wav, 0003.wav, and the mean variance groups of the fundamental frequency values ​​corresponding to the three audios are [200, 1], [100, 10], and [201, 1.1]. Then, after clustering, the clustering module 208 will obtain two clustering results A: [200, 1], [201, 1.1]; B: [100, 10].

[0079] Classification module 209: Classify the screened text and its corresponding voice data according to the clustering results to obtain k corpora.

[0080] Specifically, the classification module 209 divides the screened text and its corresponding speech data into two categories according to the clustering result, that is, k=2, the A language library contains audio 0001.wav, 0003.wav and its corresponding text; the B language library contains 0002.wav and its corresponding text.

[0081] In some embodiments, the segmentation module 202 in the above device segments the speech data to obtain segmented corpora, including:

[0082] The voice activity detection algorithm VAD in the segmentation module 202 segments a long speech into multiple short speech segments according to its silent segments, that is, segments the speech into segmented corpora.

[0083] In some embodiments, the comparison module 204 is further used to:

[0084] The filtered text is obtained by filtering according to the number of compared words and accuracy.

[0085] Specifically, if the second text is "I love China" and the first text is "I am Chinese", the comparison module 204 compares the second text with reference to the first text. The first text has 5 characters, and the accuracy of the second text is 3 / 5=60%, which is lower than 90%. In the specific application process, 90% is just an example. It can be specifically set to filter out "I love China" to obtain the filtered text. For example, if the second text is "I love China" and the first text is "I love China", the first text has 4 characters, and the accuracy of the second text is 4 / 4=100%, so the second text "I love China" will not be filtered out.

[0086] In a third aspect, an embodiment of the present invention further provides an electronic device, including: a processor and a memory;

[0087] The processor is used to execute any of the above-mentioned methods for establishing a speech synthesis corpus by calling the program or instruction stored in the memory.

[0088] In a fourth aspect, an embodiment of the present invention further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a program or instruction, wherein the program or instruction enables a computer to execute any one of the methods for establishing a speech synthesis corpus as described above.

[0089] Figure 3 It is a schematic block diagram of an electronic device provided by an embodiment of the present disclosure.

[0090] like Figure 3 As shown, the electronic device includes: at least one processor 301, at least one memory 302 and at least one communication interface 303. The various components in the electronic device are coupled together through a bus system 304. The communication interface 303 is used to transmit information between external devices. It can be understood that the bus system 304 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 304 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, Figure 3 Various buses are labeled as bus system 304 .

[0091] It can be understood that the memory 302 in this embodiment can be a volatile memory or a non-volatile memory, or can include both volatile and non-volatile memories.

[0092] In some implementations, the memory 302 stores the following elements, executable units or data structures, or a subset thereof, or an extended set thereof: an operating system and application programs.

[0093] Among them, the operating system includes various system programs, such as a framework layer, a core library layer, a driver layer, etc., which are used to implement various basic services and process hardware-based tasks. The application program includes various application programs, such as a media player (Media Player), a browser (Browser), etc., which are used to implement various application services. The program for establishing any method for speech synthesis corpus in the method for unlocking a computer screen and locking a computer screen provided in the embodiment of the present application can be included in the application program.

[0094] In an embodiment of the present application, the processor 301 calls a program or instruction stored in the memory 302, specifically, a program or instruction stored in an application, and the processor 301 is used to execute the steps of each embodiment of the method for establishing a speech synthesis corpus provided in the embodiment of the present application.

[0095] Acquire a first text and speech data corresponding to the first text; segment the speech data to obtain a segmented corpus; identify the segmented corpus to obtain a second text; compare the second text with the first text, and filter to obtain a filtered text; determine a filtered audio according to the filtered text; extract a fundamental frequency value of the filtered audio; calculate a mean and a variance of the fundamental frequency value; cluster the mean and the variance to obtain a clustering result; and divide the filtered text and its corresponding speech data into k corpora according to the clustering result.

[0096] Any of the methods for establishing a speech synthesis corpus provided in the embodiments of the present application can be applied to the processor 301, or implemented by the processor 301. The processor 301 can be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in the processor 301 or an instruction in the form of software. The above-mentioned processor 301 can be a general-purpose processor, a digital signal processor (DigitalSignal Processor, DSP), an application-specific integrated circuit (Application Specific Integrated Circuit, ASIC), a field programmable gate array (Field Programmable Gate Array, FPGA) or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components. The general-purpose processor can be a microprocessor or the processor can also be any conventional processor, etc.

[0097] The steps of any method in the method for establishing a speech synthesis corpus provided in the embodiment of the present application can be directly embodied as being executed by a hardware decoding processor, or being executed by a combination of hardware and software units in a decoding processor. The software unit can be located in a storage medium mature in the art such as a random access memory, a flash memory, a read-only memory, a programmable read-only memory, or an electrically erasable programmable memory, a register, etc. The storage medium is located in the memory 302, and the processor 301 reads the information in the memory 302, and completes the steps of the method for establishing a speech synthesis corpus in combination with its hardware.

[0098] Those skilled in the art will appreciate that although some embodiments described herein include certain features included in other embodiments but not other features, the combination of features from different embodiments is meant to be within the scope of the present application and to form different embodiments.

[0099] Those skilled in the art will appreciate that the description of each embodiment has its own emphasis, and for parts not described in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.

[0100] Although the embodiments of the present application are described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present application, and such modifications and variations all fall within the scope defined by the attached claims. The above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or substitutions within the technical scope disclosed by the present invention, and these modifications or substitutions should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be subject to the protection scope of the claims.

[0101] The above are only specific embodiments of the present invention, but the protection scope of the present invention is not limited thereto. Any technician familiar with the technical field can easily think of various equivalent modifications or replacements within the technical scope disclosed by the present invention, and these modifications or replacements should be included in the protection scope of the present invention. Therefore, the protection scope of the present invention shall be based on the protection scope of the claims.

Claims

1. A method for establishing a speech synthesis corpus, characterized in that: include: Acquire a first text and voice data corresponding to the first text; Segmenting the speech data to obtain segmented corpus; Recognize the segmented corpus to obtain a second text; Comparing the second text with the first text, and filtering according to the number of compared words and accuracy to obtain a filtered text; Determine the filtering audio according to the filtering text; Extracting the fundamental frequency value of the filtered audio; Calculating the mean and variance of the fundamental frequency values; Clustering the means and the variances to obtain a clustering result; The screened text and its corresponding speech data are divided into k corpora according to the clustering result.

2. The method for establishing a speech synthesis corpus according to claim 1, characterized in that: The segmenting of the speech data to obtain segmented corpora includes: The speech data is segmented using a speech activity detection algorithm to obtain segmented corpus.

3. The method for establishing a speech synthesis corpus according to claim 1, characterized in that: The method further comprises: The k corpora are distinguished by using different style-ids.

4. The method for establishing a speech synthesis corpus according to claim 1, characterized in that: Recognizing the segmented corpus to obtain the second text includes: using automatic speech recognition technology to recognize the segmented corpus to obtain the second text.

5. A device for establishing a speech synthesis corpus, characterized in that: include: Acquisition module: used to acquire the first text and the voice data corresponding to the first text; Segmentation module: used for segmenting the speech data to obtain segmented corpus; Recognition module: used for recognizing the segmented corpus to obtain a second text; Comparison module: used for comparing the second text with the first text, and filtering according to the number of words and accuracy of the comparison to obtain a filtered text; Determination module: determining the filtered audio according to the filtered text; Extraction module: used for extracting the fundamental frequency value of the filtered audio; Calculation module: used to calculate the mean and variance of the fundamental frequency value; Clustering module: used for clustering the mean and the variance to obtain a clustering result; Classification module: classify the screened text and its corresponding voice data according to the clustering results to obtain k corpora.

6. The device for establishing a speech synthesis corpus according to claim 5, characterized in that: The segmenting of the speech data to obtain segmented corpora includes: The speech data is segmented using a speech activity detection algorithm to obtain segmented corpus.

7. An electronic device, characterized in that: include: Processor and memory; The processor is used to execute the method for establishing a speech synthesis corpus as claimed in any one of claims 1 to 4 by calling the program or instruction stored in the memory.

8. A computer-readable storage medium, characterized in that: A non-transitory computer-readable storage medium stores a program or instruction, wherein the program or instruction enables a computer to execute the method for establishing a speech synthesis corpus as claimed in any one of claims 1 to 4.