Character recognition method and device, model deployment method and device and electronic equipment

By introducing the similarity relationship between character categories in character recognition technology and using an integrated storage and computing chip for parallel computing, the problems of low recognition accuracy and high energy consumption in the existing technology are solved, achieving high efficiency and high accuracy. character recognition.

CN118823752APending Publication Date: 2024-10-22CHINA MOBILE COMM LTD RES INST +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202311499264.1
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2023-11-10
Publication Date
2024-10-22

AI Technical Summary

Technical Problem

Existing character recognition technology ignores the similarity between different character categories, resulting in low recognition accuracy and high energy consumption of computing equipment.

Method used

By inputting the image to be recognized into the classifier in each character cluster, character recognition is performed based on the similarity between character clusters, and the integrated storage and computing chip is used for parallel computing to improve recognition efficiency and accuracy.

Benefits of technology

It improves the accuracy and efficiency of character recognition, reduces energy consumption, and is suitable for a variety of scenarios such as license plate recognition and invoice number recognition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118823752A_ABST
    Figure CN118823752A_ABST
Patent Text Reader

Abstract

The invention discloses a character recognition method and device, a model deployment method and device and electronic equipment. Inputting the to-be-recognized image into the classifiers corresponding to the characters in the character clusters; the classifiers corresponding to the characters in each character cluster are deployed in the storage and calculation integrated chip; wherein each character corresponds to one character cluster, and the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; performing character recognition on the to-be-recognized image based on the confidence output by the classifier corresponding to the characters in each character cluster; the confidence coefficient represents the probability that the character in the to-be-recognized image is the character corresponding to the classifier.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to a character recognition method, a model deployment method, a device and an electronic device. Background Art

[0002] Character recognition refers to obtaining character information in an image. Related technologies extract the features of the target image (such as grayscale histogram, edge features, texture features, etc.), calculate the similarity between the target image features and the sample image features of various characters, and use the character with the highest similarity as the character recognition result. It can be seen that the related technology only considers the similarity between the target image features and the sample image features of various characters, and ignores the similarity between the sample image features of different characters, so the accuracy of character recognition is low. Summary of the invention

[0003] In view of this, embodiments of the present invention provide a character recognition method, device, electronic device, electronic device and storage medium, which can improve the accuracy of character recognition.

[0004] The technical solution of the embodiment of the present invention is achieved as follows:

[0005] On the one hand, an embodiment of the present invention provides a character recognition method, the method comprising:

[0006] Input the image to be recognized into the classifier corresponding to the characters in each character cluster; the classifier corresponding to the characters in each character cluster is deployed in the storage and computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value;

[0007] Based on the confidence of the classifier output corresponding to the characters in each character cluster, character recognition is performed on the image to be recognized; the confidence represents the probability that the character in the image to be recognized is the character corresponding to the classifier.

[0008] In the above scheme, the character recognition of the image to be recognized based on the confidence of the classifier output corresponding to the characters in each character cluster includes:

[0009] Determine the mean of the confidence scores of the classifier outputs corresponding to all characters in each character cluster;

[0010] Determine the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster;

[0011] A target character in the image to be recognized is determined based on the target character cluster.

[0012] In the above solution, determining the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster includes:

[0013] Determine the character cluster with the largest mean as the target character cluster;

[0014] If there are multiple target character clusters, determining the character intersection of the multiple target character clusters;

[0015] Determine the target character in the image to be recognized based on the character intersection.

[0016] On the other hand, an embodiment of the present invention provides a model deployment method, the method comprising:

[0017] Determine the similarity between images corresponding to various characters;

[0018] Based on the similarity, determining a character cluster corresponding to each character; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier;

[0019] The classifiers corresponding to the characters in each character cluster are deployed in the storage and computing integrated chip.

[0020] In the above solution, the determining of the similarity between the images corresponding to various characters includes:

[0021] Inputting the image data set corresponding to the first character into the classifier corresponding to the second character to obtain the confidence of each image in the image data set; the confidence represents the probability that the classifier recognizes the character in the image as the second character;

[0022] Determining the number of images in the image data set whose confidence level is greater than a second set value;

[0023] Based on the number of images, a similarity between the image corresponding to the first character and the image corresponding to the second character is determined.

[0024] In the above scheme, the classifier is a neural network model adapted to the storage and computing integrated chip.

[0025] On the other hand, an embodiment of the present invention provides a character recognition device, the device comprising:

[0026] An input module, used for inputting the image to be recognized into the classifier corresponding to the characters in each character cluster; the classifier corresponding to the characters in each character cluster is deployed in the storage and computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value;

[0027] The recognition module is used to perform character recognition on the image to be recognized based on the confidence output of the classifier corresponding to the characters in each character cluster; the confidence represents the probability that the characters in the image to be recognized are the characters corresponding to the classifier.

[0028] On the other hand, an embodiment of the present invention provides a model deployment device, the device comprising:

