An image reconstruction method for salary payment system

By using the reconstructed image artificial neural network of the feature rough extraction module, feature depth reproduction unit and feature integration reconstruction module in the salary issuance system, the problem of high error rate in certificate and document image recognition is solved, and the image resolution is improved and Improvement of OCR recognition accuracy.

CN115222844BActive Publication Date: 2024-10-18CHONGQING HONGYE TECH CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202210861521.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-07-20
Publication Date
2024-10-18
Estimated Expiration
2042-07-20

AI Technical Summary

Technical Problem

In the existing salary issuance system, due to the difference in text size and insufficient hardware imaging capabilities of electronic images of certificates and documents, the OCR recognition error rate is high, the image resolution is low, and text information cannot be effectively recognized.

Method used

A reconstructed image artificial neural network including a rough feature extraction module, a feature depth reproduction unit and a feature integration and reconstruction module is used to improve image resolution, reconstruct detailed features and improve OCR recognition accuracy through convolution operations and attention correction modules. .

Benefits of technology

It effectively improves the image resolution and OCR recognition accuracy, removes low-frequency interference information, highlights high-frequency text information, improves the local and global effects of image reconstruction, and significantly reduces the recognition error rate.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115222844B_ABST
    Figure CN115222844B_ABST
Patent Text Reader

Abstract

The present invention discloses an image reconstruction method for a salary payment system, including obtaining a pre-trained neural network and an uploaded image; a feature rough extraction module uses the uploaded image as input and outputs a rough feature map; the feature map is transmitted along the depth direction of the network, and each feature depth extraction module performs feature extraction operations on the feature map in turn; a feature integration reconstruction module uses the refined feature map as input, and after super-resolution reconstruction, outputs a new image and the like. In the feature depth extraction module, several convolution operations with different convolution kernel sizes are first set in parallel, and then the output results after convolution are spliced ​​and the number of channels is reduced, so that a large amount of low-frequency interference information at this level can be removed; the spatial correction map AtmS further highlights and strengthens the text image part containing a large amount of high-frequency information, the directional correction ability of the spatial attention correction module is more prominent, and the reconstructed image quality is high.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the technical field of wage payment system and image processing, and in particular, relates to an image reconstruction method for a wage payment system. Background Art

[0002] When the wage payment system is actually used, in many scenarios (such as entering the basic information of the new wage recipients to be paid, adjusting the wage amount of specific employees), relevant personnel are required to upload certificates, documents or certificates and other materials to the wage payment system in the form of electronic images, and then verify the relevant information based on the electronic images, enter the information in the images into the system, and archive the relevant materials. In order to improve the efficiency of information entry, most of the existing wage payment systems are equipped with OCR recognition software. However, in some certificates, the text sizes in different locations vary greatly, resulting in low resolution of small text in the uploaded image; it may also be due to the poor imaging ability of the hardware itself when taking electronic images, resulting in the loss of some text information details in the image; these all increase the error rate of OCR recognition. Summary of the invention

[0003] In view of the above-mentioned deficiencies in the prior art, the present invention provides an image reconstruction method for a salary payment system, which reconstructs the image according to the characteristics of the electronic image information content in the salary payment system, improves the image resolution, reconstructs some detail features, and improves the OCR recognition accuracy.

[0004] In order to achieve the above object, the solution adopted by the present invention is: an image reconstruction method for a salary payment system, comprising the following steps:

[0005] S100, obtaining a pre-trained reconstructed image artificial neural network, obtaining an uploaded image, and inputting the uploaded image into the reconstructed image artificial neural network;

[0006] The reconstructed image artificial neural network includes a feature rough extraction module, a feature depth reconstruction unit and a feature integration reconstruction module; the feature rough extraction module is a convolution operation layer with a convolution kernel size of 3*3, and the feature depth reconstruction unit includes a plurality of feature depth extraction modules connected in sequence;

[0007] S200, the feature rough extraction module takes the uploaded image as input, and outputs a rough feature map after convolution operation;

[0008] S300, inputting the rough feature map into the feature depth reconstruction unit, and then transmitting the feature map along the depth direction of the network, each feature depth extraction module sequentially accepts the feature map output by its previous module as input, and sequentially performs feature extraction operations on the feature map, until the last feature depth extraction module outputs a refined feature map;

