WO2021052306A1 - 声纹特征注册 - Google Patents

声纹特征注册 Download PDF

Info

Publication number
WO2021052306A1
WO2021052306A1 PCT/CN2020/115256 CN2020115256W WO2021052306A1 WO 2021052306 A1 WO2021052306 A1 WO 2021052306A1 CN 2020115256 W CN2020115256 W CN 2020115256W WO 2021052306 A1 WO2021052306 A1 WO 2021052306A1
Authority
WO
WIPO (PCT)
Prior art keywords
voice
feature
cluster
user
voice feature
Prior art date
Application number
PCT/CN2020/115256
Other languages
English (en)
French (fr)
Inventor
李世杰
陈欢
Original Assignee
北京三快在线科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 北京三快在线科技有限公司 filed Critical 北京三快在线科技有限公司
Publication of WO2021052306A1 publication Critical patent/WO2021052306A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L17/00Speaker identification or verification techniques
    • G10L17/02Preprocessing operations, e.g. segment selection; Pattern representation or modelling, e.g. based on linear discriminant analysis [LDA] or principal components; Feature selection or extraction
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L17/00Speaker identification or verification techniques
    • G10L17/04Training, enrolment or model building
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L25/00Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00
    • G10L25/03Speech or voice analysis techniques not restricted to a single one of groups G10L15/00 - G10L21/00 characterised by the type of extracted parameters