[0029] A first determination module is used to determine the similarity between images corresponding to various characters;

[0030] A second determination module is used to determine a character cluster corresponding to each character based on the similarity; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier;

[0031] The deployment module is used to deploy the classifiers corresponding to the characters in each character cluster into the storage and computing integrated chip.

[0032] On the other hand, an embodiment of the present invention provides an electronic device, including a processor and a memory, which are interconnected, wherein the memory is used to store a computer program, the computer program includes program instructions, and the processor is configured to call the program instructions to execute the steps of the character recognition method or model deployment method provided in the embodiment of the present invention.

[0033] On the other hand, an embodiment of the present invention provides a computer-readable storage medium, including: the computer-readable storage medium stores a computer program. When the computer program is executed by a processor, the steps of the information processing method or model deployment method provided in the embodiment of the present invention are implemented.

[0034] The embodiment of the present invention performs character recognition on the image to be recognized by inputting the image to be recognized into the classifiers corresponding to the characters in each character cluster, based on the confidence output by the classifiers corresponding to the characters in each character cluster. The confidence represents the probability that the character in the image to be recognized is the character corresponding to the classifier, and the classifiers corresponding to the characters in each character cluster are deployed in a storage-computing integrated chip. Each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value. This embodiment introduces the similarity between the images of various characters in the character recognition process, and performs character recognition based on the confidence output by the classifiers of the characters in each character cluster, thereby increasing the utilization rate of effective information and improving the accuracy of character recognition. In addition, the characteristics of the storage-computing integrated computing architecture are fully utilized to realize parallel calculation of classifiers corresponding to multiple characters in multiple character clusters, thereby improving the recognition efficiency of character recognition. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] Figure 1 It is a schematic diagram of an implementation flow of a model deployment method provided by an embodiment of the present invention;

[0036] Figure 2 is a schematic diagram of character image similarity provided by an embodiment of the present invention;

[0037] Figure 3 It is a schematic diagram of deploying a classifier to a storage-computing integrated chip provided by an embodiment of the present invention;

[0038] Figure 4 It is a schematic diagram of an implementation flow of a character recognition method provided by an embodiment of the present invention;

[0039] Figure 5 It is a schematic diagram of a flow chart of character recognition by a classifier provided by an embodiment of the present invention;

[0040] Figure 6 is a schematic diagram of a character recognition device provided by an embodiment of the present invention;

[0041] Figure 7 is a schematic diagram of a model deployment device provided by an embodiment of the present invention;

[0042] Figure 8 is a schematic diagram of an electronic device provided by an embodiment of the present invention. DETAILED DESCRIPTION

[0043] The following will be combined with the drawings in the embodiments of the present invention to clearly and completely describe the technical solutions in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by ordinary technicians in this field without creative work are within the scope of protection of the present invention.

[0044] Character recognition refers to obtaining character information in an image and converting the text in the image into text. Common character recognition methods are based on artificially extracted feature information (such as grayscale histograms, edge features, texture features, etc.), and the final recognition result is obtained by comparing the similarity between the features of the recognition target and the features of the labeled data. With the development of computer technology, character recognition methods represented by convolutional neural networks are also widely used in the field of text recognition. However, character recognition faces complex situations including illumination changes, low resolution, font and layout diversity, and a large number of character types. The recognition accuracy of existing methods depends on the accuracy of feature extraction, and the feature extraction process is computationally intensive and energy-intensive. Therefore, studying a low-energy character recognition method has important application value and research significance.

[0045] The character recognition method of the related art has the following problems:

[0046] 1) Related technologies mostly rely on manually extracted feature information (such as grayscale histogram, edge features, texture features, etc.), and feature extraction directly affects the accuracy of subsequent image text recognition;

[0047] 2) Most of the related technologies aim to classify whether a single character image belongs to a certain character category, while ignoring the similarity between images of different character categories. For example, the image of the character "7" has a high similarity with the image of the character "1", but has a low similarity with the image of the character "3". However, the related technologies generally do not pay attention to whether the image of the character "7" is similar to the images of other characters.

[0048] 3) Related technologies use complex operators such as convolution, nonlinear activation, and batch normalization in the process of image feature extraction, character segmentation, and recognition. These require computing devices to have high computing power and consume high energy when used on devices such as central processing units (CPU) and graphics processing units (GPU) for calculations.

[0049] In view of the shortcomings of the above-mentioned related technologies, the embodiments of the present invention provide a model deployment method and a character recognition method, which can improve the accuracy of character recognition. In order to illustrate the technical solution of the present invention, a specific embodiment is used for description below.

[0050] Figure 1 1 is a schematic diagram of an implementation flow of a model deployment method provided by an embodiment of the present invention, wherein the execution subject of the model deployment method is an electronic device. Figure 1 , model deployment methods include:

[0051] S101, determining the similarity between images corresponding to various characters.

