Answer sheet identification method and device, electronic equipment and storage medium
By using an alignment and slicing method to recognize answer sheets, combined with machine recognition of objective questions and human marking of subjective questions, the consistency and accuracy issues of traditional marking methods are solved, achieving efficient answer sheet recognition and marking.
Patent Information
- Application Number
- CN202511590255.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2025-10-31
- Publication Date
- 2026-02-13
AI Technical Summary
Traditional manual marking methods suffer from poor consistency in scoring standards, limited accuracy, low efficiency, and lack of transparency. Answer sheet recognition systems based on optical marker recognition technology also suffer from low recognition accuracy.
The scanned images and answer sheet templates are aligned through preprocessing operations. Based on the different template information of objective and subjective questions, the images are sliced, the objective question information is identified, and the subjective questions are assigned to the graders. This process combines machine recognition and human grading.
It improves the accuracy of answer sheet recognition and the efficiency of marking, taking into account both the automatic recognition of objective questions and the manual marking of subjective questions, thus ensuring the accuracy and efficiency of marking.
Smart Images

Figure CN121527786A_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application belongs to the technical field of identification of answer sheets, and particularly relates to an identification method and device for answer sheets, an electronic device, and a computer readable storage medium. BACKGROUND
[0002] At present, the traditional manual marking method mainly depends on the subjective judgment and manual operation of the marking teacher. Although a lot of experience has been accumulated in long-term practice, in large-scale standardized tests or daily teaching evaluation, there are problems such as poor consistency of scoring standards, difficulty in guaranteeing fairness, high error rate, limited accuracy, low marking efficiency, insufficient timeliness, lack of transparency and traceability in the scoring process, etc.
[0003] Compared with the manual marking method, the current automatic marking system for answer sheet identification based on optical mark recognition (OMR) technology has been widely used. Although it can partially solve the above problems, it still has the problem of low identification accuracy. SUMMARY
[0004] The present application aims to at least solve one of the technical problems existing in the prior art. To this end, the present application provides an identification method and device for answer sheets, an electronic device, and a computer readable storage medium, which can accurately identify the answer information for objective questions, and assign the subjective questions with low identification accuracy to corresponding marking personnel for marking through a marking system, thereby balancing marking efficiency and marking accuracy.
[0005] In a first aspect, the present application provides an identification method for answer sheets, which comprises: aligning a scanned image of the answer sheet and a preset answer sheet template through a preprocessing operation, the answer sheet template comprising first template information corresponding to objective questions of the answer sheet and second template information corresponding to subjective questions, the answer sheet being made based on the answer sheet template; slicing the preprocessed scanned image based on the first template information and the second template information to obtain first slice images corresponding to the first template information and second slice images corresponding to the second template information; identifying the first slice images to obtain first answer information of each objective question, and assigning the second slice images as second answer information to corresponding target objects for marking.
[0006] In a second aspect, the present application provides an identification device, which comprises: An aligning module is configured to align a scanned image of an answer sheet and a preset answer sheet template through a preprocessing operation, the answer sheet template including first template information corresponding to objective questions of the answer sheet and second template information corresponding to subjective questions, and the answer sheet being made based on the answer sheet template. A slicing module is configured to slice the preprocessed scanned image based on the first template information and the second template information to obtain first sliced images corresponding to the first template information and second sliced images corresponding to the second template information. An identifying module is configured to identify the first sliced images to obtain first answer information of the objective questions, and distribute the second sliced images as second answer information to corresponding target objects for marking.
[0007] In a third aspect, the present application provides an electronic device, comprising: a memory and a processor; the memory is configured to store one or more computer instructions; the processor is configured to execute the one or more computer instructions to implement the above-mentioned answer sheet identification method.
[0008] In a fourth aspect, the present application provides a computer readable storage medium having one or more computer instructions stored thereon, the instructions being executed by a processor to implement the above-mentioned answer sheet identification method.
[0009] The answer sheet identification method, identification device, electronic device and computer readable storage medium provided by the embodiments of the present application first align the scanned image and the answer sheet template through a preprocessing operation to improve the accuracy of subsequent template matching. Then, based on the first template information corresponding to the objective questions, the objective question part is positioned and sliced to obtain the first sliced images, and then based on the second template information corresponding to the subjective questions, the subjective question part is positioned and sliced to obtain the second sliced images.
[0010] Finally, the filling and writing conditions of the filling and writing frames of each objective question in the first sliced images are identified, and the first answer information of each objective question can be accurately obtained. For the subjective question part, the second sliced images obtained by slicing are directly distributed to the corresponding marking personnel in the marking system for marking, thereby avoiding the problem of reduced marking accuracy caused by reduced handwriting recognition accuracy of the subjective questions, and taking into account the marking efficiency and marking accuracy.
[0011] Additional aspects and advantages of the embodiments of the present application will be in part apparent and in part pointed out hereinafter. BRIEF DESCRIPTION OF DRAWINGS
[0012] The above and / or additional aspects and advantages of the present application will become apparent and more readily appreciated from the following description, taken in conjunction with the following drawings in which: Figure 1 is a schematic diagram of an application scenario of the answer sheet recognition method provided by the embodiments of the present application; Figure 2 is a first flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 3 is a first scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 4 is a second flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 5 is a second scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 6 is a third scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 7 is a fourth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 8 is a fifth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 9 is a sixth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 10 is a seventh scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 11 is an eighth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 12 is a third flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 13 is a fourth flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 14 is a ninth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 15 is a tenth scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 16 is a fifth flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 17 is an eleventh scenario diagram of the answer sheet recognition method provided by the embodiments of the present application; Figure 18 is a sixth flowchart of the answer sheet recognition method provided by the embodiments of the present application; Figure 19 This is a schematic diagram of the seventh process of the answer sheet recognition method provided in the embodiments of this application; Figure 20 This is the eighth flowchart of the answer sheet recognition method provided in the embodiments of this application; Figure 21 This is a schematic diagram of the identification device provided in the embodiments of this application; Figure 22 This is a schematic diagram of the structure of the terminal device provided in the embodiments of this application; and Figure 23 This is a schematic diagram of the hardware structure of the terminal device provided in the embodiments of this application. Detailed Implementation
[0013] Numerous specific details are set forth in the following description to provide a full understanding of this application. However, this application can be implemented in many other ways different from those described herein, and those skilled in the art can make similar extensions without departing from the spirit of this application. Therefore, this application is not limited to the specific embodiments disclosed below.
[0014] It should be noted that the terms "first," "second," "third," etc., in the claims, specification, and drawings of this application are used to distinguish similar objects and are not used to describe a specific order or sequence. Such data are interchangeable where appropriate so that the embodiments of this application described herein can be implemented in a sequence other than that shown or described herein. Furthermore, the terms "comprising," "having," and their variations are intended to cover non-exclusive inclusion; for example, a process, method, system, product, or apparatus that includes a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to these processes, methods, products, or apparatuses.
[0015] It should be understood that in the embodiments of this application, "at least one" means one or more, and "more than one" means two or more. "And / or" is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, and B existing alone. The character " / " generally indicates that the related objects before and after it are in an "or" relationship. "Contains A, B and / or C" means containing any one, two, or three of A, B, and C.
[0016] It should be understood that in the embodiments of this application, "B corresponding to A", "B corresponding to A", "A corresponds to B" or "B corresponds to A" means that B is associated with A, and B can be determined based on A. Determining B based on A does not mean that B is determined solely based on A; B can also be determined based on A and / or other information.
[0017] This application provides a method, apparatus, electronic device, and computer-readable storage medium for recognizing answer sheets.
[0018] The answer sheet recognition method provided in this application can be executed by an electronic device, which can be a terminal device or a server, etc. The terminal device can be a smartphone, tablet computer, laptop computer, etc.
[0019] A server can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud storage, network services, cloud communication, middleware services, domain name services, security services, CDN, and big data and artificial intelligence platforms.
[0020] In an optional embodiment, when the answer sheet recognition method is run on a terminal device, the terminal device may include a display screen and a processor, the display screen being used to present first answer information and second answer information.
[0021] There are several ways in which a terminal device can provide a graphical user interface to a player, such as rendering it on the terminal device's display screen or presenting the graphical user interface through holographic projection.
[0022] It should be noted that, in this embodiment of the application, the entity executing the answer sheet recognition method can be a terminal device or a server. This embodiment of the application does not limit the type of the entity executing the method.
[0023] For example, in conjunction with the above description, Figure 1 This application illustrates a marking system 1000 that provides a method for recognizing answer sheets. The marking system 1000 may include at least one terminal device 100, at least one server 200, at least one database 300, and a network.
[0024] The user's terminal device 100 can connect to different servers via a network. The terminal device is any device with computing hardware capable of supporting and executing the software application tools corresponding to the marking system 1000.
[0025] In the aforementioned marking system 1000, the terminal device 100 is used to install and run the marking application. In some cases, the marking application may not need to be installed on the terminal device 100 in advance, and players can directly access the marking system through a browser or other client.
[0026] The examiners log in to the marking application using their registered marking accounts. When logging in, the terminal device 100 sends a login request to the server 200. The server 200 verifies the marking account used by the examiner, and if the verification is successful, it returns a login success notification to the terminal device 100.
[0027] Furthermore, when the marking system 1000 includes multiple terminal devices, multiple servers, and multiple networks, different terminal devices can connect to each other through different networks and different servers. The network can be a wireless network or a wired network; for example, wireless networks include wireless local area networks (WLAN), local area networks (LAN), cellular networks, 2G networks, 3G networks, 4G networks, 5G networks, etc.
[0028] In addition, different terminal devices can also use their own Bluetooth network or hotspot network to connect to other terminal devices or to servers.
[0029] In addition, the system 100 may include multiple databases, which are coupled to different servers for storing answer information.
[0030] It should be noted that, Figure 1 The illustrated marking system diagram is merely an example. The marking system 1000 described in this application embodiment is intended to more clearly illustrate the technical solutions of this application embodiment and does not constitute a limitation on the technical solutions provided in this application embodiment. As those skilled in the art will know, with the evolution of marking systems and the emergence of new business scenarios, the technical solutions provided in this application embodiment are also applicable to similar technical problems.
[0031] The technical solution of this application will be described in detail below through specific embodiments. It should be noted that the following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.
[0032] Please see Figure 2 The answer sheet recognition method of this application may include the following steps 011 to 013, which are described in detail below.
[0033] Step 011: Align the scanned image of the answer sheet with the preset answer sheet template through preprocessing operations. The answer sheet template includes first template information corresponding to the objective questions on the answer sheet and second template information corresponding to the subjective questions. The answer sheet is made based on the answer sheet template. The preprocessing operation is performed to facilitate matching and positioning between the scanned image and the answer sheet template. For example, the scanned image is scaled so that its size matches that of the answer sheet template, thus making matching and positioning easier.
[0034] The answer sheet template refers to the standardized style used to create answer sheets. It specifies the layout, format, information columns, and other content of the answer sheet to ensure that the answer sheet can meet the requirements of the examination and facilitate candidates' answers and machine scanning and grading.
[0035] Please refer to Figure 3 Answer sheet templates generally include an objective question area S1 and a subjective question area S2. The first template information is the relevant information for the objective question area (such as the edge position of the objective question area, the position of each objective question, and the type of objective question (such as single choice, multiple choice, etc.), and the second template information is the relevant information for the subjective question area (such as the edge position of the subjective question area and the position of each subjective question, etc.).
[0036] Please see Figure 4 In one optional embodiment, step 011 includes: Step 0111: Scale the scanned image so that the scanned image and the answer sheet template are the same size; Step 0112: Convert the scaled scanned image into a binary image and perform opening and closing operations to remove noise; Step 0113: Detect the four corner positioning points in the denoised binarized image, and perform an affine transformation based on the four corner positioning points and the four corner reference positioning points in the answer sheet template to obtain a scanned image aligned with the answer sheet template.
[0037] Specifically, in order to align the scanned image and the answer sheet template, the dimensions of the scanned image and the answer sheet template need to be aligned first, such as by scaling the scanned image and / or the answer sheet template so that the scanned image and the answer sheet template are the same size.
[0038] After scaling, to improve the matching accuracy of the answer sheet template, the scaled scanned image can be converted into a grayscale image. Then, by applying a preset threshold, the grayscale image can be converted into a binarized image. Finally, opening and closing operations are performed on the binarized image to remove noise, resulting in a more accurate binarized image.
[0039] Among them, opening and closing operation denoising removes specific types of noise by interacting with the image through "structuring elements". It preserves the main structure of the image while removing specific types of noise, and is especially suitable for the preprocessing of binary images (black and white images) and grayscale images.
[0040] Opening and closing operations for denoising mainly include opening and closing operations. The opening operation first erodes the image and then dilates it, denoted as: opening operation = dilation(erosion(image, structuring element), structuring element). The closing operation first dilates the image and then erodes it, denoted as: closing operation = erosion(dilation(image, structuring element), structuring element).
[0041] Thus, by using opening and closing operations to denoise, interference noise in the scanned image (such as ink spots, scratches, and paper stains) can be accurately removed, while preserving the key structure of the answer sheet (such as the answer area border, filling marks, and four corner positioning points) to the greatest extent possible, thereby improving the accuracy of subsequent alignment.
[0042] Finally, the four corner positioning points of the denoised binarized image can be detected, and then an affine transformation is performed based on the four corner positioning points of the binarized image and the corresponding four corner positioning points in the answer sheet template to obtain a scanned image aligned with the answer sheet template.
[0043] Among them, affine transformation can achieve image alignment by combining various transformations such as translation, rotation, scaling, and shearing based on the relationship between the original coordinates and the transformed coordinates.
[0044] For example, the answer sheet includes preset markers to assist in aligning the scanned image and the answer sheet template. If the preset markers include four corner positioning points, the affine transformation of the denoised binary image can be performed by using the positional relationship between the four corner reference positioning points O1 in the answer sheet template and the corresponding four corner positioning points in the binarized image. This ensures that the four corner positioning points in the transformed binary image are respectively aligned with their corresponding four corner reference positioning points O1 (e.g., when the transformed binary image and the answer sheet template are superimposed, each four corner positioning point and its corresponding four corner reference positioning point O1 essentially coincide).
[0045] In an optional embodiment, the preset mark further includes a direction marker point for indicating the placement orientation of the answer sheet. Before the affine transformation, the scanned image is rotated so that the direction marker point of the scanned image is aligned with the direction of the reference direction marker point O2 in the answer sheet template.
[0046] It is understandable that the answer sheet may be rotated in different directions. In order to ensure the accuracy of subsequent alignment, it is necessary to use orientation markers to calibrate the orientation of the scanned image. If the orientation markers are multiple rectangles located on one side of the answer sheet, rotation is used to align the orientation markers of the denoised binarized image with the reference orientation marker O2 in the answer sheet template.
[0047] Step 012: Based on the first template information and the second template information, slice the preprocessed scanned image to obtain a first slice image corresponding to the first template information and a second slice image corresponding to the second template information; Specifically, please refer to Figures 5 to 7 , Figure 5 For the scanned image, the first template information may include the position information of the edges of the objective question region S1 (e.g., if the objective question region is a rectangle, the first template information includes the coordinates of the four corners of the rectangle). In the aligned scanned image, the objective question region S3 is also aligned with the objective question region S1 in the answer sheet template. Therefore, based on the first template information, the objective question region S3 can be quickly located in the scanned image, thereby cropping the first slice image P1. Similarly, based on the second template information, the subjective question region S4 can be quickly located in the scanned image, thereby cropping the second slice image P2.
[0048] Please see Figures 8 to 11 In one optional embodiment, the answer sheet template further includes at least one of the following: third template information corresponding to the absence marking area S5, fourth template information corresponding to the admission ticket area S6, and fifth template information corresponding to the student information area S7. Based on the third template information, the scanned image can be sliced to obtain a third slice image P3 corresponding to the absence marking area S5; based on the fourth template information, the scanned image can be sliced to obtain a fourth slice image P4 corresponding to the admission ticket area S6; and based on the fifth template information, the scanned image can be sliced to obtain a fifth slice image P5 corresponding to the student information area S7.
[0049] In this way, by using the template information in the answer sheet template, the corresponding area can be quickly located in the scanned image and the corresponding slice image can be cropped.
[0050] Step 013: Identify the first slice image to obtain the first answer information for each objective question, and assign the second slice image as the second answer information to the corresponding target object for grading.
[0051] The first template information also includes information about each objective question, such as the location of each objective question and the location of the corresponding fill-in box for each objective question.
[0052] Using the first template information, each objective question in the first slice image is identified, and the filling recognition result of the filling box of each objective question (such as whether it is filled) is obtained, thereby obtaining the first answer information of the objective question.
[0053] Please see Figure 6 , Figure 7 and Figure 12 In an optional embodiment, step 013 includes: Step 0131: Identify the filling boxes in each first slice image to obtain the filling identification results of each filling box.
[0054] It is understandable that, since objective questions are filled in with blank boxes, there is no problem with the low recognition accuracy caused by handwriting. By using a pre-trained recognition model for filling recognition, or by using OCR recognition, the filling boxes in each first slice image can be recognized accurately to obtain the filling recognition results of each filling box.
[0055] For example, by identifying the filling in of each option for each objective question, the filling in and identification results of each objective question can be determined separately (such as the filling in of each objective question option (such as A, B, C, D, etc.)).
[0056] For subjective questions with handwritten characters, there is no need for recognition. The second slice image containing the second answer information of the subjective question is simply assigned to the examiner (i.e. the target object) for marking. This fully leverages the examiner's rich marking experience and avoids the problem of low recognition accuracy caused by irregular handwriting, which leads to low marking accuracy, thus ensuring the marking accuracy of subjective questions.
[0057] In this way, objective questions are quickly answered by machine recognition to ensure the accuracy and efficiency of marking, while subjective questions are marked by human examiners to ensure the accuracy of marking.
[0058] Please see Figure 13 In an optional embodiment, step 0131: Step 01311: Scale the reference position coordinates of each fill-in box in the answer sheet template to generate scaled positioning coordinates; Step 01312: Based on the positioning coordinates corresponding to each filling box, slice the filling boxes in the first slice image to obtain the filling box images corresponding to each filling box; Step 01313: Convert each fill box image into a binary image and perform opening and closing operations to denoise it, so as to crop the cropped image corresponding to the fill box region in the fill box image. Step 01314: Input cropped images from different batches into the pre-trained filling box recognition model to obtain the filling recognition results of each filling box.
[0059] Specifically, in order to further improve the accuracy of filling, the filling frame can be precisely positioned when performing filling frame recognition.
[0060] First, after aligning the entire scanned image, there may be a deviation between the aligned scanned image and the corresponding fill-in boxes in the answer sheet template, and they will not be completely aligned.
[0061] Therefore, please refer to Figure 14To generate magnified positioning coordinates, you can first enlarge the reference coordinates of each fill-in box in the answer sheet template. For example, if the fill-in box is rectangular, the coordinates of the top-left corner of any target fill-in box in the answer sheet template are (x1, y1), and the coordinates of the bottom-right corner are (x2, y2). You can shrink the top-left corner coordinates and enlarge the bottom-right corner coordinates to enlarge the area matched by the target fill-in box. Figure 14 The coordinates of the top left corner of the matched region S8 become (x1-a, y1-a), and the coordinates of the bottom right corner become (x2+b, y2+b). The scaling factor 'a' of the top left corner coordinates and the scaling factor 'b' of the bottom right corner coordinates are determined based on the spacing between adjacent fill box regions and the size of the fill box region, ensuring that the region matched by the target fill box in the first slice image contains at least one complete fill box and does not contain two complete fill boxes at the same time.
[0062] Please refer to the following: Figure 15 Based on the magnified positioning coordinates of the target filling box (the coordinates of the top left corner are (x1-a, y1-a), and the coordinates of the bottom right corner are (x2+b, y2+b)), the target filling box is located in the first slice image, the matching region S8 is determined, and the region S8 is sliced to obtain the filling box image P6 containing the target filling box. As shown in the slice... Figure 14 The image on page 6 shows the corresponding fill boxes for the four options in question 1.
[0063] Next, each filled-in bounding box image P6 can be converted into a binary image, and opening / closing operations can be performed to denoise it, so as to crop the cropped image P7 corresponding to the filled-in bounding box region in the filled-in bounding box image P6. For example... Figure 15 As shown, the fill box regions in each fill box image P6 are cropped to obtain the corresponding cropped image P7. By combining binarized images and opening / closing operations for denoising, irrelevant noise outside the edge lines of the filling box and the filling content can be removed, thereby accurately locating the filling box and cropping the cropped image P7 corresponding to the filling box area, further improving the accuracy of subsequent filling box recognition.
[0064] Finally, the cropped images P7 corresponding to each filling box can be divided into multiple batches and input into a pre-trained filling box recognition model in batches to obtain the filling recognition results for each batch of filling boxes. The filling box recognition model can be a neural network model.
[0065] Thus, by implementing batch-based filling and identification, the efficiency of filling and identification can be improved.
[0066] The answer sheet recognition method provided in this application first aligns the scanned image and the answer sheet template through preprocessing to improve the accuracy of subsequent template matching. Then, based on the first template information corresponding to the objective questions, the objective question portion is located and sliced to obtain a first slice image. Next, based on the second template information corresponding to the subjective questions, the subjective question portion is located and sliced to obtain a second slice image.
[0067] Finally, by identifying the filling status of the fill boxes for each objective question in the first slice image, the first answer information for each objective question can be accurately obtained. For the subjective questions, the second slice image obtained from the first slice is directly assigned to the corresponding examiners in the marking system for marking. This avoids the problem of reduced marking accuracy caused by the reduced accuracy of handwriting recognition for subjective questions, thus balancing marking efficiency and marking accuracy.
[0068] Please see Figures 9 to 11 ,and Figure 16 In some embodiments, the answer sheet template further includes at least one of the following: third template information corresponding to the absence marking area, fourth template information corresponding to the admission ticket area, and fifth template information corresponding to the student information area. The answer sheet recognition method of this application further includes: Step 014: Based on the third template information, slice the preprocessed scanned image to obtain the third slice image P3 corresponding to the missing examination marking area; Step 015: Based on the fourth template information, slice the preprocessed scanned image to obtain the fourth slice image P4 corresponding to the examination admission ticket area; Step 016: Based on the fifth template information, slice the preprocessed scanned image to obtain the fifth slice image P5 corresponding to the student information area.
[0069] The absence marking area is used to indicate whether a student is absent from the exam, the admission ticket area is used to record the admission ticket number, and the student information area is used to record student information (such as name, class, exam room, seat number, etc.).
[0070] Specifically, other information in the answer sheet also needs to be identified. The answer sheet template may also include at least one of the following: third template information corresponding to the absence mark area, fourth template information corresponding to the admission ticket area, and fifth template information corresponding to the student information area.
[0071] To identify absence information, examination admission ticket number, and student information, it is also necessary to slice the corresponding areas in the scanned image to obtain sliced images corresponding to different information.
[0072] For example, using third template information (such as the location coordinates of the absence mark area), the scanned image is located and sliced to obtain a third slice image corresponding to the absence mark area; using fourth template information (such as the location coordinates of the admission ticket area), the scanned image is located and sliced to obtain a fourth slice image corresponding to the admission ticket area; using fifth template information (such as the location coordinates of the student information area), the scanned image is located and sliced to obtain a fifth slice image corresponding to the student information area.
[0073] Please continue reading. Figures 9 to 11 ,and Figure 16 In some embodiments, after obtaining the third to fifth slice images, the answer sheet recognition method of this application further includes: Step 017: Based on the filling recognition result of the filling box in the third slice image P3 corresponding to the absence mark region, determine the absence recognition result; Step 018: Based on the filling recognition result of the filling box in the fourth slice image P4 corresponding to the admission ticket area, determine the admission ticket number recognition result; Step 019: Assign the fifth slice image P5 corresponding to the student information area to the corresponding target object for grading.
[0074] Specifically, by performing fill-in recognition on the fill-in boxes in the third slice image corresponding to the absence marker area, the absence recognition result, such as whether the candidate is absent, can be obtained.
[0075] By filling in the marked box in the fourth slice image corresponding to the examination admission ticket area, the examination admission ticket number can be determined.
[0076] For example, such as Figure 10 As shown, the admission ticket area comprises multiple columns, each corresponding to one digit of the admission ticket number. Each column includes multiple fill-in boxes; the number corresponding to the filled-in box is the value of the corresponding digit in the admission ticket number for that column. Thus, based on the filling and recognition results of each fill-in box in each column, the admission ticket number can be quickly determined. Figure 10 Based on the filling recognition results of the filling boxes in each column, the admission ticket number can be determined as 12051798.
[0077] For student information, which is usually handwritten, the fifth slice image containing the student information can be directly assigned to the corresponding examiner for grading.
[0078] Please see Figure 17 In some embodiments, the subjective question area includes an optional question area with fill-in boxes and a writing area corresponding to each optional question. The answer sheet recognition method of this application further includes: Step 020: Identify the fill-in boxes in the optional question area of the second slice image corresponding to the subjective question area to obtain the optional question identification result; Step 013: Assign the second slice image as the second answer information to the corresponding target for grading, including: Step 0132: Assign the writing areas corresponding to each optional question in the second slice image corresponding to the optional question recognition results and the subjective question area to the corresponding target objects for grading.
[0079] Specifically, subjective questions may include optional questions. Students need to select the number of the optional question and answer it in the designated writing area for the subjective question.
[0080] Therefore, in order to facilitate the marking of papers, in addition to providing the marking staff with the writing area for subjective questions, the marking staff should also be informed of the serial number of the question they selected on the current answer sheet.
[0081] Therefore, the fill boxes in the optional question area of the second slice image corresponding to the subjective question area can be identified to obtain the optional question identification result and determine the serial number of the optional question.
[0082] Then, the writing areas corresponding to each optional question in the second slice image corresponding to the subjective question area are assigned to the corresponding target object for grading.
[0083] Please see Figure 18 In some embodiments, the answer sheet template includes multiple pages, the second template information includes a subjective question area, and each page's subjective question area contains a second slice image. The answer sheet recognition method further includes: Step 021: In the case where the subjective question area spans multiple pages, the multiple second slice images corresponding to the subjective question area that spans multiple pages are stitched together according to the page number to obtain the sixth slice image; Step 013: Assign the second slice image as the second answer information to the corresponding target for grading, including: Step 0133: Assign the sixth slice image as the second answer information to the corresponding target object for grading.
[0084] Specifically, the subjective question area may be large and spread across different pages of different answer sheets, i.e., the subjective question area spans multiple pages. In this case, to facilitate the examiners' viewing and avoid the need for manual sorting, which reduces the efficiency of the marking process, multiple second-slice images corresponding to the multi-page subjective question area can be stitched together according to page numbers to obtain the sixth-slice image. In this way, the subjective question areas in the sixth-slice image are continuous and accurately ordered, making it easier for the examiners to mark the papers.
[0085] Please see Figure 19In some embodiments, the answer sheet recognition method further includes: Step 022: Convert each second slice image into a binary image and perform opening and closing operations to denoise it, so as to crop out the seventh slice image corresponding to the subjective question region in the second slice image; Step 013: Assign the second slice image as the second answer information to the corresponding target for grading, including: Step 0134: Assign the seventh slice image as the second answer information to the corresponding target object for grading.
[0086] Specifically, aligning the four corner positioning points of the scanned image and the answer sheet template may cause a discrepancy between the subjective question area in the scanned image and the subjective question area in the answer sheet template. Therefore, to improve the accuracy of the second slice image, each second slice image can be converted into a binary image and subjected to opening and closing operations for noise reduction to remove noise outside the subjective question area, thereby more accurately defining the subjective question area. This allows for the accurate cropping of the subjective question area in the second slice image, resulting in the seventh slice image.
[0087] Then, the seventh slice image can be used as the second answer information and assigned to the corresponding target for marking, which improves the accuracy of the subjective question area and makes it easier for the markers to mark the papers.
[0088] In some embodiments, the information of the answer sheet template is recorded in a JSON file. By reading the JSON file, different template information in the answer sheet template can be quickly obtained, such as relevant information for the objective question area and relevant information for the subjective question area.
[0089] The answer sheet template includes basic image information, four corner reference points, reference direction markers, an absence marking area, student information, admission ticket number, objective question area, and subjective question area.
[0090] (1) Basic image information includes: image name: imageName, image height: imageHeight and image width: imageWidth.
[0091] (2) Four corner reference positioning points Set a black square frame in each of the four corners of the template page (for page positioning and answer sheet correction).
[0092] The top left corner point is named: layout_flag_01; The top right corner is named: layout_flag_02; The bottom right corner is named: layout_flag_03; The bottom left corner is named: layout_flag_04.
[0093] (3) Reference direction markers Add a column of long black squares on the left side of the template page to determine the page orientation.
[0094] (4) Absentee marking area The test includes a fill-in box. Filling in the box confirms absence from the test, while leaving it blank indicates that you are not absent.
[0095] (5) Student Information Area It is used to record students' names, classes, examination rooms, and seat numbers.
[0096] (6) Examination Admission Ticket Area Used to record the admission ticket number, the admission ticket area includes multiple columns, one column corresponds to one digit on the admission ticket, and each column includes multiple fill boxes. The number corresponding to the filled-in box is the value of the corresponding digit on the admission ticket.
[0097] (7) Objective Questions Area It includes multiple objective questions, and the corresponding fill-in boxes for the options of each objective question.
[0098] (8) Subjective Question Area It can include fill-in-the-blank questions, answer questions, essay questions, optional questions, etc. In the subjective question area, except for the optional questions which have a fill-in-the-blank box, all other types of questions require students to write their answers by hand.
[0099] Based on the method described in the above embodiments, this application also provides an answer sheet recognition device 300 for performing the steps in the above answer sheet recognition method. Please refer to... Figure 21 , Figure 21 This is a schematic diagram of the identification device 300 provided in an embodiment of this application. The identification device 300 includes: Alignment module 301 is used for alignment module, used to align scanned image and preset answer sheet template through preprocessing operation. The answer sheet template includes first template information corresponding to each objective question on the answer sheet and second template information corresponding to each subjective question. The slicing module 302 is used to slice the scanned image based on the first template information and the second template information to obtain a first slice image corresponding to the first template information and a second slice image corresponding to the second template information. The recognition module 303 is used to recognize the first slice image to obtain the first answer information for each objective question, and to assign the second slice image as the second answer information to the corresponding target object for grading.
[0100] In the embodiments of this application, the terms "module" or "unit" refer to computer instructions or a portion of computer instructions that have a predetermined function and work together with other related parts to achieve a predetermined goal, and can be implemented wholly or partially using software, hardware (such as processing circuitry or memory), or a combination thereof. Similarly, a processor (or multiple processors or memory) can be used to implement one or more modules or units. Furthermore, each module or unit can be part of an overall module or unit that includes the functionality of that module or unit.
[0101] In some embodiments, the identification device in this application can be implemented in hardware, such as a terminal device or a component in the terminal device, such as an integrated circuit or a chip; the identification device can also be implemented in software, such as as an application installed in the terminal device.
[0102] In some embodiments, please refer to Figure 22 , Figure 22 This is a schematic diagram of the terminal device provided in the embodiments of this application. The terminal device 500 includes a processor 501, a memory 502, and a display screen 503. The memory 502 stores computer instructions 504 that can be executed by the processor 501. When the processor 501 executes the instructions 504, it implements the various processes of the embodiments of the above-described answer sheet recognition method and achieves the same technical effect. To avoid repetition, it will not be described again here.
[0103] Please see Figure 23 , Figure 23 This is a schematic diagram of the hardware structure of a terminal device provided in an embodiment of this application. The terminal device can be a terminal or a server. Exemplarily, the terminal device 700 includes a central processing unit (CPU) 701, a system memory 704 including random access memory (RAM) 702 and read-only memory (ROM) 703, and a system bus 705 connecting the system memory 704 and the central processing unit 701.
[0104] In some embodiments, the terminal device 700 may further include a basic input / output system 706 that helps transmit information between various devices within the computer, and a large-capacity storage device 707 for storing the operating system 713, the client 714, and other program modules 715.
[0105] In some embodiments, the basic input / output system 706 includes a display 708 for displaying a graphical user interface and input devices 709 for user input, such as touch panels and other input devices. A touch panel is also called a touchscreen. A touch panel may include both a touch device and a touch controller. Other input devices may include, but are not limited to, physical keyboards, function keys (such as volume control buttons, power buttons, etc.), trackballs, mice, and joysticks, which will not be described further here.
[0106] Both the display 708 and the input device 709 are connected to the central processing unit 701 via an input / output controller 710 connected to the system bus 705. The basic input / output system 706 may also include the input / output controller 710 for receiving and processing input from touch panels, other input devices, etc. Similarly, the input / output system 706 also includes output devices such as displays, printers, or other types of output devices.
[0107] Mass storage device 707 is connected to central processing unit 701 via a mass storage controller (not shown) connected to system bus 705. Mass storage device 707 and its associated computer-readable media provide non-volatile storage for terminal device 700. That is, mass storage device 707 may include computer-readable media (not shown) such as hard disk or compact disc read-only memory (CD-ROM) drive.
[0108] According to various embodiments of this application, the terminal device 700 can also be connected to a remote computer on a network, such as the Internet. That is, the terminal device 700 can be connected to the network 717 via the network interface unit 716 connected to the system bus 705, or the network interface unit 716 can be used to connect to other types of networks or remote computer systems (not shown).
[0109] This application also provides a non-transitory computer-readable storage medium storing computer instructions. When these computer instructions are executed by a processor, they implement the various processes of the above-described answer sheet recognition method and achieve the same technical effect. To avoid repetition, they will not be described again here.
[0110] The processor can be the processor in the terminal device described in the above embodiments. The computer-readable storage medium can be a computer read-only memory (ROM), random access memory (RAM), magnetic disk, or optical disk, etc.
[0111] Computer-readable media can include computer storage media and communication media. Computer storage media includes volatile and non-volatile, removable and non-removable media implemented using any method or technology for storing information such as computer-readable instructions, data structures, program modules, or other data. Computer storage media include RAM, ROM, erasable programmable read-only memory (EPROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other solid-state storage technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape cassettes, magnetic tape, disk storage, or other magnetic storage devices. Of course, those skilled in the art will recognize that computer storage media are not limited to the above-mentioned types.
[0112] This application also provides a computer instruction product, including computer instructions that, when executed by a processor, implement the above-described answer sheet recognition method. The processor may be the processor in the terminal device described in the above embodiments. When executed by the processor, the computer instructions implement various processes of the embodiments of the above-described answer sheet recognition method and achieve the same technical effects; therefore, to avoid repetition, they will not be described again here.
[0113] It is understood that in the specific implementation of this application, data related to user identity or characteristics is involved. When the above embodiments of this application are applied to specific products or technologies, user permission or consent is required, and the collection, use and processing of related data must comply with the relevant laws, regulations and standards of the relevant countries and regions.
Claims
1. A method for recognizing answer sheets, characterized in that, include: The scanned image of the answer sheet and the preset answer sheet template are aligned through preprocessing operations. The answer sheet template includes first template information corresponding to the objective questions of the answer sheet and second template information corresponding to the subjective questions. The answer sheet is made based on the answer sheet template. Based on the first template information and the second template information, the preprocessed scanned image is sliced to obtain a first slice image corresponding to the first template information and a second slice image corresponding to the second template information; The first slice image is identified to obtain the first answer information for each of the objective questions, and the second slice image is assigned as the second answer information to the corresponding target object for grading.
2. The answer sheet recognition method according to claim 1, characterized in that, The answer sheet includes preset markers, which include four corner positioning points. The preprocessing operation to align the scanned image and the preset answer sheet template includes: The scanned image is scaled so that the scanned image and the answer sheet template are the same size; The scaled scanned image is converted into a binary image, and opening and closing operations are performed to denoise it. The four corner positioning points in the denoised binarized image are detected, and an affine transformation is performed based on the four corner positioning points and the four corner reference positioning points in the answer sheet template to obtain the scanned image aligned with the answer sheet template.
3. The answer sheet recognition method according to claim 2, characterized in that, The preset markers also include direction markers. Before detecting the four corner positioning points in the denoised binarized image, the method further includes: Rotate the scanned image so that the orientation markers of the scanned image are aligned with the orientation markers of the reference orientation markers in the answer sheet template.
4. The answer sheet recognition method according to claim 1, characterized in that, The step of identifying the first slice image to obtain the first answer information for each of the objective questions includes: The filling boxes in each of the first slice images are identified to obtain the filling identification results of each filling box.
5. The answer sheet recognition method according to claim 4, characterized in that, The step of identifying the filling boxes in each of the first slice images to obtain the filling identification results of each filling box includes: The reference position coordinates of each fill-in box in the answer sheet template are scaled to generate scaled positioning coordinates; Based on the positioning coordinates corresponding to each of the filling boxes, the filling boxes in the first slice image are sliced to obtain the filling box images corresponding to each of the filling boxes; Each of the filling box images is converted into a binary image, and opening and closing operations are performed to denoise it, so as to crop the cropped image corresponding to the filling box region in the filling box image. Different batches of the cropped images are input into a pre-trained filling box recognition model to obtain the filling recognition results of each filling box.
6. The answer sheet recognition method according to claim 1, characterized in that, The answer sheet template also includes at least one of the following: third template information corresponding to the absence marking area, fourth template information corresponding to the admission ticket area, and fifth template information corresponding to the student information area. The method further includes: Based on the third template information, the preprocessed scanned image is sliced to obtain a third slice image corresponding to the absence mark area; Based on the fourth template information, the preprocessed scanned image is sliced to obtain a fourth slice image corresponding to the examination admission ticket area; Based on the fifth template information, the preprocessed scanned image is sliced to obtain a fifth slice image corresponding to the student information area.
7. The answer sheet recognition method according to claim 6, characterized in that, Also includes: Based on the filling recognition result of the filling box in the third slice image corresponding to the absence mark area, the absence recognition result is determined; Based on the filling recognition result of the filling box in the fourth slice image corresponding to the admission ticket area, the admission ticket number recognition result is determined; The fifth slice image corresponding to the student information area is assigned to the corresponding target object for grading.
8. An identification device, characterized in that, The device includes: The alignment module is used to align the scanned image and the preset answer sheet template through preprocessing operations. The answer sheet template includes first template information corresponding to the objective questions on the answer sheet and second template information corresponding to the subjective questions. The slicing module is used to slice the preprocessed scanned image based on the first template information and the second template information to obtain a first sliced image corresponding to the first template information and a second sliced image corresponding to the second template information. The recognition module is used to recognize the first slice image to obtain the first answer information for each of the objective questions, and to assign the second slice image as the second answer information to the corresponding target object for grading.
9. An electronic device, characterized in that, include: Memory and processor; The memory is used to store one or more computer instructions; The processor is used to execute the one or more computer instructions to implement the method as described in any one of claims 1-7.
10. A computer-readable storage medium storing one or more computer instructions thereon, characterized in that, The instruction is executed by the processor to implement the method as described in any one of claims 1-7.