Handwritten manuscript scoring method and device, computer equipment and storage medium

By acquiring handwritten images and identifying the answer area, filtering text images and considering the semantic order of the context, and using a scoring model for text recognition and scoring, the problem of low scoring accuracy for handwritten calculation questions in existing technologies is solved, and efficient scoring of complex science and engineering questions is achieved.

CN121768016APending Publication Date: 2026-03-31SHENZHEN SEA SKY LAND TECH
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-12-11
Publication Date
2026-03-31

AI Technical Summary

Technical Problem

Existing scoring systems struggle to accurately handle complex handwritten calculation problems in science and engineering, especially due to differences in students' writing habits and diverse forms of expression, resulting in low accuracy of optical character recognition technology and making automated scoring impossible.

Method used

By acquiring handwritten images, identifying the answer area, filtering text images and considering the semantic order of the context, a scoring model is used for text recognition and scoring, including predictive segmentation, classification, text block merging, rotation correction and LaTeX syntax verification. The scoring model is built and trained to improve accuracy.

Benefits of technology

It improves the accuracy of text recognition and scoring efficiency for handwritten calculation problems, ensuring the accuracy and consistency of scoring, especially for complex science and engineering problems.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121768016A_ABST
    Figure CN121768016A_ABST
Patent Text Reader

Abstract

The invention relates to a handwritten manuscript scoring method and device, computer equipment and a storage medium. The method comprises the following steps: acquiring a handwritten image of a handwritten manuscript; obtaining an answering area corresponding to each question according to the handwritten image; the answer areas are screened to obtain a text image, and the text image comprises context semantic sequence information; performing text recognition according to the text image and the context semantic sequence information to obtain a to-be-scored text; and scoring the to-be-scored text according to a scoring model. According to the invention, the accuracy of handwritten manuscript scoring can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of image recognition, and more particularly to a method, apparatus, computer device, and storage medium for scoring handwritten manuscripts. Background Technology

[0002] The development of information technology and the Internet has driven the development of intelligent marking and scoring technologies.

[0003] In traditional online marking systems, exam papers, especially math, physics, and chemistry calculation problems in the middle and high school entrance exams, have complex answers involving multiple knowledge points and diverse student responses. However, due to the large differences in students' writing habits and the variety of expression formats, such as fractions versus decimals, with or without units, and equivalent expressions, the existing optical character recognition (OCR) technology can only perform simple string matching, resulting in low accuracy and making subsequent automated marking difficult to achieve.

[0004] It is evident that the existing grading system is insufficient for the more complex grading of science and engineering subjects, and this issue urgently needs to be addressed. Summary of the Invention

[0005] In order to solve the above-mentioned technical problems, or at least partially solve the above-mentioned technical problems, the present invention provides a handwritten manuscript scoring method, apparatus, computer equipment and storage medium.

[0006] In a first aspect, the present invention provides a method for grading handwritten manuscripts, the method comprising: Obtain the handwritten image of the handwritten manuscript; Based on the handwritten image, obtain the answer area corresponding to each question; The answer area is filtered to obtain a text image, which includes contextual semantic order information; Based on the text image and the contextual semantic order information, text recognition is performed to obtain the text to be scored; The text to be scored is scored according to the scoring model.

[0007] Optionally, obtaining the answer area corresponding to each question based on the handwritten image includes: Based on the standard version corresponding to the handwritten manuscript, the standard answer area corresponding to the target question is obtained as the first area; Obtain a preset range outside the first region corresponding to the target question as the second region; Determine whether there is handwritten text in the second area; If there is handwritten text in the second area, then the first area and the second area are merged together to form the answer area corresponding to the target question; If there is no handwritten text in the second area, then the first area will be used as the answer area for the target question.

[0008] Optionally, filtering the answer area to obtain the text image includes: The answering region is predicted and segmented to obtain multiple segmentation blocks, each of which includes position information and order information; The segmented blocks are classified, and the categories of the segmented blocks include text blocks and non-text blocks; Filter out non-text block segments and keep text blocks. Obtain the outer contour of the segmented block for each text class; Based on the outer contour of the segmentation block of each text class, obtain the maximum bounding rectangle of all segmentation blocks of the text classes; A blank image is created based on the maximum bounding matrix, and the blank image covers the maximum bounding matrix; Based on the position and order information of the segmented blocks of the text class, the segmented blocks of the text class are filled into the blank image to obtain the text image; The contextual semantic order information of the text image is generated based on the position and order information of the segmented blocks of the text class.