[0052] The model of this embodiment refers to a classifier, for example, a binary classifier. Each character corresponds to a classifier, and the classifier can identify whether the character in the image is the character corresponding to the classifier. For example, the classifier corresponding to the character "1" can be used to identify whether the image includes the character "1".

[0053] Prior to this, it is necessary to pre-train a classifier for each image category. First, a binary classification dataset is established for each character, where one subset contains images of characters of a specific category (e.g., character "1"), and the other subset contains images of other character categories (e.g., character "2" and character "3"). The binary classifier is trained using the binary classification dataset, and the output result is the confidence p that the input image contains characters of a specific category. Each target character corresponds to a specific binary classifier.

[0054] The established binary classification data set includes two subsets. The first subset is an image set containing characters of a specific category, which may account for 50% to 60% of the binary classification data set, and the second subset is images of other character categories, which may account for 40% to 50% of the binary classification data set.

[0055] The number of binary classification data sets established is equal to the number of categories. For example, in digital character recognition, it is necessary to establish 10 binary classification data sets for numbers 0 to 9. The establishment of binary classification data sets does not rely on manual extraction. On the basis of the existence of labeled data sets, only random extraction is required to complete the establishment of binary classification data sets, saving manpower and time costs.

[0056] Here, the similarity between characters refers to the similarity between an image containing character A and an image containing character B. Image similarity judgment may be performed between image data sets of two characters to obtain the similarity between the characters.

[0057] For example, input n images corresponding to character A into the binary classifier of character B, and obtain n classification results. The classification result is the confidence, which indicates the probability that the character in the image is recognized as character B. Count the number m of confidences greater than the threshold θ in the n classification results, and calculate the similarity between character B and character A based on n and m.

[0058] S102, based on the similarity, determine the character cluster corresponding to each character; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier.

[0059] Here, each character corresponds to a character cluster.

[0060] For example, characters whose similarity to the image of character A is greater than or equal to the first set value include character B, character C, and character D. Characters B, C, and D are divided into the same character cluster to obtain the character cluster {B, C, D} corresponding to character A. This indicates that the image corresponding to character B, the image corresponding to character C, and the image corresponding to character D have a similarity to the image of character A that is greater than or equal to the first set value.

[0061] After obtaining the similarity between the images of various characters, character clusters are divided. A dynamic threshold t is set, and for each character, characters with image similarity greater than t are divided into a cluster.

[0062] For example, Figure 2 As shown, Figure 2 It is a schematic diagram of character image similarity provided by an embodiment of the present invention.

[0063] in, Figure 1 The numbers 0 to 9 in the first column and the first row represent characters respectively. The threshold t=0.5 is set. The characters whose image similarity with character 0 is greater than the threshold include 2, 6 and 9. Then the character cluster corresponding to character 0 is (2, 6, 9), the character cluster corresponding to character 1 is (4, 7), the character cluster corresponding to character 2 is (3, 8), and so on.

[0064] S103, deploying the classifiers corresponding to the characters in each character cluster into the storage and computing integrated chip.

[0065] In one embodiment, the classifier is a neural network model adapted to the storage and computing integrated chip.

[0066] Each character corresponds to a classifier. The classifier is essentially a neural network model. The weight matrix of the classifier is written into the storage array of the storage and computing integrated chip to realize the deployment of the classifier on the storage and computing integrated chip.

[0067] At present, modern computers using the von Neumann architecture have a large amount of power consumption and latency due to the separation of computing units and storage units. Data is repeatedly transferred between the CPU and the memory, which hinders the innovation of memory-intensive scenarios such as artificial intelligence that have strong computing power requirements. Storage-computing integration is a new type of computing technology that relies on innovations in materials, devices, computing paradigms, and architectures. It can use storage units to complete computing functions to achieve zero distance between storage and computing, greatly improving computing power and energy efficiency.

[0068] In this embodiment, the storage and computing integrated chip includes resistive random access memory (RRAM), static random access memory (SRAM), Flash (non-volatile flash memory) memory, dynamic random access memory (DRAM), magnetic random access memory (MRAM), etc.

[0069] For example, the integrated storage and computing chip can be a memristor (Resistive Random Access Memory, RRAM). The resistive random access memory array is based on memristor devices that can change resistance by applying external bias voltage. The weight value of the "neuron" is programmed into the memristor device in the array. The vector is input into the array in the form of voltage, and the multiplication and addition operation result can be obtained in the form of current.

[0070] The principle of matrix multiplication and addition operation of resistive switching array is: the vector is encoded into different read voltages or different numbers of read pulses and applied to different columns, and the element values ​​in the matrix are encoded into the conductance value of the memristor device. According to Ohm's law, when the voltage acts on the conductance, the output current value represents the result of the multiplication calculation; according to Kirchhoff's current law, the output current value of each row naturally summarizes the current flowing through each device, completing the cumulative calculation. Finally, the output current value of each row represents the result vector of the matrix-vector multiplication.

