CN-122024248-A - Optical mark recognition method, optical mark recognition device, computer equipment and storage medium
Abstract
The invention relates to an optical mark recognition method, an optical mark recognition device, computer equipment and a storage medium, wherein the method comprises the steps of obtaining an original image; the method comprises the steps of positioning areas to be judged from an original image, obtaining characteristic values of each area to be judged, obtaining attention weight values of each area to be judged according to the characteristic values of each area to be judged, and obtaining types of each area to be judged according to the attention weight values of each area to be judged, wherein the types comprise effective filling, ineffective filling and abnormal filling, and the abnormal filling comprises stain pollution, filling position offset and erasing residues. The invention can improve the accuracy of optical mark recognition.
Inventors
- YAN BAOQIANG
- GAO JUNLING
- LIU XIONGMIN
- TAO XIAOLIU
- ZHANG KAIGUO
Assignees
- 深圳市海云天科技股份有限公司
Dates
- Publication Date
- 20260512
- Application Date
- 20260126
Claims (10)
- 1. A method of optical marker identification, the method comprising: Acquiring an original image; Positioning a region to be judged from the original image; acquiring a characteristic value of each region to be judged; acquiring the attention weight value of each region to be judged according to the characteristic value of each region to be judged; acquiring the type of each region to be judged according to the attention weight value of each region to be judged; The types include effective fill, ineffective fill and abnormal fill, wherein the abnormal fill includes stain contamination, fill position offset and erase residue.
- 2. The method of claim 1, wherein locating the region to be determined from the original image comprises: Acquiring a positioning point in the original image; Calibrating the coordinates of the original image according to the positioning points; acquiring a marking frame, a filling area and an interference area through neighborhood pixel connectivity; Acquiring coordinate information of each marking frame, each filling area and each interference area; and carrying out coordinate adjustment according to the barycenter coordinates of the connected domain, and taking the mark frame after coordinate adjustment, the filling area after coordinate adjustment and the interference area after coordinate adjustment as the area to be judged.
- 3. The method according to claim 2, wherein the obtaining the feature value of each region to be determined includes: acquiring gray characteristic values, density characteristic values and shape characteristic values of the region to be judged; Normalizing the gray scale feature value, the density feature value and the shape feature value to obtain a normalized gray scale feature value, a normalized density feature value and a normalized shape feature value of the region to be judged; The density characteristic value is the proportion of the area to be judged occupied by the filling pixel; The gray characteristic value is an average gray value of the region to be judged; The shape characteristic is the shape matching degree of the region to be judged and the marking frame, which is obtained through the edge contour matching degree.
- 4. A method according to claim 3, wherein the obtaining the attention weight value of each region to be determined according to the feature value of each region to be determined includes: Acquiring a characteristic response value according to the normalized gray scale characteristic value, the normalized density characteristic value and the normalized shape characteristic value; Acquiring the attention weight value according to the characteristic response value, the importance weight value, the recognition confidence coefficient, the noise interference coefficient and the weight coefficient; the importance weight value is associated with a region attribute, wherein the region attribute comprises a region which is a marking frame, a region which is a filling region and a region which is an interference region.
- 5. The method of claim 4, wherein the obtaining the attention weight value is preceded by the step of obtaining the attention weight value based on the feature response value, an importance weight value, an identification confidence level, a noise interference coefficient, and a weight coefficient: if the area attribute of the current area to be judged is that the area is a filling area, acquiring a first target question to which the current area to be judged belongs; judging whether an effective filling area exists under the first target question; and if the effective filling area exists under the first target title, adjusting the identification confidence of the current area according to the similarity between the current area to be judged and the effective filling area under the first target title.
- 6. The method according to claim 4, wherein the obtaining the type of each region to be determined according to the attention weight value of each region to be determined includes: Judging a region level according to the attention weight value, wherein the region level comprises a high attention region, a medium attention region and a low attention region; Taking the high-attention area as an effective filling area, and taking the low-attention area as an ineffective filling area or an interference area; in the middle-attention area, then: Acquiring a second target subject to which the middle attention area belongs, Judging whether an effective filling area exists under the second target question, If the effective filling area exists under the second target title, acquiring the filling confidence of the current area to be judged according to the corresponding minimum characteristic response value in the effective filling area under the second target title as a reference, Judging the current area to be judged as an effective filling area or an abnormal filling area according to the filling confidence, And judging the abnormal filling area as stain pollution, filling position deviation or erasing residue according to the noise interference coefficient and the shape characteristic value.
- 7. The method of claim 1, wherein the original image comprises a sensitive image and a non-sensitive image, the method further comprising: encrypting and storing the sensitive image at the edge; and synchronizing the non-sensitive images to cloud collaborative storage after locally storing the non-sensitive images at the edges.
- 8. An optical marker identification device, the device comprising: The acquisition unit is used for acquiring an original image; The positioning unit is used for positioning the area to be judged from the original image; the characteristic value acquisition unit is used for acquiring the characteristic value of each region to be judged; The attention unit is used for acquiring an attention weight value of each region to be judged according to the characteristic value of each region to be judged; the judging unit is used for acquiring the type of each region to be judged according to the attention weight value of each region to be judged; The types include effective fill, ineffective fill and abnormal fill, wherein the abnormal fill includes stain contamination, fill position offset and erase residue.
- 9. A computer device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, characterized in that the processor implements the method of any of claims 1 to 7 when executing the computer program.
- 10. A computer readable storage medium, on which a computer program is stored, characterized in that the computer program, when being executed by a processor, implements the method of any of claims 1 to 7.
Description
Optical mark recognition method, optical mark recognition device, computer equipment and storage medium Technical Field The present invention relates to the field of image recognition, and in particular, to an optical mark recognition method, an optical mark recognition device, a computer device, and a storage medium. Background Optical mark (OMR, optical MARK READER) identification is a method for identifying a mark in a specific format through Optical scanning and converting the mark into an electric signal, and is mainly applied to the fields of education examination, dry part evaluation, questionnaire and the like. The optical mark recognition method is generally used for marking the paper of the answer sheet. In the prior art, OMR recognition technology is mainly divided into two types, namely one type is based on a traditional cursor reader system, relies on fixed template matching and simple feature extraction, adopts a binary judgment rule of 'non-black and white' through calculating the density and gray level of recognition items, and the other type is based on an image, and is optimized in a preprocessing link, but core judgment logic still does not deviate from single-dimension feature dependence. The method has the advantage that in the practical application scene of irregular filling and complex environment interference, the existing OMR recognition rate is low. It can be seen that the optical mark recognition method in the prior art is difficult to meet the accuracy requirement. Disclosure of Invention In order to solve the technical problems described above or at least partially solve the technical problems described above, the present invention provides an optical mark recognition method, an optical mark recognition device, a computer device, and a storage medium. In a first aspect, the present invention provides a method of optical marker identification, the method comprising: Acquiring an original image; Positioning a region to be judged from the original image; acquiring a characteristic value of each region to be judged; acquiring the attention weight value of each region to be judged according to the characteristic value of each region to be judged; acquiring the type of each region to be judged according to the attention weight value of each region to be judged; The types include effective fill, ineffective fill and abnormal fill, wherein the abnormal fill includes stain contamination, fill position offset and erase residue. Optionally, the positioning the area to be determined from the original image includes: Acquiring a positioning point in the original image; Calibrating the coordinates of the original image according to the positioning points; acquiring a marking frame, a filling area and an interference area through neighborhood pixel connectivity; Acquiring coordinate information of each marking frame, each filling area and each interference area; and carrying out coordinate adjustment according to the barycenter coordinates of the connected domain, and taking the mark frame after coordinate adjustment, the filling area after coordinate adjustment and the interference area after coordinate adjustment as the area to be judged. Optionally, the obtaining the feature value of each to-be-judged area includes: acquiring gray characteristic values, density characteristic values and shape characteristic values of the region to be judged; Normalizing the gray scale feature value, the density feature value and the shape feature value to obtain a normalized gray scale feature value, a normalized density feature value and a normalized shape feature value of the region to be judged; The density characteristic value is the proportion of the area to be judged occupied by the filling pixel; The gray characteristic value is an average gray value of the region to be judged; The shape characteristic is the shape matching degree of the region to be judged and the marking frame, which is obtained through the edge contour matching degree. Optionally, the obtaining the attention weight value of each to-be-judged area according to the feature value of each to-be-judged area includes: Acquiring a characteristic response value according to the normalized gray scale characteristic value, the normalized density characteristic value and the normalized shape characteristic value; Acquiring the attention weight value according to the characteristic response value, the importance weight value, the recognition confidence coefficient, the noise interference coefficient and the weight coefficient; the importance weight value is associated with a region attribute, wherein the region attribute comprises a region which is a marking frame, a region which is a filling region and a region which is an interference region. Optionally, before the attention weight value is obtained according to the feature response value, the importance weight value, the recognition confidence level, the noise interference coefficient and