[0009] Optionally, the step of performing text recognition based on the text image to obtain the text to be scored further includes: Within a preset angle range, the text image is rotated multiple times according to the rotation step size to perform text recognition.

[0010] Optionally, the step of performing text recognition based on the text image to obtain the text to be scored further includes: When performing text recognition on the text image, a Gaussian blur parameter is added to simulate ink diffusion.

[0011] Optionally, the step of performing text recognition based on the text image and the contextual semantic order information to obtain the text to be scored further includes: After text recognition, the recognized text is subjected to LaTeX syntax verification. If the recognized text passes the LaTeX syntax check, then the text that passes the LaTeX syntax check is directly output. If the recognized text fails the LaTeX syntax check, the recognized text is converted to output text that conforms to the LaTeX syntax check. The output text that conforms to LaTeX syntax validation is semantically equivalent and classified to merge texts with different writing forms but the same meaning. Based on the contextual semantic order information, the merged texts are equivalently categorized to merge texts with different writing styles but the same meaning again, thus obtaining the text to be scored.

[0012] Optionally, before scoring the text to be scored according to the scoring model, the method includes: Build the initial model; The initial model is trained to obtain the scoring model; The initial model training includes initial training and retraining. The initial training data is standard scoring training data, and the retraining data is data after correcting the standard scoring training data.

[0013] Secondly, a handwritten manuscript scoring device is provided, the device applying the method as described in any of the preceding claims, the device comprising: The image acquisition unit is used to acquire handwritten images of the handwritten manuscript; The answer area acquisition unit is used to acquire the answer area corresponding to each question based on the handwritten image; A text image acquisition unit is used to filter the answer area to acquire a text image, wherein the text image includes contextual semantic order information; The recognition unit is used to perform text recognition based on the text image and the contextual semantic order information to obtain the text to be scored; The scoring unit is used to score the text to be scored according to the scoring model.

[0014] Thirdly, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor, when executing the computer program, implements the method as described in any of the preceding claims.

[0015] Fourthly, a computer-readable storage medium is provided having a computer program stored thereon, which, when executed by a processor, implements the method as described in any of the preceding claims.

[0016] This invention provides a method, apparatus, computer device, and storage medium for scoring handwritten manuscripts. The method includes: acquiring a handwritten image of the manuscript; acquiring a response area for each question based on the handwritten image; filtering the response area to obtain a text image, the text image including contextual semantic order information; performing text recognition based on the text image and the contextual semantic order information to obtain text to be scored; and scoring the text to be scored according to a scoring model. In this embodiment of the invention, the selection of the response area and the subsequent acquisition of the text image both take into account the contextual semantic order, so that the contextual semantic order can also be considered during subsequent text recognition, resulting in better accuracy and efficiency in text recognition and more accurate scoring of the text. Attached Figure Description

[0017] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with the invention and, together with the description, serve to explain the principles of the invention.

[0018] To more clearly illustrate the technical solutions in the embodiments of the present invention or the prior art, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, for those skilled in the art, other drawings can be obtained based on these drawings without creative effort.

[0019] Figure 1 The diagram shown illustrates the application environment of the handwritten manuscript scoring method according to an embodiment of the present invention. Figure 2 The diagram shown is a flowchart illustrating the handwritten manuscript scoring method according to an embodiment of the present invention. Figure 3 The diagram shown is a structural block diagram of the handwritten manuscript scoring device according to an embodiment of the present invention; Figure 4 The diagram shown is an internal structural diagram of a computer device in an embodiment of the present invention. Detailed Implementation

[0020] To make the objectives, technical solutions, and advantages of the embodiments of the present invention clearer, the technical solutions of the embodiments of the present invention will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0021] Figure 1 This is a diagram illustrating the application environment of a handwritten manuscript scoring method in one embodiment. (Refer to...) Figure 1This handwritten manuscript scoring method is applied to a handwritten manuscript scoring system. The handwritten manuscript scoring method includes a terminal 110 and / or a server 120. The terminal 110 and the server 120 are connected via a network. The terminal 110 can be a desktop terminal or a mobile terminal; a mobile terminal can be at least one of a mobile phone, tablet computer, or laptop computer. The server 120 can be a standalone server or a server cluster consisting of multiple servers.