[0071] Based on the analog computing characteristics of the integrated storage and computing chip, parallel calculation of confidence can be achieved, efficient feature extraction can be completed, and the recognition efficiency of character recognition can be improved.

[0072] For example, Figure 3 FIG. 1 is a schematic diagram of deploying a classifier to a storage-computing integrated chip provided by an embodiment of the present invention. Figure 3 As shown, multiple cluster weak classifiers are deployed in parallel in the computing array of the storage and computing integrated chip, and multiple classifiers are calculated in parallel when performing confidence calculation. Among them, multiple cluster weak classifiers refer to classifiers corresponding to characters in multiple character clusters.

[0073] Among them, V1, V2, and V3 represent input data respectively. In memristor array calculation, the input data is converted into voltage and input into the memristor array in parallel. 1.1 , W 1.2 , W 1.3 , W 2.1 , W 2.2 , W 2.3 , W 3.1 , W 3.2 , W 3.3 They represent model parameters (weights) respectively. In the memristor array calculation, the conductance value of each memristor is used to store the corresponding model parameters. After each cluster of model parameters is expanded into a column, it will be deployed on a column of memristors. I1, I2, and I3 represent the calculation results. Based on Ohm's law and Kirchhoff's law, current = voltage * conductance, and the final output current = the sum of the currents of each branch, so the current output is equivalent to the final multiplication and addition result.

[0074] In one embodiment, determining the similarity between images corresponding to various characters includes:

[0075] Inputting the image data set corresponding to the first character into the classifier corresponding to the second character to obtain the confidence of each image in the image data set; the confidence represents the probability that the classifier recognizes the character in the image as the second character;

[0076] Determining the number of images in the image data set whose confidence level is greater than a second set value;

[0077] Based on the number of images, a similarity between the image corresponding to the first character and the image corresponding to the second character is determined.

[0078] For example, the classifier Ψ corresponding to character A is trained A ,Ψ A The input is image G, and the output is confidence p, where p represents the probability of whether the character in image G is character A. The image similarity between character A and character B can be obtained by the following method:

[0079] Assumption D B is the image dataset corresponding to character B, D B The character image that only contains character B, D B Input classifier Ψ A Get the output P AB ={p1,p2,…,p n}, n is the number of images in the image dataset, then the image similarity evaluation value of character A and character B is Where m is P AB The number of p values ​​greater than the threshold θ.

[0080] Figure 4 is a schematic diagram of an implementation flow of a character recognition method provided by an embodiment of the present invention, with reference to Figure 4 , character recognition methods include:

[0081] S401, input the image to be recognized into the classifier corresponding to the characters in each character cluster; the classifier corresponding to the characters in each character cluster is deployed in a storage and computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value.

[0082] S402, based on the confidence output by the classifier corresponding to the characters in each character cluster, character recognition is performed on the image to be recognized; the confidence represents the probability that the character in the image to be recognized is the character corresponding to the classifier.

[0083] Here, the storage-computing integrated chip may be a memory of an electronic device, and the image to be recognized is an image including characters to be recognized.

[0084] Each character corresponds to a character cluster, which may include multiple characters. For example, the character cluster corresponding to the digital character "0" is (2, 6, 9), where the similarity between the image including character 0 and the image including character 2 is greater than or equal to a first set value (for example, 0.5); the similarity between the image including character 0 and the image including character 6 is greater than or equal to the first set value; the similarity between the image including character 0 and the image including character 9 is greater than or equal to the first set value.

[0085] For example, suppose there are 5 character clusters, and the classifier corresponding to each character in each character cluster outputs a confidence score respectively. A threshold A can be set here. First, the character clusters whose classifier confidence scores of all characters in the character cluster are less than threshold A are excluded. Then, the mean of the confidence scores output by the classifiers corresponding to each character in the remaining character clusters is calculated, and the character corresponding to the character cluster with the largest mean score is determined as the character in the image to be recognized.

[0086] If there are multiple character clusters with the same mean, they can be calculated multiple times through the integrated storage and computing chip. Because the calculation results of each calculation of the integrated storage and computing chip may be different, multiple calculations can ensure that the mean corresponding to each character cluster is different.

[0087] The embodiment of the present application introduces the correlation between character categories in the character recognition process through a method based on character cluster similarity, thereby increasing the utilization rate of effective information and improving the accuracy of character recognition.

[0088] The embodiment of the present application is based on a new storage-computing integrated computing architecture, and uses character cluster similarity to achieve efficient feature extraction. In this process, the characteristics of the storage-computing integrated architecture are fully utilized to achieve efficient and high-accuracy character recognition.