Definitions

  • the present disclosure relates to the field of computer technology, and in particular to a method, device, computer equipment, and storage medium for registering voiceprint features.
  • voice processing technology With the development of voice processing technology, more and more computer equipment uses voice processing technology.
  • the user can control the device through voice data to perform corresponding operations, such as voice unlocking, voice payment, and so on.
  • the user needs to register the user's voiceprint characteristics on the device before controlling the device. After that, the device can determine whether the current user is allowed to control the device by judging whether the voice feature of the current user matches the voiceprint feature.
  • the embodiment of the present disclosure provides a voiceprint feature registration.
  • the technical solution is as follows:
  • the method includes:
  • the multiple pieces of historical voice data including a first type of historical voice data and a second type of historical voice data, and the distance between the voice source of the second type of historical voice data and the terminal is greater than the first type of historical voice data The distance between the voice source of a type of historical voice data and the terminal;
  • each voice feature cluster includes voice features belonging to the same voice source
  • the voiceprint feature of the terminal user is generated.
  • the selecting a voice feature cluster satisfying a first reference condition from the at least one voice feature cluster as a user voice feature cluster includes at least one of the following steps:
  • a voice feature cluster that meets a data source condition from the at least one voice feature cluster as the user voice feature cluster, and the data source condition is that the number of data sources of the user voice feature cluster is greater than the number of data sources of other voice feature clusters ,
  • the data source of the voice feature cluster is the source of voice data corresponding to the voice feature in the voice feature cluster;
  • a voice feature cluster satisfying a time distribution condition from the at least one voice feature cluster as the user voice feature cluster and the time distribution condition is that the number of time periods of the user voice feature cluster is greater than the number of time periods of other voice feature clusters
  • the time period of the voice feature cluster is a time period to which the voice data corresponding to the voice feature in the voice feature cluster belongs.
  • the selecting a voice feature cluster satisfying a first reference condition from the at least one voice feature cluster as a user voice feature cluster includes:
  • the second reference condition is used to indicate the attributes of the user voice feature cluster The conditions met.
  • the first reference condition is used to indicate a condition satisfied by the description information of the voice data of the terminal user, and the obtaining voice features corresponding to multiple pieces of historical voice data includes:
  • the method further includes:
  • a first voiceprint feature is generated based on the first type of historical voice data
  • a second voiceprint feature is generated based on the second type of historical voice data
  • the first voiceprint feature and the user information of the terminal are established The association relationship between and the association relationship between the second voiceprint feature and the user information of the terminal.
  • the method further includes:
  • the voice features corresponding to the second type of historical voice data are discarded.
  • the generating a second voiceprint feature based on the second type of historical voice data includes: combining the voice features corresponding to the second type of historical voice data with the first voice feature. The voice features that do not match the pattern feature are discarded, and the voice feature matching the first voiceprint feature is obtained; the second voiceprint feature is generated according to the voice feature that matches the first voiceprint feature.
  • the generating the voiceprint feature of the terminal user according to the voice feature in the user voice feature cluster includes any of the following steps:
  • a voice feature is selected from the user voice feature cluster as the voiceprint feature, and the distance between the selected voice feature and the cluster center is smaller than the distance between other voice features in the user voice feature cluster and the cluster center ;
  • the user voiceprint model is trained, and the trained user voiceprint model is used as the voiceprint feature.
  • the method includes:
  • each voice feature cluster includes voice features belonging to the same voice source
  • a voice feature cluster meeting a first reference condition is selected from the at least one voice feature cluster as a user voice feature cluster, and the first reference condition includes at least one of the largest number of data sources and the largest number of time periods, either
  • the data source of the voice feature cluster is the source of voice data corresponding to the voice feature in any voice feature cluster
  • the time period of any voice feature cluster is the generation of voice data corresponding to the voice feature in any voice feature cluster The time period to which the time belongs;
  • the voiceprint feature of the terminal user is generated.
  • a voiceprint feature registration device which includes:
  • An acquiring module configured to acquire voice features corresponding to the multiple pieces of historical voice data
  • a selecting module configured to select a voice feature cluster that meets a first reference condition from the at least one voice feature cluster as a user voice feature cluster, and the first reference condition is used to indicate a condition satisfied by the voice data of the terminal user;
  • the generating module is configured to generate the voiceprint feature of the terminal user according to the voice feature in the user's voice feature cluster.
  • the selection module includes at least one of the following units:
  • the first selecting unit is configured to select a voice feature cluster that meets a data source condition from the at least one voice feature cluster as the user voice feature cluster, and the data source condition is that the number of data sources of the user voice feature cluster is greater than other voice feature clusters The number of data sources of the voice feature cluster, where the data source of the voice feature cluster is the source of voice data corresponding to the voice feature in the voice feature cluster;
  • the selection module is further configured to select a voice feature cluster satisfying the first reference condition and the second reference condition from the at least one voice feature cluster, as the user voice feature cluster ;
  • the second reference condition is used to indicate a condition satisfied by the attributes of the user's voice feature cluster.
  • the segmentation unit is used to segment the multiple pieces of historical voice data to obtain multiple pieces of historical voice data containing the target number of frames;
  • the relationship establishment unit is used to establish the corresponding relationship between each piece of historical voice data and the description information of the historical voice data to which it belongs;
  • the acquiring unit is used to acquire the voice feature corresponding to each piece of historical voice data.
  • the device further includes:
  • the association relationship establishment module is configured to establish the first voiceprint feature if a first voiceprint feature is generated based on the first type of historical voice data, and a second voiceprint feature is generated based on the second type of historical voice data.
  • the device further includes:
  • the matching module is configured to discard the voice features that do not match the first voiceprint feature among the voice features corresponding to the second type of historical voice data.
  • the association relationship establishment module is configured to discard the voice features that do not match the first voiceprint feature among the voice features corresponding to the second type of historical voice data to obtain Voice feature matching the first voiceprint feature; generating the second voiceprint feature according to the voice feature matching the first voiceprint feature.
  • the generating module includes any of the following units:
  • a merging unit configured to merge multiple voice features in the user voice feature cluster into one voice feature as the voiceprint feature
  • the selecting unit is configured to select a voice feature from the user voice feature cluster as the voiceprint feature, and the distance between the selected voice feature and the cluster center is less than that of other voice features in the user voice feature cluster.
  • the training unit is configured to train a user's voiceprint model according to the voice features in the user's voice feature cluster, and use the trained user's voiceprint model as the voiceprint feature.
  • the dividing module is used to divide the acquired multiple voice features to obtain at least one voice feature cluster, and each voice feature cluster includes voice features belonging to the same voice source;
  • the selection module is configured to select a voice feature cluster that meets a first reference condition from the at least one voice feature cluster as a user voice feature cluster, and the first reference condition includes at least one of the largest number of data sources and the largest number of time periods
  • a condition that the data source of any voice feature cluster is the source of voice data corresponding to the voice feature in any voice feature cluster, and the time period of any voice feature cluster corresponds to the voice feature in any voice feature cluster The time period to which the generation time of the voice data belongs;
  • the generating module is configured to generate the voiceprint feature of the terminal user according to the voice feature in the user's voice feature cluster.
  • a computer-readable storage medium is provided, and at least one instruction is stored in the storage medium, and the at least one instruction is loaded and executed by a processor to implement the voiceprint as described in any of the foregoing possible implementation manners.
  • the operation performed by the feature registration method is performed by the feature registration method.
  • the voiceprint feature registration method, device, computer equipment, and storage medium provided by the embodiments of the present disclosure can classify the acquired multiple voice features based on whether the voice features belong to the same voice source by acquiring voice features corresponding to multiple pieces of historical voice data , Get at least one voice feature cluster; based on the conditions satisfied by the voice data of the terminal user, filter out the user voice feature cluster from the at least one voice feature cluster, and generate the voiceprint feature of the terminal user according to the user voice feature cluster, which realizes automatic Acquire the user's voiceprint characteristics, and during voiceprint registration, the user does not need to input voice data, which simplifies user operations, speeds up registration time, and improves registration efficiency.
  • FIG. 1 is a schematic diagram of an implementation environment provided by an embodiment of the present disclosure
  • FIG. 4 is a flowchart of a preprocessing method provided by an embodiment of the present disclosure.
  • FIG. 6 is a flowchart of a clustering method provided by an embodiment of the present disclosure.
  • FIG. 8 is a flowchart of a method for generating voiceprint features according to an embodiment of the present disclosure
  • FIG. 12 is a schematic structural diagram of a terminal provided by an embodiment of the present disclosure.
  • voice processing technology With the development of voice processing technology, more and more computer equipment uses voice processing technology.
  • the user can control the device through voice data to perform corresponding operations, such as voice unlocking, voice payment, and so on.
  • the user needs to register the user's voiceprint characteristics on the device before controlling the device. After that, the device can determine whether the current user is allowed to control the device by judging whether the voice feature of the current user matches the voiceprint feature.
  • the device will provide a sentence to the user. The user needs to clearly speak the sentence to the device and repeat the sentence 10 times.
  • the device obtains the 10 voice data according to the received 10 voice data.
  • a voice feature corresponding to a piece of voice data is used to generate a voiceprint feature based on the 10 voice features.
  • the embodiments of the present disclosure can be applied to the scenario of performing voiceprint feature registration.
  • the embodiments of the present disclosure acquire multiple pieces of historical voice data, and extract the user’s voiceprint features from multiple pieces of historical voice data.
  • the method provided in the embodiments of the present disclosure can be applied to computer equipment.
  • the computer equipment can be a terminal with applications installed such as a mobile phone, a computer, or a tablet.
  • the terminal user may generate voice data when using the terminal. .
  • the terminal can save the voice data generated by the user during use, as historical voice data, the terminal extracts the voiceprint characteristics of the terminal user through the historical voice data.
  • FIG. 1 is a schematic diagram of an implementation environment provided by an embodiment of the present disclosure. Referring to FIG. 1, the implementation environment includes: a terminal 101 and a server 102.
  • each voice feature cluster includes voice features belonging to the same voice source.
  • the voiceprint feature registration method obtains voice features corresponding to multiple pieces of historical voice data, and divides the acquired multiple voice features based on whether the voice features belong to the same voice source, to obtain at least one voice feature cluster; Based on the conditions satisfied by the voice data of the terminal user, the user's voice feature cluster is filtered out of at least one voice feature cluster, and the voice feature cluster of the terminal user is generated according to the user voice feature cluster, which realizes the automatic acquisition of the user's voice feature.
  • voiceprint registration is performed, there is no need for users to input voice data, which simplifies user operations, speeds up registration time, and improves registration efficiency.
  • the user’s voice feature clusters are filtered from at least one voice feature cluster based on the first reference condition, which ensures that the voiceprint features generated based on the user’s voice feature cluster belong to the end user, avoids the interference of other users’ voiceprint features, and ensures The accuracy of voiceprint registration is improved.
  • multiple pieces of historical voice data include the first type (near) historical voice data and the second type (distant) historical voice data, and the generated voiceprint characteristics can both Represents the characteristics of distant voice data, and can also represent the characteristics of nearby voice data.
  • selecting a voice feature cluster satisfying the first reference condition from the at least one voice feature cluster as a user voice feature cluster includes at least one of the following steps:
  • a voice feature cluster that meets the data source condition is selected as the user voice feature cluster.
  • the data source condition is that the number of data sources of the user voice feature cluster is greater than the number of data sources of other voice feature clusters.
  • the data source of the feature cluster is the source of the voice data corresponding to the voice feature in the voice feature cluster;
  • the time distribution condition is that the number of time periods of the user voice feature cluster is greater than the number of time periods of other voice feature clusters, and the voice The time period of the feature cluster is the time period to which the voice data corresponding to the voice feature in the voice feature cluster belongs.
  • the selecting a voice feature cluster satisfying the first reference condition from the at least one voice feature cluster as the user voice feature cluster includes:
  • a voice feature cluster satisfying the first reference condition and the second reference condition is selected as the user voice feature cluster; the second reference condition is used to indicate the conditions satisfied by the attributes of the user voice feature cluster .
  • the first reference condition is used to indicate a condition satisfied by the description information of the voice data of the terminal user, and the obtaining of voice features corresponding to multiple pieces of historical voice data includes:
  • the method further includes:
  • the voice features corresponding to the second type of historical voice data are discarded.
  • generating the second voiceprint feature based on the second type of historical voice data includes: discarding the voice features that do not match the first voiceprint feature among the voice features corresponding to the second type of historical voice data, Obtain the voice feature matching the first voiceprint feature; generate the second voiceprint feature according to the voice feature matching the first voiceprint feature.
  • generating the voiceprint feature of the terminal user according to the voice feature in the user's voice feature cluster includes any of the following steps:
  • the user's voiceprint model is trained, and the trained user's voiceprint model is used as the voiceprint feature.
  • the method further includes:
  • different sources of historical voice data indicate that the historical voice data comes from different files.
  • the terminal can obtain historical voice data of an application.
  • the application may include multiple pieces of historical voice data.
  • the data is stored in different files.
  • the voice data sent by the terminal user is acquired. In this way, on the basis of ensuring the accuracy of the voiceprint feature, it can also reduce the amount of historical voice data acquired, thereby reducing the amount of calculation of the terminal. Improved the registration speed.
  • the terminal can also obtain historical voice data of multiple applications.
  • the embodiments of the present disclosure are concerned with how to obtain historical voice data and which applications to obtain.
  • the historical voice data in is not limited. In the embodiments of the present disclosure, only the acquisition of multiple pieces of historical voice data is used as an example for description. The acquisition of multiple pieces of historical voice data can more comprehensively obtain the voiceprint characteristics of the terminal user, and make the registration result more accurate.
  • the target historical voice data may also be acquired.
  • the target historical voice data may be voice data that the terminal user can pronounce clearly. For example, when the terminal user unlocks the terminal through the voice data, the terminal acquires the voice data of the terminal user.
  • step 202 may include: the terminal separately determines whether the multiple pieces of historical voice data are the first type of historical voice data or the second type of historical voice data according to the data sources of the multiple pieces of historical voice data, where the data source is used for Indicates the method of obtaining the historical voice data.
  • the historical voice data may be divided into the first type of historical voice data and the second type of historical voice data by the server.
  • the server can be divided according to the data source.
  • the data source can refer to different applications as shown in the terminal embodiment.
  • the data source can also indicate the terminal type. According to the user's habits of using different terminals, the historical voice data can be divided into The first type of historical voice data and the second type of historical voice data.
  • the historical voice data collected by the mobile phone can be the first type of historical voice data;
  • the space in the vehicle is large, and the terminal user will input voice data at his own location, which is far away from the vehicle terminal. Therefore, the historical voice data collected by the vehicle terminal is the second type of historical voice data.
  • the embodiment of the present disclosure There is no limitation on the form of how the server divides the first type of historical voice data and the second type of historical voice data.
  • the method for acquiring the first voice feature by the terminal is similar to that for acquiring the second voice feature.
  • the terminal acquires the voice feature corresponding to the historical voice data.
  • the method for obtaining the first voice feature and the second voice feature is similar to the method for obtaining the voice feature corresponding to the historical voice data.
  • the speech feature extraction model can be obtained through sample training, and the training process can be: prepare a large amount of speech data, and label these speech data according to the MFCC (Mel-Frequency Cepstrum Coefficients, Mel frequency cepstrum coefficients) of the speech data.
  • the annotated speech data is input into the acoustic model for training, and the trained speech feature extraction model is obtained.
  • the terminal may also preprocess multiple pieces of historical voice data first, and obtain voice features corresponding to the multiple pieces of historical voice data based on the multiple pieces of processed historical voice data. That is, the above step 303 may include step 3031 and step 3032.
  • the preprocessing process may include at least one of the following steps:
  • the historical voice data is dual-channel voice data
  • separate the historical voice data to obtain left historical voice data and right historical voice data, where the left historical voice data and the right historical voice data are both monophonic Voice data.
  • the process of segmenting multiple pieces of historical voice data may include: moving a window containing a fixed number of frames to segment the monophonic voice data.
  • the embodiment of the present disclosure does not limit the segmentation method.
  • the invalid historical voice data can be noise data, mute data, and so on.
  • the preprocessing process may include any one or more steps described above, and the embodiment of the present disclosure does not limit the preprocessing process.
  • the process of preprocessing multiple pieces of historical voice data by the terminal includes the above four steps: when multiple pieces of historical voice data include two-channel historical voice data, The two-channel historical voice data is separated and processed to obtain two single-channel historical voice data, and the two single-channel historical voice data are left historical voice data and right historical voice data. Split multiple pieces of monophonic historical voice data to obtain multiple pieces of historical voice data containing the target number of frames, filter multiple pieces of historical voice data, and discard invalid pieces of historical voice data. According to the description information of each historical voice data, the corresponding relationship between each historical voice data segment and the description information of the historical voice data to which it belongs is established.
  • the terminal divides the multiple first voice features to obtain at least one first voice feature cluster, and each first voice feature cluster includes voice features belonging to the same voice source.
  • the classification condition is the similarity between voice features
  • the terminal clusters the acquired multiple first voice features to obtain at least one first voice feature cluster.
  • embodiments of the present disclosure only use clustering as an example to describe the division of multiple voice features.
  • voice features can also be classified by other classification criteria.
  • the embodiments of the present disclosure classify voice features.
  • the standard is not limited.
  • the multiple pieces of historical voice data are acquired, and the multiple pieces of historical voice data include the first type of historical voice data and the second type of historical voice data; the voice features corresponding to the multiple pieces of historical voice data are acquired, and among the acquired voice features
  • the first voice feature may be included, and the second voice feature may also be included.
  • the multiple acquired voice features can be directly divided to obtain at least one voice feature cluster, and each voice feature cluster includes voice features belonging to the same voice source; Select a voice feature cluster that satisfies the first reference condition from the at least one voice feature cluster as a user voice feature cluster.
  • the first reference condition is used to indicate the conditions satisfied by the voice data of the terminal user; Voice features, generating voiceprint features of the end user.
  • a larger target number threshold is used to cluster multiple voice features to obtain at least one voice feature cluster, so that the user The first voice feature and the second voice feature of are clustered into a user voice feature cluster. Therefore, a voice feature cluster that meets the first reference condition is selected from the at least one voice feature cluster as a user voice feature cluster.
  • the user voice feature cluster includes the first voice feature and the second voice feature, based on the user voice feature At least two voice features in the cluster generate the voiceprint feature of the end user.
  • two voice feature clusters satisfying the first reference condition are selected from the at least two voice feature clusters as the first user voice feature cluster and the second user voice feature cluster, and the first user voice feature cluster includes at least one The first voice feature, and the second voice feature cluster includes at least one second voice feature, based on at least one first voice feature in the first user voice feature cluster and at least one second voice feature in the second user voice feature cluster, Generate the voiceprint characteristics of the end user.
  • the first reference condition is used to indicate the condition satisfied by the voice data of the terminal user.
  • the second reference condition is used to indicate the conditions satisfied by the attributes of the user's voice feature cluster.
  • the historical voice data may also include voice data of other sound sources. However, since the amount of voice data of other sound sources is small, the number of corresponding voice features is also small.
  • the terminal may obtain the number of voice features of each first voice feature cluster, and when the number of first voice features of any first voice feature cluster is less than the reference number, the first voice feature cluster is discarded.
  • the terminal may also obtain the voice data of other users, but it is difficult for the applications on the terminal to obtain the voice data of other users.
  • the terminal when a terminal user uses the terminal, when contacting others by phone, the terminal records the content of the call.
  • the voice data obtained through the recording includes not only the voice data of the terminal user, but also the voice data of the contact person.
  • an instant messaging application is also installed on the terminal. If the terminal user does not contact the contact through the instant messaging application, the instant messaging application does not include the voice data of the contact.
  • the process of determining the description information corresponding to the first voice feature may further include: determining the first type of historical voice data segment corresponding to the first voice feature according to the first voice feature, and obtaining the description information corresponding to the first type of historical voice data segment ,
  • the description information is the description information corresponding to the first voice feature.
  • the first reference condition may also include multiple conditions, and the multiple conditions may include data source conditions and time distribution conditions, and may also include other conditions.
  • the method of obtaining the first user's voice feature cluster adopts a weighted average method, and the method may include the following steps: the terminal assigns a weight value to each condition, and for any voice feature cluster in at least one first voice feature cluster, each voice feature cluster is obtained. Under two conditions, the score corresponding to the first voice feature cluster; according to the weight value of each condition, weighting is performed to obtain the processed score of the first voice feature cluster, according to the processed score from large to small In order, the at least one first voice feature cluster is sorted, and the first voice feature cluster located in the first position is selected as the first user voice feature cluster.
  • a first voice feature cluster is sorted, and the first voice feature cluster at the first position is selected as the first user voice feature cluster.
  • an implementation manner for the terminal to score the second voice feature corresponding to the second type of historical voice data may include: the terminal inputs the first voiceprint feature and the second voice feature into the PLDA scoring model, The score value of the voice feature corresponding to the second type of historical voice data is obtained through the PLDA score model.
  • the terminal divides the screened voice features of the terminal users to obtain at least one second voice feature cluster, and each second voice feature cluster includes second voice features belonging to the same voice source.
  • the terminal can establish an association relationship between the first voiceprint feature and the user information of the terminal user, or after acquiring the second voiceprint feature, establish an association relationship.
  • the embodiments of the present disclosure do not limit the timing of establishing an association relationship.
  • the voiceprint feature registration method obtains voice features corresponding to multiple pieces of historical voice data, and divides the acquired multiple voice features based on whether the voice features belong to the same voice source, to obtain at least one voice feature cluster; Based on the conditions satisfied by the voice data of the terminal user, the user's voice feature cluster is filtered out of at least one voice feature cluster, and the voice feature cluster of the terminal user is generated according to the user voice feature cluster, which realizes the automatic acquisition of the user's voice feature.
  • voiceprint registration is performed, there is no need for users to input voice data, which simplifies user operations, speeds up registration time, and improves registration efficiency.
  • the user’s voice feature clusters are filtered from at least one voice feature cluster based on the first reference condition, which ensures that the voiceprint features generated based on the user’s voice feature cluster belong to the end user, avoids the interference of other users’ voiceprint features, and ensures The accuracy of voiceprint registration is improved.
  • the multiple pieces of historical voice data are divided into the first type (near) historical voice data and the second type (distant) historical voice data, and the generated voiceprint characteristics It can represent both the characteristics of distant voice data and the characteristics of nearby voice data.
  • the voice data input by the user is analyzed, it can accurately identify whether the user is a terminal user, and avoid the recognition failure due to the difference between far and near sounds The problem.
  • voice feature clusters before acquiring voice features, historical voice data will be preprocessed to remove invalid data, so as to reduce the amount of subsequent calculations.
  • voice feature clusters before the voice feature clusters are screened by the first reference condition, the voice feature clusters can also be briefly screened by the second reference condition, so as to reduce the amount of calculation when screening by the first reference condition and improve registration. Speed and registration efficiency.
  • this embodiment can also not divide multiple pieces of historical voice data into the first type of historical voice data and the second type of historical voice data, but directly obtain the voice features corresponding to the multiple pieces of historical voice data.
  • this embodiment can also not divide multiple pieces of historical voice data into the first type of historical voice data and the second type of historical voice data, but directly obtain the voice features corresponding to the multiple pieces of historical voice data.
  • to obtain the voice features corresponding to multiple pieces of historical voice data please refer to the process of obtaining multiple first voice features corresponding to the first type of historical voice data in 303, or refer to the process of obtaining the second type of historical voice data in 303. The process of multiple second voice features.
  • a voice feature cluster meeting a first reference condition from at least one voice feature cluster as a user voice feature cluster where the first reference condition includes at least one of the largest number of data sources and the largest number of time periods, any voice feature
  • the data source of the cluster is the source of the voice data corresponding to the voice feature in any voice feature cluster
  • the time period of any voice feature cluster is the time period to which the voice data corresponding to the voice feature in any voice feature cluster belongs.
  • the obtaining module 1002 is used to obtain the voice features corresponding to the multiple pieces of historical voice data
  • the generating module 1005 is used to generate the voiceprint feature of the terminal user according to the voice feature in the voice feature cluster of the user.
  • the user’s voice feature clusters are filtered from at least one voice feature cluster based on the first reference condition, which ensures that the voiceprint features generated based on the user’s voice feature cluster belong to the end user, avoids the interference of other users’ voiceprint features, and ensures The accuracy of voiceprint registration is improved.
  • multiple pieces of historical voice data include the first type (near) historical voice data and the second type (distant) historical voice data, and the generated voiceprint characteristics can both Represents the characteristics of distant voice data, and can also represent the characteristics of nearby voice data.
  • the selection module 1004 includes at least one of the following units:
  • the selecting module 1004 is further configured to select a voice feature cluster satisfying the first reference condition and the second reference condition from the at least one voice feature cluster, as the user voice feature cluster;
  • the second reference condition is used to indicate the conditions satisfied by the attributes of the user's voice feature cluster.
  • the first reference condition is used to indicate a condition satisfied by the description information of the voice data of the terminal user, and the obtaining module 1002 includes:
  • the matching module 1007 is configured to discard the voice features that do not match the first voiceprint feature among the voice features corresponding to the second type of historical voice data.
  • the wireless communication protocol includes but is not limited to: metropolitan area network, various generations of mobile communication networks (2G, 3G, 4G, and 5G), wireless local area network and/or WiFi (Wireless Fidelity, wireless fidelity) network.
  • the radio frequency circuit 1204 may also include a circuit related to NFC (Near Field Communication), which is not limited in this application.
  • the display screen 1205 is used to display UI (User Interface).
  • the UI can include graphics, text, icons, videos, and any combination thereof.
  • the display screen 1205 also has the ability to collect touch signals on or above the surface of the display screen 1205.
  • the touch signal can be input to the processor 1201 as a control signal for processing.
  • the display screen 1205 may also be used to provide virtual buttons and/or virtual keyboards, also called soft buttons and/or soft keyboards.
  • the audio circuit 1207 may include a microphone and a speaker.
  • the microphone is used to collect sound waves from the user and the environment, convert the sound waves into electrical signals and input them to the processor 1201 for processing, or input to the radio frequency circuit 1204 to implement voice communication. For the purpose of stereo collection or noise reduction, there may be multiple microphones, which are respectively set in different parts of the terminal 1200.
  • the microphone can also be an array microphone or an omnidirectional collection microphone.
  • the speaker is used to convert the electrical signal from the processor 1201 or the radio frequency circuit 1204 into sound waves.
  • the speaker can be a traditional thin-film speaker or a piezoelectric ceramic speaker.
  • the pressure sensor 1213 may be disposed on the side frame of the terminal 1200 and/or the lower layer of the touch display screen 1205.
  • the processor 1201 performs left and right hand recognition or quick operation according to the holding signal collected by the pressure sensor 1213.
  • the processor 1201 controls the operability controls on the UI interface according to the user's pressure operation on the touch display screen 1205.
  • the operability control includes at least one of a button control, a scroll bar control, an icon control, and a menu control.