[0022] The handwritten manuscript scoring method of the present invention is applied to terminal 110 and / or server 120.

[0023] like Figure 2 As shown, in one embodiment, a method for scoring handwritten manuscripts is provided. This embodiment mainly applies this method to the above-mentioned... Figure 1 The example uses terminal 110 and / or server 120. Figure 2 The handwritten manuscript scoring method includes: Step 210: Obtain the handwritten image of the handwritten manuscript; Handwritten images can be obtained through high-definition cameras, scanners, or other methods available in existing technology, which will not be elaborated here.

[0024] Step 220: Based on the handwritten image, obtain the answer area corresponding to each question; Step 230: Filter the answer area to obtain a text image, the text image including contextual semantic order information; Step 240: Based on the text image and the contextual semantic order information, perform text recognition to obtain the text to be scored; Step 250: Score the text to be scored according to the scoring model.

[0025] In the method of this invention embodiment, the answer area corresponding to each question is obtained based on the handwritten image, and the answer area is filtered to obtain a text image. The text image includes contextual semantic order information. That is, in this invention embodiment, the selection of the answer area and the subsequent acquisition of the text image both take into account the contextual semantic order, so that the contextual semantic order can also be considered when performing text recognition in the future, making the text recognition more accurate and efficient, and making the scoring of the text more accurate.

[0026] In this embodiment of the invention, step 220, obtaining the answer area corresponding to each question based on the handwritten image, includes: Based on the standard version corresponding to the handwritten manuscript, the standard answer area corresponding to the target question is obtained as the first area; Obtain a preset range outside the first region corresponding to the target question as the second region; Determine whether there is handwritten text in the second area; If there is handwritten text in the second area, then the first area and the second area are merged together to form the answer area corresponding to the target question; If there is no handwritten text in the second area, then the first area will be used as the answer area for the target question.

[0027] In this embodiment of the invention, the standard document can be an exam paper or other document that needs to be graded. Typically, the standard document defines the scope of the answers, which is the standard answer area, such as the blank area below each question. However, test takers usually write their answers outside the answer area, such as outside the boundaries of the left and right answer areas, below the answer area, or by pointing to other locations with arrows.

[0028] The preset range outside the first area can be a range defined according to needs or actual situation. For example, the answer range may extend to the left boundary and to the right boundary; if the question is at the top of the page, the preset range may include the blank space above the question.

[0029] If there is handwritten text in the second area, it means that there may be answers that need to be scored in the second area. Therefore, the first and second areas need to be merged into the answer area.

[0030] The method of this invention expands the scope of the answer area, which can avoid missing answers and make the scoring more accurate.

[0031] In this embodiment of the invention, step 230, filtering the answer area to obtain a text image, includes: The answering region is predicted and segmented to obtain multiple segmentation blocks, each of which includes position information and order information; The segmented blocks are classified, and the categories of the segmented blocks include text blocks and non-text blocks; Filter out non-text block segments and keep text blocks. Obtain the outer contour of the segmented block for each text class; Based on the outer contour of the segmentation block of each text class, obtain the maximum bounding rectangle of all segmentation blocks of the text classes; A blank image is created based on the maximum bounding matrix, and the blank image covers the maximum bounding matrix; Based on the position and order information of the segmented blocks of the text class, the segmented blocks of the text class are filled into the blank image to obtain the text image; The contextual semantic order information of the text image is generated based on the position and order information of the segmented blocks of the text class.

[0032] Location information can be coordinate information, and sequence information can be numbering information from top to bottom or from left to right. The purpose of these two pieces of information is to identify the segmentation block of each text class and its relationship with the preceding and following text and context, which facilitates subsequent recognition and scoring and also helps to improve the accuracy of subsequent recognition and scoring.

[0033] In this embodiment of the invention, the text image includes the position and order information of the segmented blocks of the text class, which can avoid errors in subsequent processing and is beneficial to subsequent recognition and scoring.

[0034] In this embodiment of the invention, only the text segmentation block is retained because it is usually text that needs to be scored.