[0089] The embodiment of the present invention performs character recognition on the image to be recognized by inputting the image to be recognized into the classifiers corresponding to the characters in each character cluster, based on the confidence output by the classifiers corresponding to the characters in each character cluster. The confidence represents the probability that the characters in the image to be recognized are the characters corresponding to the classifiers, and the classifiers corresponding to the characters in each character cluster are deployed in a storage-computing integrated chip. Each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value. This embodiment introduces the similarity between the images of various characters in the character recognition process, and performs character recognition based on the confidence output by the classifiers of the characters in each character cluster, thereby increasing the utilization rate of effective information and improving the accuracy of character recognition. In addition, the characteristics of the storage-computing integrated computing architecture are fully utilized to realize parallel calculation of classifiers of multiple character clusters, thereby improving the recognition efficiency of character recognition.

[0090] In one embodiment, the character recognition of the image to be recognized based on the confidence of the classifier output corresponding to the characters in each character cluster includes:

[0091] Determine the mean of the confidence scores of the classifier outputs corresponding to all characters in each character cluster;

[0092] Determine the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster;

[0093] A target character in the image to be recognized is determined based on the target character cluster.

[0094] For example, assuming there are three character clusters in total, the mean confidence value of the classifier outputs of all characters in the character cluster corresponding to character A is 0.5, the mean confidence value of the classifier outputs of all characters in the character cluster corresponding to character B is 0.6, and the mean confidence value of the classifier outputs of all characters in the character cluster corresponding to character C is 0.7. The character cluster corresponding to character C has the largest mean value, so it can be determined that the target character cluster is the character cluster corresponding to character C.

[0095] For example, the character C may be determined as the target character in the image to be recognized. Alternatively, the character with the highest confidence in the character cluster corresponding to the character C may be determined as the target character in the image to be recognized.

[0096] In one embodiment, determining the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster includes:

[0097] Determine the character cluster with the largest mean as the target character cluster;

[0098] If there are multiple target character clusters, determining the character intersection of the multiple target character clusters;

[0099] A target character in the image to be recognized is determined based on the character intersection.

[0100] If there are multiple character clusters with the largest mean, the character intersection of the multiple target character clusters is determined. For example, the character intersection of the target character cluster (2, 6, 9) and the target character cluster (2, 8) is (2), and the character "2" therein is the target character in the image to be recognized.

[0101] If there are multiple intersections, the target character can be determined based on the confidence of the classifier corresponding to each character in the intersection. For example, the intersection is (2, 6), the confidence of the classifier corresponding to the character "2" is 0.6, and the confidence of the classifier corresponding to the character "6" is 0.7. The character "6" with a higher confidence is the target character in the image to be recognized.

[0102] In the embodiments of the present application, a method based on character cluster similarity introduces the correlation between character categories in the process of character recognition, increases the utilization rate of effective information, and can improve the accuracy of character recognition.

[0103] In an application embodiment, Figure 5 FIG. 5 is a schematic diagram of a license plate recognition process provided by an application embodiment of the present invention. Taking license plate recognition as an example, in the license plate recognition task, the number of target characters is fixed: 24 English characters (excluding O and I), 10 digital characters, and 31 Chinese characters (Beijing, Tianjin, Hebei, Shanxi, Inner Mongolia, Liaoning, Jilin, Heilongjiang, Shanghai, Jiangsu, Zhejiang, Anhui, Fujian, Jiangxi, Shandong, Henan, Hubei, Hunan, Guangdong, Guangxi, Hainan, Chongqing, Sichuan, Guizhou, Yunnan, Tibet, Shaanxi, Gansu, Qinghai, Ningxia, Xinjiang). Each of these characters corresponds to a classifier, and each character corresponds to a character cluster.

[0104] First, perform character segmentation on the license plate image to obtain multiple segmented images, and each segmented image includes one character. As Figure 5 shown, after segmenting the license plate image, each segmented image includes one character in the license plate number "Su EUK722".

[0105] Then, perform category cluster feature extraction. The category cluster feature refers to the mean of the confidence levels output by the classifiers corresponding to the characters in each character cluster. Input the image to be recognized into the classifiers corresponding to the characters in each character cluster respectively. Each character cluster corresponds to N classifiers, N is greater than or equal to 1, and each of the N classifiers corresponding to each character cluster outputs a confidence level. Calculate the mean of the confidence levels output by the N classifiers corresponding to each character cluster, determine the character cluster with the highest mean, determine the character corresponding to the classifier with the highest confidence level in the character cluster with the highest mean, and determine this character as the character in the image to be recognized.

[0106] If there are multiple character clusters with the highest mean, the intersection of the multiple character clusters can be determined. If the intersection has only one character, determine this character as the character in the image to be recognized. If the intersection has multiple characters, determine the character with the highest confidence level in the intersection, and determine this character as the character in the image to be recognized.

[0107] If there are multiple characters with the highest confidence level in the intersection, the image to be recognized can be input into the classifiers corresponding to the characters in each character cluster multiple times, and the output results of the image to be recognized can be obtained multiple times. Because the results obtained by the in-memory computing chip in each operation may be slightly different, and the confidence levels output by the classifier each time may be different, by comprehensively considering the results of multiple operations, the final mean is determined to be different, so as to recognize the character in the image to be recognized according to the above method.