[0009] S400, the feature integration and reconstruction module takes the refined feature map as input, and after super-resolution reconstruction, the feature integration and reconstruction module outputs a new image, and the resolution of the new image is greater than that of the uploaded image;

[0010] The process of extracting features by the feature depth extraction module is expressed as the following mathematical model:

[0011]

[0012] Ta2=Cv4(Ta1)

[0013]

[0014] L n+1 =Atts(Ta2+Ta3)×Ta3

[0015] Among them, the feature depth extraction module is based on the feature map L n As input, Cv1, Cv2, Cv3, Cv4, Cv5 and Cv6 all represent convolution operations on feature maps. The convolution kernel sizes of Cv1 and Cv4 are 1*1, the convolution kernel sizes of Cv2, Cv5 and Cv6 are 3*3, and the convolution kernel size of Cv3 is 5*5. and Both represent the activation function ReLU, Indicates that the feature maps are spliced, Atts represents the spatial attention correction module, × represents the element-by-element product, and the feature depth extraction module is based on the feature map L n+1 as output.

[0016] Furthermore, after the feature map is input into the spatial attention correction module, the process of generating the spatial correction map is expressed as the following mathematical model:

[0017]

[0018]

[0019] AtmS=δs(Sat1+Sat2)

[0020] Among them, the spatial attention correction module takes the feature map Ta2+Ta3 as input, SAtM and SAtA represent global average pooling and global maximum pooling of the feature map respectively, the pooling directions of SAtM and SAtA are both along the channel direction of the feature map, CL represents the number of channels of the feature map Ta2+Ta3, δs represents the activation function sigmoid, and the spatial attention correction module takes the spatial correction map AtmS as output.

[0021] Furthermore, a channel attention correction module is provided inside the reconstructed image artificial neural network; the channel attention correction module takes the Ta2 feature map in each of the feature depth extraction modules as input, and then generates and outputs a channel correction map, and the channel correction map is used to correct each channel of the refined feature map.

[0022] Furthermore, after the feature map is input into the channel attention correction module, the process of generating the channel correction map is expressed as the following mathematical model:

[0023] Cat1=CAtA(τ11(D1))+CAtV(τ12(D1))

[0024] Cat2=CAtA(τ21(D2))+CAtV(τ22(D2))

[0025] ···

[0026] Catm=CAtA(τm1(D m ))+CAtV(τm2(D m ))

[0027] CaY=Cat1×Cat2×···×Catm

[0028]

[0029] AtmC=CaY+CaE

[0030] Among them, D1, D2, ..., D m Denote the Ta2 feature maps output from each of the feature depth extraction modules, D1, D2, ..., D m At the same time, as the input of the channel attention correction module, CAtA, CAtV and CAtM represent global maximum pooling, global variance pooling and global average pooling of the feature map respectively. The pooling directions of CAtA, CAtV and CAtM are all along the spatial direction of the feature map. τ11, τ12, τ21, τ22, …, τm1 and τm2 all represent activation functions Tanh, and × represents the corresponding product of elements. It indicates that the feature maps are concatenated, δc indicates the activation function sigmoid, CvC indicates the convolution operation with a convolution kernel size of 1*1, and AtmC indicates the channel correction map output by the channel attention correction module.

[0031] The beneficial effects of the present invention are:

[0032] (1) Since most of the uploaded images are from certificates and other related materials, the important high-frequency information in the image is concentrated in the text part, while the background is a large amount of repeated low-frequency information. Therefore, in the feature depth extraction module, several convolution operations with different convolution kernel sizes are first set in parallel, and then the output results after convolution are spliced ​​and the number of channels is reduced. This can remove a large amount of low-frequency interference information at this level. Next, the convolution superimposed in the depth direction is used to extract features at a higher level. The module has high efficiency in extracting effective information;

[0033] (2) The input of the spatial attention correction module is the sum of feature map Ta2 and feature map Ta3. Compared with the feature map Ta3 alone as input, feature map Ta2 injects a large amount of filtered high-frequency feature information into the spatial attention correction module, which improves the correction effect of the spatial attention correction module at the pixel level, which plays an important role in promoting the network to reconstruct the subtle parts of the text image;