[0035] In this embodiment of the invention, the predicted segmentation of the answer area can be based on semantic segmentation. The page segmentation algorithm can employ a segmentation model, specifically the Yolo11-seg model. The segmentation categories designed for the written content of calculation questions are roughly divided into text block categories and non-text block categories. Non-text block categories can include text deletion categories, drawing categories, table categories, etc. The training data mainly involves calculation questions in mathematics, physics, and chemistry. The mathematical knowledge points involved include functions, solid sets, analytic sets, etc. The physics knowledge points involved include mechanics, thermodynamics, magnetism, etc., and the chemistry mainly involves inorganic chemical reaction equations and the calculation of the mass of reactants and products.

[0036] In one embodiment of the present invention, the segmentation model framework structure can be as follows: (1) The image size used for training is uniformly scaled to 960×960, keeping the long side ≤ 960 and padding to a multiple of 32. The algorithm architecture is mainly based on convolutional neural networks (CNN), with an improved lightweight C3K2 backbone network for handwritten answer feature extraction. Bottlenneck is designed as... and 5 Depthwise convolutional combination, followed by conncat concatenation and then connection 1 Convolutional compression is performed, and Ghost convolution is introduced to reduce the FLOPS parameter and accelerate inference. Downsampling uses a Conv-Pool parallel approach, mainly through 5 layers of stride-2 downsampling, obtaining five feature maps of 480×480, 240×240, 120×120, 60×60, and 30×30. Among them, 120×120, 60×60, and 30×30 correspond to the P3, P4, and P5 outputs, respectively, for use by the subsequent Neck-C2PSA fusion and detection head.

[0037] (2) The designed Neck-C2PSA is mainly based on the PANet+FPN architecture, combined with C2PSA (Convolutional Two-branch Pyramid Spatial Attention) spatial attention Neck multi-scale fusion. C2PSA modules are inserted in the three scales of P3, P4, and P5, which mainly suppress background noise, fuse high-level semantics with low-level details under weighted spatial attention, reduce the "sticking" phenomenon of masks, improve the edge IOU segmentation accuracy between page blocks, and greatly reduce the error segmentation of page due to unclear context semantics.

[0038] The spatial attention of this model is: in, The sigmoid function is used to normalize the values ​​to [0,1] to obtain the attention weights. express Convolution, F represents C Feature map of size, For global average pooling, an average value is taken for each channel. For global max pooling, the maximum value is taken for each channel. Let C be a matrix, H be the channel, and W be the height. This indicates concatenation of channel dimensions.

[0039] The dual-branch fusion of the model is as follows: high branch: Current scale feature (stride 16) Low branch: adjacent shallow layer features (stride 8) The final fused feature size is C , For spatial attention, C High-level semantic features of size For downsampling operations, low-level features are enlarged to the same size as high-level features. To perform pixel-by-pixel multiplication, upsampling is performed using bilinear + Variable convolution.

[0040] The model's output stage employs a single-stage Proto-mask segmentation, using dynamic dimensions, with the dimension selected as [value missing]. in, The number of single images, Proto convolutional concatenation Depthwise separable convolutions combined with channel shuffle help improve the ability to express details. The Coeff branch adds short connections to concatenate the bounding box regression features into the coefficient vector, reducing edge localization errors.

[0041] The complete segmentation output process can be as follows: The 960×960 original image is downsampled stepwise through 5 layers of backbone to extract three layers of features: 120×120, 60×60, and 30×30. Then, Neck-C2PSA fuses the multi-scale features, and the detector head generates 18,900 candidate boxes and corresponding 32-dimensional mask coefficients in one go. After NMS filtering to obtain the final instance, the coefficients are linearly combined with the 120×120 prototype image to generate a mask. This mask is then restored to 960×960 using bilinear interpolation and binarized with a 0.5 threshold, ultimately outputting accurate layout bounding boxes, category masks, and instance masks.

[0042] During training, the model employs a training strategy with uncertain weighting of loss weights. .

[0043] To lose weight, Representing the The tasks include classification, bounding box regression, and masking. It is the first The original loss of each task, These are learnable parameters. Is related to the task The corresponding uncertainty.

[0044] This model can employ a cosine annealing strategy: Cosine + WarmRestarts. This strategy ensures training stability while effectively promoting rapid model convergence on limited labeled data, avoiding optimization oscillations caused by periodic learning rate resets.