[0108] After applying the integrated storage and computing chip for efficient feature extraction, the features obtained include both the correlation between the target characters and each category cluster, and the correlation between each character category, which can perform more accurate character recognition.

[0109] The embodiment of the present application is based on a new storage-computing integrated computing architecture, and uses character cluster similarity to achieve efficient feature extraction. In this process, the characteristics of the storage-computing integrated architecture are fully utilized to achieve efficient and high-accuracy character recognition.

[0110] The embodiment of the present application introduces the correlation between categories in the character recognition process through a method based on the similarity of character clusters, thereby increasing the utilization rate of effective information. By making full use of the characteristics of the new computing architecture that integrates storage and computing, parallel feature extraction of weak classifiers of multiple category clusters can be achieved, realizing a high degree of integration of software algorithms and hardware devices.

[0111] The embodiment of the present application is based on a new storage and computing integrated computing architecture, and uses character cluster similarity to achieve efficient feature extraction. In this process, the characteristics of the storage and computing integrated architecture are fully utilized to achieve efficient and high-accuracy character recognition. First, the embodiment of the present application does not rely on artificial feature extraction methods, such as grayscale histograms, edge features, texture features, etc., which greatly saves manpower and time. Secondly, the embodiment of the present application introduces the correlation between categories in the character recognition process through a method based on character cluster similarity, increases the utilization rate of effective information, and improves the accuracy of character recognition. At present, there are methods for improving the accuracy of character recognition based on the correlation of context characters, but such methods are not suitable for character recognition scenarios without context relationships such as license plate recognition and invoice number recognition. Thirdly, the embodiment of the present application fully utilizes the characteristics of the new storage and computing integrated computing architecture to achieve a high degree of integration of software algorithms and hardware devices, which can effectively improve computing efficiency. The image similarity evaluation method proposed in the embodiment of the present application is applicable to a variety of scenarios, such as license plate recognition, banknote crown code recognition, invoice number recognition, etc. It is especially suitable for scenarios where context information cannot be used, such as license plate recognition.

[0112] It should be understood that the order of execution of the steps in the above embodiment does not necessarily mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present invention.

[0113] It should be understood that when used in this specification and the appended claims, the terms "include" and "comprises" indicate the presence of described features, integers, steps, operations, elements and / or components, but do not exclude the presence or addition of one or more other features, integers, steps, operations, elements, components and / or combinations thereof.

[0114] It should be noted that the technical solutions described in the embodiments of the present invention can be arbitrarily combined without conflict.

[0115] In addition, in the embodiments of the present invention, "first", "second", etc. are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.

[0116] refer to Figure 6 , Figure 6 is a schematic diagram of a character recognition device provided by an embodiment of the present invention, such as Figure 6 As shown, the device comprises:

[0117] An input module, used for inputting the image to be recognized into the classifier corresponding to the characters in each character cluster; the classifier corresponding to the characters in each character cluster is deployed in the storage and computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value;

[0118] The recognition module is used to perform character recognition on the image to be recognized based on the confidence output of the classifier corresponding to the characters in each character cluster; the confidence represents the probability that the characters in the image to be recognized are the characters corresponding to the classifier.

[0119] In one embodiment, the identification module is specifically used for:

[0120] Determine the mean of the confidence scores of the classifier outputs corresponding to all characters in each character cluster;

[0121] Determine the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster;

[0122] A target character in the image to be recognized is determined based on the target character cluster.

[0123] In one embodiment, when the recognition module determines the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster, it is specifically configured to:

[0124] Determine the character cluster with the largest mean as the target character cluster;

[0125] If there are multiple target character clusters, determining the character intersection of the multiple target character clusters;

[0126] A target character in the image to be recognized is determined based on the character intersection.

[0127] refer to Figure 7 , Figure 7 is a schematic diagram of another model deployment device provided by an embodiment of the present invention, such as Figure 7 As shown, the device comprises:

[0128] A first determination module is used to determine the similarity between images corresponding to various characters;

[0129] A second determination module is used to determine a character cluster corresponding to each character based on the similarity; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier;

[0130] The deployment module is used to deploy the classifiers corresponding to the characters in each character cluster into the storage and computing integrated chip.

[0131] In one embodiment, the first determining module is specifically configured to:

[0132] Inputting the image data set corresponding to the first character into the classifier corresponding to the second character to obtain the confidence of each image in the image data set; the confidence represents the probability that the classifier recognizes the character in the image as the second character;

[0133] Determining the number of images in the image data set whose confidence level is greater than a second set value;

[0134] Based on the number of images, a similarity between the image corresponding to the first character and the image corresponding to the second character is determined.