[0034] (3) In conventional attention mechanisms, the results obtained after average pooling and maximum pooling are directly added together without making corresponding adjustments based on the importance of different types of information. In the spatial attention correction module of the present invention, after global average pooling, the maximum pooling is divided by At the same time, after the global maximum pooling, multiply In this way, the spatial correction map AtmS generated by the additive activation of Sat1 and Sat2 can further highlight and strengthen the text image part containing a large amount of high-frequency information, and the directional correction ability of the spatial attention correction module is more prominent;

[0035] (4) Considering that the important information and interference information of feature maps at different levels are scattered in different channels, the present invention designs a channel attention correction module. On the one hand, a separate maximum pooling and variance pooling are used for the feature maps output by each feature depth extraction module, and then the various correction maps are gradually fused. The correction map CaY generated in this way can more accurately focus on specific channels containing important high-frequency information; on the other hand, the feature maps output by each feature depth extraction module are first spliced ​​and reduced in dimension, and then globally averaged pooled to generate the correction map CaE, which is conducive to extracting features with size invariance in the feature map. The channel correction map AtmC also has a good correction and enhancement effect on the global feature information. The channel attention correction module uses different methods to generate corresponding correction maps for different types of features, which can simultaneously improve the local and global image reconstruction effects. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] Figure 1 This is a schematic diagram of the structure of the artificial neural network for reconstructing images of the present invention;

[0037] Figure 2 A schematic diagram of the internal structure of the feature depth extraction module of the present invention;

[0038] Figure 3 Schematic diagram of the internal structure of the spatial attention correction module of the present invention;

[0039] Figure 4 It is a structural schematic diagram of the feature integration reconstruction module of the present invention;

[0040] Figure 5 Schematic diagram of the internal structure of the modified feature depth extraction module in Example 2;

[0041] Figure 6 A schematic diagram of the structure of the artificial neural network for reconstructing images of the present invention after a channel attention correction module is set;

[0042] Figure 7 Schematic diagram of the internal structure of the channel attention correction module of the present invention;

[0043] In the attached figure:

[0044] 1-uploaded image, 2-feature rough extraction module, 3-feature depth reconstruction unit, 4-feature depth extraction module, 5-feature integration and reconstruction module, 6-spatial attention correction module, 7-channel attention correction module, 8-long connection, 9-new image. DETAILED DESCRIPTION

[0045] The present invention will be further described below in conjunction with the accompanying drawings:

[0046] Embodiment 1:

[0047] The present invention provides an image reconstruction method for a salary payment system, wherein the implementation method of the image reconstruction artificial neural network is as follows: Figure 1As shown, the feature rough extraction module 2, the feature depth reconstruction unit 3 and the feature integration reconstruction module 5 are connected in sequence along the depth direction of the network. The number of channels of the rough feature map output by the feature rough extraction module 2 after the convolution operation on the uploaded image 1 is 64. Four feature depth extraction modules 4 are set in the feature depth reconstruction unit 3. The feature map output at the tail of the previous feature depth extraction module 4 is also the feature map input to the head of the next feature depth extraction module 4. The refined feature map is the feature map output at the tail of the last feature depth extraction module 4. In order to avoid the disappearance of the gradient as the network depth increases, a long connection 8 is also set in the reconstructed image artificial neural network of this embodiment, and the rough feature map is added and fused with the refined feature map through the long connection 8.

[0048] The implementation method of the feature depth extraction module 4 is as follows Figure 2 As shown, the feature map L of each feature depth extraction module 4 is input n The number of channels is 64, and the feature map L output by each feature depth extraction module 4 n+1 The number of channels is also 64. Inside the feature depth extraction module 4, after the Cv1, Cv2, and Cv3 convolution operations are set in parallel, the number of channels of the output feature maps is 64. After splicing, the number of channels of the Ta1 feature map is 192, and then the Cv4 convolution is used to reduce the dimension, so that the number of channels of Ta2 is reduced to 64. The number of channels of the feature maps output after the two convolution operations of Cv5 and Cv6 is also 64.