[0045] In this embodiment of the invention, step 240, which involves performing text recognition based on the text image to obtain the text to be scored, further includes: Within a preset angle range, the text image is rotated multiple times according to the rotation step size to perform text recognition.

[0046] The preset angle range can be ±5 degrees or ±10 degrees, etc.; depending on the rotation step, it can be 0.5 degrees or 1 degree, etc.

[0047] The most common difference between handwritten and printed text is that handwritten text usually has a certain tilt, especially in large areas, where it tends to tilt in one direction, such as "left low and right high". This reduces the accuracy of subsequent recognition. Therefore, in this embodiment of the invention, the text image can be rotated multiple times for text recognition to reduce the recognition error rate.

[0048] In this embodiment of the invention, step 240, which involves performing text recognition based on the text image to obtain the text to be scored, further includes: When performing text recognition on the text image, a Gaussian blur parameter is added to simulate ink diffusion.

[0049] In this embodiment of the invention, step 240, which involves performing text recognition based on the text image and the contextual semantic order information to obtain the text to be scored, further includes: After text recognition, the recognized text is subjected to LaTeX syntax verification. If the recognized text passes the LaTeX syntax check, then the text that passes the LaTeX syntax check is directly output. If the recognized text fails the LaTeX syntax check, the recognized text is converted to output text that conforms to the LaTeX syntax check. The output text that conforms to LaTeX syntax validation is semantically equivalent and classified to merge texts with different writing forms but the same meaning. Based on the contextual semantic order information, the merged texts are equivalently categorized to merge texts with different writing styles but the same meaning again, thus obtaining the text to be scored.

[0050] The method of this invention is more specifically designed for science and engineering exam papers or assignments. Since there are many formulas in science and engineering, formulas that do not conform to LaTeX syntax validation will lead to errors in subsequent grading. Therefore, in this invention, LaTeX syntax validation and conversion are performed during the recognition process. In addition, this invention also merges texts with different writing styles but the same meaning, which can reduce subsequent recognition errors and improve the accuracy of grading.

[0051] In this embodiment of the invention, before scoring the text to be scored according to the scoring model, the method includes: Build the initial model; The initial model is trained to obtain the scoring model; The initial model training includes initial training and retraining. The initial training data is standard scoring training data, and the retraining data is data after correcting the standard scoring training data.

[0052] The scoring model in this embodiment of the invention includes two training sessions: an initial training session and a second training session. The training data for the initial training session is the standard scoring training data, while the training data for the second training session is the data after the standard scoring training data has been corrected.

[0053] The corrected data can be data that has been manually corrected or data that has been corrected by other models.

[0054] In this embodiment of the invention, the two training sessions use different data, and the training data for the second training session is the corrected data from the standard scoring training data, which can improve the accuracy of subsequent scoring.

[0055] The method described in this invention can improve the accuracy of scoring handwritten manuscripts.

[0056] like Figure 3 As shown, the present invention also provides a handwritten manuscript scoring device, which applies the method described above, and the device includes: Image acquisition unit 310 is used to acquire handwritten images of handwritten manuscripts; The answer area acquisition unit 320 is used to acquire the answer area corresponding to each question based on the handwritten image. The text image acquisition unit 330 is used to filter the answer area to acquire a text image, the text image including contextual semantic order information; The recognition unit 340 is used to perform text recognition based on the text image and the contextual semantic order information to obtain the text to be scored; The scoring unit 350 is used to score the text to be scored according to the scoring model.

[0057] In this embodiment of the invention, the answer area acquisition unit 320 is further configured to: Based on the standard version corresponding to the handwritten manuscript, the standard answer area corresponding to the target question is obtained as the first area; Obtain a preset range outside the first region corresponding to the target question as the second region; Determine whether there is handwritten text in the second area; If there is handwritten text in the second area, then the first area and the second area are merged together to form the answer area corresponding to the target question; If there is no handwritten text in the second area, then the first area will be used as the answer area for the target question.