[0135] In one embodiment, the classifier is a neural network model adapted to the storage and computing integrated chip.

[0136] In actual application, the input module and the recognition module can be implemented by a processor in an electronic device, such as a central processing unit (CPU), a digital signal processor (DSP), a microcontroller unit (MCU) or a programmable gate array (FPGA).

[0137] It should be noted that: the character recognition device provided in the above embodiment only uses the division of the above modules as an example when performing character recognition. In actual applications, the above processing can be assigned to different modules as needed, that is, the internal structure of the device is divided into different modules to complete all or part of the processing described above. In addition, the character recognition device provided in the above embodiment and the character recognition method embodiment belong to the same concept, and the specific implementation process is detailed in the method embodiment, which will not be repeated here.

[0138] The above-mentioned character recognition device can be in the form of an image file. After the image file is executed, it can be run in the form of a container or a virtual machine to implement the character recognition method described in this application. Of course, it is not limited to the image file form. As long as some software forms that can implement the character recognition method described in this application are within the protection scope of this application.

[0139] Based on the hardware implementation of the above program modules and in order to implement the method of the embodiment of the present application, the embodiment of the present application also provides an electronic device. Figure 8 Schematic diagram of the hardware structure of the electronic device of the present application embodiment. Figure 8 As shown, the electronic equipment includes:

[0140] Communication interface 801, capable of exchanging information with other devices such as network devices;

[0141] The processor 802 is connected to the communication interface 801 to implement information exchange with other devices and is used to execute the method provided by one or more technical solutions of the electronic device side when running the computer program. The computer program is stored in the memory 803.

[0142] Of course, in actual application, the various components in the electronic device are coupled together through the bus system 804. It can be understood that the bus system 804 is used to realize the connection and communication between these components. In addition to the data bus, the bus system also includes a power bus, a control bus, and a status signal bus. However, for the sake of clarity, Figure 8 Various buses are labeled as bus system 804 .

[0143] The memory 803 in the embodiment of the present application is used to store various types of data to support the operation of the electronic device. Examples of such data include: any computer program used to operate on the electronic device.

[0144] It can be understood that the memory can be a volatile memory or a non-volatile memory, and can also include both volatile and non-volatile memories. Among them, the non-volatile memory can be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable programmable read-only memory (EEPROM), a magnetic random access memory (FRAM), a flash memory, a magnetic surface memory, an optical disc, or a compact disc read-only memory (CD-ROM); the magnetic surface memory can be a disk memory or a tape memory. The volatile memory can be a random access memory (RAM), which is used as an external cache. By way of example and not limitation, many forms of RAM are available, such as static random access memory (SRAM), synchronous static random access memory (SSRAM), dynamic random access memory (DRAM), synchronous dynamic random access memory (SDRAM), double data rate synchronous dynamic random access memory (DDRSDRAM), enhanced synchronous dynamic random access memory (ESDRAM), synchronous link dynamic random access memory (SLDRAM, SyncLink Dynamic Random Access Memory), and direct RAM bus random access memory (DRRAM, Direct Rambus Random Access Memory).The memories described in the embodiments of the present application are intended to include, but are not limited to, these and any other suitable types of memories.

[0145] The method disclosed in the above embodiment of the present application can be applied to a processor or implemented by a processor. The processor may be an integrated circuit chip with signal processing capabilities. In the implementation process, each step of the above method can be completed by an integrated logic circuit of hardware in the processor or an instruction in the form of software. The above processor may be a general-purpose processor, a DSP, or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc. The processor can implement or execute the various methods, steps and logic block diagrams disclosed in the embodiments of the present application. The general-purpose processor may be a microprocessor or any conventional processor, etc. In combination with the steps of the method disclosed in the embodiment of the present application, it can be directly embodied as a hardware decoding processor to execute, or it can be executed by a combination of hardware and software modules in the decoding processor. The software module can be located in a storage medium, which is located in a memory, and the processor reads the program in the memory and completes the steps of the above method in combination with its hardware.

[0146] Optionally, when the processor executes the program, the corresponding processes implemented by the electronic device in each method of the embodiments of the present application are implemented, which will not be described in detail here for the sake of brevity.

[0147] In an exemplary embodiment, the present application also provides a storage medium, namely a computer storage medium, specifically a computer-readable storage medium, for example, including a first memory storing a computer program, and the computer program can be executed by a processor of an electronic device to complete the steps of the aforementioned method. The computer-readable storage medium can be a memory such as FRAM, ROM, PROM, EPROM, EEPROM, Flash Memory, magnetic surface storage, optical disk, or CD-ROM.

[0148] In the several embodiments provided in the present application, it should be understood that the disclosed devices, electronic devices and methods can be implemented in other ways. The device embodiments described above are only schematic. For example, the division of the units is only a logical function division. There may be other division methods in actual implementation, such as: multiple units or components can be combined, or can be integrated into another system, or some features can be ignored or not executed. In addition, the coupling, direct coupling, or communication connection between the components shown or discussed can be through some interfaces, and the indirect coupling or communication connection of the devices or units can be electrical, mechanical or other forms.

