CN111797617A - Data processing method and device - Google Patents

Data processing method and device Download PDF

Info

Publication number
CN111797617A
CN111797617A CN202010456999.6A CN202010456999A CN111797617A CN 111797617 A CN111797617 A CN 111797617A CN 202010456999 A CN202010456999 A CN 202010456999A CN 111797617 A CN111797617 A CN 111797617A
Authority
CN
China
Prior art keywords
state diagram
finite state
digital
numbers
rule
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202010456999.6A
Other languages
Chinese (zh)
Inventor
吴帅
李健
武卫东
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Sinovoice Technology Co Ltd
Original Assignee
Beijing Sinovoice Technology Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Beijing Sinovoice Technology Co Ltd filed Critical Beijing Sinovoice Technology Co Ltd
Priority to CN202010456999.6A priority Critical patent/CN111797617A/en
Publication of CN111797617A publication Critical patent/CN111797617A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/253Grammatical analysis; Style critique
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L15/00Speech recognition
    • G10L15/06Creation of reference templates; Training of speech recognition systems, e.g. adaptation to the characteristics of the speaker's voice
    • G10L15/063Training
    • GPHYSICS
    • G10MUSICAL INSTRUMENTS; ACOUSTICS
    • G10LSPEECH ANALYSIS TECHNIQUES OR SPEECH SYNTHESIS; SPEECH RECOGNITION; SPEECH OR VOICE PROCESSING TECHNIQUES; SPEECH OR AUDIO CODING OR DECODING
    • G10L15/00Speech recognition
    • G10L15/26Speech to text systems

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computational Linguistics (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Human Computer Interaction (AREA)
  • Artificial Intelligence (AREA)
  • Acoustics & Sound (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • General Health & Medical Sciences (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)

Abstract

The embodiment of the invention provides a data processing method and a data processing device, wherein the method comprises the following steps: enumerating all numbers of a preset digit from zero; generating a digital model from all enumerated numbers; converting the digital model into a digital finite state diagram; acquiring a grammar rule, and converting the grammar rule into a finite state diagram of the rule; and combining the finite state diagram of the number and the finite state diagram of the rule to generate a number recognition model so as to recognize the number by using the number recognition model. By generating the finite state diagram form of the number, the grammar recognition model of the required number is trained, so that the corresponding grammar rule can be customized, and the accuracy of recognizing the number by adopting the number recognition model is improved.

Description

Data processing method and device
Technical Field
The present invention relates to the field of data processing technologies, and in particular, to a data processing method and a data processing apparatus.
Background
In recent years, with the development of large-scale continuous speech recognition technology, speech recognition technology is applied to more and more application scenes to improve the efficiency of user handling things.
At present, language models are widely applied to artificial intelligence technologies such as voice recognition, voice synthesis, machine translation, image recognition and the like. Because the number is very critical information and needs to be accurately judged, especially the number related in application scenes such as banks, securities, express delivery, flights and the like, the voice recognition generally needs to accurately recognize the number, the voice synthesis needs to accurately read the number, and the machine translation needs to correctly translate the number, for example, for intelligent customer service of the banks, if the bank card number reported by the user is recognized incorrectly, the transfer error is caused, so that the property loss of the user is caused.
Disclosure of Invention
In view of the above problems, embodiments of the present invention are proposed to provide a data processing method and a corresponding data processing apparatus that overcome or at least partially solve the above problems.
The embodiment of the invention discloses a data processing method, which comprises the following steps:
enumerating all numbers of a preset digit from zero;
generating a digital model from all enumerated numbers;
converting the digital model into a digital finite state diagram;
acquiring a grammar rule, and converting the grammar rule into a finite state diagram of the rule;
and combining the finite state diagram of the number and the finite state diagram of the rule to generate a number recognition model so as to recognize the number by using the number recognition model.
Optionally, the generating a digital model from all enumerated numbers comprises:
classifying all enumerated numbers to obtain a plurality of types of numbers with different digits;
generating a plurality of digital models according to the various numbers with different digits;
the converting the digital model into a digital finite state diagram includes:
converting the plurality of digital models into a finite state diagram of a plurality of numbers.
Optionally, the generating a plurality of digital models according to the plurality of types of numbers with different digits includes:
generating a plurality of numerical models and a plurality of number models according to the various numbers with different digits;
wherein the numerical model has a corresponding number unit and the number model has a corresponding number unit.
Optionally, the converting the plurality of digital models into a finite state diagram of a plurality of numbers includes:
converting the numerical models into a first finite state diagram and converting the number models into a second finite state diagram.
Optionally, the merging the digital finite state diagram and the rule finite state diagram to generate the digital recognition model includes:
and respectively combining the finite-state diagrams of the plurality of numbers and the finite-state diagram of the rule to generate a plurality of number recognition models.
Optionally, the finite state diagram of the rule includes a number category and a number length, and the merging the finite state diagrams of the numbers and the finite state diagram of the rule to generate a plurality of number recognition models includes:
traversing and searching the number category, the corresponding state connecting edge and the number length in the finite state diagram of the rule;
deleting the state connecting edge from the finite state diagram of the rule, and recording the starting point and the end point of the state connecting edge;
determining a target finite state diagram matched with the number category and the number length from the finite state diagrams of the numbers;
newly adding a first state edge and a second state edge to generate a plurality of digital identification models; wherein the first state edge is from the starting point of the state connecting edge to the starting point of the target finite state diagram, and the first state edge is from the end point of the target finite state diagram to the end point of the state connecting edge.
Optionally, the method further comprises:
acquiring audio data to be identified;
and inputting the audio data to be recognized into the digital recognition model, and outputting a recognition number.
The embodiment of the invention also discloses a data processing device, which comprises:
the digital enumeration module is used for enumerating all numbers with preset digits from zero;
the digital model generation module is used for generating a digital model according to all enumerated numbers;
the state diagram conversion module is used for converting the digital model into a digital finite state diagram;
the rule acquisition module is used for acquiring grammar rules and converting the grammar rules into a rule finite state diagram;
and the identification model generation module is used for combining the digital finite state diagram and the rule finite state diagram to generate a digital identification model so as to identify the number by adopting the digital identification model.
The embodiment of the invention also discloses an electronic device, which comprises:
one or more processors; and
one or more machine-readable media having instructions stored thereon, which when executed by the one or more processors, cause the electronic device to perform one or more of the method steps as described in embodiments of the invention.
Embodiments of the invention also disclose a computer-readable storage medium having instructions stored thereon, which, when executed by one or more processors, cause the processors to perform one or more of the method steps as described in embodiments of the invention.
The embodiment of the invention has the following advantages:
in the embodiment of the invention, the digital recognition model is generated by enumerating all digits of the preset digit number from zero, generating the digital model according to all the enumerated digits, converting the digital model into the finite state diagram of the digits, acquiring the grammar rule, converting the grammar rule into the finite state diagram of the rule, and merging the finite state diagram of the digits and the finite state diagram of the rule. Therefore, by generating the finite state diagram form of the digits, the grammar recognition model of the needed digits is trained, so that the corresponding grammar rules can be customized, and the accuracy of recognizing the digits by adopting the digit recognition model is improved.
Drawings
FIG. 1 is a flow chart of the steps of one data processing method embodiment of the present invention;
FIG. 2 is a flow chart of steps in another data processing method embodiment of the present invention;
fig. 3 is a block diagram of a data processing apparatus according to an embodiment of the present invention.
Detailed Description
In order to make the aforementioned objects, features and advantages of the present invention comprehensible, embodiments accompanied with figures are described in further detail below.
Referring to fig. 1, a flowchart illustrating steps of an embodiment of a data processing method according to the present invention is shown, which may specifically include the following steps:
step 101, enumerating all numbers with preset digits from zero;
the preset digit can be a preset number of natural digits, for example, if the preset digit is 5, all the digits of 0 to 99999 are enumerated.
In the embodiment of the present invention, the maximum value of the number of the preset number of bits may be determined, and then all the numbers from 0 to the maximum value may be enumerated. Specifically, the maximum value of the number of the preset number of bits may be 1eN-1, that is, 1 is subtracted from the nth power of 10, where N is the preset number of bits and e is the base number of the natural logarithm. For example, when N is 6 and N is substituted into 1eN-1 described above, a maximum value 99999999 of numbers with a predetermined number of digits can be obtained, and all numbers from 0 to 999999 are enumerated.
102, generating a digital model according to all enumerated numbers;
wherein a numerical model may refer to a model or function for identifying a number of language data.
Specifically, training samples of audio data for all enumerated numbers may be obtained, and the initial recognition model may be trained through the training samples to generate a required digital model. In a specific implementation, considering that different people have different readings for the number, for example, for the number "129", some will read "one hundred twenty nine", others will read "one two nine", and still others will read "two nine per unit", audio data of multiple readings can be obtained as training samples to improve the accuracy of the number model for recognizing the number.
Step 103, converting the digital model into a digital finite state diagram;
finite state diagrams are used to display the finite state machine (specifying the sequence of states in which an object is located), the events and conditions that cause an object to reach those states, and the operations that occur when those states are reached.
In embodiments of the present invention, the digital model may be converted into a digital finite state diagram. For example, a Finite State diagram of numbers is FST (Finite State translators), which has an output tag called input/output tag pair at each State transition, and through the input/output tag pair, the FST can describe a set of regular transitions or a transition from one set of symbol sequences to another set of symbol sequences.
As an example, a numerical model may be converted to a finite state diagram of weighted numbers. Specifically, the digital model may be converted into a digital finite state diagram by using an existing conversion tool, for example, Openfst, which is a library for constructing, merging, optimizing and searching the weighted finite state machine FST, is used to convert the digital model into a digital finite state diagram.
104, acquiring a grammar rule, and converting the grammar rule into a finite state diagram of the rule;
in the embodiment of the present invention, the grammar rule may be first obtained, and then the grammar rule may be converted into the finite state diagram of the rule by using Openfst in the same manner as the above processing manner of generating the finite state diagram of the number.
The grammar rule can be a preset grammar related to the reading number, namely, the grammar rule can be customized according to the actual application scene. Specifically, the grammar rule may include five attributes of a preamble, a length or a digit, a category, a postamble, and a weight, wherein the preamble attribute may refer to content before reading the digits, the length or the digit attribute may refer to the length or the digit of the read digits, the category attribute may refer to the category (e.g., a number category or a value category) of the read digits, the postamble attribute may be content after reading the digits, and the weight attribute may be a weighted weight of the multiple read digits.
As an example, the grammar rule indicates that "the last four digits of the phone number are D4 (1.0)", where "the last four digits of the phone number are" corresponding to the preamble attribute; "D" corresponds to a category attribute, which indicates that the category is a number category; "4" corresponds to a length attribute; "(space)" corresponds to a postamble attribute, indicating that the postamble is empty; "1.0" corresponds to the weight attribute.
And 105, combining the finite state diagram of the number and the finite state diagram of the rule to generate a number recognition model so as to recognize the number by using the number recognition model.
In the embodiment of the present invention, after the finite state diagram of the number and the finite state diagram of the rule are generated, the finite state diagram of the number and the finite state diagram of the rule may be further merged to obtain the number recognition model. The digital recognition model can be used for recognizing the audio data and outputting the numbers in the audio data.
By generating the finite state diagram form of the number, the grammar recognition model of the required number is trained, so that the corresponding grammar rule can be customized, and the accuracy of recognizing the number by adopting the number recognition model is improved.
In a preferred embodiment of the present invention, the step 102 may include the following sub-steps:
classifying all enumerated numbers to obtain a plurality of types of numbers with different digits; and generating a plurality of digital models according to the plurality of types of numbers with different digits.
In the embodiment of the invention, all enumerated numbers can be classified according to the digits of the numbers, so that multiple types of numbers with different digits are obtained.
Specifically, only 1-bit numbers can be classified into one category, 2-bit numbers can be classified into another category, and the like, which are respectively: 0 to 9, 10 to 99, 1e (N-1) to 1 eN-1. The number of each class can be denoted as Li, i.e., LiThe following formula is satisfied: l isi=[10i-1,10i) Where i represents the number of bits or length of each type of digit. As an example, if all enumerated data is 0-99999, the enumerated data can be classified into five categories, which are: 0 to 9, 10 to 99, 100 to 999, 1000 to 9999, 10000 to 99999.
After all enumerated numbers are classified, a number model can be generated according to the obtained numbers of multiple classes with different digits. For example, for the five types of numbers, a digital model can be generated according to 0-9, 10-99, 100-999, 1000-9999 and 10000-99999.
The step 103 may comprise the following sub-steps:
converting the plurality of digital models into a finite state diagram of a plurality of numbers.
In the embodiment of the present invention, after a plurality of digital models are generated, each digital model may be converted into a digital finite state diagram, and a plurality of digital models generate a plurality of digital finite state diagrams correspondingly.
In a preferred embodiment of the present invention, the generating a plurality of digital models from a plurality of sets of numbers with different numbers of bits includes:
generating a plurality of numerical models and a plurality of number models according to the various numbers with different digits;
wherein the numerical model has a corresponding number unit and the number model has a corresponding number unit.
Since in some application scenarios the reading of digits as numbers is different from the reading of numbers, the digits read as numbers will typically have a corresponding number unit, e.g., 129 reads one hundred twenty nine. When digits are used as numbers, the digits that are read generally do not have a corresponding number unit, e.g., 1001 reads a zero, a one. Therefore, in the embodiment of the present invention, in order to further improve the accuracy of digit recognition, a plurality of numerical models and a plurality of number models may be generated from a plurality of sets of digits with different digits.
Specifically, for the numerical model, each type of number may be converted by using a numerical function, and each type of number is directly converted in a numerical manner to generate a series of VALUEs, so as to obtain a corresponding numerical model, where the numerical function may be recorded as VALUE, and the generated numerical model is recorded as ViWhere i represents the number of digits of each class, then Vi=VALUE(Li). E.g. when i is 2, V2Comprises the following steps: ten, eleven, twelve, thirteen, say, ninety-eight, ninety-nine.
For the number model, a number function can be adopted to convert each type of DIGITs, each type of DIGITs are directly converted in a number mode, a series of numbers are generated, a corresponding number model is obtained, the number function can be marked as DIGIT, and the generated numerical model is marked as DiWhere i denotes the number of digits of each class, then Di=DIGIT(Li). E.g. when i is 2, D2Comprises the following steps: the method includes the steps of conducting zero, conducting two, conducting three, say, nine eight and nine.
In a preferred embodiment of the present invention, the converting the plurality of digital models into a finite state diagram of a plurality of numbers includes:
converting the numerical models into a first finite state diagram and converting the number models into a second finite state diagram.
The first finite state diagram may be a finite state diagram corresponding to a numerical model, and the second finite state diagram may be a finite state diagram corresponding to a number model. In the embodiment of the present invention, a plurality of numerical models may be converted into a plurality of first finite state diagrams, and a plurality of number models may be converted into a plurality of second finite state diagrams. If N types of numbers are set, N number models and N number models are correspondingly generated respectively, then the N number models are converted into N first finite state diagrams respectively, the N number models are converted into N second finite state diagrams respectively, and then 2N state diagram libraries can be generated finally.
In a preferred embodiment of the present invention, the merging the finite state diagram and the rule finite state diagram of the number to generate the number recognition model includes:
and respectively merging the finite state diagrams of the plurality of numbers and the rule finite state diagram to generate a plurality of number recognition models.
In the embodiment of the invention, the finite state diagram and the rule finite state diagram of each number can be respectively used for generating the number recognition model. With 2N state galleries as described above, 2N number of digital recognition models can be generated.
In a preferred embodiment of the present invention, the finite state diagram of the rule includes a number category and a number length, and the merging the finite state diagrams of the numbers and the finite state diagram of the rule to generate a plurality of number recognition models includes:
traversing and searching the number category, the corresponding state connecting edge and the number length in the finite state diagram of the rule; deleting the state connecting edge from the finite state diagram of the rule, and recording the starting point and the end point of the state connecting edge; determining a target finite state diagram matched with the number category and the number length from the finite state diagrams of the numbers; newly adding a first state edge and a second state edge to generate a plurality of digital identification models; wherein the first state edge is from the starting point of the state connecting edge to the starting point of the target finite state diagram, and the first state edge is from the end point of the target finite state diagram to the end point of the state connecting edge.
The number category is used for indicating the type of the number, and includes a value type and a number type, wherein the value type can be marked as V, and the number type can be marked as D. The digit length may refer to the number of digits of the number.
In the embodiment of the invention, the number category in the finite state diagram of the search rule can be traversed, and the corresponding state connecting edge and the number lengthAnd deleting the state connecting edge from the finite state diagram of the rule, and recording the starting point and the end point of the state connecting edge. Then, a target finite state diagram matching the number category and the number length can be determined from the finite state diagram of a plurality of numbers, for example, if the number category in the finite state diagram of the rule is D and the number length is 4, then the finite state diagram D of the number with the number type, length or number of digits of 4 can be searched4As a target finite state diagram.
And newly adding a first state side from the starting point of the state connecting side to the starting point of the target finite state diagram, and newly adding a second state side from the end point of the target finite state diagram to the end point of the state connecting side. For example, from the start of a state connecting edge in a regular finite state diagram, an edge is newly added to D4From D4To the end point of the state connecting edge in the regular finite state diagram.
In a preferred embodiment of the present invention, the method may further comprise the steps of:
acquiring audio data to be identified; and inputting the audio data to be recognized into the digital recognition model, and outputting a recognition number.
Wherein, the audio data to be identified can be the audio data to be identified.
In the embodiment of the invention, the audio data to be identified can be obtained, the audio data to be identified is input into the digital identification model, and the identification number is output. The digital recognition model can recognize the audio data to be recognized and output recognition numbers.
Through a numerical model and a number model, one type is numbers representing numerical values, the other type is numbers representing numbers, the numbers are identified according to two different models, and the characteristics of digits and weights are uniformly adopted for representation, so that the grammar rule of the number identification model is defined, and the accuracy of identifying the numbers by adopting the number identification model is improved.
Referring to fig. 2, a flowchart illustrating steps of another embodiment of a data processing method according to the present invention is shown, which may specifically include the following steps:
step 201, enumerating all numbers of a preset digit from zero;
the preset digit can be a preset number of natural digits, for example, if the preset digit is 5, all the digits of 0 to 99999 are enumerated.
Step 202, classifying all enumerated numbers to obtain multi-class numbers with different digits;
specifically, all enumerated numbers may be classified according to the digit number of the number, so as to obtain multiple types of numbers with different digit numbers, which are: 0 to 9, 10 to 99, 1e (N-1) to 1 eN-1. The number of each class can be denoted as Li, i.e., LiThe following formula is satisfied: l isi=[10i-1,10i)。
Step 203, generating a plurality of numerical models and a plurality of number models according to the plurality of types of numbers with different digits; wherein the numerical model has a corresponding number unit and the number model has a corresponding number unit;
specifically, for the numerical model, a numerical function may be adopted to convert each type of number, each type of number is directly converted in a numerical manner to generate a corresponding numerical model, the numerical function may be marked as VALUE, and the generated numerical model is marked as ViWhere i represents the number of digits of each class, then Vi=VALUE(Li). E.g. when i is 2, V2Comprises the following steps: ten, eleven, twelve, thirteen, say, ninety-eight, ninety-nine.
For the number model, a number function can be adopted to convert each type of DIGITs, each type of DIGITs are directly converted in a number mode to generate a corresponding number model, the number function can be marked as DIGIT, and the generated numerical model is marked as DiWhere i denotes the number of digits of each class, then Di=DIGIT(Li). E.g. when i is 2, D2Comprises the following steps: the method includes the steps of conducting zero, conducting two, conducting three, say, nine eight and nine.
Step 204, converting the numerical models into a plurality of first finite state diagrams, and converting the number models into a plurality of second finite state diagrams;
the first finite state diagram may be a finite state diagram corresponding to a numerical model, and the second finite state diagram may be a finite state diagram corresponding to a number model. In the embodiment of the present invention, a plurality of numerical models may be converted into a plurality of first finite state diagrams, and a plurality of number models may be converted into a plurality of second finite state diagrams. If N types of numbers are set, N number models and N number models are correspondingly generated respectively, then the N number models are converted into N first finite state diagrams respectively, the N number models are converted into N second finite state diagrams respectively, and then 2N state diagram libraries can be generated finally.
Step 205, obtaining grammar rules and converting the grammar rules into finite state diagrams of rules;
the grammar rule may be a preset grammar related to the read number, that is, the grammar rule may be customized according to an actual application scenario.
Specifically, the grammar rule may include five attributes of a preamble, a length or a digit, a category, a postamble, and a weight, wherein the preamble attribute may refer to content before reading the digits, the length or the digit attribute may refer to the length or the digit of the read digits, the category attribute may refer to the category (e.g., a number category or a value category) of the read digits, the postamble attribute may be content after reading the digits, and the weight attribute may be a weighted weight of the multiple read digits.
And step 206, combining the plurality of first finite state diagrams and the plurality of second finite state diagrams with the finite state diagrams of the rules respectively to generate a plurality of digital recognition models so as to recognize the numbers by using the digital recognition models.
In the embodiment of the present invention, a plurality of first finite state diagrams may be merged with the finite state diagram of the rule, and a plurality of second finite state diagrams may be merged with the finite state diagram of the rule, respectively, to generate a plurality of digital recognition models.
In a preferred embodiment of the present invention, the finite state diagram of the rule includes a number class and a number length, and the step 206 may include the following sub-steps:
traversing and searching the number category, the corresponding state connecting edge and the number length in the finite state diagram of the rule; deleting the state connecting edge from the finite state diagram of the rule, and recording the starting point and the end point of the state connecting edge; determining a target finite state diagram matching the digit category and digit length from the first finite state diagrams and the second finite state diagrams; newly adding a first state edge and a second state edge to generate a plurality of digital identification models; wherein the first state edge is from the starting point of the state connecting edge to the starting point of the target finite state diagram, and the first state edge is from the end point of the target finite state diagram to the end point of the state connecting edge.
In the embodiment of the invention, the number category, the corresponding state connecting side and the number length in the finite state diagram of the rule can be searched in a traversing way, the state connecting side is deleted from the finite state diagram of the rule, and the starting point and the end point of the state connecting side are recorded. Then, from the plurality of first finite state diagrams and the plurality of second finite state diagrams, a target finite state diagram matching the number class and the number length may be determined. And then, newly adding a first state side from the starting point of the state connecting side to the starting point of the target finite state diagram, and newly adding a second state side from the end point of the target finite state diagram to the end point of the state connecting side.
In a preferred embodiment of the present invention, the method further comprises:
acquiring audio data to be identified; and inputting the audio data to be recognized into the digital recognition model, and outputting a recognition number.
In the embodiment of the invention, the audio data to be identified can be obtained, the audio data to be identified is input into the digital identification model, and the identification number is output. The digital recognition model can recognize the audio data to be recognized and output recognition numbers.
It should be noted that, for simplicity of description, the method embodiments are described as a series of acts or combination of acts, but those skilled in the art will recognize that the present invention is not limited by the illustrated order of acts, as some steps may occur in other orders or concurrently in accordance with the embodiments of the present invention. Further, those skilled in the art will appreciate that the embodiments described in the specification are presently preferred and that no particular act is required to implement the invention.
Referring to fig. 3, a block diagram of a data processing apparatus according to an embodiment of the present invention is shown, which may specifically include the following modules:
a number enumeration module 301, configured to enumerate all numbers with a preset number of bits from zero;
a digital model generation module 302 for generating a digital model from all enumerated numbers;
a state diagram conversion module 303, configured to convert the digital model into a digital finite state diagram;
a rule obtaining module 304, configured to obtain a grammar rule, and convert the grammar rule into a rule finite state diagram;
a recognition model generation module 305, configured to combine the digital finite state diagram and the rule finite state diagram to generate a digital recognition model, so as to recognize a number using the digital recognition model.
In a preferred embodiment of the present invention, the digital model generation module 302 includes:
the classification submodule is used for classifying all enumerated numbers to obtain multi-class numbers with different digits;
the digital model generation submodule is used for generating a plurality of digital models according to the various numbers with different digits;
the state diagram conversion module 303 includes:
and the state diagram conversion submodule is used for converting the plurality of digital models into a finite state diagram of a plurality of numbers.
In a preferred embodiment of the present invention, the digital model generation submodule includes:
a digital model generating unit for generating a plurality of numerical models and a plurality of number models according to a plurality of types of numbers with different digits;
wherein the numerical model has a corresponding number unit and the number model has a corresponding number unit.
In a preferred embodiment of the present invention, the state diagram conversion sub-module includes:
and the state diagram conversion unit is used for converting the numerical models into a plurality of first finite state diagrams and converting the number models into a plurality of second finite state diagrams.
In a preferred embodiment of the present invention, the recognition model generating module 305 includes:
and the recognition model generation submodule is used for respectively merging the finite state diagrams of the plurality of numbers and the finite state diagram of the rule to generate a plurality of number recognition models.
In a preferred embodiment of the present invention, the finite state diagram of the rule includes a number category and a number length, and the recognition model generation submodule includes:
the digital category searching unit is used for searching the digital category, the corresponding state connecting edge and the digital length in the finite state diagram of the rule in a traversing way;
a state connecting edge deleting unit, configured to delete the state connecting edge from the finite state diagram of the rule, and record a start point and an end point of the state connecting edge;
a target finite state diagram determining unit, configured to determine a target finite state diagram matching the digit category and the digit length from the finite state diagrams of the digits;
the state edge adding unit is used for adding a first state edge and a second state edge and generating a plurality of digital identification models; wherein the first state edge is from the starting point of the state connecting edge to the starting point of the target finite state diagram, and the first state edge is from the end point of the target finite state diagram to the end point of the state connecting edge.
In a preferred embodiment of the present invention, the method further comprises:
the data acquisition module is used for acquiring audio data to be identified;
and the digital output module is used for inputting the audio data to be identified to the digital identification model and outputting identification numbers.
For the device embodiment, since it is basically similar to the method embodiment, the description is simple, and for the relevant points, refer to the partial description of the method embodiment.
An embodiment of the present invention further provides an electronic device, including:
one or more processors; and
one or more machine-readable media having instructions stored thereon, which when executed by the one or more processors, cause the electronic device to perform steps of a method as described by embodiments of the invention.
Embodiments of the present invention also provide a computer-readable storage medium having stored thereon instructions, which, when executed by one or more processors, cause the processors to perform the steps of the method according to embodiments of the present invention.
The embodiments in the present specification are described in a progressive manner, each embodiment focuses on differences from other embodiments, and the same and similar parts among the embodiments are referred to each other.
As will be appreciated by one skilled in the art, embodiments of the present invention may be provided as a method, apparatus, or computer program product. Accordingly, embodiments of the present invention may take the form of an entirely hardware embodiment, an entirely software embodiment or an embodiment combining software and hardware aspects. Furthermore, embodiments of the present invention may take the form of a computer program product embodied on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, and the like) having computer-usable program code embodied therein.
Embodiments of the present invention are described with reference to flowchart illustrations and/or block diagrams of methods, terminal devices (systems), and computer program products according to embodiments of the invention. It will be understood that each flow and/or block of the flow diagrams and/or block diagrams, and combinations of flows and/or blocks in the flow diagrams and/or block diagrams, can be implemented by computer program instructions. These computer program instructions may be provided to a processor of a general purpose computer, special purpose computer, embedded processor, or other programmable data processing terminal to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing terminal, create means for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be stored in a computer-readable memory that can direct a computer or other programmable data processing terminal to function in a particular manner, such that the instructions stored in the computer-readable memory produce an article of manufacture including instruction means which implement the function specified in the flowchart flow or flows and/or block diagram block or blocks.
These computer program instructions may also be loaded onto a computer or other programmable data processing terminal to cause a series of operational steps to be performed on the computer or other programmable terminal to produce a computer implemented process such that the instructions which execute on the computer or other programmable terminal provide steps for implementing the functions specified in the flowchart flow or flows and/or block diagram block or blocks.
While preferred embodiments of the present invention have been described, additional variations and modifications of these embodiments may occur to those skilled in the art once they learn of the basic inventive concepts. Therefore, it is intended that the appended claims be interpreted as including preferred embodiments and all such alterations and modifications as fall within the scope of the embodiments of the invention.
Finally, it should also be noted that, herein, relational terms such as first and second, and the like may be used solely to distinguish one entity or action from another entity or action without necessarily requiring or implying any actual such relationship or order between such entities or actions. Also, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or terminal that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or terminal. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or terminal that comprises the element.
The data processing method and the data processing apparatus provided by the present invention are described in detail above, and the principle and the implementation of the present invention are explained in the present document by applying specific examples, and the description of the above examples is only used to help understanding the method and the core idea of the present invention; meanwhile, for a person skilled in the art, according to the idea of the present invention, there may be variations in the specific embodiments and the application scope, and in summary, the content of the present specification should not be construed as a limitation to the present invention.

Claims (10)

1. A data processing method, comprising:
enumerating all numbers of a preset digit from zero;
generating a digital model from all enumerated numbers;
converting the digital model into a digital finite state diagram;
acquiring a grammar rule, and converting the grammar rule into a finite state diagram of the rule;
and combining the finite state diagram of the number and the finite state diagram of the rule to generate a number recognition model so as to recognize the number by using the number recognition model.
2. The method of claim 1, wherein generating a digital model from all enumerated numbers comprises:
classifying all enumerated numbers to obtain a plurality of types of numbers with different digits;
generating a plurality of digital models according to the various numbers with different digits;
the converting the digital model into a digital finite state diagram includes:
converting the plurality of digital models into a finite state diagram of a plurality of numbers.
3. The method of claim 2, wherein generating a plurality of digital models from a plurality of types of numbers that differ in the number of bits comprises:
generating a plurality of numerical models and a plurality of number models according to the various numbers with different digits;
wherein the numerical model has a corresponding number unit and the number model has a corresponding number unit.
4. The method of claim 3, wherein converting the plurality of numerical models into a finite state diagram of a plurality of numbers comprises:
converting the numerical models into a first finite state diagram and converting the number models into a second finite state diagram.
5. The method of claim 2, wherein said merging the digital finite state diagram and the rule finite state diagram to generate a digital recognition model comprises:
and respectively combining the finite-state diagrams of the plurality of numbers and the finite-state diagram of the rule to generate a plurality of number recognition models.
6. The method of claim 5, wherein the finite state diagram of the rule includes a number class and a number length, and wherein merging the finite state diagram of the plurality of numbers and the finite state diagram of the rule to generate the plurality of number recognition models comprises:
traversing and searching the number category, the corresponding state connecting edge and the number length in the finite state diagram of the rule;
deleting the state connecting edge from the finite state diagram of the rule, and recording the starting point and the end point of the state connecting edge;
determining a target finite state diagram matched with the number category and the number length from the finite state diagrams of the numbers;
newly adding a first state edge and a second state edge to generate a plurality of digital identification models; wherein the first state edge is from the starting point of the state connecting edge to the starting point of the target finite state diagram, and the first state edge is from the end point of the target finite state diagram to the end point of the state connecting edge.
7. The method of claim 1, further comprising:
acquiring audio data to be identified;
and inputting the audio data to be recognized into the digital recognition model, and outputting a recognition number.
8. A data processing apparatus, comprising:
the digital enumeration module is used for enumerating all numbers with preset digits from zero;
the digital model generation module is used for generating a digital model according to all enumerated numbers;
the state diagram conversion module is used for converting the digital model into a digital finite state diagram;
the rule acquisition module is used for acquiring grammar rules and converting the grammar rules into a rule finite state diagram;
and the identification model generation module is used for combining the digital finite state diagram and the rule finite state diagram to generate a digital identification model so as to identify the number by adopting the digital identification model.
9. An electronic device, comprising:
one or more processors; and
one or more machine-readable media having instructions stored thereon that, when executed by the one or more processors, cause the electronic device to perform the method of one or more of claims 1-7.
10. A computer-readable storage medium having stored thereon instructions, which, when executed by one or more processors, cause the processors to perform the method of one or more of claims 1-7.
CN202010456999.6A 2020-05-26 2020-05-26 Data processing method and device Pending CN111797617A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202010456999.6A CN111797617A (en) 2020-05-26 2020-05-26 Data processing method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202010456999.6A CN111797617A (en) 2020-05-26 2020-05-26 Data processing method and device

Publications (1)

Publication Number Publication Date
CN111797617A true CN111797617A (en) 2020-10-20

Family

ID=72806287

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202010456999.6A Pending CN111797617A (en) 2020-05-26 2020-05-26 Data processing method and device

Country Status (1)

Country Link
CN (1) CN111797617A (en)

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010037201A1 (en) * 2000-02-18 2001-11-01 Robert Alexander Keiller Speech recognition accuracy in a multimodal input system
CN109147767A (en) * 2018-08-16 2019-01-04 平安科技(深圳)有限公司 Digit recognition method, device, computer equipment and storage medium in voice
CN109616121A (en) * 2018-11-28 2019-04-12 北京捷通华声科技股份有限公司 A kind of digital conversion method and device
CN109801630A (en) * 2018-12-12 2019-05-24 平安科技(深圳)有限公司 Digital conversion method, device, computer equipment and the storage medium of speech recognition
CN110070859A (en) * 2018-01-23 2019-07-30 阿里巴巴集团控股有限公司 A kind of audio recognition method and device

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20010037201A1 (en) * 2000-02-18 2001-11-01 Robert Alexander Keiller Speech recognition accuracy in a multimodal input system
CN110070859A (en) * 2018-01-23 2019-07-30 阿里巴巴集团控股有限公司 A kind of audio recognition method and device
CN109147767A (en) * 2018-08-16 2019-01-04 平安科技(深圳)有限公司 Digit recognition method, device, computer equipment and storage medium in voice
CN109616121A (en) * 2018-11-28 2019-04-12 北京捷通华声科技股份有限公司 A kind of digital conversion method and device
CN109801630A (en) * 2018-12-12 2019-05-24 平安科技(深圳)有限公司 Digital conversion method, device, computer equipment and the storage medium of speech recognition

Non-Patent Citations (2)

* Cited by examiner, † Cited by third party
Title
VIKRAMJIT MITRA: "Articulatory_Information_and_Multiview_Features_for_Large_Vocabulary_Continuous_Speech_Recognition", 《2018 IEEE INTERNATIONAL CONFERENCE ON ACOUSTICS, SPEECH AND SIGNAL PROCESSING (ICASSP)》, 13 September 2018 (2018-09-13), pages 5634 - 5638 *
贾玉祥;黄德智;刘武;俞士汶;: "中文语音合成中的文本正则化研究", 中文信息学报, no. 05, 15 September 2008 (2008-09-15) *

Similar Documents

Publication Publication Date Title
CN109065031A (en) Voice annotation method, device and equipment
CN110046231B (en) Customer service information processing method, server and system
CN109299276B (en) Method and device for converting text into word embedding and text classification
CN113297379A (en) Text data multi-label classification method and device
CN112784009A (en) Subject term mining method and device, electronic equipment and storage medium
CN116010902A (en) Cross-modal fusion-based music emotion recognition method and system
CN113535817B (en) Feature broad table generation and service processing model training method and device
CN112989117A (en) Video classification method and device, electronic equipment and computer storage medium
CN109902162B (en) Text similarity identification method based on digital fingerprints, storage medium and device
CN114691907B (en) Cross-modal retrieval method, device and medium
CN111724810B (en) Audio classification method and device
CN116883740A (en) Similar picture identification method, device, electronic equipment and storage medium
CN111797617A (en) Data processing method and device
CN115203206A (en) Data content searching method and device, computer equipment and readable storage medium
CN112541357B (en) Entity identification method and device and intelligent equipment
CN115455083A (en) Duplicate checking method and device, electronic equipment and computer storage medium
CN114817586A (en) Target object classification method and device, electronic equipment and storage medium
CN111291208B (en) Front-end page element naming method and device and electronic equipment
CN114706943A (en) Intention recognition method, apparatus, device and medium
CN116303909B (en) Matching method, equipment and medium for electronic bidding documents and clauses
JP6441203B2 (en) Speech recognition result compression apparatus, speech recognition result compression method, and program
CN114547285B (en) Method and device for inferring meaning of table data, computer device and storage medium
CN117975489A (en) Method, system and storage medium for identifying complex characters
CN118013936A (en) Method, device, equipment and medium for unified data structure of overseas house source data
CN116542249A (en) Message identification method and device, storage medium and electronic device

Legal Events

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