[0058] In this embodiment of the invention, the text image acquisition unit 330 is further configured to: The answering region is predicted and segmented to obtain multiple segmentation blocks, each of which includes position information and order information; The segmented blocks are classified, and the categories of the segmented blocks include text blocks and non-text blocks; Filter out non-text block segments and keep text blocks. Obtain the outer contour of the segmented block for each text class; Based on the outer contour of the segmentation block of each text class, obtain the maximum bounding rectangle of all segmentation blocks of the text classes; A blank image is created based on the maximum bounding matrix, and the blank image covers the maximum bounding matrix; Based on the position and order information of the segmented blocks of the text class, the segmented blocks of the text class are filled into the blank image to obtain the text image; The contextual semantic order information of the text image is generated based on the position and order information of the segmented blocks of the text class.

[0059] In this embodiment of the invention, the identification unit 340 is further configured to: Within a preset angle range, the text image is rotated multiple times according to the rotation step size to perform text recognition.

[0060] In this embodiment of the invention, the identification unit 340 is further configured to: When performing text recognition on the text image, a Gaussian blur parameter is added to simulate ink diffusion.

[0061] In this embodiment of the invention, the identification unit 340 is further configured to: After text recognition, the recognized text is subjected to LaTeX syntax verification. If the recognized text passes the LaTeX syntax check, then the text that passes the LaTeX syntax check is directly output. If the recognized text fails the LaTeX syntax check, the recognized text is converted to output text that conforms to the LaTeX syntax check. The output text that conforms to LaTeX syntax validation is semantically equivalent and classified to merge texts with different writing forms but the same meaning. Based on the contextual semantic order information, the merged texts are equivalently categorized to merge texts with different writing styles but the same meaning again, thus obtaining the text to be scored.

[0062] In this embodiment of the invention, the scoring unit 350 is further used for: Build the initial model; The initial model is trained to obtain the scoring model; The initial model training includes initial training and retraining. The initial training data is standard scoring training data, and the retraining data is data after correcting the standard scoring training data.

[0063] The embodiments of the present invention can improve the accuracy of scoring handwritten manuscripts.

[0064] This invention also provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor. When the processor executes the computer program, it implements the following method: acquiring a handwritten image of a handwritten manuscript; acquiring an answer area corresponding to each question based on the handwritten image; filtering the answer area to acquire a text image, the text image including contextual semantic order information; performing text recognition based on the text image and the contextual semantic order information to acquire text to be scored; and scoring the text to be scored according to a scoring model.

[0065] This invention also provides a computer-readable storage medium storing a computer program thereon. When executed by a processor, the computer program implements the following method: acquiring a handwritten image of a handwritten manuscript; acquiring an answer area corresponding to each question based on the handwritten image; filtering the answer area to acquire a text image, the text image including contextual semantic order information; performing text recognition based on the text image and the contextual semantic order information to acquire text to be scored; and scoring the text to be scored according to a scoring model.

[0066] The above-mentioned handwritten manuscript scoring method can effectively solve the technical problems raised in the background section.

[0067] Figure 2 This is a flowchart illustrating a handwritten manuscript scoring method in one embodiment. It should be understood that, although... Figure 2 The steps in the flowchart are shown sequentially as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order in which these steps are executed, and they can be performed in other orders. Figure 2 At least some of the steps in the process may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least some of the sub-steps or stages of other steps.

[0068] Figure 4An internal structural diagram of a computer device in one embodiment is shown. Specifically, this computer device may be... Figure 1 Server 120 in the middle. For example... Figure 4 As shown, the computer device includes a processor, memory, network interface, input device, and display screen connected via a system bus. The memory includes non-volatile storage media and internal memory. The non-volatile storage media stores an operating system and may also store computer programs. When executed by the processor, these programs enable the processor to implement a handwritten manuscript grading method. The internal memory may also store computer programs, which, when executed by the processor, enable the processor to implement the handwritten manuscript grading method. The display screen can be an LCD screen or an e-ink screen. The input device can be a touch layer covering the display screen, buttons, a trackball, or a touchpad mounted on the computer device's casing, or an external keyboard, touchpad, or mouse.

[0069] Those skilled in the art will understand that Figure 4 The structure shown is merely a block diagram of a portion of the structure related to the present invention and does not constitute a limitation on the computer device to which the present invention is applied. A specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have different component arrangements.

[0070] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The program can be stored in a non-volatile computer-readable storage medium, and when executed, it can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments provided by this invention can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in various forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), Rambus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0071] It should be noted that, in this document, relational terms such as "first" and "second" are used merely to distinguish one entity or operation from another, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Furthermore, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or apparatus. Without further limitations, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or apparatus that includes said element.