[0149] The units described above as separate components may or may not be physically separated, and the components displayed as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units; some or all of the units may be selected according to actual needs to achieve the purpose of the present embodiment.

[0150] In addition, all functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be a separate unit, or two or more units may be integrated into one unit; the above-mentioned integrated units may be implemented in the form of hardware or in the form of hardware plus software functional units.

[0151] A person of ordinary skill in the art can understand that: all or part of the steps of implementing the above-mentioned method embodiment can be completed by hardware related to program instructions, and the aforementioned program can be stored in a computer-readable storage medium, which, when executed, executes the steps of the above-mentioned method embodiment; and the aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROM, RAM, disks or optical disks.

[0152] Alternatively, if the above-mentioned integrated unit of the present application is implemented in the form of a software function module and sold or used as an independent product, it can also be stored in a computer-readable storage medium. Based on such an understanding, the technical solution of the embodiment of the present application can be essentially or partly embodied in the form of a software product that contributes to the relevant technology. The computer software product is stored in a storage medium, including several instructions to enable a computer device (which can be a personal computer, a server, or a network device, etc.) to execute all or part of the methods described in each embodiment of the present application. The aforementioned storage medium includes: various media that can store program codes, such as mobile storage devices, ROM, RAM, magnetic disks or optical disks.

[0153] It should be noted that the technical solutions described in the embodiments of the present application can be combined arbitrarily without conflict.

[0154] In addition, in the examples of the present application, "first", "second", etc. are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence.

[0155] The above is only a specific implementation of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. A character recognition method, characterized in that: The method comprises: Input the image to be recognized into the classifier corresponding to the characters in each character cluster; the classifier corresponding to the characters in each character cluster is deployed in the storage and computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image corresponding to the character in the character cluster is greater than or equal to a first set value; Based on the confidence of the classifier output corresponding to the characters in each character cluster, character recognition is performed on the image to be recognized; the confidence represents the probability that the character in the image to be recognized is the character corresponding to the classifier.

2. The method according to claim 1, characterized in that: The step of performing character recognition on the image to be recognized based on the confidence of the classifier output corresponding to the characters in each character cluster includes: Determine the mean of the confidence scores of the classifier outputs corresponding to all characters in each character cluster; Determine the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster; A target character in the image to be recognized is determined based on the target character cluster.

3. The method according to claim 2, characterized in that The step of determining the target character cluster of the image to be recognized based on the mean value corresponding to each character cluster includes: Determine the character cluster with the largest mean as the target character cluster; If there are multiple target character clusters, determining the character intersection of the multiple target character clusters; A target character in the image to be recognized is determined based on the character intersection.

4. A model deployment method, characterized in that: The method comprises: Determine the similarity between images corresponding to various characters; Based on the similarity, determining a character cluster corresponding to each character; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier; The classifiers corresponding to the characters in each character cluster are deployed in the storage and computing integrated chip.

5. The method according to claim 4, characterized in that Determining the similarity between images corresponding to various characters includes: Inputting the image data set corresponding to the first character into the classifier corresponding to the second character to obtain the confidence of each image in the image data set; the confidence represents the probability that the classifier recognizes the character in the image as the second character; Determining the number of images in the image data set whose confidence level is greater than a second set value; Based on the number of images, a similarity between the image corresponding to the first character and the image corresponding to the second character is determined.

6. The method according to claim 4, characterized in that The classifier is a neural network model adapted to the storage and computing integrated chip.

7. A character recognition device, characterized in that: include: An input module, used for inputting the image to be recognized into the classifier corresponding to the characters in each character cluster; The classifiers corresponding to the characters in each character cluster are deployed in a storage-computing integrated chip; wherein each character corresponds to a character cluster, and the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; The recognition module is used to perform character recognition on the image to be recognized based on the confidence output of the classifier corresponding to the characters in each character cluster; the confidence represents the probability that the characters in the image to be recognized are the characters corresponding to the classifier.

8. A model deployment device, characterized in that: include: A first determination module is used to determine the similarity between images corresponding to various characters; A second determination module is used to determine a character cluster corresponding to each character based on the similarity; wherein the similarity between the image corresponding to the character in the character cluster and the image of the character corresponding to the character cluster is greater than or equal to a first set value; and each character corresponds to a classifier; The deployment module is used to deploy the classifiers corresponding to the characters in each character cluster into the storage and computing integrated chip.

9. An electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, it implements the character recognition method as described in claims 1 to 3 or the model deployment method as described in claims 4 to 6.

10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a computer program, which includes program instructions. When the program instructions are executed by a processor, the processor executes the character recognition method as described in claims 1 to 3 or the model deployment method as described in claims 4 to 6.