CN109063702B - License plate recognition method, device, equipment and storage medium - Google Patents

License plate recognition method, device, equipment and storage medium Download PDF

Info

Publication number
CN109063702B
CN109063702B CN201810899533.6A CN201810899533A CN109063702B CN 109063702 B CN109063702 B CN 109063702B CN 201810899533 A CN201810899533 A CN 201810899533A CN 109063702 B CN109063702 B CN 109063702B
Authority
CN
China
Prior art keywords
license plate
confidence
plate recognition
recognition result
assumed
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201810899533.6A
Other languages
Chinese (zh)
Other versions
CN109063702A (en
Inventor
邵帅
史雨轩
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Kuangshi Technology Co Ltd
Original Assignee
Beijing Kuangshi 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 Kuangshi Technology Co Ltd filed Critical Beijing Kuangshi Technology Co Ltd
Priority to CN201810899533.6A priority Critical patent/CN109063702B/en
Publication of CN109063702A publication Critical patent/CN109063702A/en
Application granted granted Critical
Publication of CN109063702B publication Critical patent/CN109063702B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V30/00Character recognition; Recognising digital ink; Document-oriented image-based pattern recognition
    • G06V30/10Character recognition
    • G06V30/14Image acquisition
    • G06V30/148Segmentation of character regions
    • G06V30/153Segmentation of character regions using recognition of characters or words
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06VIMAGE OR VIDEO RECOGNITION OR UNDERSTANDING
    • G06V10/00Arrangements for image or video recognition or understanding
    • G06V10/20Image preprocessing
    • G06V10/22Image preprocessing by selection of a specific region containing or referencing a pattern; Locating or processing of specific regions to guide the detection or recognition
    • G06V10/23Image preprocessing by selection of a specific region containing or referencing a pattern; Locating or processing of specific regions to guide the detection or recognition based on positionally close patterns or neighbourhood relationships

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Multimedia (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Character Discrimination (AREA)
  • Traffic Control Systems (AREA)

Abstract

The invention provides a license plate recognition method, a license plate recognition device, license plate recognition equipment and a storage medium, and belongs to the technical field of image processing. The method comprises the following steps: acquiring a license plate recognition result recognized by a bitwise recognition method; determining assumed license plate recognition results corresponding to a plurality of preset license plate types one by one according to the processing rules of the plurality of preset license plate types and the license plate recognition results; determining confidence degrees corresponding to a plurality of assumed license plate recognition results respectively; and selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result. By generating assumed license plate recognition results corresponding to a plurality of preset license plate types one to one, different types of license plates can keep higher confidence, the confidence of wrong types of license plates after the license plates are processed is greatly reduced, and the confidence of the license plate recognition results of the license plates after the license plates pass through the processing rules of different preset license plate types is compared, so that the accuracy of license plate recognition is effectively improved.

Description

License plate recognition method, device, equipment and storage medium
Technical Field
The invention relates to the field of image processing, in particular to a license plate recognition method, a license plate recognition device, license plate recognition equipment and a storage medium.
Background
The license plate detection and identification technology is an important part in security monitoring environment, and the license plate in a picture can be clearly identified in application scenes such as automatic parking lot monitoring and high-speed gate monitoring. Therefore, the existing license plate recognition technology is also systematically developed, among numerous algorithms, a classification algorithm is generally used for classifying each character of the license plate according to a bit to obtain a predicted character and a confidence coefficient of the character, the results of each bit of the license plate are spliced together to obtain a final result, and the confidence coefficients of each bit are multiplied to obtain the recognition confidence coefficient of the license plate.
However, the existing method has many defects in recognition accuracy, and the most important problem is that illegal characters can be recognized at some positions by the method in order to be compatible with recognition of some special heterogeneous license plates (such as non-Chinese-character initial license plates, abnormal Chinese-character license plates of a museum/police car and the like), for example, the first position of a blue common license plate of a license plate is not a Chinese character, or the second position of the blue common license plate is not a letter, or the letter D and the number 0 are mixed.
Disclosure of Invention
The license plate recognition method, the license plate recognition device, the license plate recognition equipment and the storage medium provided by the embodiment of the invention can solve the technical problem of low license plate recognition precision in the prior art.
In order to achieve the above purpose, the embodiment of the present invention adopts the following technical solutions:
in a first aspect, a license plate recognition method provided in an embodiment of the present invention includes: acquiring a license plate recognition result recognized by a bitwise recognition method; determining assumed license plate identification results corresponding to a plurality of preset license plate types one by one according to processing rules of the plurality of preset license plate types and the license plate identification results; determining confidence degrees corresponding to a plurality of assumed license plate recognition results respectively; and selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result.
With reference to the first aspect, an embodiment of the present invention provides a first possible implementation manner of the first aspect, where the determining, according to processing rules of multiple preset license plate types and the license plate recognition result, an assumed license plate recognition result that corresponds to the multiple preset license plate types one to one includes: determining assumed positions of the license plates corresponding to the processing rules of the preset license plate types one by one according to the license plate identification result; determining the product of the confidence degrees corresponding to the characters of all character bits before the dummy bit and the dummy bit; determining a character string corresponding to the maximum value in the product; and generating a supposed license plate recognition result which corresponds to the plurality of preset license plate types one by one according to the character string.
With reference to the first aspect, an embodiment of the present invention provides a second possible implementation manner of the first aspect, where the selecting, as a target license plate recognition result, the assumed license plate recognition result corresponding to a maximum confidence coefficient from among the multiple confidence coefficients includes: determining the maximum total confidence that the number bit in each assumed license plate recognition result contains at most two English letters according to the processing rule of each preset license plate type; determining a post-processing identification result corresponding to the number bit according to the maximum total confidence; and selecting the post-processing recognition result with the maximum confidence as a target license plate recognition result from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types.
With reference to the second possible implementation manner of the first aspect, an embodiment of the present invention provides a third possible implementation manner of the first aspect, where the determining, according to the processing rule for each preset license plate type, a maximum total confidence that a number bit in the target license plate recognition result includes at most two english letters includes: respectively determining a first total confidence coefficient containing zero English letters, a second total confidence coefficient containing one English letter and a third total confidence coefficient containing two English letters in the number bits according to the processing rule of each preset license plate type; and taking the maximum value of the first total confidence, the second total confidence and the third total confidence as the maximum total confidence.
With reference to the third possible implementation manner of the first aspect, an embodiment of the present invention provides a fourth possible implementation manner of the first aspect, where the number bits include N-bit characters, where N is an integer greater than or equal to 4, and the determining, for each processing rule of the preset number plate type, a first total confidence level that a number bit includes a zero-bit english alphabet, a second total confidence level that a number bit includes a one-bit english alphabet, and a third total confidence level that a number bit includes a two-bit english alphabet respectively includes: acquiring a number confidence coefficient with the maximum confidence coefficient from confidence coefficients corresponding to a plurality of preset numbers and acquiring a letter confidence coefficient with the maximum confidence coefficient from confidence coefficients corresponding to a plurality of preset letters aiming at the processing rule of each preset license plate type; obtaining a first product of a first confidence coefficient and the numerical confidence coefficient, wherein the front M comprises J English letters, M is equal to N minus one, and J is an integer less than or equal to 2; acquiring a second product of a second confidence coefficient of the English letter containing X bits in the front M bits and the letter confidence coefficient, wherein X is equal to the subtraction of J by one; when J is 0, taking the maximum numerical value in the first product and the second product as a first total confidence coefficient; when J is 1, taking the maximum value in the first product and the second product as a second total confidence coefficient; and when J is 2, taking the maximum value in the first product and the second product as a third total confidence level.
With reference to the second possible implementation manner of the first aspect, an embodiment of the present invention provides a fifth possible implementation manner of the first aspect, where the selecting, as a target license plate recognition result, the post-processing recognition result with the highest confidence level from the multiple post-processing recognition results corresponding to the multiple processing rules of the preset license plate types includes: determining a confidence corresponding to each post-processing recognition result from a plurality of post-processing recognition results corresponding to a plurality of processing rules of the preset license plate types; and selecting the post-processing recognition result with the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result.
In a second aspect, an embodiment of the present invention provides a license plate recognition apparatus, including: the acquisition module is used for acquiring a license plate identification result identified by a bitwise identification method; the first data processing module is used for determining assumed license plate recognition results corresponding to a plurality of preset license plate types one by one according to processing rules of the plurality of preset license plate types and the license plate recognition results; the second data processing module is used for determining confidence degrees corresponding to the plurality of assumed license plate recognition results respectively; and the third data processing module is used for selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result.
With reference to the second aspect, an embodiment of the present invention provides a first possible implementation manner of the second aspect, where the third data processing module is further configured to: determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type; determining a post-processing identification result corresponding to the number bit according to the maximum total confidence; and selecting the post-processing recognition result with the maximum confidence coefficient from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types as a target license plate recognition result.
In a third aspect, a terminal device provided in an embodiment of the present invention includes: a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the steps of the license plate recognition method according to any one of the first aspect when executing the computer program.
In a fourth aspect, an embodiment of the present invention provides a storage medium, where the storage medium stores instructions, and when the instructions are executed on a computer, the instructions cause the computer to execute the license plate identification method according to any one of the first aspect.
Compared with the prior art, the embodiment of the invention has the following beneficial effects:
according to the license plate recognition method, the device, the equipment and the storage medium provided by the embodiment of the invention, the assumed license plate recognition results corresponding to the preset license plate types one by one are generated, so that the confidence coefficient of the heterogeneous license plates is kept higher, the confidence coefficient of the wrong license plates is greatly reduced after the wrong license plates are processed, and the confidence coefficient of the license plate recognition results of the license plates after the license plate recognition results of the license plates pass through the processing rules of different preset license plate types is compared, so that the accuracy of license plate recognition is effectively improved, the license plate recognition result with higher accuracy is obtained, and the technical problem of low license plate recognition accuracy in the prior art is solved.
Additional features and advantages of the disclosure will be set forth in the description which follows, or in part may be learned by the practice of the above-described techniques of the disclosure, or may be learned by practice of the disclosure.
In order to make the aforementioned and other objects, features and advantages of the present invention comprehensible, preferred embodiments accompanied with figures are described in detail below.
Drawings
In order to more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings needed to be used in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present invention and therefore should not be considered as limiting the scope, and for those skilled in the art, other related drawings can be obtained from the drawings without inventive effort.
Fig. 1 is a flowchart of a license plate recognition method according to a first embodiment of the present invention;
FIG. 2 is a flow chart of an identification structure of the license plate identification method shown in FIG. 1;
FIG. 3 is a flow chart of another recognition structure of the license plate recognition method shown in FIG. 1;
fig. 4 is a schematic functional module diagram of a license plate recognition device according to a second embodiment of the present invention;
fig. 5 is a schematic diagram of a terminal device according to a third embodiment of the present invention.
Detailed Description
In order to make the objects, technical solutions and advantages of the embodiments of the present invention clearer, the technical solutions in the embodiments of the present invention will be clearly and completely described below with reference to the drawings in the embodiments of the present invention, and it is obvious that the described embodiments are some, but not all embodiments of the present invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without making any creative effort, shall fall within the protection scope of the present invention. Thus, the following detailed description of the embodiments of the present invention, presented in the figures, is not intended to limit the scope of the invention, as claimed, but is merely representative of selected embodiments of the invention. All other embodiments, which can be derived by a person skilled in the art from the embodiments given herein without any inventive step, are within the scope of the present invention.
Some embodiments of the invention are described in detail below with reference to the accompanying drawings. The embodiments described below and the features of the embodiments can be combined with each other without conflict.
First embodiment
Since there are many defects in the recognition accuracy of the existing license plate recognition method, in order to compensate for the defects to improve the recognition accuracy, the present embodiment provides a license plate recognition method, it should be noted that the steps shown in the flowchart of the drawings may be executed in a computer system such as a set of computer executable instructions, and although a logical order is shown in the flowchart, in some cases, the steps shown or described may be executed in an order different from that here. This embodiment will be described in detail below.
Fig. 1 is a flowchart of a license plate recognition method according to an embodiment of the present invention. The specific process shown in FIG. 1 will be described in detail below.
Step S101, obtaining a license plate recognition result recognized by a position-based recognition method.
The license plate recognition result comprises a plurality of character bits.
Optionally, the license plate recognition result includes 9 bits of character bits, each bit of character bit corresponds to one character recognition result, each character recognition result is composed of real numbers of a length (numbers 0 to 9, chinese characters or english letters that may appear in the license plate) of a character set, and the ith real number represents a probability (i.e., a confidence) that the character may be the ith character. The 9-bit character recognition result comprises 8-bit license plate numbers and one-bit null characters, and the null character bits are used for later license plate number increase.
In practical use, the number of digits of the license plate recognition result can be adjusted according to license plate rules of different countries, and is not particularly limited herein.
For example, if the first real number in the character set corresponding to the first character recognition result in the license plate recognition result is 0.9 and the corresponding character is a, the second real number is 0.8 and the corresponding character is B, the first real number 0.9 represents the probability that the first character recognition result may be the character a.
Optionally, the license plate recognition result may be a matrix of K × L, where K is used to represent the number of bits of the character bits, and L is used to represent the length of the character set corresponding to the character recognition result corresponding to each bit of the character bits. For example, the license plate recognition result may be a matrix of 9 x 74.
In practical use, the license plate recognition result is usually classified by bit for each character of the license plate using a classification algorithm, and L predicted characters and a confidence for each predicted character are obtained for each character bit. And splicing the K-bit character recognition results of the license plate together to obtain a final result (namely a license plate recognition result). For example, the classification algorithm may be, but is not limited to, a bayesian classification method, a decision tree or support vector machine, or the like.
And S102, determining assumed license plate recognition results corresponding to a plurality of preset license plate types one by one according to processing rules of the plurality of preset license plate types and the license plate recognition results.
The processing rules of the plurality of preset license plate types comprise common seven-digit license plate processing rules, police vehicle license plate processing rules, embassy license plate processing rules, license plate processing rules of a license plate of a police car of a license plate of a country of China.
In order to more intuitively embody the processing rules of a plurality of preset license plate types, as shown in table one:
Figure BDA0001758209930000071
watch 1
As a possible implementation manner, step S102 includes: determining assumed positions of the license plates corresponding to the processing rules of the preset license plate types one by one according to the license plate recognition result; determining the product of the confidence degrees corresponding to the characters of all character bits before the dummy bit and the dummy bit; determining a character string corresponding to the maximum value in the product; and generating a supposed license plate recognition result which corresponds to the plurality of preset license plate types one by one according to the character string.
Wherein, the assumed bit refers to one or two of the 9 bits in the license plate recognition result. For example, the first bit, the last bit or any middle bit of the license plate recognition result can be obtained. For example, assume that the license plate recognition result is a Beijing P72U6 alarm, and if the bit is assumed to be the last bit, assume that the character corresponding to the bit is an alarm.
For example, as an example of the processing rule of one license plate type, for example, the license plate a is a beijing P72U6 police, the assumed bit is the last bit, the L confidence degrees corresponding to the first bit are a1 and a2 … aL, the L confidence degrees corresponding to the second bit are b1 and b2 … bL, the L confidence degrees corresponding to the third bit are c1 and c2 … cL, the L confidence degrees corresponding to the fourth bit are d1 and d2 … dL, the L confidence degrees corresponding to the fifth bit are e1 and e2 … eL, and the L confidence degrees corresponding to the sixth bit are f1 and f2 … fL,since the dummy bit is the seventh bit, the confidence level corresponding to the seventh bit is g1, and the products of the confidence levels corresponding to the characters in all the character bits before the dummy bit and the characters in all the character bits before the dummy bit are the products of the confidence level of any character in each bit and the confidence level of any character in each other bit, that is: CJ1 ═ a1, b1, c1, 0d1, 1e1, 2f1, 3g 1; CJ2 ═ a2, 4b2, 5c2, 6d2, 7e2, 8f2, 9g 1; CJ3 ═ a2, b1, 0c2, 1d2, 2e2, 3f2, g 1; CJ4, a2, b1, c1, d2, e2, f2, g1 and the like, in various combinations
Figure BDA0001758209930000081
Figure BDA0001758209930000082
A product from L6And selecting the character string corresponding to the product with the largest product from the products. Assuming that the value of the product CJ1 is the maximum value and the character string corresponding to CJ1 is 'Jing P72U6 police', the obtained assumed license plate recognition result corresponding to the police car license plate processing rule is 'Jing P72U6 police'.
For each preset license plate type processing rule, the character corresponding to the assumed position has the maximum confidence corresponding to the rule. For example, for the processing rule of the license plate of the police car, the confidence corresponding to the character with the 'alarm' at the last position is the highest relative to the confidence corresponding to the other character sets in the last position. For example, in the face of a license plate recognition result, it is assumed that the license plate is a certain type of license plate, and then a limit for recognizing the type of license plate is added to the license plate recognition result, for example, if a license plate is regarded as a police car license plate, it can be specified that the last position of the license plate must be a 'warning' character.
In this embodiment, by generating the assumed license plate recognition results corresponding to the preset license plate types one to one, a higher confidence level will be retained for different types of license plates, and the confidence level will be greatly reduced for the wrong type of license plate after the processing, and further, by comparing the confidence levels of the license plate recognition results of the license plates after the license plate recognition results of the license plates pass through the processing rules of the different preset license plate types, a license plate recognition result with higher accuracy is obtained.
Step S103, determining confidence degrees corresponding to the plurality of assumed license plate recognition results respectively.
An assumed license plate recognition result is obtained through each preset license plate type processing rule, and the assumed license plate recognition result corresponds to a confidence coefficient.
For example, if the license plate of a vehicle is jing P72U6D, the recognition result obtained by the processing rule of the common seven-digit license plate in the processing rules of the preset license plate types may be 'jing P72U 6D', and the confidence is 0.96; when the processing rule of the police car license plate in the processing rule of the preset license plate type is passed, the last position is fixed to be a character 'alarm', namely the position is assumed to be 'alarm', the identification result is 'Jing P72U6 alarm', and the position pattern is too different from the alarm character, so the confidence degree is 0.0001 which is extremely low.
If the license plate of a vehicle is a jinggo P72U6 police, the recognition result obtained by the processing rule of the common seven-digit license plate in the processing rules of the preset license plate types may be 'jinggo P72U 61' (from the experience, the model will regard the fuzzy 'alarm' word as a vertical line and judge the word as a number 1), but the confidence is 0.3 because the last digit and '1' are not special images; and the result obtained by the processing rule of the police car license plate in the processing rules of the preset license plate types is 'Jing P72U6 police', and the confidence is 0.9.
And step S104, selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result.
And comparing the confidence degrees corresponding to the assumed license plate recognition results obtained by the processing rules of each preset license plate type, thereby selecting the assumed license plate recognition result with the maximum confidence degree as the target license plate recognition result.
Continuing with the foregoing example, for the license plate of jing P72U6D, by comparing the confidence degrees, the assumed license plate recognition result corresponding to the maximum confidence degree is selected as the final result, and the final result will output a result of "jing P72U 6D", that is, the target license plate recognition result is "jing P72U 6D". For the license plate of the jinggin P72U6 police, the confidence corresponding to the 'jinggin P72U6 police' is 0.9, and the confidence corresponding to the 'jinggin P72U 6D' is 0.3, and the assumed license plate recognition result with the highest confidence is selected as the final result, so the final result will output the 'jinggin P72U6 police'.
In order to more intuitively embody the beneficial effects of the license plate recognition method in the embodiment of the invention, as shown in fig. 2, the license plate recognition result is processed by the processing rule of each preset license plate type, so as to obtain the assumed license plate recognition result corresponding to the processing rule of each preset license plate type one by one, and then the confidence corresponding to each assumed license plate recognition result is calculated, and the assumed license plate recognition result with the maximum confidence is selected as the target license plate recognition result. Therefore, compared with the prior art, by generating the assumed license plate recognition results corresponding to the preset license plate types one by one, higher confidence coefficient of the heterogeneous license plate is kept, the confidence coefficient of the wrong license plate after the processing is greatly reduced, and the confidence coefficient of the license plate recognition result of the license plate after the license plate recognition result of the license plate passes through the processing rules of different preset license plate types is compared, so that the accuracy of license plate recognition is effectively improved, the license plate recognition result with higher accuracy is obtained, and the technical problem of low license plate recognition accuracy in the prior art is solved.
As a possible implementation manner, step S104 includes: determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type; determining a post-processing identification result corresponding to the number bit according to the maximum total confidence; and selecting the post-processing recognition result with the maximum confidence as a target license plate recognition result from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types.
Optionally, the post-processing recognition result is different from the assumed license plate recognition result.
Optionally, the determining, by the processing rule for each preset license plate type, a maximum total confidence that a number bit in each assumed license plate recognition result includes at most two english letters includes: respectively determining a first total confidence coefficient containing zero English letters, a second total confidence coefficient containing one English letter and a third total confidence coefficient containing two English letters in the number positions according to the processing rule of each preset license plate type; and taking the maximum value of the first total confidence, the second total confidence and the third total confidence as the maximum total confidence.
Optionally, the number bits include N-bit characters, N is an integer greater than or equal to 4, the processing rule for each preset license plate type respectively determines a first total confidence level that includes zero-bit english letters in the number bits, a second total confidence level that includes one-bit english letters, and a third total confidence level that includes two-bit english letters, including: acquiring a number confidence degree with the maximum confidence degree from confidence degrees corresponding to a plurality of preset numbers and acquiring a letter confidence degree with the maximum confidence degree from confidence degrees corresponding to a plurality of preset letters according to the processing rule of each preset license plate type; obtaining a first product of a first confidence coefficient and the numeric confidence coefficient, wherein the first M bits comprise J-bit English letters, M is equal to the N minus one, and J is an integer less than or equal to 2; acquiring a second product of a second confidence coefficient of the English letter containing X bits in the front M bits and the letter confidence coefficient, wherein X is equal to the subtraction of J by one; when J is 0, taking the maximum numerical value in the first product and the second product as a first total confidence coefficient; when J is 1, taking the maximum value of the first product and the second product as a second total confidence coefficient; and when J is 2, taking the maximum value of the first product and the second product as a third total confidence level.
Optionally, the first product satisfies: f [ M ] [ j ] is the numerical confidence, and the second product satisfies: f [ M ] [ X ] X [ X ] letter confidence, where M is N-1 and X is j-1, i.e., fm ] [ j ] is fn-1 ] [ j ], fm ] [ X ] is fn-1 ] [ j-1 ], and N represents the length of (or represents that) a code bit includes an N-bit character.
F [ M ] [ j ] represents a first confidence degree when the front N-1 bit number contains j English letters, and F [ N-1 ] [ j-1 ] represents a second confidence degree when the front N-1 bit number contains j-1 English letters.
The first product and the second product maximum satisfy: f [ N ] [ j ] ═ max (F [ N-1 ] [ j ]/[ numerical confidence, F [ N-1 ] [ j-1 ]/[ alphabetical confidence);
the first total confidence satisfies: fn < 0 > max (Fn-1 < 0 > numeric confidence, Fn-1 < 0-1 > alphabetic confidence);
the second total confidence satisfies: f [ N ] [1] ═ max (F [ N-1 ] [1 ]. times the numeric confidence, F [ N-1 ] [ 1-1 ]. times the alphabetical confidence);
the third overall confidence satisfies: f [ N ] [2] max (F [ N-1 ] [2] x number confidence, F [ N-1 ] [ 2-1 ] x letter confidence).
In this embodiment, through a dynamic programming algorithm, let g [ i ] [ j ] represent the license plate character selected when selecting F [ i ] [ j ] to transfer, and the following state transfer formula is adopted:
f [ i ] [ j ] ═ max (confidence of F [ i-1 ] [ j ]/, highest confidence number, confidence of F [ i-1 ] [ j-1 ]/, highest confidence letter);
and selecting one with the highest confidence coefficient from F [ L (total number of digits) ] [0], F [ L ] [1] and F [ L ] [2], and performing reverse derivation through g [ i ] [ j ] to obtain a final license plate recognition result. For example, the character corresponding to each bit of the number bit is found through the maximum total confidence, wherein the character corresponding to each bit of the number bit satisfies the following conditions: g [ N ] [ j ] ═ F [ N ] [ j ] ═ max (F [ N-1 ] [ j ]/, number confidence, F [ N-1 ] [ j-1 ]/, letter confidence), for example, the first character of a code bit satisfies: if g [0] [0], (F [ 0-1 ] [0] is max (F [ 0-1 ] [0] x number confidence, F [ 0-1 ] [ 0-1 ] x letter confidence), then it means that the first digit of the code bit is a digit and the character of the digit is the digit corresponding to the digit confidence. On the contrary, if g [0] [0] ═ F [ 0-1 ] [ 0-1 ] x letter confidence level, the first digit of the number digit is the letter, and the character of the digit is the letter corresponding to the letter confidence level. And the rest is done in sequence, so that all characters of the number digits are obtained.
Optionally, the selecting, as the target license plate recognition result, the post-processing recognition result with the highest confidence level from the plurality of post-processing recognition results corresponding to the processing rules of the plurality of preset license plate types includes: determining a confidence corresponding to each post-processing recognition result from a plurality of post-processing recognition results corresponding to a plurality of processing rules of the preset license plate types; and selecting the post-processing recognition result with the maximum confidence level from the confidence levels as a target license plate recognition result.
For example, as shown in fig. 3, by further processing the number bits of the assumed license plate recognition result obtained in step S102 (for example, by executing one possible implementation manner in step S104), recognition results corresponding to the plurality of preset license plate types one to one are respectively obtained, and a confidence corresponding to each recognition result is determined; and selecting the recognition result with the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result. By further identifying the number digits of the assumed license plate identification result, unreasonable conditions of the number digits can be effectively avoided, such as three or more English letters appear in the number digits, the error rate of identification is further reduced, and the accuracy of license plate identification is effectively improved.
According to the license plate recognition method provided by the embodiment of the invention, the license plate recognition result is processed through the processing rule of each preset license plate type, so that the assumed license plate recognition result corresponding to the processing rule of each preset license plate type one by one is obtained, and the assumed license plate recognition result with the maximum confidence coefficient is selected as the target license plate recognition result by calculating the confidence coefficient corresponding to each assumed license plate recognition result. Therefore, compared with the prior art, by generating the assumed license plate recognition results corresponding to the preset license plate types one by one, higher confidence coefficient of different license plates can be kept, the confidence coefficient of wrong license plates after the processing is greatly reduced, and then the confidence coefficient of the license plate recognition results of the license plates after the license plates pass through the processing rules of different preset license plate types is compared, so that the accuracy of license plate recognition is effectively improved, the license plate recognition result with higher accuracy is obtained, and the technical problem of low license plate recognition accuracy in the prior art is solved.
Second embodiment
Fig. 4 shows a license plate recognition apparatus that uses the license plate recognition method shown in the first embodiment in a one-to-one correspondence, corresponding to the license plate recognition method in the first embodiment. As shown in fig. 4, the license plate recognition device 400 includes an acquisition module 410, a first data processing module 420, a second data processing module 430, and a third data processing module 440. The implementation functions of the obtaining module 410, the first data processing module 420, the second data processing module 430, and the third data processing module 440 correspond to the corresponding steps in the first embodiment one to one, and for avoiding redundancy, detailed descriptions are not needed in this embodiment.
The obtaining module 410 is configured to obtain a license plate recognition result recognized by a bitwise recognition method.
The first data processing module 420 is configured to determine assumed license plate recognition results corresponding to a plurality of preset license plate types one to one according to processing rules of the plurality of preset license plate types and the license plate recognition results.
Optionally, the first data processing module 420 is further configured to: determining the assumed positions of the license plates corresponding to the processing rules of the plurality of preset license plate types one by one according to the license plate identification result; determining the product of the confidence degrees corresponding to the characters of all character bits before the assumed bit and the assumed bit; determining a character string corresponding to the maximum value in the product; and generating assumed license plate recognition results corresponding to the preset license plate types one by one according to the character strings.
And the second data processing module 430 is configured to determine confidence levels corresponding to the plurality of assumed license plate recognition results.
The third data processing module 440 is configured to select the assumed license plate recognition result corresponding to the maximum confidence level from the multiple confidence levels as a target license plate recognition result.
Optionally, the third data processing module 440 is further configured to: determining the maximum total confidence that the number bit in each assumed license plate recognition result contains at most two English letters according to the processing rule of each preset license plate type; determining a post-processing identification result corresponding to the number bit according to the maximum total confidence; and selecting the post-processing recognition result with the maximum confidence as a target license plate recognition result from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types.
Optionally, the determining that the number bit in the target license plate recognition result includes the maximum total confidence of at most two english letters includes: respectively determining a first total confidence coefficient containing zero English letters, a second total confidence coefficient containing one English letter and a third total confidence coefficient containing two English letters in the number positions; and taking the maximum value of the first total confidence, the second total confidence and the third total confidence as the maximum total confidence.
Optionally, the number bits include N-bit characters, where N is an integer greater than or equal to 4, the determining a first total confidence level that includes zero english letters, a second total confidence level that includes one english letter, and a third total confidence level that includes two english letters in the number bits respectively includes: respectively acquiring a numeric confidence coefficient with the maximum confidence coefficient from confidence coefficients corresponding to a plurality of preset numbers and acquiring a letter confidence coefficient with the maximum confidence coefficient from confidence coefficients corresponding to a plurality of preset letters; obtaining a first product of a first confidence coefficient and the numerical confidence coefficient, wherein the front M comprises J English letters, M is equal to N minus one, and J is an integer less than or equal to 2; acquiring a second product of a second confidence coefficient of the English letter containing X bits in the front M bits and the letter confidence coefficient, wherein X is equal to the subtraction of J by one; when J is 0, taking the maximum numerical value in the first product and the second product as a first total confidence coefficient; when J is 1, taking the maximum value in the first product and the second product as a second total confidence coefficient; and when J is 2, taking the maximum value in the first product and the second product as a third total confidence coefficient.
Optionally, the selecting, as the target license plate recognition result, the post-processing recognition result with the highest confidence level from the plurality of post-processing recognition results corresponding to the processing rules of the plurality of preset license plate types includes: determining a confidence corresponding to each post-processing recognition result from a plurality of post-processing recognition results corresponding to a plurality of processing rules of the preset license plate types; and selecting the recognition result with the maximum confidence degree from the confidence degrees as a target license plate recognition result.
Third embodiment
As shown in fig. 5, is a schematic diagram of a terminal device 300. The terminal device 300 includes a memory 302, a processor 304, and a computer program 303 stored in the memory 302 and capable of running on the processor 304, where the computer program 303 is executed by the processor 304 to implement the license plate recognition method in the first embodiment, and details are not repeated here to avoid repetition. Alternatively, the computer program 303 is executed by the processor 304 to implement the functions of each model/unit in the license plate recognition apparatus according to the second embodiment, and details are not repeated here to avoid repetition.
Illustratively, the computer program 303 may be partitioned into one or more modules/units, which are stored in the memory 302 and executed by the processor 304 to implement the present invention. One or more of the modules/units may be a series of computer program instruction segments capable of performing specific functions, which are used to describe the execution of the computer program 303 in the terminal device 300. For example, the computer program 303 may be divided into the obtaining module 410, the first data processing module 420, the second data processing module 430, and the third data processing module 440 in the second embodiment, and specific functions of the modules are as described in the first embodiment or the second embodiment, which are not described herein again.
The terminal device 300 may be a desktop computer, a notebook, a palm computer, a cloud server, or other computing devices.
The Memory 302 may be, but is not limited to, a Random Access Memory (RAM), a Read Only Memory (ROM), a Programmable Read-Only Memory (PROM), an Erasable Read-Only Memory (EPROM), an electrically Erasable Read-Only Memory (EEPROM), and the like. The memory 302 is used for storing a program, and the processor 304 executes the program after receiving an execution instruction, and the method defined by the flow disclosed in any of the foregoing embodiments of the present invention may be applied to the processor 304, or implemented by the processor 304.
The processor 304 may be an integrated circuit chip having signal processing capabilities. The Processor 304 may be a general-purpose Processor, including a Central Processing Unit (CPU), a Network Processor (NP), and the like; but also Digital Signal Processors (DSPs), Application Specific Integrated Circuits (ASICs), Field Programmable Gate Arrays (FPGAs) or other Programmable logic devices, discrete Gate or transistor logic devices, discrete hardware components. The various methods, steps and logic blocks disclosed in the embodiments of the present invention may be implemented or performed. A general purpose processor may be a microprocessor or the processor may be any conventional processor or the like.
It is understood that the structure shown in fig. 5 is only a schematic structure of the terminal device 300, and the terminal device 300 may further include more or less components than those shown in fig. 5. The components shown in fig. 5 may be implemented in hardware, software, or a combination thereof.
Fourth embodiment
An embodiment of the present invention further provides a storage medium, where the storage medium stores instructions, and when the instructions run on a computer, when the computer program is executed by a processor, the license plate recognition method in the first embodiment is implemented, and for avoiding repetition, details are not repeated here. Alternatively, the computer program is executed by the processor to implement the functions of the models/units in the license plate recognition device according to the second embodiment, and details are not repeated here to avoid repetition.
From the above description of the embodiments, it is clear to those skilled in the art that the present invention can be implemented by hardware, or by software plus a necessary general hardware platform, and based on such understanding, the technical solution of the present invention can be embodied in the form of a software product, which can be stored in a non-volatile storage medium (which can be a CD-ROM, a usb disk, a removable hard disk, etc.), and includes several instructions to make a computer device (which can be a personal computer, a server, or a network device, etc.) execute the method of the embodiments of the present invention.
The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention, and various modifications and changes may be made by those skilled in the art. Any modification, equivalent replacement, improvement and the like made within the spirit and principle of the present invention shall be included in the protection scope of the present invention. It should be noted that: like reference numbers and letters refer to like items in the following figures, and thus, once an item is defined in one figure, it need not be further defined and explained in subsequent figures.

Claims (7)

1. A license plate recognition method is characterized by comprising the following steps:
acquiring a license plate recognition result recognized by a bitwise recognition method;
determining assumed license plate recognition results corresponding to the preset license plate types one by one according to processing rules of the preset license plate types and the license plate recognition results, wherein the assumed license plate recognition results are K-bit strings;
determining confidence degrees corresponding to a plurality of assumed license plate recognition results respectively;
selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result;
the method for determining the assumed license plate recognition results corresponding to the preset license plate types in one-to-one mode according to the processing rules of the preset license plate types and the license plate recognition results comprises the following steps: determining assumed positions of the license plates corresponding to the processing rules of the preset license plate types one by one according to the license plate identification result; determining the product of the confidence degrees corresponding to the characters of all character bits before the dummy bit and the dummy bit; determining a character string corresponding to the maximum value in the product; and generating a hypothetical license plate recognition result which corresponds to the preset license plate types one by one according to the character string, wherein the hypothetical bits refer to the last bit or any middle bit of the K bits in the license plate recognition result.
2. The method of claim 1, wherein said selecting the assumed license plate recognition result corresponding to the highest confidence level from the plurality of confidence levels as the target license plate recognition result comprises:
determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type;
determining a post-processing identification result corresponding to the number bit according to the maximum total confidence;
selecting the post-processing recognition result with the maximum confidence as a target license plate recognition result from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types;
the step of determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type comprises the following steps:
respectively determining a first total confidence coefficient containing zero English letters, a second total confidence coefficient containing one English letter and a third total confidence coefficient containing two English letters in the number positions according to the processing rule of each preset license plate type;
and taking the maximum value of the first total confidence, the second total confidence and the third total confidence as the maximum total confidence.
3. The method of claim 2, wherein the selecting a target license plate recognition result with a highest confidence level from the plurality of post-processing recognition results corresponding to the processing rules of the plurality of preset license plate types comprises:
determining a confidence corresponding to each post-processing recognition result from a plurality of post-processing recognition results corresponding to a plurality of processing rules of the preset license plate types;
and selecting the post-processing recognition result with the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result.
4. A license plate recognition device, comprising:
the acquisition module is used for acquiring a license plate identification result identified by a bitwise identification method;
the first data processing module is used for determining assumed license plate recognition results corresponding to a plurality of preset license plate types one by one according to processing rules of the plurality of preset license plate types and the license plate recognition results, and the assumed license plate recognition results are K-bit character strings;
the second data processing module is used for determining confidence degrees corresponding to the plurality of assumed license plate recognition results respectively;
the third data processing module is used for selecting the assumed license plate recognition result corresponding to the maximum confidence coefficient from the confidence coefficients as a target license plate recognition result;
the first data processing module is specifically used for determining assumed positions of the license plates corresponding to the processing rules of the multiple preset license plate types one by one according to the license plate recognition result; determining the product of the confidence degrees corresponding to the characters of all character bits before the dummy bit and the dummy bit; determining a character string corresponding to the maximum value in the product; generating assumed license plate recognition results corresponding to the preset license plate types one by one according to the character strings; the false bit refers to the last bit or the middle arbitrary bit in the K bits in the license plate recognition result.
5. The apparatus of claim 4, wherein the third data processing module is further configured to:
determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type;
determining a post-processing identification result corresponding to the number bit according to the maximum total confidence;
selecting the post-processing recognition result with the maximum confidence as a target license plate recognition result from a plurality of post-processing recognition results corresponding to the processing rules of the preset license plate types;
the step of determining the maximum total confidence that the number bits in each assumed license plate recognition result contain at most two English letters according to the processing rule of each preset license plate type comprises the following steps:
respectively determining a first total confidence coefficient containing zero English letters, a second total confidence coefficient containing one English letter and a third total confidence coefficient containing two English letters in the number positions according to the processing rule of each preset license plate type;
and taking the maximum value of the first total confidence, the second total confidence and the third total confidence as the maximum total confidence.
6. A terminal device, comprising: a memory, a processor and a computer program stored in the memory and executable on the processor, the processor implementing the steps of the license plate recognition method according to any one of claims 1 to 3 when executing the computer program.
7. A storage medium having stored thereon instructions which, when run on a computer, cause the computer to execute the license plate recognition method of any one of claims 1 to 3.
CN201810899533.6A 2018-08-08 2018-08-08 License plate recognition method, device, equipment and storage medium Active CN109063702B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201810899533.6A CN109063702B (en) 2018-08-08 2018-08-08 License plate recognition method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201810899533.6A CN109063702B (en) 2018-08-08 2018-08-08 License plate recognition method, device, equipment and storage medium

Publications (2)

Publication Number Publication Date
CN109063702A CN109063702A (en) 2018-12-21
CN109063702B true CN109063702B (en) 2022-05-17

Family

ID=64679032

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201810899533.6A Active CN109063702B (en) 2018-08-08 2018-08-08 License plate recognition method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN109063702B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111563504B (en) * 2020-07-16 2020-10-30 平安国际智慧城市科技股份有限公司 License plate recognition method and related equipment

Family Cites Families (12)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6553131B1 (en) * 1999-09-15 2003-04-22 Siemens Corporate Research, Inc. License plate recognition with an intelligent camera
KR100798477B1 (en) * 2006-05-23 2008-01-28 주식회사 인프라밸리 License plate recognition method using differential image and neural network
CN102693431B (en) * 2012-05-31 2014-09-24 贺江涛 Method and device for identifying type of white number plate
CN102722733A (en) * 2012-05-31 2012-10-10 信帧电子技术(北京)有限公司 Identification method and device of license plate types
CN104915644B (en) * 2015-05-29 2018-01-19 安徽四创电子股份有限公司 A kind of car plate intelligent distinguishing method rebuild based on difference data
CN105631470A (en) * 2015-12-21 2016-06-01 深圳市捷顺科技实业股份有限公司 Method and system for verifying license plate type
US10068146B2 (en) * 2016-02-25 2018-09-04 Conduent Business Services, Llc Method and system for detection-based segmentation-free license plate recognition
US10019640B2 (en) * 2016-06-24 2018-07-10 Accenture Global Solutions Limited Intelligent automatic license plate recognition for electronic tolling environments
CN106408950A (en) * 2016-11-18 2017-02-15 北京停简单信息技术有限公司 Parking lot entrance and exit license plate recognition system and method
CN108108734B (en) * 2016-11-24 2021-09-24 杭州海康威视数字技术股份有限公司 License plate recognition method and device
CN108229466B (en) * 2016-12-15 2020-12-11 杭州海康威视数字技术股份有限公司 License plate recognition method and device
CN106845478B (en) * 2016-12-30 2019-09-10 同观科技(深圳)有限公司 A kind of secondary licence plate recognition method and device of character confidence level

Also Published As

Publication number Publication date
CN109063702A (en) 2018-12-21

Similar Documents

Publication Publication Date Title
WO2022227388A1 (en) Log anomaly detection model training method, apparatus and device
US11734341B2 (en) Information processing method, related device, and computer storage medium
CN111783767B (en) Character recognition method, character recognition device, electronic equipment and storage medium
CN113051356A (en) Open relationship extraction method and device, electronic equipment and storage medium
CN112528633A (en) Text error correction method and device, electronic equipment and computer readable storage medium
CN114861635B (en) Chinese spelling error correction method, device, equipment and storage medium
CN113435499A (en) Label classification method and device, electronic equipment and storage medium
CN115473726A (en) Method and device for identifying domain name
CN109063702B (en) License plate recognition method, device, equipment and storage medium
CN115795065A (en) Multimedia data cross-modal retrieval method and system based on weighted hash code
CN113591881B (en) Intention recognition method and device based on model fusion, electronic equipment and medium
CN113869464A (en) Training method of image classification model and image classification method
CN110019193A (en) Similar account number recognition methods, device, equipment, system and readable medium
CN113342977B (en) Invoice image classification method, device, equipment and storage medium
CN114818686A (en) Text recommendation method based on artificial intelligence and related equipment
CN114301671A (en) Network intrusion detection method, system, device and storage medium
WO2005093554A2 (en) System and method for blocking key selection
CN111368071A (en) Video detection method and device based on video related text and electronic equipment
CN107111756B (en) Apparatus and method for detecting entities in an image
CN111680513B (en) Feature information identification method and device and computer readable storage medium
CN113111833B (en) Safety detection method and device of artificial intelligence system and terminal equipment
CN112527858B (en) Marketing account identification method, device, medium and equipment based on social content
CN114706927B (en) Data batch labeling method based on artificial intelligence and related equipment
CN116257856A (en) Source code detection method, source code detection device, computer equipment and storage medium
CN117633631A (en) Sensitive data identification method, device, equipment and storage medium based on information entropy

Legal Events

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