[0049] The implementation method of the spatial attention correction module 6 is as follows Figure 3 As shown in Figure 2, after performing global average pooling and global maximum pooling on the feature map Ta2+Ta3 in the channel direction, two two-dimensional matrices of the same size are obtained. Since the number of channels is 64, The value is 8. All elements in the matrix generated by global average pooling are divided by 8 to obtain matrix Sat1, and all elements in the matrix generated by global maximum pooling are multiplied by 8 to obtain matrix Sat2. Finally, Sat1 and Sat2 are added and activated to generate the spatial correction map AtmS. The spatial correction map AtmS is element-wise multiplied with the Ta3 feature map, and different weight parameters of different sizes are assigned to different spatial positions of the feature map to achieve correction of different spatial positions of the feature map.

[0050] The feature integration and reconstruction module 5 is implemented by using existing mature technology. The feature integration and reconstruction module 5 performs upsampling and super-resolution reconstruction on the feature map and then outputs a new image 9 with 3 channels. Figure 4 As shown, it includes a sub-pixel convolution layer and two ordinary convolution layers. The two ordinary convolution layers are set at the front and back ends of the sub-pixel convolution layer. The convolution kernel size of the two ordinary convolution layers is 3*3, and the number of channels of the output feature map of the first ordinary convolution layer is 64A 2(A is the upsampling multiple), the number of channels of the sub-pixel convolutional layer output feature map is 64.

[0051] 500 images with good quality were selected from the images saved in the system, 350 images were randomly selected as the training set, and the remaining 150 images were used as the test set. The images in the training set and the test set were bicubic downsampled to obtain the corresponding low-resolution images. The network was built on the computer through programming. In order to compare the performance of the network of the present invention horizontally, the existing OISR model and MDCN model were also constructed at the same time, and then the above models were trained using the same training set. The details such as the loss function and learning rate during the training process were the same. After the training was completed, the test was performed on the above test set, and the results of the peak signal-to-noise ratio and structural similarity index were as follows:

[0052]

[0053]

[0054] It can be seen from the above data that in the test results of the two upsampling multiples, the image quality reconstructed by the network embodiment 1 of the present invention is better than that of the OISR model and the MDCN model.

[0055] Embodiment 2:

[0056] In order to explore the difference in the reconstructed image effect when different feature maps are input into the spatial attention correction module 6, this embodiment modifies the internal structure of the feature depth extraction module 4 in Example 1. The modified structure is as follows: Figure 5 As shown, the Ta3 feature map is used alone as the input of the spatial attention correction module 6, and the other parts of the reconstructed image artificial neural network are kept exactly the same as those in Example 1. After the same training and testing process, the following results are obtained:

[0057]

[0058] It can be seen from the above data that if the Ta3 feature map is used alone as the input of the spatial attention correction module 6, in the test results of the two upsampling multiples, the quality of the reconstructed image is lower than that of Example 1.

[0059] Embodiment 3:

[0060] This embodiment adds a channel attention correction module 7 (its internal structure is as follows) to the reconstructed image artificial neural network. Figure 7 After adding channel attention correction module 7, the network structure is as follows Figure 6As shown. Since the number of channels of the Ta2 feature map output by each feature depth extraction module 4 is 64, the channel attention correction module 7 outputs a vector of length 64 after global maximum pooling and global variance pooling. After fusion, the length of the obtained vector CaY is also 64. On the other hand, the number of channels of the spliced ​​feature map is reduced to 64 by CvC convolution. After global average pooling and activation, the length of the obtained vector CaE is also 64. The length of the final channel correction map AtmC is exactly equal to the number of channels of the refined feature map, and weight parameters of different sizes are assigned to different layers in the refined feature map through element-by-element multiplication. Except for the channel attention correction module 7, the other parts of the reconstructed image artificial neural network of Example 3 are exactly the same as those of Example 1. After the same training and testing process as Example 1, the following results are obtained:

[0061]

[0062] It can be seen from the above data that after adding the channel attention correction module 7, in the test results of two upsampling multiples, the quality of the network reconstructed image in Example 3 is significantly better than that in Example 1.

[0063] The above-mentioned embodiments only express the specific implementation of the present invention, and the description thereof is relatively specific and detailed, but it cannot be understood as limiting the scope of the present invention. It should be pointed out that, for ordinary technicians in this field, several variations and improvements can be made without departing from the concept of the present invention, which all belong to the protection scope of the present invention.

Claims