Landscapes

  • Engineering & Computer Science (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Physics & Mathematics (AREA)
  • Acoustics & Sound (AREA)
  • Multimedia (AREA)
  • Computational Linguistics (AREA)
  • Signal Processing (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Telephonic Communication Services (AREA)
  • Telephone Function (AREA)

Abstract

一种声纹特征注册方法及装置,该方法包括:获取多条历史语音数据,多条历史语音数据包括第一类历史语音数据和第二类历史语音数据;第二类历史语音数据的语音源与终端之间的距离大于第一类历史语音数据的语音源与终端之间的距离(201);获取多条历史语音数据对应的语音特征(202);对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征(203);从至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,第一参考条件用于指示终端用户的语音数据所满足的条件(204);根据用户语音特征簇中的语音特征,生成终端用户的声纹特征(205)。

Description

声纹特征注册
本公开要求于2019年09月19日提交的申请号为201910887744.2、申请名称为“声纹特征注册方法、装置、计算机设备及存储介质”的中国专利申请的优先权,其全部内容通过引用结合在本公开中。
技术领域
本公开涉及计算机技术领域,特别涉及一种声纹特征注册方法、装置、计算机设备及存储介质。
背景技术
随着语音处理技术的发展,越来越多的计算机设备用到了语音处理技术。用户可以通过语音数据控制设备执行相应地操作,例如,语音开锁、语音支付等。而用户在控制设备之前需要在设备上注册用户的声纹特征。之后,设备即可通过判断当前用户的语音特征与声纹特征是否匹配,确定是否允许当前用户控制该设备。
发明内容
本公开实施例提供了一种声纹特征注册。该技术方案如下:
一方面,提供了一种声纹特征注册方法,该方法包括:
获取多条历史语音数据,所述多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,所述第二类历史语音数据的语音源与终端之间的距离大于所述第一类历史语音数据的语音源与所述终端之间的距离;
获取所述多条历史语音数据对应的语音特征;
对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件用于指示终端用户的语音数据所满足的条件;
根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
在一种可能实现方式中,所述从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括下述至少一个步骤:
从所述至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为所述用户语音特征簇,所述数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,所述语音特征簇的数据来源为所述语音特征簇中的语音特征对应的语音数据的来源;
从所述至少一个语音特征簇中选取满足时间分布条件的语音特征簇,作为所述用户语音特征簇,所述时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,所述语音特征簇的时间段为所述语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
在一种可能实现方式中,所述从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括:
从所述至少一个语音特征簇中选取满足所述第一参考条件和第二参考条件的语音特征簇,作为所述用户语音特征簇;所述第二参考条件用于指示用户语音特征簇的属性所满足的条件。
在一种可能实现方式中,所述第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,所述获取多条历史语音数据对应的语音特征,包括:
对所述多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
获取每个历史语音数据片段对应的语音特征。
在一种可能实现方式中,所述方法还包括:
如果基于所述第一类历史语音数据生成第一声纹特征,且基于所述第二类历史语音数据生成第二声纹特征,则建立所述第一声纹特征与所述终端的用户信息的关联关系和所述第二声纹特征与所述终端的用户信息的关联关系。
在一种可能实现方式中,在所述基于所述第一类历史语音数据生成第一声纹特征,且获取到所述第二类历史语音数据对应的语音特征之后,所述方法还包括:
将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃。
在一种可能的实现方式中,所述基于所述第二类历史语音数据生成第二声纹特征,包 括:将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃,得到与所述第一声纹特征匹配的语音特征;根据所述与所述第一声纹特征匹配的语音特征生成所述第二声纹特征。
在一种可能实现方式中,所述根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征,包括下述任一步骤:
将所述用户语音特征簇中的多个语音特征合并为一个语音特征,作为所述声纹特征;
从所述用户语音特征簇中选取一个语音特征,作为所述声纹特征,所述选取的语音特征与簇中心的距离小于所述用户语音特征簇中的其他语音特征与所述簇中心的距离;
根据所述用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为所述声纹特征。
一方面,提供了一种声纹特征注册方法,该方法包括:
获取多条历史语音数据;
获取所述多条历史语音数据对应的语音特征;
对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为所述任一个语音特征簇中语音特征对应的语音数据的来源,任一个语音特征簇的时间段为所述任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段;
根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
一方面,提供了一种声纹特征注册装置,该装置包括:
第一划分模块,用于获取多条历史语音数据,所述多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,所述第二类历史语音数据的语音源与终端之间的距离大于所述第一类历史语音数据的语音源与所述终端之间的距离;
获取模块,用于获取所述多条历史语音数据对应的语音特征;
第二划分模块,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
选取模块,用于从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件用于指示终端用户的语音数据所满足的条件;
生成模块,用于根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
在一种可能实现方式中,所述选取模块包括下述至少一个单元:
第一选取单元,用于从所述至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为所述用户语音特征簇,所述数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,所述语音特征簇的数据来源为所述语音特征簇中的语音特征对应的语音数据的来源;
第二选取单元,用于从所述至少一个语音特征簇中选取满足时间分布条件的语音特征簇,作为所述用户语音特征簇,所述时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,所述语音特征簇的时间段为所述语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
在一种可能实现方式中,所述选取模块,还用于从所述至少一个语音特征簇中选取满足所述第一参考条件和第二参考条件的语音特征簇,作为所述用户语音特征簇;所述第二参考条件用于指示用户语音特征簇的属性所满足的条件。
在一种可能实现方式中,所述第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,所述获取模块包括:
切分单元,用于对所述多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
关系建立单元,用于建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
获取单元,用于获取每个历史语音数据片段对应的语音特征。
在一种可能实现方式中,所述装置还包括:
关联关系建立模块,用于如果基于所述第一类历史语音数据生成第一声纹特征,且基于所述第二类历史语音数据生成第二声纹特征,则建立所述第一声纹特征与所述终端的用户信息的关联关系和所述第二声纹特征与所述终端的用户信息的关联关系。
在一种可能实现方式中,所述装置还包括:
匹配模块,用于将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃。
在一种可能的实现方式中,所述关联关系建立模块,用于将所述第二类历史语音数据 对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃,得到与所述第一声纹特征匹配的语音特征;根据所述与所述第一声纹特征匹配的语音特征生成所述第二声纹特征。
在一种可能实现方式中,所述生成模块包括下述任一单元;
合并单元,用于将所述用户语音特征簇中的多个语音特征合并为一个语音特征,作为所述声纹特征;
选取单元,用于从所述用户语音特征簇中选取一个语音特征,作为所述声纹特征,所述选取的语音特征与簇中心的距离小于所述用户语音特征簇中的其他语音特征与所述簇中心的距离;
训练单元,用于根据所述用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为所述声纹特征。
一方面,提供了一种声纹特征注册装置,该装置包括:
获取模块,用于获取多条历史语音数据,获取所述多条历史语音数据对应的语音特征;
划分模块,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
选取模块,用于从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为所述任一个语音特征簇中语音特征对应的语音数据的来源,任一个语音特征簇的时间段为所述任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段;
生成模块,用于根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
一方面,提供了一种终端,所述终端包括一个或多个处理器和一个或多个存储器,所述一个或多个存储器中存储有至少一条指令,所述至少一条指令由所述一个或多个处理器加载并执行以实现如上述任一种可能实现方式所述的声纹特征注册方法所执行的操作。
一方面,提供了一种服务器,所述服务器包括一个或多个处理器和一个或多个存储器,所述一个或多个存储器中存储有至少一条指令,所述至少一条指令由所述一个或多个处理器加载并执行以实现如上述任一种可能实现方式所述的声纹特征注册方法所执行的操作。
一方面,提供了一种计算机可读存储介质,所述存储介质中存储有至少一条指令,所述至少一条指令由处理器加载并执行以实现如上述任一种可能实现方式所述的声纹特征注册方法所执行的操作。
本公开实施例提供的技术方案带来的有益效果至少包括:
本公开实施例提供的声纹特征注册方法、装置、计算机设备及存储介质,通过获取多条历史语音数据对应的语音特征,基于语音特征是否属于同一语音源对获取到的多个语音特征进行划分,得到至少一个语音特征簇;基于终端用户的语音数据所满足的条件,在至少一个语音特征簇中筛选出用户语音特征簇,根据用户语音特征簇来生成终端用户的声纹特征,实现了自动获取用户的声纹特征,在进行声纹注册时,无需用户输入语音数据,简化了用户操作,加快了注册时间,提高了注册效率。
另外,通过第一参考条件从至少一个语音特征簇中筛选出用户语音特征簇,保证了基于用户语音特征簇生成的声纹特征是终端用户的,避免了其他用户的声纹特征的干扰,确保了声纹注册的准确性。还考虑到了终端用户距离终端远近不一带来的声音差异,多条历史语音数据包括第一类(近处)历史语音数据和第二类(远处)历史语音数据,生成的声纹特征既能代表远处语音数据的特征,也能代表近处语音数据的特征,对用户输入的语音数据进行分析时,能够准确地识别用户是否为终端用户,避免了由于远近声音的差异导致识别失败的问题。
附图说明
为了更清楚地说明本公开实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本公开的一些实施例,对于本领域普通技术人员来讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的附图。
图1是本公开实施例提供的一种实施环境的示意图;
图2是本公开实施例提供的一种声纹特征注册方法的流程图;
图3是本公开实施例提供的一种声纹注册方法的流程图;
图4是本公开实施例提供的一种预处理方法的流程图;
图5是本公开实施例提供的一种提取语音特征方法的流程图;
图6是本公开实施例提供的一种聚类方法的流程图;
图7是本公开实施例提供的一种筛选第二语音特征方法的流程图;
图8是本公开实施例提供的一种生成声纹特征方法的流程图;
图9是本公开实施例提供的一种声纹注册方法的流程图;
图10是本公开实施例提供的一种声纹注册装置的结构图;
图11是本公开实施例提供的一种声纹注册装置的结构图;
图12是本公开实施例提供的终端的结构示意图;
图13是本公开实施例提供的计算机设备的结构示意图。
具体实施方式
为使本公开实施例的目的、技术方案和优点更加清楚,下面将结合附图对本公开实施方式作进一步地详细描述。
随着语音处理技术的发展,越来越多的计算机设备用到了语音处理技术。用户可以通过语音数据控制设备执行相应地操作,例如,语音开锁、语音支付等。而用户在控制设备之前需要在设备上注册用户的声纹特征。之后,设备即可通过判断当前用户的语音特征与声纹特征是否匹配,确定是否允许当前用户控制该设备。目前,进行声纹特征注册时,设备会向用户提供一个语句,用户需要清晰地对设备说出该语句,且重复说出该语句10次,设备根据接收到的10条语音数据,获取该10条语音数据对应的语音特征,根据该10个语音特征生成声纹特征。
本公开实施例可以应用于进行声纹特征注册的场景下,本公开实施例在进行声纹特征注册时,会获取多条历史语音数据,从多条历史语音数据中提取出用户的声纹特征。本公开实施例提供的方法可以应用于计算机设备中,在一种可能实现方式中,计算机设备可以为手机、电脑、平板电脑等安装有应用的终端,终端用户在使用终端时可能会生成语音数据。终端可以保存用户在使用过程中生成的语音数据,作为历史语音数据,终端通过历史语音数据来提取终端用户的声纹特征。
在另一种可能实现方式中,计算机设备还可以是与终端上安装的应用相关的服务器。图1是本公开实施例提供的一种实施环境的示意图,参见图1,该实施环境包括:终端101和服务器102。
该终端101可以为手机、电脑、平板电脑等安装有应用或者具有安装应用功能的终端,该服务器102可以是一台服务器,也可以是若干台服务器组成的服务器集群,或者是一个云计算服务中心。
终端101可以将历史语音数据上传至服务器102中,终端101可以在历史语音数据生成时上传,也可以在进行声纹注册时上传,还可以每隔参考时间上传一次,本公开实施例对历史语音数据的上传时机不做限定。服务器102根据终端101上传的历史语音数据提取终端用户的声纹特征。
图2是本公开实施例提供的一种声纹特征注册方法的流程图。参见图2,该实施例包括:
201、获取多条历史语音数据,该多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,该第二类历史语音数据的语音源与终端之间的距离大于该第一类历史语音数据的语音源与该终端之间的距离。
202、获取多条历史语音数据对应的语音特征。
203、对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征。
204、从该至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,该第一参考条件用于指示终端用户的语音数据所满足的条件。
205、根据该用户语音特征簇中的语音特征,生成该终端用户的声纹特征。
本公开实施例提供的声纹特征注册方法,通过获取多条历史语音数据对应的语音特征,基于语音特征是否属于同一语音源对获取到的多个语音特征进行划分,得到至少一个语音特征簇;基于终端用户的语音数据所满足的条件,在至少一个语音特征簇中筛选出用户语音特征簇,根据用户语音特征簇来生成终端用户的声纹特征,实现了自动获取用户的声纹特征,在进行声纹注册时,无需用户输入语音数据,简化了用户操作,加快了注册时间,提高了注册效率。另外,通过第一参考条件从至少一个语音特征簇中筛选出用户语音特征簇,保证了基于用户语音特征簇生成的声纹特征是终端用户的,避免了其他用户的声纹特征的干扰,确保了声纹注册的准确性。还考虑到了终端用户距离终端远近不一带来的声音差异,多条历史语音数据包括第一类(近处)历史语音数据和第二类(远处)历史语音数据,生成的声纹特征既能代表远处语音数据的特征,也能代表近处语音数据的特征,对用户输入的语音数据进行分析时,能够准确地识别用户是否为终端用户,避免了由于远近声音的差异导致识别失败的问题。
在一种可能实现方式中,从该至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括下述至少一个步骤:
从该至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为该用户语音特征簇,该数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,该语音特征簇的数据来源为该语音特征簇中的语音特征对应的语音数据的来源;
从该至少一个语音特征簇中选取满足时间分布条件的语音特征簇,作为该用户语音特 征簇,该时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,该语音特征簇的时间段为该语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
在一种可能实现方式中,该从该至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括:
从该至少一个语音特征簇中选取满足该第一参考条件和第二参考条件的语音特征簇,作为该用户语音特征簇;该第二参考条件用于指示用户语音特征簇的属性所满足的条件。
在一种可能实现方式中,该第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,该获取多条历史语音数据对应的语音特征,包括:
对该多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
获取每个历史语音数据片段对应的语音特征。
在一种可能实现方式中,该方法还包括:
如果基于该第一类历史语音数据生成第一声纹特征,且基于该第二类历史语音数据生成第二声纹特征,则建立该第一声纹特征与该终端的用户信息的关联关系和该第二声纹特征与该终端的用户信息的关联关系。
在一种可能实现方式中,在该基于该第一类历史语音数据生成第一声纹特征,且获取到该第二类历史语音数据对应的语音特征之后,该方法还包括:
将该第二类历史语音数据对应的语音特征中,与该第一声纹特征不匹配的语音特征丢弃。
在一种可能实现方式中,基于第二类历史语音数据生成第二声纹特征,包括:将第二类历史语音数据对应的语音特征中,与第一声纹特征不匹配的语音特征丢弃,得到与第一声纹特征匹配的语音特征;根据与第一声纹特征匹配的语音特征生成第二声纹特征。
在一种可能实现方式中,该根据该用户语音特征簇中的语音特征,生成该终端用户的声纹特征,包括下述任一步骤:
将该用户语音特征簇中的多个语音特征合并为一个语音特征,作为该声纹特征;
从该用户语音特征簇中选取一个语音特征,作为该声纹特征,该选取的语音特征与簇中心的距离小于该用户语音特征簇中的其他语音特征与该簇中心的距离;
根据该用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为该声纹特征。
在一种可能实现方式中,在该根据该用户语音特征簇中的语音特征,生成该终端用户的声纹特征之后,该方法还包括:
建立该声纹特征与该终端用户的用户信息之间的绑定关系。
上述所有可选技术方案,可以采用任意结合形成本公开的可选实施例,在此不再一一赘述。
图3是本公开实施例提供的一种声纹注册方法的流程图。参见图3,本实施例以执行主体为终端为例进行说明,该实施例包括:
301、当终端接收到声纹注册指令时,获取多条历史语音数据。
终端用户在使用终端时,可能会生成语音数据,终端可以将生成的语音数据保存在本地,作为历史语音数据。例如,该历史语音数据为终端用户使用即时通信应用向其他用户发送的语音消息,或者,终端用户通过电话联系其他用户时,生成的电话录音等。
在终端的任一应用中,当用户想要注册声纹特征时,可以通过点击操作、触摸操作或者滑动操作来触发声纹注册指令,本公开实施例对如何触发声纹注册指令不做限定,另外,本公开实施例对终端用户是在第三方应用中触发声纹注册指令,还是在系统应用中触发声纹注册指令不做限定。
当终端接收到声纹注册指令时,终端可以获取多条历史语音数据,该多条历史语音数据的来源可以不同。在一种可能实现方式中,历史语音数据的来源不同指示历史语音数据来源于不同的应用,终端可以获取多个应用的历史语音数据。当终端获取多个应用的历史语音数据时,获取到的历史语音数据中可能包括大量的终端用户的语音数据和少量的其他语音源的语音数据,如其他用户、外界环境中存在的噪音源等,对该历史语音数据进行分析,能够区分终端用户的语音数据和其他语音源的语音数据,还能够更加全面地获取到终端用户的声纹特征,使得注册结果更加准确。
在另一种可能实现方式中,历史语音数据的来源不同指示历史语音数据来源于不同的文件,终端可以获取一个应用的历史语音数据,该应用中可以包括多条历史语音数据,每条历史语音数据存储在不同的文件内。例如,在一个即时通信应用中获取终端用户发送的语音数据,这样,在保证了声纹特征的准确性的基础上,还能够减少获取的历史语音数据的数量,进而减少了终端的计算量,提高了注册速度。
需要说明的是,当历史语音数据的来源不同指示历史语音数据来源于不同的文件时,终端也可以获取多个应用的历史语音数据,本公开实施例对如何获取历史语音数据,以及 获取哪些应用中的历史语音数据不做限定。在本公开实施例中,仅是以获取多条历史语音数据为例进行说明,获取多条历史语音数据可以更加全面地获取到终端用户的声纹特征,使得注册结果更加准确。在一些实施例中,还可以获取目标历史语音数据,该目标历史语音数据可以为终端用户发音较为清楚的语音数据,例如,终端用户在通过语音数据解锁终端时,终端获取终端用户的语音数据,将其作为历史语音数据,对该历史语音数据进行处理,得到终端用户的声纹特征,在保证声纹特征的准确性的基础上,能够快速地获取终端用户的声纹特征,减少了终端的计算量,加快了注册速度,提高了注册效率。
需要说明的是,本公开实施例所涉及的历史语音数据可以为经用户授权或者经过各方充分授权的数据。
302、终端将多条历史语音数据分为第一类历史语音数据和第二类历史语音数据,第二类历史语音数据的语音源与终端之间的距离大于第一类历史语音数据的语音源与终端之间的距离。
终端用户在输入语音数据时,距离终端远近不同,可能会带来声音差异,因此,可以将历史语音数据分为第一类(近处)历史语音数据和第二类(远处)历史语音数据,分别根据第一类历史语音数据和第二类历史语音数据,生成声纹特征。
终端用户在使用不同的应用时,可能因为该应用的特点,终端用户输入语音数据时与终端的距离不同。例如,当该历史语音数据的数据来源为电话录音时,由于终端用户在使用电话时,均是将电话放在耳边,此时,终端用户的嘴巴与终端的距离较近,该历史语音数据为第一类历史语音数据;当该历史语音数据的数据来源为智能交互应用时,终端用户通过智能交互应用向终端输入语音数据时,大部分情况下,终端用户会看着显示屏幕,此时,终端用户的嘴巴距离终端相对较远,该历史语音数据为第二类历史语音数据。
因此,步骤202的实现方式可以包括:终端根据多条历史语音数据的数据来源,分别确定该多条历史语音数据为第一类历史语音数据还是第二类历史语音数据,其中,数据来源用于指示获取该历史语音数据的方式。
另外,终端用户在向终端输入语音数据时,若终端用户距离终端较近,则终端接收到的语音数据的能量较大;若终端用户距离终端较远,则终端接收到的语音数据的能量较小。因此,终端可以根据多条历史语音数据中语音的能量大小,来确定该历史语音数据是第一类历史语音数据还是第二类历史语音数据。步骤302的实现方式还可以包括:当语音的能量小于目标能量阈值时,确定该历史语音数据为第二类历史语音数据;当语音的能量不小于目标能量阈值时,确定该历史语音数据为第一类历史语音数据。
需要说明的是,本公开实施例仅是以终端为例进行说明,在一些实施例中,可以由服务器将历史语音数据分为第一类历史语音数据和第二类历史语音数据。其中,服务器可以按照数据来源进行划分,该数据来源可以如终端实施例中所示指代不同的应用,该数据来源也可以指示终端类型,根据用户使用不同终端的习惯,将历史语音数据划分为第一类历史语音数据和第二类历史语音数据。例如,终端为手机时,由于终端用户使用手机时,会将手机握在手中,终端用户与手机的距离较近,因此手机收集的历史语音数据可以为第一类历史语音数据;当终端为车载终端时,车内空间较大,终端用户会在自己的位置上输入语音数据,与车载终端的距离较远,因此,车载终端收集的历史语音数据为第二类历史语音数据,本公开实施例对服务器如何划分第一类历史语音数据和第二类历史语音数据的形式不做限定。
303、终端获取第一类历史语音数据对应的多个第一语音特征和第二类历史语音数据对应的多个第二语音特征。
其中,第一类历史语音数据可以是一条语音数据,也可以是多条历史语音数据。当第一类历史语音数据为一条语音数据时,终端可以将该语音数据切分为多个语音片段,获取每个语音片段对应的语音特征;当第一类历史语音数据为多条语音数据时,终端可以获取每条语音数据对应的语音特征。
语音特征为语音数据的特征,每个用户发出的语音数据的语音特征不同,因此,可以基于语音特征来区分不同的用户。其中,语音特征可以为向量或者其他形式,本公开实施例对语音特征的形式不做限定。
终端获取第一语音特征与获取第二语音特征的方式类似,本公开实施例在对终端获取第一语音特征和第二语音特征的实现方式进行介绍时,以终端获取历史语音数据对应的语音特征为例进行说明,获取第一语音特征和第二语音特征的方式均与获取历史语音数据对应的语音特征的方式类似。
终端可以直接对获取的多条历史语音数据进行处理,得到多条历史语音数据对应的语音特征,其过程可以包括:将历史语音数据输入至语音特征提取模型,获取该语音特征提取模型输出的语音特征,该语音特征为该历史语音数据对应的语音特征,依次将多条历史语音数据输入至语音特征提取模型,获取到每条历史语音数据对应的语音特征。该语音特征提取模型可以为i-vector(identity-vector,身份向量)声学模型、x-vector(x向量)声学模型等任一能够提取语音特征向量的模型。
其中,语音特征提取模型可以通过样本训练得到,其训练过程可以为:准备大量的语音数据,根据这些语音数据的MFCC(Mel-FrequencyCepstrumCoefficients,梅尔频率倒谱系数)对这些语音数据进行标注,将标注后的语音数据输入至声学模型中进行训练,得到训练完成的语音特征提取模型。
另外,在一种可能实现方式中,终端还可以先对多条历史语音数据进行预处理,基于处理后的多条历史语音数据,获取多条历史语音数据对应的语音特征。即上述步骤303可以包括步骤3031和步骤3032。
3031、对多条历史语音数据进行预处理,得到处理后的多条历史语音数据。该预处理过程可以包括以下至少一个步骤:
(1)当历史语音数据为双声道语音数据时,将历史语音数据进行分离处理,得到左历史语音数据和右历史语音数据,其中,左历史语音数据和右历史语音数据均为单声道语音数据。
(2)对多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段。
其中,对多条历史语音数据进行切分的过程可以包括:移动包含固定帧数的窗口对单声道语音数据进行分帧,本公开实施例对切分的方式不做限定。
(3)对多条历史语音数据进行筛选,过滤掉无效历史语音数据,该无效历史语音数据可以为噪声数据、静音数据等。
(4)建立每个历史语音数据与该历史语音数据的描述信息的对应关系,该描述信息可以为历史语音数据的来源信息、生成时间信息等。在一种可能实现的方式中,建立每个历史语音数据与该历史语音数据的描述信息的对应关系的方式可以为:基于该历史语音数据的描述信息,为该历史语音数据进行编号。例如,当该历史语音数据来源于第一即时通信应用、且该历史语音数据的生成时间为2015年7月3号12点18分,该历史语音数据的编号可以为A201507031218。
其中,预处理过程可以包括上述任意一个或者多个步骤,本公开实施例对预处理的过程不做限定。在一种可能实现方式中,如图4所示,终端对多条历史语音数据进行预处理的过程包括上述4个步骤:当多条历史语音数据中包括双声道的历史语音数据时,将双声道的历史语音数据进行分离处理,得到两个单声道的历史语音数据,该两个单声道的历史语音数据为左历史语音数据和右历史语音数据。将多条单声道的历史语音数据进行切分,得到包含目标帧数的多个历史语音数据片段,对多个历史语音数据片段进行筛选,将无效历史语音数据片段丢弃。根据每个历史语音数据的描述信息,建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系。
3032、终端获取多条处理后的历史语音数据对应的语音特征。
以处理后的历史语音数据为通过上述4个步骤进行处理得到的历史语音数据片段为例进行说明,如图5所示,终端将多个历史语音数据片段输入至语音特征提取模型,获取该语音特征提取模型输出的历史语音数据片段对应的语音特征。
需要说明的是,终端在获取语音特征时,可以先获取第一类历史语音数据对应的第一语音特征,也可以先获取第二类历史语音数据对应的第二语音特征,本公开实施例对获取第一语音特征和第二语音特征的顺序不做限定。
304、终端对该多个第一语音特征进行划分,得到至少一个第一语音特征簇,每个第一语音特征簇包括属于同一语音源的语音特征。
终端会按照一定的分类条件,对获取到的多个第一语音特征进行划分,该分类条件可以是语音特征之间的相似性、语音特征对应的数据来源、语音特征对应的生成时间等,本公开实施例对分类条件不做限定。
在一种可能实现方式中,该分类条件为语音特征之间的相似性,终端对获取到的多个第一语音特征进行聚类,得到至少一个第一语音特征簇。
其中,终端对获取到的多个第一语音特征进行聚类的方式可以包括:如图6所示,随机选定K个中心,对每个中心点执行下述步骤:计算每个第一语音特征与该中心的距离,对于每个第一语音特征,通过该第一语音特征与中心点的距离,将这个第一语音特征分类到与其距离最短的中心点所在的第一语音特征簇中。对于每一个第一语音特征簇,获取该第一语音特征簇中所有第一语音特征的向量均值,将该向量均值作为该第一语音特征簇新的簇中心;基于新的簇中心,将与新的簇中心距离超过目标距离阈值的第一语音特征丢弃,得到新的第一语音特征簇,之后,重复执行基于新的第一语音特征簇,重新确定簇中心,将与新的簇中心距离超过目标距离阈值的第一语音特征丢弃的过程,直至簇中心不再变化或者重复次数达到目标次数。
其中,上述获取距离时可以采用的算法包括但不限于:概率线性鉴别分析(ProbabilisticLinearDiscriminantAnalysis,PLDA)得分算法、欧式距离算法、余弦距离算法等任一种能够计算相似度距离的算法。本公开实施例对计算相似度距离的方式不做限定。
需要说明的是,本公开实施例仅是以聚类为例对多个语音特征的划分进行说明,在一些实施例中,还可以通过其他划分标准对语音特征进行分类,本公开实施例对划分的标准 不做限定。
需要说明的是,本公开实施例仅是以执行步骤302至步骤304为例,说明可以将多条历史语音数据划分为第一类语音数据和第二类语音数据,对第一类语音数据和第二类语音数据分别进行处理。而在另一实施例中,可以在步骤301执行之后,直接执行步骤303,不执行步骤302。也即,不对多条历史语音数据进行划分,将多条历史语音数据一同处理。
也即是,获取多条历史语音数据,该多条历史语音数据包括第一类历史语音数据和第二类历史语音数据;获取该多条历史语音数据对应的语音特征,获取到的语音特征中可以包括第一语音特征,还可以包括第二语音特征。此时,无论是第一语音特征还是第二语音特征,均可直接对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;从该至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,第一参考条件用于指示终端用户的语音数据所满足的条件;根据该用户语音特征簇中的语音特征,生成终端用户的声纹特征。
用户距离终端的远近不同,输入的语音数据属于同一个用户,但语音特征会存在差异,因此,在进行聚类时,采用不同的划分标准,可能会将第一语音特征和第二语音特征划分到同一个用户语音特征簇中,或者划分到不同的用户语音特征簇中。
在一种可能实现方式中,在获取到多条历史语音数据对应的语音特征后,采用较大的目标数量阈值,将多个语音特征进行聚类,可以得到至少一个语音特征簇,从而将用户的第一语音特征和第二语音特征聚类到一个用户语音特征簇中。因此,从该至少一个语音特征簇中选取满足第一参考条件的一个语音特征簇,作为用户语音特征簇,该用户语音特征簇中包括第一语音特征和第二语音特征,基于该用户语音特征簇中的至少两个语音特征,生成终端用户的声纹特征。
在另一种可能实现方式中,在获取到多条历史语音数据对应的语音特征后,采用较小的目标数量阈值,将多个语音特征进行聚类,可以得到至少两个语音特征簇,从而将用户的第一语音特征和第二语音特征聚类到不同的用户语音特征簇中,将远处语音数据的语音特征和近处语音数据的语音特征分离开来。因此,从该至少两个语音特征簇中选取满足第一参考条件的两个语音特征簇,作为第一用户语音特征簇和第二用户语音特征簇,该第一用户语音特征簇中包括至少一个第一语音特征,第二语音特征簇中包括至少一个第二语音特征,基于第一用户语音特征簇中的至少一个第一语音特征和第二用户语音特征簇中的至少一个第二语音特征,生成终端用户的声纹特征。
305、终端从至少一个第一语音特征簇中选取满足第一参考条件和第二参考条件的第一语音特征簇,作为第一用户语音特征簇。
其中,第一参考条件用于指示终端用户的语音数据所满足的条件。第二参考条件用于指示用户语音特征簇的属性所满足的条件。
其中,终端获取的多条历史语音数据中包括终端用户的语音数据,还可能包括其他用户的语音数据,例如,终端获取的多条历史语音数据为终端上的电话录音,该电话录音中不仅包括用户的语音数据,还包括与该用户进行通话的联系人的语音数据,如果用户多次与该联系人进行通话,则多条历史语音数据中会包括较多的该联系人的语音数据,从而导致通过划分得到的至少一个语音特征簇中包括该联系人的语音特征簇。因此,需要对至少一个语音特征簇进行筛选,才能得到用户的语音数据对应的语音特征簇。
在对至少一个第一语音特征簇进行筛选时,可以先基于终端用户的语音特征簇的属性所满足的条件对至少一个语音特征簇进行筛选,再基于终端用户在终端上输入的语音数据所满足的条件对筛选后的至少一个第一语音特征簇进行二次筛选。即,终端先基于第二参考条件对至少一个第一语音特征簇进行筛选,再基于第一参考条件对至少一个第一语音特征簇进行筛选。这样,通过簇类的基本特征能够筛选掉一部分语音特征簇,再通过第一参考条件筛选时,可以减少计算量,提高注册速度。
其中,终端从至少一个第一语音特征簇中选取满足第二参考条件的至少一个第一语音特征簇的过程可以包括以下至少一个步骤:
(1)第一语音特征簇中的第一语音特征数目达到参考数目。
由于历史语音数据中可能除了包括用户的语音数据之外,还包括其他声音源的语音数据,但是由于其他声音源的语音数据数量较少,因此,其对应的语音特征的数量也较少。终端可以获取每个第一语音特征簇的语音特征数目,当任一第一语音特征簇的第一语音特征的数目小于参考数目时,将该第一语音特征簇丢弃。
(2)第一语音特征簇中的每个第一语音特征与第一语音特征簇的簇中心之间的距离之和小于参考距离。
若第一语音特征簇中的每个第一语音特征与第一语音特征簇的簇中心之间的距离之和大于或等于参考距离,则该第一语音特征簇中可能包括距离簇中心较远的第一语音特征,也即,该第一语音特征簇中的多个第一语音特征的相似度较低,聚类效果较差,因此,终端可以将该第一语音特征簇丢弃。
(3)第一语音特征簇的语音特征密度大于参考密度。
若第一语音特征簇的语音特征密度不大于参考密度,则说明该第一语音特征簇中的数量不够多,相似度也不够高,该第一语音特征簇的聚类效果较差。因此,终端可以将该第一语音特征簇丢弃。
需要说明的是,本公开实施例仅是以上述三个步骤对满足第二参考条件进行说明,在一些实施例中,满足第二参考条件还可以是语音特征簇中的每个语音特征的得分方差小于参考和值,本公开实施例对第二参考条件的内容不做限定。
其中,终端从筛选后的至少一个语音特征簇中选取满足第一参考条件的语音特征簇的过程可以包括以下至少一个步骤:
(1)从筛选后的至少一个第一语音特征簇中选取满足数据来源条件的第一语音特征簇,作为该第一用户语音特征簇,该数据来源条件为第一用户语音特征簇的数据来源数目大于其他第一语音特征簇的数据来源数目,该第一语音特征簇的数据来源为该第一语音特征簇中的第一语音特征对应的第一类语音数据的来源。
由于终端用户在使用终端的过程中,会在多个应用上生成语音数据,而终端可能也会获取到其他用户的语音数据,但是终端上的应用很难都获取到其他用户的语音数据。例如,终端用户在使用终端的过程中,在通过电话联系他人时,终端对通话内容进行录音,通过录音得到的语音数据中不仅包括终端用户的语音数据,还包括联系人的语音数据。另外,终端上还安装有即时通信应用,终端用户未通过该即时通信应用与该联系人联系,则该即时通信应用中不包括该联系人的语音数据。由此可知,终端用户会在终端的多个应用程序上产生语音数据,即终端用户的语音数据来源较广,而其他用户可能只在其中的某一个或者几个应用程序上生成语音数据,即其他用户的语音数据来源较少。因此,可以基于语音特征的数据来源对语音特征簇进行筛选。
终端在对历史语音数据进行预处理时,已经建立了历史语音数据与描述信息的对应关系或者历史语音数据片段与描述信息的对应关系。无论建立了哪种对应关系,都可以根据该对应关系确定该语音特征簇中语音特征对应的描述信息,该描述信息中包括数据来源。其中,确定第一语音特征对应的描述信息的过程可以包括:根据第一语音特征可以确定第一语音特征对应的第一类历史语音数据,获取该第一类历史语音数据对应的描述信息,该描述信息为该第一语音特征对应的描述信息。确定第一语音特征对应的描述信息的过程还可以包括:根据第一语音特征,确定该第一语音特征对应的第一类历史语音数据片段,获取该第一类历史语音数据片段对应的描述信息,该描述信息为第一语音特征对应的描述信息。
对于任一个第一语音特征簇,可以获取该第一语音特征簇中每个第一语音特征的描述信息,基于每个第一语音特征的描述信息,可以确定该第一语音特征簇中第一语音特征的数据来源数目。在一种可能实现方式中,基于第一类历史语音数据或者第一类历史语音数据片段的编号,确定第一语音特征簇中第一语音特征的数据来源数目。例如,对于编号中用于代表数据来源的数据段,统计多个数据段中出现的不同字符数目,该不同字符数目即为数据来源数目。
在获取每个第一语音特征簇的数据来源数目之后,将数据来源数目最大的第一语音特征簇作为第一用户语音特征簇,在一种可能实现方式中,根据每个第一语音特征簇的数据来源数目,按照从大到小的顺序,对至少一个第一语音特征簇进行排序,选取位于第一位的第一语音特征簇,作为第一用户语音特征簇。
(2)从筛选后的至少一个第一语音特征簇中选取满足时间分布条件的语音特征簇,作为该第一用户语音特征簇,该时间分布条件为第一用户语音特征簇的时间段数目大于其他第一语音特征簇的时间段数目,该第一语音特征簇的时间段为该第一语音特征簇中的第一语音特征对应的第一类语音数据的生成时间所属的时间段。
由于终端用户在使用终端的过程中,会在多个时刻生成语音数据,终端在获取历史语音数据中,可能会包括多个时刻生成的终端用户的语音数据,还包括某个时刻生成的其他用户的语音数据。例如,终端用户上午通过电话联系第一联系人,终端通过获取通话录音,获取到了终端用户的语音数据和第一联系人的语音数据。终端用户下午通过电话联系第二联系人,终端通过获取通话录音,获取到了终端用户的语音数据和第二联系人的语音数据。由此可知,终端获取的多条历史语音数据中终端用户的语音数据的生成时间段较多,其他用户的语音数据的生成时间段较少。
其中,确定语音特征簇的时间段数目的方式与上述确定语音特征簇的数据来源数目的方式类似,从至少一个第一语音特征簇中,筛选出时间段数目最多的第一语音特征簇的方式与筛选出数据来源数目最多的第一语音特征簇的方式类似,在此不再一一赘述。
另外,第一参考条件还可以包括多个条件,该多个条件中可以包括数据来源条件和时间分布条件,也可以包括其他条件。其中,获取第一用户语音特征簇采用加权平均的方法,该方法可以包括以下步骤:终端为每个条件分配了权重值,针对至少一个第一语音特征簇中的任一语音特征簇,获取每个条件下,第一语音特征簇对应的分值;根据每个条件的权重值,进行加权处理,得到该第一语音特征簇处理后的分值,按照处理后的分值从大到小 的顺序,对至少一个第一语音特征簇进行排序,选取位于第一位的第一语音特征簇,作为第一用户语音特征簇。
以多个条件为数据来源条件和时间分布条件为例,对获取第一用户语音特征簇的过程进行说明,终端为数据来源条件分配有第一权重值,为时间分布条件分配有第二权重值;终端基于第一语音特征对应的第一类语音数据的来源,获取至少一个第一语音特征簇的第一分值,其中,第一语音特征簇的第一分值与该第一语音特征簇的数据来源数目呈正相关关系;终端基于第一语音特征对应的第一语音数据生成的时间所属的时间段,获取至少一个第一语音特征簇的第二分值,其中,第一语音特征簇的第二分值与第一语音特征簇的时间段数目呈正相关关系。获取第一分值与第一权重值的乘积、和第二分值与第二权重值的乘积之和,得到第一语音特征簇的分值,按照分值从大到小的顺序,对至少一个第一语音特征簇进行排序,选取位于第一位的第一语音特征簇,作为第一用户语音特征簇。
本实施例仅是以先根据第二参考条件对第一语音特征簇进行筛选,再根据第一参考条件对筛选后的第一语音特征簇进行筛选,在一些实施例中,还可以先根据第一参考条件进行筛选,再根据第二参考条件进行进一步地筛选,本公开实施例中对筛选条件的执行顺序不做限定。
另外,本公开实施例仅是以筛选条件包括第一参考条件和第二参考条件为了进行说明,在一些实施例中,该筛选条件还可以只包括第一参考条件或者第二参考条件,其中,基于第一参考条件或第二参考条件对至少一个语音特征簇筛选的过程与上述过程类似,在此不再一一赘述,本公开实施例对筛选条件不做限定。
306、终端根据第一用户语音特征簇中的第一语音特征,生成终端用户的第一声纹特征。
其中,声纹特征是能够确定唯一用户的特征,该声纹特征可以为向量形式、矩阵形式或者模型形式,本公开实施例对声纹特征的形式不做限定。
若该声纹特征为向量,步骤306的实现方式可以包括:终端将第一用户语音特征簇中的多个第一语音特征合并为一个第一语音特征,作为声纹特征,该多个第一语音特征可以为第一用户语音特征簇中的全部第一语音特征,也可以是第一用户语音特征簇中的部分第一语音特征。其中,若选取部分第一语音特征进行合并,则可以选择与簇中心的距离最近的目标数目的语音特征。
在将多个第一语音特征合并为一个语音特征的过程可以为:如图8所示,终端获取该多个第一语音特征的平均向量,将该平均向量作为第一声纹特征。另外,终端根据第一声纹特征对后续用户输入的语音数据进行识别分析时,第一声纹特征的向量长度与用户输入语音数据的特征向量长度不同时,可能会影响到识别分析的结果,因此,终端还可以将平均向量做向量长度归一化处理,在提取用户输入语音数据的特征向量后,也将该特征向量做向量长度归一化处理,这样可以避免向量长度不同对识别分析结果的影响。因此,终端可以将经过向量长度归一化处理的平均向量,作为第一声纹特征。
另外,终端还可以根据该多个第一语音特征,生成一个向量矩阵,该向量矩阵为第一声纹特征。
步骤306的实现方式还可以包括:终端从第一用户语音特征簇中选取一个第一语音特征,作为第一声纹特征,该选取的第一语音特征与簇中心的距离小于第一用户语音特征簇中的其他第一语音特征与簇中心的距离。
步骤306的实现方式还可以包括:终端根据第一用户语音特征簇中的第一语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为第一声纹特征。
307、基于第一声纹特征,终端从第二类历史语音数据对应的多个第二语音特征中筛选出终端用户的语音特征。
其中,第一类历史语音数据是终端用户距离终端较近时输入的语音数据,因此,第一类历史语音数据中包括的杂音较少,而第二类历史语音数据是终端用户距离终端较远时输入的语音数据,由于外界环境中存在多个语音源,终端在接收终端用户的语音数据时,还会接收到外界环境中其他语音源的语音数据,因此,第二类历史语音数据中包括的杂音较多。
其中,步骤307的实现方式可以包括以下步骤:终端将第二类历史语音数据对应的第二语音特征与第一声纹特征进行对比,当第二语音特征与第一声纹特征匹配时,该第二语音特征为终端用户的语音特征;当第二语音特征与第一声纹特征不匹配时,该第二语音特征为其他语音源的语音特征,将该第二语音特征丢弃。
在一种可能实现方式中,终端基于第一声纹特征,为多个第二语音特征进行打分,当第二语音特征的分值小于目标分值阈值时,将该第二语音特征丢弃。其中,第二语音特征与第一声纹特征的相似度越高,第二语音特征的分值越高。
其中,终端基于第一声纹特征,为第二类历史语音数据对应的第二语音特征进行打分的实现方式可以包括:终端将第一声纹特征和第二语音特征输入至PLDA得分模型中,通过该PLDA得分模型获取第二类历史语音数据对应的语音特征的分值。
如图7所示,通过训练样本来训练PLDA得分模型,将第一声纹特征和第二语音特征 输入训练好的PLDA得分模型中,通过该PLDA得分模型获取该语音特征对应的分值,当分值高于目标阈值时,保留该第二语音特征;当分值低于或等于目标阈值时,丢弃该第二语音特征。
在一种可能实现方式中,基于第二类历史语音数据生成第二声纹特征,包括:将第二类历史语音数据对应的语音特征中,与第一声纹特征不匹配的语音特征丢弃,得到与第一声纹特征匹配的语音特征;根据与第一声纹特征匹配的语音特征生成第二声纹特征。
其中,按照上述说明中的方法将第二类历史语音数据对应的语音特征中与第一声纹特征不匹配的语音特征丢弃之后,第二类历史语音数据对应的语音特征中剩余的语音特征均为与第一声纹特征匹配的语音特征。因此,在后续获取第二声纹特征时,是根据与第一声纹特征相匹配的这部分语音特征获取第二声纹特征,从而提高了获取到的第二声纹特征的准确性。
需要说明的是,上述步骤307为可选步骤,若执行步骤307,如图9所示,则终端基于第一声纹特征从多个第二语音特征中筛选出终端用户的语音特征,使得在后续基于第二语音特征获取第二声纹特征时,得到的第二声纹特征更加准确。若不执行步骤307,在获取到第二语音特征之后,直接将多个第二语音特征划分为至少一个第二语音特征簇。
308、终端对筛选出的终端用户的语音特征进行划分,得到至少一个第二语音特征簇,每个第二语音特征簇包括属于同一语音源的第二语音特征。
309、终端从至少一个第二语音特征簇中选取满足第一参考条件和第二参考条件的第二语音特征簇,作为第二用户语音特征簇。
310、终端根据第二用户语音特征簇中的第二语音特征,生成终端用户的第二声纹特征。
其中,步骤308至步骤310与步骤304至步骤306类似,在此不再一一赘述。
311、终端建立第一声纹特征与终端用户的用户信息之间的关联关系和第二声纹特征与终端用户的用户信息之间的关联关系。
其中,用户信息可以为用户的ID(identity,身份标识),例如,用户的终端账号、用户的身份证号等能够确定唯一用户的标识。终端建立第一声纹特征与终端用户的用户信息之间的关联关系的方式,和建立第二声纹特征与终端用户的用户信息之间的关联关系的方式类似。终端可以将声纹特征与终端用户的用户信息对应存储,其过程可以包括:终端将第一声纹特征与终端用户的用户信息对应存储,将第二声纹特征与终端用户的用户信息对应存储。
其中,步骤311可以为可选步骤,在另一实施例中,由于该注册过程是在终端上进行的,终端可以将注册生成的声纹特征保存在本地,在需要对用户输入的语音数据进行识别时,直接获取第一声纹特征和第二声纹特征,基于用户输入的语音数据,确定用户是否为终端用户。
需要说明的是,终端在获取第一声纹特征之后,即可建立第一声纹特征与终端用户的用户信息之间的关联关系,也可以在获取第二声纹特征之后,建立关联关系,本公开实施例对建立关联关系的时机不做限定。
需要说明的是,本公开实施例仅是以执行主体为终端为例进行说明,在一些实施例中,执行主体还可以为服务器,本公开实施例对执行主体的形式不做限定。当执行主体为服务器时,则需要建立声纹特征与终端用户的用户信息之间的关联关系。在一种可能实现方式中,服务器根据用户信息将声纹特征存储至声纹注册数据库中。
本公开实施例提供的声纹特征注册方法,通过获取多条历史语音数据对应的语音特征,基于语音特征是否属于同一语音源对获取到的多个语音特征进行划分,得到至少一个语音特征簇;基于终端用户的语音数据所满足的条件,在至少一个语音特征簇中筛选出用户语音特征簇,根据用户语音特征簇来生成终端用户的声纹特征,实现了自动获取用户的声纹特征,在进行声纹注册时,无需用户输入语音数据,简化了用户操作,加快了注册时间,提高了注册效率。另外,通过第一参考条件从至少一个语音特征簇中筛选出用户语音特征簇,保证了基于用户语音特征簇生成的声纹特征是终端用户的,避免了其他用户的声纹特征的干扰,确保了声纹注册的准确性。还考虑到了终端用户距离终端远近不一带来的声音差异,将多条历史语音数据划分为第一类(近处)历史语音数据和第二类(远处)历史语音数据,生成的声纹特征既能代表远处语音数据的特征,也能代表近处语音数据的特征,对用户输入的语音数据进行分析时,能够准确地识别用户是否为终端用户,避免了由于远近声音的差异导致识别失败的问题。
另外,在获取语音特征之前,会先对历史语音数据进行预处理,来去除无效数据,以便减少后续的计算量。示例性地,在通过第一参考条件对语音特征簇进行筛选之前,还可以先通过第二参考条件对语音特征簇进行简要筛选,以便减少通过第一参考条件进行筛选时的计算量,提高注册速度和注册效率。
示例性地,本实施例还提供了另一种声纹注册方法,以执行主体为终端为例,该方法包括:
401、获取多条历史语音数据。
该步骤参见上文301中的说明,此处不再进行赘述。
402、获取多条历史语音数据对应的语音特征。
示例性地,该步骤参见上文302及303中的说明,此处不再进行赘述。另外,本实施例还能够不将多条历史语音数据分为第一类历史语音数据和第二类历史语音数据,而是直接获取多条历史语音数据对应的语音特征。此种情况下,获取多条历史语音数据对应的语音特征可参见303中获取第一类历史语音数据对应的多个第一语音特征的过程,或者,参见303中获取第二类历史语音数据对应的多个第二语音特征的过程。
403、对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征。
该步骤参见上文304中对划分多个第一语音特征得到至少一个第一语音特征簇的说明,此处不再进行赘述。
404、从至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为任一个语音特征簇中语音特征对应的语音数据的来源,任一个语音特征簇的时间段为任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
该步骤可参见上文305中的说明,此处不再进行赘述。其中,由于第一参考条件是数据来源数目最大以及时间段数目最大中的至少一个条件,因而该第一参考条件能够较好的指示语音特征簇与用户的关联性。也就是说,通过该第一参考条件筛选出的用户语音特征簇与用户的关联性较强,从而能够保证后续基于用户语音特征簇生成的声纹特征是终端用户的。由此,避免了其他用户的声纹特征的干扰,确保了声纹注册的准确性。
405、根据用户语音特征簇中的语音特征,生成终端用户的声纹特征。
该步骤参见上文306中的说明,此处不再进行赘述。
综上所述,本公开实施例提供的声纹特征注册方法,通过获取多条历史语音数据对应的语音特征,基于语音特征是否属于同一语音源对获取到的多个语音特征进行划分,得到至少一个语音特征簇;基于终端用户的语音数据所满足的条件,在至少一个语音特征簇中筛选出用户语音特征簇,根据用户语音特征簇来生成终端用户的声纹特征,实现了自动获取用户的声纹特征,在进行声纹注册时,无需用户输入语音数据,简化了用户操作,加快了注册时间,提高了注册效率。由于在注册过程中通过第一参考条件进行了筛选,因而所生成的声纹特征是终端用户的,保证了声纹注册的准确性。
图10是本公开实施例提供的一种声纹特征注册装置的结构图,参见图10,该装置包括:
第一划分模块1001,用于获取多条历史语音数据,该多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,该第二类历史语音数据的语音源与终端之间的距离大于该第一类历史语音数据的语音源与该终端之间的距离;
获取模块1002,用于获取该多条历史语音数据对应的语音特征;
第二划分模块1003,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
选取模块1004,用于从该至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,该第一参考条件用于指示终端用户的语音数据所满足的条件;
生成模块1005,用于根据该用户语音特征簇中的语音特征,生成该终端用户的声纹特征。
本公开实施例提供的声纹特征注册装置,通过获取多条历史语音数据对应的语音特征,基于语音特征是否属于同一语音源对获取到的多个语音特征进行划分,得到至少一个语音特征簇;基于终端用户的语音数据所满足的条件,在至少一个语音特征簇中筛选出用户语音特征簇,根据用户语音特征簇来生成终端用户的声纹特征,实现了自动获取用户的声纹特征,在进行声纹注册时,无需用户输入语音数据,简化了用户操作,加快了注册时间,提高了注册效率。另外,通过第一参考条件从至少一个语音特征簇中筛选出用户语音特征簇,保证了基于用户语音特征簇生成的声纹特征是终端用户的,避免了其他用户的声纹特征的干扰,确保了声纹注册的准确性。还考虑到了终端用户距离终端远近不一带来的声音差异,多条历史语音数据包括第一类(近处)历史语音数据和第二类(远处)历史语音数据,生成的声纹特征既能代表远处语音数据的特征,也能代表近处语音数据的特征,对用户输入的语音数据进行分析时,能够准确地识别用户是否为终端用户,避免了由于远近声音的差异导致识别失败的问题。
在一种可能实现方式中,该选取模块1004包括下述至少一个单元:
第一选取单元10041,用于从该至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为该用户语音特征簇,该数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,该语音特征簇的数据来源为该语音特征簇中的语音特征对应的语音数据的来源;
第二选取单元10042,用于从该至少一个语音特征簇中选取满足时间分布条件的语音特 征簇,作为该用户语音特征簇,该时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,该语音特征簇的时间段为该语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
在一种可能实现方式中,该选取模块1004,还用于从该至少一个语音特征簇中选取满足该第一参考条件和第二参考条件的语音特征簇,作为该用户语音特征簇;该第二参考条件用于指示用户语音特征簇的属性所满足的条件。
在一种可能实现方式中,该第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,该获取模块1002包括:
切分单元10021,用于对该多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
关系建立单元10022,用于建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
获取单元10023,用于获取每个历史语音数据片段对应的语音特征。
在一种可能实现方式中,该装置还包括:
关联关系建立模块1006,用于如果基于该第一类历史语音数据生成第一声纹特征,且基于该第二类历史语音数据生成第二声纹特征,则建立该第一声纹特征与该终端的用户信息的关联关系和该第二声纹特征与该终端的用户信息的关联关系。
在一种可能实现方式中,该装置还包括:
匹配模块1007,用于将该第二类历史语音数据对应的语音特征中,与该第一声纹特征不匹配的语音特征丢弃。
在一种可能实现方式中,关联关系建立模块1006,用于将第二类历史语音数据对应的语音特征中,与第一声纹特征不匹配的语音特征丢弃,得到与第一声纹特征匹配的语音特征;根据与第一声纹特征匹配的语音特征生成第二声纹特征。
在一种可能实现方式中,该生成模块包括下述任一单元;
合并单元10051,用于将该用户语音特征簇中的多个语音特征合并为一个语音特征,作为该声纹特征;
选取单元10052,用于从该用户语音特征簇中选取一个语音特征,作为该声纹特征,该选取的语音特征与簇中心的距离小于该用户语音特征簇中的其他语音特征与该簇中心的距离;
训练单元10053,用于根据该用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为该声纹特征。
示例性地,本公开实施例提供了另一种声纹特征注册装置,该装置包括:
获取模块,用于获取多条历史语音数据,获取所述多条历史语音数据对应的语音特征;
划分模块,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
选取模块,用于从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为所述任一个语音特征簇中语音特征对应的语音数据的来源,任一个语音特征簇的时间段为所述任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段;
生成模块,用于根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
需要说明的是:上述实施例提供的声纹特征注册装置在生成声纹特征时,仅以上述各功能模块的划分进行举例说明,实际应用中,可以根据需要而将上述功能分配由不同的功能模块完成,即将设备的内部结构划分成不同的功能模块,以完成以上描述的全部或者部分功能。另外,上述实施例提供的声纹特征注册的装置与声纹特征注册的方法实施例属于同一构思,其实现过程详见方法实施例,这里不再赘述。
图12示出了本公开一个示例性实施例提供的终端1200的结构框图。该终端1200可以是:智能手机、平板电脑、MP3播放器(MovingPictureExpertsGroupAudioLayerIII,动态影像专家压缩标准音频层面3)、MP4(MovingPictureExpertsGroupAudioLayerIV,动态影像专家压缩标准音频层面4)播放器、笔记本电脑或台式电脑。终端1200还可能被称为用户设备、便携式终端、膝上型终端、台式终端等其他名称。
通常,终端1200包括有:处理器1201和存储器1202。
处理器1201可以包括一个或多个处理核心,比如4核心处理器、8核心处理器等。处理器1201可以采用DSP(DigitalSignalProcessing,数字信号处理)、FPGA(Field-ProgrammableGateArray,现场可编程门阵列)、PLA(ProgrammableLogicArray,可编程逻辑阵列)中的至少一种硬件形式来实现。处理器1201也可以包括主处理器和协处理器,主处理器是用于对在唤醒状态下的数据进行处理的处理器,也称CPU(CentralProcessingUnit,中央处理器);协处理器是用于对在待机状态下的数据进行处理的低功耗处理器。在一些 实施例中,处理器1201可以在集成有GPU(GraphicsProcessingUnit,图像处理器),GPU用于负责显示屏所需要显示的内容的渲染和绘制。一些实施例中,处理器1201还可以包括AI(ArtificialIntelligence,人工智能)处理器,该AI处理器用于处理有关机器学习的计算操作。
存储器1202可以包括一个或多个计算机可读存储介质,该计算机可读存储介质可以是非暂态的。存储器1202还可包括高速随机存取存储器,以及非易失性存储器,比如一个或多个磁盘存储设备、闪存存储设备。在一些实施例中,存储器1202中的非暂态的计算机可读存储介质用于存储至少一个指令,该至少一个指令用于被处理器1201所执行以实现本申请中方法实施例提供的声纹特征注册方法。
在一些实施例中,终端1200还可选包括有:外围设备接口1203和至少一个外围设备。处理器1201、存储器1202和外围设备接口1203之间可以通过总线或信号线相连。各个外围设备可以通过总线、信号线或电路板与外围设备接口1203相连。可选地,外围设备包括:射频电路1204、触摸显示屏1205、摄像头1206、音频电路1207、定位组件1208和电源1209中的至少一种。
外围设备接口1203可被用于将I/O(Input/Output,输入/输出)相关的至少一个外围设备连接到处理器1201和存储器1202。在一些实施例中,处理器1201、存储器1202和外围设备接口1203被集成在同一芯片或电路板上;在一些其他实施例中,处理器1201、存储器1202和外围设备接口1203中的任意一个或两个可以在单独的芯片或电路板上实现,本实施例对此不加以限定。
射频电路1204用于接收和发射RF(RadioFrequency,射频)信号,也称电磁信号。射频电路1204通过电磁信号与通信网络以及其他通信设备进行通信。射频电路1204将电信号转换为电磁信号进行发送,或者,将接收到的电磁信号转换为电信号。可选地,射频电路1204包括:天线系统、RF收发器、一个或多个放大器、调谐器、振荡器、数字信号处理器、编解码芯片组、用户身份模块卡等等。射频电路1204可以通过至少一种无线通信协议来与其它终端进行通信。该无线通信协议包括但不限于:城域网、各代移动通信网络(2G、3G、4G及5G)、无线局域网和/或WiFi(WirelessFidelity,无线保真)网络。在一些实施例中,射频电路1204还可以包括NFC(NearFieldCommunication,近距离无线通信)有关的电路,本申请对此不加以限定。
显示屏1205用于显示UI(UserInterface,用户界面)。该UI可以包括图形、文本、图标、视频及其它们的任意组合。当显示屏1205是触摸显示屏时,显示屏1205还具有采集在显示屏1205的表面或表面上方的触摸信号的能力。该触摸信号可以作为控制信号输入至处理器1201进行处理。此时,显示屏1205还可以用于提供虚拟按钮和/或虚拟键盘,也称软按钮和/或软键盘。在一些实施例中,显示屏1205可以为一个,设置终端1200的前面板;在另一些实施例中,显示屏1205可以为至少两个,分别设置在终端1200的不同表面或呈折叠设计;在再一些实施例中,显示屏1205可以是柔性显示屏,设置在终端1200的弯曲表面上或折叠面上。甚至,显示屏1205还可以设置成非矩形的不规则图形,也即异形屏。显示屏1205可以采用LCD(LiquidCrystalDisplay,液晶显示屏)、OLED(OrganicLight-EmittingDiode,有机发光二极管)等材质制备。
摄像头组件1206用于采集图像或视频。可选地,摄像头组件1206包括前置摄像头和后置摄像头。通常,前置摄像头设置在终端的前面板,后置摄像头设置在终端的背面。在一些实施例中,后置摄像头为至少两个,分别为主摄像头、景深摄像头、广角摄像头、长焦摄像头中的任意一种,以实现主摄像头和景深摄像头融合实现背景虚化功能、主摄像头和广角摄像头融合实现全景拍摄以及VR(VirtualReality,虚拟现实)拍摄功能或者其它融合拍摄功能。在一些实施例中,摄像头组件1206还可以包括闪光灯。闪光灯可以是单色温闪光灯,也可以是双色温闪光灯。双色温闪光灯是指暖光闪光灯和冷光闪光灯的组合,可以用于不同色温下的光线补偿。
音频电路1207可以包括麦克风和扬声器。麦克风用于采集用户及环境的声波,将声波转换为电信号输入至处理器1201进行处理,或者输入至射频电路1204以实现语音通信。出于立体声采集或降噪的目的,麦克风可以为多个,分别设置在终端1200的不同部位。麦克风还可以是阵列麦克风或全向采集型麦克风。扬声器则用于将来自处理器1201或射频电路1204的电信号转换为声波。扬声器可以是传统的薄膜扬声器,也可以是压电陶瓷扬声器。当扬声器是压电陶瓷扬声器时,不仅可以将电信号转换为人类可听见的声波,也可以将电信号转换为人类听不见的声波以进行测距等用途。在一些实施例中,音频电路1207还可以包括耳机插孔。
定位组件1208用于定位终端1200的当前地理位置,以实现导航或LBS(LocationBasedService,基于位置的服务)。定位组件1208可以是基于美国的GPS(GlobalPositioningSystem,全球定位系统)、中国的北斗系统、俄罗斯的格雷纳斯系统或欧盟的伽利略系统的定位组件。
电源1209用于为终端1200中的各个组件进行供电。电源1209可以是交流电、直流电、 一次性电池或可充电电池。当电源1209包括可充电电池时,该可充电电池可以支持有线充电或无线充电。该可充电电池还可以用于支持快充技术。
在一些实施例中,终端1200还包括有一个或多个传感器1210。该一个或多个传感器1210包括但不限于:加速度传感器1211、陀螺仪传感器1212、压力传感器1213、指纹传感器1214、光学传感器1215以及接近传感器1216。
加速度传感器1211可以检测以终端1200建立的坐标系的三个坐标轴上的加速度大小。比如,加速度传感器1211可以用于检测重力加速度在三个坐标轴上的分量。处理器1201可以根据加速度传感器1211采集的重力加速度信号,控制触摸显示屏1205以横向视图或纵向视图进行用户界面的显示。加速度传感器1211还可以用于游戏或者用户的运动数据的采集。
陀螺仪传感器1212可以检测终端1200的机体方向及转动角度,陀螺仪传感器1212可以与加速度传感器1211协同采集用户对终端1200的3D动作。处理器1201根据陀螺仪传感器1212采集的数据,可以实现如下功能:动作感应(比如根据用户的倾斜操作来改变UI)、拍摄时的图像稳定、游戏控制以及惯性导航。
压力传感器1213可以设置在终端1200的侧边框和/或触摸显示屏1205的下层。当压力传感器1213设置在终端1200的侧边框时,可以检测用户对终端1200的握持信号,由处理器1201根据压力传感器1213采集的握持信号进行左右手识别或快捷操作。当压力传感器1213设置在触摸显示屏1205的下层时,由处理器1201根据用户对触摸显示屏1205的压力操作,实现对UI界面上的可操作性控件进行控制。可操作性控件包括按钮控件、滚动条控件、图标控件、菜单控件中的至少一种。
指纹传感器1214用于采集用户的指纹,由处理器1201根据指纹传感器1214采集到的指纹识别用户的身份,或者,由指纹传感器1214根据采集到的指纹识别用户的身份。在识别出用户的身份为可信身份时,由处理器1201授权该用户执行相关的敏感操作,该敏感操作包括解锁屏幕、查看加密信息、下载软件、支付及更改设置等。指纹传感器1214可以被设置终端1200的正面、背面或侧面。当终端1200上设置有物理按键或厂商Logo时,指纹传感器1214可以与物理按键或厂商Logo集成在一起。
光学传感器1215用于采集环境光强度。在一个实施例中,处理器1201可以根据光学传感器1215采集的环境光强度,控制触摸显示屏1205的显示亮度。可选地,当环境光强度较高时,调高触摸显示屏1205的显示亮度;当环境光强度较低时,调低触摸显示屏1205的显示亮度。在另一个实施例中,处理器1201还可以根据光学传感器1215采集的环境光强度,动态调整摄像头组件1206的拍摄参数。
接近传感器1216,也称距离传感器,通常设置在终端1200的前面板。接近传感器1216用于采集用户与终端1200的正面之间的距离。在一个实施例中,当接近传感器1216检测到用户与终端1200的正面之间的距离逐渐变小时,由处理器1201控制触摸显示屏1205从亮屏状态切换为息屏状态;当接近传感器1216检测到用户与终端1200的正面之间的距离逐渐变大时,由处理器1201控制触摸显示屏1205从息屏状态切换为亮屏状态。
本领域技术人员可以理解,图12中示出的结构并不构成对终端1200的限定,可以包括比图示更多或更少的组件,或者组合某些组件,或者采用不同的组件布置。
图13是本公开实施例提供的一种计算机设备的结构示意图,该计算机设备1300可因配置或性能不同而产生比较大的差异,可以包括一个或一个以上处理器(centralprocessingunits,CPU)1301和一个或一个以上的存储器1302,其中,该存储器1302中存储有至少一条指令,该至少一条指令由该处理器1301加载并执行以实现上述各个方法实施例提供的方法。当然,该计算机设备还可以具有有线或无线网络接口、键盘以及输入输出接口等部件,以便进行输入输出,该计算机设备还可以包括其他用于实现设备功能的部件,在此不做赘述。
在示例性实施例中,还提供了一种计算机可读存储介质,例如包括指令的存储器,上述指令可由终端中的处理器执行以完成上述实施例中资源领取方法。例如,该计算机可读存储介质可以是ROM、随机存取存储器(RAM)、CD-ROM、磁带、软盘和光数据存储设备等。
本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,该程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。
以上所述仅为本公开的实施例,不用以限制本公开,凡在本公开的精神和原则之内,所作的任何修改、等同替换、改进等,均应包含在本公开的保护范围之内。

Claims (21)

  1. 一种声纹特征注册方法,其中,所述方法包括:
    获取多条历史语音数据,所述多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,所述第二类历史语音数据的语音源与终端之间的距离大于所述第一类历史语音数据的语音源与所述终端之间的距离;
    获取所述多条历史语音数据对应的语音特征;
    对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
    从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件用于指示终端用户的语音数据所满足的条件;
    根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
  2. 根据权利要求1所述的方法,其中,所述从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括下述至少一个步骤:
    从所述至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为所述用户语音特征簇,所述数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,所述语音特征簇的数据来源为所述语音特征簇中的语音特征对应的语音数据的来源;
    从所述至少一个语音特征簇中选取满足时间分布条件的语音特征簇,作为所述用户语音特征簇,所述时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,所述语音特征簇的时间段为所述语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
  3. 根据权利要求1所述的方法,其中,所述从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,包括:
    从所述至少一个语音特征簇中选取满足所述第一参考条件和第二参考条件的语音特征簇,作为所述用户语音特征簇;所述第二参考条件用于指示用户语音特征簇的属性所满足的条件。
  4. 根据权利要求1所述的方法,其中,所述第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,所述获取所述多条历史语音数据对应的语音特征,包括:
    对所述多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
    建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
    获取每个历史语音数据片段对应的语音特征。
  5. 根据权利要求1所述的方法,其中,所述方法还包括:
    如果基于所述第一类历史语音数据生成第一声纹特征,且基于所述第二类历史语音数据生成第二声纹特征,则建立所述第一声纹特征与所述终端的用户信息的关联关系和所述第二声纹特征与所述终端的用户信息的关联关系。
  6. 根据权利要求5所述的方法,其中,在所述基于所述第一类历史语音数据生成第一声纹特征,且获取到所述第二类历史语音数据对应的语音特征之后,所述方法还包括:
    将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃。
  7. 根据权利要求5所述的方法,其中,所述基于所述第二类历史语音数据生成第二声纹特征,包括:
    将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃,得到与所述第一声纹特征匹配的语音特征;
    根据所述与所述第一声纹特征匹配的语音特征生成所述第二声纹特征。
  8. 根据权利要求1所述的方法,其中,所述根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征,包括下述任一步骤:
    将所述用户语音特征簇中的多个语音特征合并为一个语音特征,作为所述声纹特征;
    从所述用户语音特征簇中选取一个语音特征,作为所述声纹特征,所述选取的语音特征与簇中心的距离小于所述用户语音特征簇中的其他语音特征与所述簇中心的距离;
    根据所述用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为所述声纹特征。
  9. 一种声纹特征注册方法,其中,所述方法包括:
    获取多条历史语音数据;
    获取所述多条历史语音数据对应的语音特征;
    对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
    从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为所述任一个语音特征簇中语音特征对应的语音数据的来源, 任一个语音特征簇的时间段为所述任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段;
    根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
  10. 一种声纹特征注册装置,其中,所述装置包括:
    第一划分模块,用于获取多条历史语音数据,所述多条历史语音数据包括第一类历史语音数据和第二类历史语音数据,所述第二类历史语音数据的语音源与终端之间的距离大于所述第一类历史语音数据的语音源与所述终端之间的距离;
    获取模块,用于获取所述多条历史语音数据对应的语音特征;
    第二划分模块,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
    选取模块,用于从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件用于指示终端用户的语音数据所满足的条件;
    生成模块,用于根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
  11. 根据权利要求10所述的装置,其中,所述选取模块包括下述至少一个单元:
    第一选取单元,用于从所述至少一个语音特征簇中选取满足数据来源条件的语音特征簇,作为所述用户语音特征簇,所述数据来源条件为用户语音特征簇的数据来源数目大于其他语音特征簇的数据来源数目,所述语音特征簇的数据来源为所述语音特征簇中的语音特征对应的语音数据的来源;
    第二选取单元,用于从所述至少一个语音特征簇中选取满足时间分布条件的语音特征簇,作为所述用户语音特征簇,所述时间分布条件为用户语音特征簇的时间段数目大于其他语音特征簇的时间段数目,所述语音特征簇的时间段为所述语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段。
  12. 根据权利要求10所述的装置,其中,所述选取模块,还用于从所述至少一个语音特征簇中选取满足所述第一参考条件和第二参考条件的语音特征簇,作为所述用户语音特征簇;所述第二参考条件用于指示用户语音特征簇的属性所满足的条件。
  13. 根据权利要求10所述的装置,其中,所述第一参考条件用于指示终端用户的语音数据的描述信息所满足的条件,所述获取模块包括:
    切分单元,用于对所述多条历史语音数据进行切分,得到多个包含目标帧数的历史语音数据片段;
    关系建立单元,用于建立每个历史语音数据片段与所属的历史语音数据的描述信息的对应关系;
    获取单元,用于获取每个历史语音数据片段对应的语音特征。
  14. 根据权利要求10所述的装置,其中,所述装置还包括:
    关联关系建立模块,用于如果基于所述第一类历史语音数据生成第一声纹特征,且基于所述第二类历史语音数据生成第二声纹特征,则建立所述第一声纹特征与所述终端的用户信息的关联关系和所述第二声纹特征与所述终端的用户信息的关联关系。
  15. 根据权利要求14所述的装置,其中,所述装置还包括:
    匹配模块,用于将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃。
  16. 根据权利要求14所述的装置,其中,所述关联关系建立模块,用于将所述第二类历史语音数据对应的语音特征中,与所述第一声纹特征不匹配的语音特征丢弃,得到与所述第一声纹特征匹配的语音特征;根据所述与所述第一声纹特征匹配的语音特征生成所述第二声纹特征。
  17. 根据权利要求10所述的装置,其中,所述生成模块包括下述任一单元;
    合并单元,用于将所述用户语音特征簇中的多个语音特征合并为一个语音特征,作为所述声纹特征;
    选取单元,用于从所述用户语音特征簇中选取一个语音特征,作为所述声纹特征,所述选取的语音特征与簇中心的距离小于所述用户语音特征簇中的其他语音特征与所述簇中心的距离;
    训练单元,用于根据所述用户语音特征簇中的语音特征,训练用户声纹模型,将训练完成的用户声纹模型作为所述声纹特征。
  18. 一种声纹特征注册装置,其中,所述装置包括:
    获取模块,用于获取多条历史语音数据,获取所述多条历史语音数据对应的语音特征;
    划分模块,用于对获取到的多个语音特征进行划分,得到至少一个语音特征簇,每个语音特征簇包括属于同一语音源的语音特征;
    选取模块,用于从所述至少一个语音特征簇中选取满足第一参考条件的语音特征簇,作为用户语音特征簇,所述第一参考条件包括数据来源数目最大以及时间段数目最大中的至少一个条件,任一个语音特征簇的数据来源为所述任一个语音特征簇中语音特征对应的 语音数据的来源,任一个语音特征簇的时间段为所述任一个语音特征簇中的语音特征对应的语音数据的生成时间所属的时间段;
    生成模块,用于根据所述用户语音特征簇中的语音特征,生成所述终端用户的声纹特征。
  19. 一种终端,其中,所述终端包括一个或多个处理器和一个或多个存储器,所述一个或多个存储器中存储有至少一条指令,所述至少一条指令由所述一个或多个处理器加载并执行以实现如权利要求1至权利要求9任一项所述的声纹特征注册方法所执行的操作。
  20. 一种服务器,其中,所述服务器包括一个或多个处理器和一个或多个存储器,所述一个或多个存储器中存储有至少一条指令,所述至少一条指令由所述一个或多个处理器加载并执行以实现如权利要求1至权利要求9任一项所述的声纹特征注册方法所执行的操作。
  21. 一种计算机可读存储介质,其中,所述存储介质中存储有至少一条指令,所述至少一条指令由处理器加载并执行以实现如权利要求1至权利要求9任一项所述的声纹特征注册方法所执行的操作。
PCT/CN2020/115256 2019-09-19 2020-09-15 声纹特征注册 WO2021052306A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201910887744.2 2019-09-19
CN201910887744.2A CN110600040B (zh) 2019-09-19 2019-09-19 声纹特征注册方法、装置、计算机设备及存储介质

Publications (1)

Publication Number Publication Date
WO2021052306A1 true WO2021052306A1 (zh) 2021-03-25

Family

ID=68861304

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/115256 WO2021052306A1 (zh) 2019-09-19 2020-09-15 声纹特征注册

Country Status (2)

Country Link
CN (1) CN110600040B (zh)
WO (1) WO2021052306A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN110600040B (zh) * 2019-09-19 2021-05-25 北京三快在线科技有限公司 声纹特征注册方法、装置、计算机设备及存储介质
CN112992152B (zh) * 2021-04-22 2021-09-14 北京远鉴信息技术有限公司 一种单兵声纹识别系统、方法、存储介质及电子设备
CN115472167A (zh) * 2022-08-17 2022-12-13 南京龙垣信息科技有限公司 基于大数据自监督的声纹识别模型训练方法、系统
CN115954007B (zh) * 2023-03-14 2023-05-23 北京远鉴信息技术有限公司 一种声纹检测方法、装置、电子设备及存储介质
CN116612766B (zh) * 2023-07-14 2023-11-17 北京中电慧声科技有限公司 具备声纹注册功能的会议系统及声纹注册方法

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160217793A1 (en) * 2015-01-26 2016-07-28 Verint Systems Ltd. Acoustic signature building for a speaker from multiple sessions
CN106782564A (zh) * 2016-11-18 2017-05-31 百度在线网络技术(北京)有限公司 用于处理语音数据的方法和装置
CN107978311A (zh) * 2017-11-24 2018-05-01 腾讯科技(深圳)有限公司 一种语音数据处理方法、装置以及语音交互设备
CN108460081A (zh) * 2018-01-12 2018-08-28 平安科技(深圳)有限公司 语音数据库创建方法、声纹注册方法、装置、设备及介质
CN109145145A (zh) * 2017-06-16 2019-01-04 阿里巴巴集团控股有限公司 一种数据更新方法、客户端及电子设备
CN109841218A (zh) * 2019-01-31 2019-06-04 北京声智科技有限公司 一种针对远场环境的声纹注册方法及装置
CN110600040A (zh) * 2019-09-19 2019-12-20 北京三快在线科技有限公司 声纹特征注册方法、装置、计算机设备及存储介质

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN105450497A (zh) * 2014-07-31 2016-03-30 国际商业机器公司 生成聚类模型以及基于该聚类模型进行聚类的方法和装置
CN105656756A (zh) * 2015-12-28 2016-06-08 百度在线网络技术(北京)有限公司 好友推荐方法和装置
CN106057212B (zh) * 2016-05-19 2019-04-30 华东交通大学 基于语音个性特征和模型自适应的驾驶疲劳检测方法
US10096321B2 (en) * 2016-08-22 2018-10-09 Intel Corporation Reverberation compensation for far-field speaker recognition
CN108806696B (zh) * 2018-05-08 2020-06-05 平安科技(深圳)有限公司 建立声纹模型的方法、装置、计算机设备和存储介质
CN109637547B (zh) * 2019-01-29 2020-11-03 北京猎户星空科技有限公司 音频数据标注方法、装置、电子设备及存储介质
CN110086629A (zh) * 2019-04-23 2019-08-02 厦门快商通信息咨询有限公司 一种多距离声纹认证方法、终端、服务器及存储介质

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20160217793A1 (en) * 2015-01-26 2016-07-28 Verint Systems Ltd. Acoustic signature building for a speaker from multiple sessions
CN106782564A (zh) * 2016-11-18 2017-05-31 百度在线网络技术(北京)有限公司 用于处理语音数据的方法和装置
CN109145145A (zh) * 2017-06-16 2019-01-04 阿里巴巴集团控股有限公司 一种数据更新方法、客户端及电子设备
CN107978311A (zh) * 2017-11-24 2018-05-01 腾讯科技(深圳)有限公司 一种语音数据处理方法、装置以及语音交互设备
CN108460081A (zh) * 2018-01-12 2018-08-28 平安科技(深圳)有限公司 语音数据库创建方法、声纹注册方法、装置、设备及介质
CN109841218A (zh) * 2019-01-31 2019-06-04 北京声智科技有限公司 一种针对远场环境的声纹注册方法及装置
CN110600040A (zh) * 2019-09-19 2019-12-20 北京三快在线科技有限公司 声纹特征注册方法、装置、计算机设备及存储介质

Also Published As

Publication number Publication date
CN110600040B (zh) 2021-05-25
CN110600040A (zh) 2019-12-20

Similar Documents

Publication Publication Date Title
WO2021052306A1 (zh) 声纹特征注册
CN111933112B (zh) 唤醒语音确定方法、装置、设备及介质
CN110660398B (zh) 声纹特征更新方法、装置、计算机设备及存储介质
CN110322760B (zh) 语音数据生成方法、装置、终端及存储介质
WO2022057435A1 (zh) 基于搜索的问答方法及存储介质
CN111127509B (zh) 目标跟踪方法、装置和计算机可读存储介质
CN111105788B (zh) 敏感词分数检测方法、装置、电子设备及存储介质
CN111370025A (zh) 音频识别方法、装置及计算机存储介质
CN111613213B (zh) 音频分类的方法、装置、设备以及存储介质
CN112667844A (zh) 检索音频的方法、装置、设备和存储介质
CN110798327B (zh) 消息处理方法、设备及存储介质
CN112001442B (zh) 特征检测方法、装置、计算机设备及存储介质
CN113220590A (zh) 语音交互应用的自动化测试方法、装置、设备及介质
CN111341317B (zh) 唤醒音频数据的评价方法、装置、电子设备及介质
CN109829067B (zh) 音频数据处理方法、装置、电子设备及存储介质
CN113744736B (zh) 命令词识别方法、装置、电子设备及存储介质
CN112116908B (zh) 唤醒音频确定方法、装置、设备及存储介质
CN113343709B (zh) 意图识别模型的训练方法、意图识别方法、装置及设备
CN111028846B (zh) 免唤醒词注册的方法和装置
CN113162837B (zh) 语音消息的处理方法、装置、设备及存储介质
CN113362836A (zh) 训练声码器方法、终端及存储介质
CN113160802B (zh) 语音处理方法、装置、设备及存储介质
CN111681654A (zh) 语音控制方法、装置、电子设备及存储介质
CN111125424A (zh) 提取歌曲核心歌词的方法、装置、设备及存储介质
CN110989963B (zh) 唤醒词推荐方法及装置、存储介质

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 20866013

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 20866013

Country of ref document: EP

Kind code of ref document: A1