[0072] The above description is merely a specific embodiment of the present invention, enabling those skilled in the art to understand or implement the invention. Various modifications to these embodiments will be readily apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the invention. Therefore, the present invention is not to be limited to the embodiments shown herein, but is to be accorded the widest scope consistent with the principles and novel features claimed herein.

Claims

1. A method for grading handwritten manuscripts, characterized in that, The method includes: Obtain the handwritten image of the handwritten manuscript; Based on the handwritten image, obtain the answer area corresponding to each question; The answer area is filtered to obtain a text image, which includes contextual semantic order information; Based on the text image and the contextual semantic order information, text recognition is performed to obtain the text to be scored; The text to be scored is scored according to the scoring model.

2. The method according to claim 1, characterized in that, The step of obtaining the answer area corresponding to each question based on the handwritten image includes: Based on the standard version corresponding to the handwritten manuscript, the standard answer area corresponding to the target question is obtained as the first area; Obtain a preset range outside the first region corresponding to the target question as the second region; Determine whether there is handwritten text in the second area; If there is handwritten text in the second area, then the first area and the second area are merged together to form the answer area corresponding to the target question; If there is no handwritten text in the second area, then the first area will be used as the answer area for the target question.

3. The method according to claim 1, characterized in that, The step of filtering the answer area to obtain the text image includes: The answering region is predicted and segmented to obtain multiple segmentation blocks, each of which includes position information and order information; The segmented blocks are classified, and the categories of the segmented blocks include text blocks and non-text blocks; Filter out non-text block segments and keep text blocks. Obtain the outer contour of the segmented block for each text class; Based on the outer contour of the segmentation block of each text class, obtain the maximum bounding rectangle of all segmentation blocks of the text classes; A blank image is created based on the maximum bounding matrix, and the blank image covers the maximum bounding matrix; Based on the position and order information of the segmented blocks of the text class, the segmented blocks of the text class are filled into the blank image to obtain the text image; The contextual semantic order information of the text image is generated based on the position and order information of the segmented blocks of the text class.

4. The method according to claim 1, characterized in that, The step of performing text recognition based on the text image to obtain the text to be scored also includes: Within a preset angle range, the text image is rotated multiple times according to the rotation step size to perform text recognition.

5. The method according to claim 4, characterized in that, The step of performing text recognition based on the text image to obtain the text to be scored also includes: When performing text recognition on the text image, a Gaussian blur parameter is added to simulate ink diffusion.

6. The method according to claim 1, characterized in that, The step of performing text recognition based on the text image and the contextual semantic order information to obtain the text to be scored also includes: After text recognition, the recognized text is subjected to LaTeX syntax verification. If the recognized text passes the LaTeX syntax check, then the text that passes the LaTeX syntax check is directly output. If the recognized text fails the LaTeX syntax check, the recognized text is converted to output text that conforms to the LaTeX syntax check. The output text that conforms to LaTeX syntax validation is semantically equivalent and classified to merge texts with different writing forms but the same meaning. Based on the contextual semantic order information, the merged texts are equivalently categorized to merge texts with different writing styles but the same meaning again, thus obtaining the text to be scored.

7. The method according to claim 1, characterized in that, Before scoring the text to be scored according to the scoring model, the method includes: Build the initial model; The initial model is trained to obtain the scoring model; The initial model training includes initial training and retraining. The initial training data is standard scoring training data, and the retraining data is data after correcting the standard scoring training data.

8. A handwritten manuscript scoring device, characterized in that, The apparatus applies the method as described in any one of claims 1 to 7, the apparatus comprising: The image acquisition unit is used to acquire handwritten images of the handwritten manuscript; The answer area acquisition unit is used to acquire the answer area corresponding to each question based on the handwritten image. A text image acquisition unit is used to filter the answer area to acquire a text image, wherein the text image includes contextual semantic order information; The recognition unit is used to perform text recognition based on the text image and the contextual semantic order information to obtain the text to be scored; The scoring unit is used to score the text to be scored according to the scoring model.

9. A computer 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 method of any one of claims 1 to 7.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the method of any one of claims 1 to 7.