1. An image reconstruction method for salary payment system, Its characteristics are: The following steps are involved: S100, obtaining a pre-trained reconstructed image artificial neural network, obtaining an uploaded image, and inputting the uploaded image into the reconstructed image artificial neural network; The reconstructed image artificial neural network includes a feature rough extraction module, a feature depth reconstruction unit and a feature integration reconstruction module; the feature rough extraction module is a convolution operation layer with a convolution kernel size of 3*3, and the feature depth reconstruction unit includes a plurality of feature depth extraction modules connected in sequence; S200, the feature rough extraction module takes the uploaded image as input, and outputs a rough feature map after convolution operation; S300, inputting the rough feature map into the feature depth reconstruction unit, and then transmitting the feature map along the depth direction of the network, each feature depth extraction module sequentially accepts the feature map output by its previous module as input, and sequentially performs feature extraction operations on the feature map, until the last feature depth extraction module outputs a refined feature map; S400, the feature integration and reconstruction module takes the refined feature map as input, and after super-resolution reconstruction, the feature integration and reconstruction module outputs a new image, and the resolution of the new image is greater than that of the uploaded image; The process of extracting features by the feature depth extraction module is expressed as the following mathematical model: Ta2=Cv4(Ta1) <h2 style=";text-align:left;direction:ltr">L<h2 style=";text-align:left;direction:ltr"> n+1 <h2 style=";text-align:left;direction:ltr"> (Atts(Ta2+Ta3)×Ta3) Among them, the feature depth extraction module is based on the feature map L n As input, Cv1, Cv2, Cv3, Cv4, Cv5 and Cv6 all represent convolution operations on feature maps. The convolution kernel sizes of Cv1 and Cv4 are 1*1, the convolution kernel sizes of Cv2, Cv5 and Cv6 are 3*3, and the convolution kernel size of Cv3 is 5*5. and Both represent the activation function ReLU, Indicates that the feature maps are spliced, Atts represents the spatial attention correction module, × represents the element-by-element product, and the feature depth extraction module is based on the feature map L n+1 as output.

2. The image reconstruction method for the salary payment system according to claim 1, Its characteristics are: After the feature map is input into the spatial attention correction module, the process of generating the spatial correction map is expressed as the following mathematical model: AtmS=δs(Sat1+Sat2) Among them, the spatial attention correction module takes the feature map Ta2+Ta3 as input, SAtM and SAtA represent global average pooling and global maximum pooling of the feature map respectively, the pooling directions of SAtM and SAtA are both along the channel direction of the feature map, CL represents the number of channels of the feature map Ta2+Ta3, δs represents the activation function sigmoid, and the spatial attention correction module takes the spatial correction map AtmS as output.

3. The image reconstruction method for the salary payment system according to claim 1, Its characteristics are: A channel attention correction module is provided inside the reconstructed image artificial neural network; the channel attention correction module takes the Ta2 feature map in each of the feature depth extraction modules as input, and then generates and outputs a channel correction map, and the channel correction map is used to correct each channel of the refined feature map.

4. The image reconstruction method for the salary payment system according to claim 3, Its characteristics are: After the feature map is input into the channel attention correction module, the process of generating the channel correction map is expressed as the following mathematical model: Cat1=CAtA(τ11(D 1 ))+CAtV(τ12(D 1 )) Cat2=CAtA(τ21(D 2 ))+CAtV(τ22(D 2 )) ··· Catm=CAtA(τm1(D m ))+CAtV(τm2(D m )) CaY=Cat1×Cat2×···×Catm AtmC=CaY+CaE Among them, D 1 , D 2 ,…,D m Denotes the Ta2 feature map output from each of the feature depth extraction modules, D 1 , D 2 ,…,D m At the same time, as the input of the channel attention correction module, CAtA, CAtV and CAtM represent global maximum pooling, global variance pooling and global average pooling of the feature map respectively. The pooling directions of CAtA, CAtV and CAtM are all along the spatial direction of the feature map. τ11, τ12, τ21, τ22, …, τm1 and τm2 all represent activation functions Tanh, and × represents the corresponding product of elements. It indicates that the feature maps are concatenated, δc indicates the activation function sigmoid, CvC indicates the convolution operation with a convolution kernel size of 1*1, and AtmC indicates the channel correction map output by the channel attention correction module.

Citation Information

Patent Citations

  • Low-resolution text image recognition method based on SROCRN network

    CN112733716A

  • Super-resolution text image recognition method and device, equipment and storage medium

    CN114170608A