Automatic student status authentication method, device, computer equipment and storage medium
By preprocessing and classifying the identification pictures of the automatic student status certification method, extracting text and verification code information, and automatically logging into the target website for student status verification, the problem of inefficient traditional student status certification is solved and efficient and accurate student status certification is achieved.
Patent Information
- Application Number
- CN202210029895.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2022-01-12
- Publication Date
- 2025-04-11
- Estimated Expiration
- 2042-01-12
AI Technical Summary
Traditional student status certification is inefficient, especially when a large number of users are certified, it is easy to cause website crashes and cannot efficiently process large amounts of student status information.
The automatic student status certification method is adopted, and the image to be identified is obtained for preprocessing, text information and verification code pictures are extracted, and the trained verification code classification model is used for classification recognition, matching the corresponding verification code extraction model to extract verification code information, and automatically log in to the target website for student status verification.
It realizes end-to-end intelligent certification of student status, improves authentication efficiency and accuracy, and reduces the duration of large-scale certification.
Smart Images

Figure CN114386013B_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the field of artificial intelligence technology, and in particular to a method, device, computer equipment and storage medium for automatic student status authentication. Background Art
[0002] At present, with the rapid development of information technology, the amount of information that needs to be processed is also increasing. Especially when verifying a large number of student status and academic qualifications, it is often necessary to process a large amount of data at the same time. Traditional student status authentication requires manual input of user identity information, logging into the target website, and authenticating the user's student status through the target website. However, when it is necessary to verify the student status of a large number of users at the same time, the processing will be too slow or even the website will crash. Summary of the invention
[0003] The purpose of the embodiments of the present application is to propose a method, device, computer equipment and storage medium for automatic student status authentication to solve the technical problem of low efficiency of student status authentication.
[0004] In order to solve the above technical problems, the present application embodiment provides an automatic student status authentication, which adopts the following technical solution:
[0005] Obtaining a picture to be identified, and preprocessing the picture to be identified to obtain a preprocessed picture;
[0006] Extracting text information and verification code images from the preprocessed images, and obtaining a trained verification code classification model, classifying and identifying the verification code images in the preprocessed images according to the verification code classification model, and obtaining verification code categories of the verification code images;
[0007] Matching a corresponding verification code extraction model according to the verification code category, and extracting verification code information in the verification code image according to the verification code extraction model;
[0008] The network address of the target website is obtained, the target website is jumped to according to the network address, the target website is logged in based on the verification code information and the text information, and the student status information in the text information is automatically verified according to the target website.
[0009] Furthermore, the step of preprocessing the image to be identified to obtain a preprocessed image includes:
[0010] Acquire a preset table line recognition model, and recognize table line information in the to-be-recognized picture based on the table line recognition model;
[0011] The table line information is filtered out from the image to be identified to obtain the preprocessed image.
[0012] Furthermore, the step of identifying the table line information in the to-be-identified picture based on the table line recognition model includes:
[0013] Detecting candidate areas of table lines in the to-be-recognized picture based on the table line recognition model to obtain a preferred candidate frame;
[0014] Inputting the preferred candidate box into the residual network in the table line recognition model for feature calculation, obtaining feature values of each convolutional layer in the residual network, and constructing a feature pyramid based on the feature values;
[0015] Regression detection is performed through the feature pyramid and the preferred candidate box to obtain table line information in the image to be identified.
[0016] Furthermore, after the step of performing regression detection through the feature pyramid and the preferred candidate box to obtain the table line information in the image to be identified, the method further includes:
[0017] A preset edge line detection algorithm is obtained, and the table line information is fitted according to the edge line detection algorithm to obtain the target table line information of the image to be identified.
[0018] Furthermore, the step of extracting text information from the preprocessed image includes:
[0019] Performing image text recognition on the preprocessed image to obtain rough text;
[0020] A stored text dictionary is obtained, and the rough text is corrected and structured based on the text dictionary to obtain the text information.
[0021] Furthermore, before the step of classifying and identifying the verification code picture in the pre-processed picture according to the verification code classification model, the step further includes:
[0022] Obtaining a timestamp of the verification code image, determining whether the verification code image is valid according to the timestamp, and determining that the verification code image is a valid image if the timestamp is within a preset validity period range;
[0023] If the timestamp is not within the preset validity period, it is determined that the verification code image is an invalid image.
[0024] Furthermore, before the step of obtaining the trained verification code classification model, the method further includes:
[0025] Collect multiple groups of website verification code images, classify the website verification code images, and obtain classification labels;
[0026] A preset basic verification classification model is trained according to the classification label and the website verification code image. When the training of the basic verification classification model is completed, the trained basic verification classification model is determined to be the verification code classification model.
[0027] In order to solve the above technical problems, the present application embodiment also provides a student status automatic authentication device, which adopts the following technical solution:
[0028] A preprocessing module is used to obtain a picture to be identified, and preprocess the picture to be identified to obtain a preprocessed picture;
[0029] A classification module, used to extract text information and verification code images from the pre-processed images, and obtain a trained verification code classification model, and classify and identify the verification code images in the pre-processed images according to the verification code classification model to obtain the verification code category of the verification code images;
[0030] A matching module, used to match the corresponding verification code extraction model according to the verification code category, and extract the verification code information in the verification code image according to the verification code extraction model;
[0031] The verification module is used to obtain the network address of the target website, jump to the target website according to the network address, log in to the target website based on the verification code information and the text information, and automatically verify the student information in the text information according to the target website.
[0032] In order to solve the above technical problems, the embodiment of the present application further provides a computer device, which adopts the following technical solution:
[0033] Obtaining a picture to be identified, and preprocessing the picture to be identified to obtain a preprocessed picture;
[0034] Extracting text information and verification code images from the preprocessed images, and obtaining a trained verification code classification model, classifying and identifying the verification code images in the preprocessed images according to the verification code classification model, and obtaining verification code categories of the verification code images;
[0035] Matching a corresponding verification code extraction model according to the verification code category, and extracting verification code information in the verification code image according to the verification code extraction model;
[0036] The network address of the target website is obtained, the target website is jumped to according to the network address, the target website is logged in based on the verification code information and the text information, and the student status information in the text information is automatically verified according to the target website.
[0037] In order to solve the above technical problems, the embodiment of the present application further provides a computer-readable storage medium, which adopts the following technical solution:
[0038] Obtaining a picture to be identified, and preprocessing the picture to be identified to obtain a preprocessed picture;
[0039] Extracting text information and verification code images from the preprocessed images, and obtaining a trained verification code classification model, classifying and identifying the verification code images in the preprocessed images according to the verification code classification model, and obtaining verification code categories of the verification code images;
[0040] Matching a corresponding verification code extraction model according to the verification code category, and extracting verification code information in the verification code image according to the verification code extraction model;
[0041] The network address of the target website is obtained, the target website is jumped to according to the network address, the target website is logged in based on the verification code information and the text information, and the student status information in the text information is automatically verified according to the target website.
[0042] The automatic student status authentication method proposed in the present application obtains a picture to be identified, pre-processes the picture to be identified, and obtains a pre-processed picture. The accuracy of picture verification and classification can be improved by pre-processing the picture; then, the text information and verification code picture in the pre-processed picture are extracted, and a trained verification code classification model is obtained. The verification code picture in the pre-processed picture is classified and identified according to the verification code classification model to obtain the verification code category of the verification code picture; the corresponding verification code extraction model is matched according to the verification code category, and the verification code information in the verification code picture is extracted according to the verification code extraction model, thereby improving the accuracy of verification code information extraction and avoiding subsequent student status login errors; then, the network address of the target website is obtained, and the target website is jumped to according to the network address, and the target website is logged in based on the verification code information and text information, and the student status information in the text information is automatically verified according to the target website, thereby realizing end-to-end intelligent authentication of student status, improving the efficiency and accuracy of student status authentication, and reducing the authentication time when authenticating a large number of student status. BRIEF DESCRIPTION OF THE DRAWINGS
[0043] In order to more clearly illustrate the scheme in the present application, a brief introduction is given below to the drawings required for use in the description of the embodiments of the present application. Obviously, the drawings described below are some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative work.
[0044] Figure 1 is an exemplary system architecture diagram to which the present application may be applied;
[0045] Figure 2 A flow chart of an embodiment of a method for automatic student status authentication according to the present application;
[0046] Figure 3 It is a structural schematic diagram of an embodiment of the automatic student status authentication device according to the present application;
[0047] Figure 4 It is a structural diagram of an embodiment of a computer device according to the present application.
[0048] Reference numerals: automatic student status authentication device 300 , preprocessing module 301 , classification module 302 , matching module 303 , and verification module 304 . DETAILED DESCRIPTION
[0049] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as those commonly understood by technicians in the technical field of the present application; the terms used in the specification of the application herein are only for the purpose of describing specific embodiments and are not intended to limit the present application; the terms "including" and "having" and any variations thereof in the specification and claims of the present application and the above-mentioned drawings are intended to cover non-exclusive inclusions. The terms "first", "second", etc. in the specification and claims of the present application or the above-mentioned drawings are used to distinguish different objects, not to describe a specific order.
[0050] Reference to "embodiments" herein means that a particular feature, structure, or characteristic described in conjunction with the embodiments may be included in at least one embodiment of the present application. The appearance of the phrase in various locations in the specification does not necessarily refer to the same embodiment, nor is it an independent or alternative embodiment that is mutually exclusive with other embodiments. It is explicitly and implicitly understood by those skilled in the art that the embodiments described herein may be combined with other embodiments.
[0051] In order to enable those skilled in the art to better understand the solution of the present application, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the accompanying drawings.
[0052] like Figure 1 As shown, the system architecture 100 may include terminal devices 101, 102, 103, a network 104 and a server 105. The network 104 is used to provide a medium for communication links between the terminal devices 101, 102, 103 and the server 105. The network 104 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0053] Users can use terminal devices 101, 102, 103 to interact with server 105 through network 104 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 101, 102, 103, such as web browser applications, shopping applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0054] Terminal devices 101, 102, 103 can be various electronic devices with display screens and supporting web browsing, including but not limited to smart phones, tablet computers, e-book readers, MP3 players (Moving Picture Experts Group Audio Layer III), MP4 (Moving Picture Experts Group Audio Layer IV) players, laptop computers, desktop computers, etc.
[0055] The server 105 may be a server that provides various services, such as a background server that provides support for web pages displayed on the terminal devices 101 , 102 , and 103 .
[0056] It should be noted that the automatic student status authentication method provided in the embodiment of the present application is generally executed by a server / terminal device, and accordingly, the automatic student status authentication device is generally set in the server / terminal device.
[0057] It should be understood that Figure 1 The number of terminal devices, networks and servers in the embodiment is only for illustration. Any number of terminal devices, networks and servers may be provided according to implementation requirements.
[0058] Continue to refer Figure 2 , shows a flow chart of an embodiment of a method for automatic student status authentication according to the present application. The method for automatic student status authentication comprises the following steps:
[0059] Step S201, obtaining a picture to be identified, and preprocessing the picture to be identified to obtain a preprocessed picture.
[0060] In this embodiment, the image to be processed is a record form image including the user's account information, student information, academic information and verification code image information. When the image to be identified is received, the image to be processed is preprocessed to obtain a preprocessed image. The preprocessing includes table line removal and upsampling of the image to be identified.
[0061] Step S202, extracting text information and verification code images from the preprocessed images, obtaining a trained verification code classification model, classifying and identifying the verification code images in the preprocessed images according to the verification code classification model, and obtaining the verification code category of the verification code images.
[0062] In this embodiment, when the pre-processed image is obtained, OCR (optical character recognition) is performed on the pre-processed image to obtain text information and verification code images in the pre-processed image. Among them, the text information includes account information, student information and academic information of multiple users, and the verification code image includes verification code information of the target website (such as China Higher Education Student Information and Career Center). A trained verification code classification model is obtained, and the verification code image is classified and identified according to the verification code classification model to obtain the verification code category corresponding to the verification code image, and the verification code category includes different categories such as letters and text. Among them, the verification code classification model can use a target detection convolutional neural network (such as RCNN, region with CNN feature), and the verification code image in the pre-processed image is detected by the target detection convolutional neural network, so as to identify the category to which the verification code image belongs.
[0063] Step S203: matching a corresponding verification code extraction model according to the verification code category, and extracting verification code information in the verification code image according to the verification code extraction model.
[0064] In this embodiment, the verification code extraction model is a pre-trained extraction model, and the verification code information in the verification code picture can be automatically extracted according to the verification code extraction model. Among them, due to the different complexity of verification code information of different categories, if the verification code information of different categories is extracted by the same verification code extraction model, the extracted verification code information will be inaccurate. Therefore, different verification code categories are associated with different verification code extraction models in advance. When the verification code category of the current verification code picture is obtained, the corresponding verification code extraction model is matched according to the verification code category, and different verification code categories correspond to different verification code extraction models. Based on the verification code extraction model, the verification code information in the verification code picture is extracted. Specifically, the verification code extraction model can adopt a deep learning model of CTPN+CRNN (scene text detection+convolutional recurrent neural network), collect multiple groups of verification codes of different categories as recognition training pictures, and train the general CTPN+CRNN deep learning model according to the recognition training pictures of different categories to obtain the verification code extraction model corresponding to each verification code category. Therefore, the accuracy of verification code recognition can be improved by extracting verification code models of corresponding categories.
[0065] It should be emphasized that in order to further ensure the privacy and security of the above verification code information, the above verification code information can also be stored in a node of a blockchain.
[0066] The blockchain referred to in this application is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.
[0067] Step S204, obtaining the network address of the target website, jumping to the target website according to the network address, logging into the target website based on the verification code information and the text information, and automatically verifying the student status information in the text information according to the target website.
[0068] In this embodiment, when the verification code information in the verification code image is obtained, the network address of the target website is obtained, and the target website is automatically jumped to according to the network address; the verification code information and the account information in the text information are input into the login interface of the target website, and the automatic login to the target website is realized. After logging in to the target website, the real student status information and real academic information of the target website can also be queried, and the student status information and academic information in the text information are verified according to the real student status information and real academic information to determine whether the student status and academic information of the current user have been verified; wherein, if the real student status information and real academic information are successfully matched with the student status information and academic information in the text information, it is determined that the student status and academic information of the current user have been verified; if any one of the real student status information and real academic information and the student status information and academic information in the text information fails to match, it is determined that the student status or academic information corresponding to the current user has failed to be verified.
[0069] This application realizes end-to-end intelligent authentication of student status, improves the efficiency and accuracy of student status authentication, and reduces the authentication time when authenticating a large number of student status.
[0070] In some optional implementations of this embodiment, the step of preprocessing the image to be identified to obtain a preprocessed image includes:
[0071] Acquire a preset table line recognition model, and recognize table line information in the to-be-recognized picture based on the table line recognition model;
[0072] The table line information is filtered out from the image to be identified to obtain the preprocessed image.
[0073] In this embodiment, when preprocessing the picture to be recognized, the table lines of the picture to be recognized can be removed. Specifically, a preset table line recognition model is obtained, and the table line information in the picture to be recognized is recognized according to the table line recognition model. Among them, the table line recognition model is a pre-trained residual network model (such as resnet100+residual network model), and the residual network model is composed of multiple convolutional layers cascaded by residual blocks. The residual network model can reduce the amount of calculation while improving the calculation accuracy of the model. When the picture to be recognized is obtained, the picture to be recognized is input into the table line recognition model, and the table line information in the picture to be recognized is obtained based on the table line recognition model; then, the table line information is screened out from the picture to be recognized, that is, the preprocessed picture corresponding to the picture to be recognized is obtained.
[0074] In this embodiment, after the table line information in the image to be recognized is processed by a preset table line recognition model, the table line information is removed from the image to be recognized to obtain a preprocessed image, thereby achieving efficient preprocessing of the image and further improving the accuracy of subsequent image processing.
[0075] In some optional implementations of this embodiment, the step of identifying the table line information in the to-be-identified picture based on the table line recognition model includes:
[0076] Detecting candidate areas of table lines in the to-be-recognized picture based on the table line recognition model to obtain a preferred candidate frame;
[0077] Inputting the preferred candidate box into the residual network in the table line recognition model for feature calculation, obtaining feature values of each convolutional layer in the residual network, and constructing a feature pyramid based on the feature values;
[0078] Regression detection is performed through the feature pyramid and the preferred candidate box to obtain table line information in the image to be identified.
[0079] In this embodiment, when the table line recognition model is obtained, the image to be recognized is input into the table line recognition model, and a candidate area of the table line in the image to be recognized is detected, and the candidate area includes a plurality of candidate boxes of different sizes and areas; then, a non-maximum suppression (NMS) calculation is performed on the candidate box through the normalization layer (i.e., softmax-nms layer) of the table line recognition model to obtain a score corresponding to each candidate box, such as<xi,yi,w,h,socre> . Afterwards, Gaussian weighting is performed on the score corresponding to each candidate box to obtain a weighted value, and each candidate box is sorted based on the weighted value, and the candidate boxes whose weighted values are less than the preset threshold are screened out as preferred candidate boxes. When the preferred candidate box is obtained, the preferred candidate box is input into the basic residual network (such as resnet50) of the table line recognition model, and the feature values of each convolutional network layer corresponding to the preferred candidate box are calculated according to the basic residual network, and then the feature values corresponding to each layer are feature fused to obtain a feature pyramid. The preferred candidate box and the feature pyramid are input into the box classification and regression detection network of the table line recognition model to calculate the regression detection result; finally, the regression detection result is pooled, such as by performing pooling calculation on the regression detection result through ROIAlign (regional feature aggregation) to obtain the table line information in the image to be recognized.
[0080] This embodiment detects the table line information in the image to be identified by using a table line recognition model, thereby achieving accurate detection of the table lines and improving the detection efficiency of the table lines.
[0081] In some optional implementations of this embodiment, after the step of performing regression detection through the feature pyramid and the preferred candidate box to obtain the table line information in the to-be-recognized picture, the method further includes:
[0082] A preset edge line detection algorithm is obtained, and the table line information is fitted according to the edge line detection algorithm to obtain the target table line information of the image to be identified.
[0083] In this embodiment, in order to obtain more accurate table line information, when the table line information in the picture to be identified is obtained by the target table line detection model, a preset edge line detection algorithm is obtained, and the table line information is fitted according to the edge line detection algorithm to obtain the target table line information. The target table line information is more accurate table line information. Specifically, the edge line detection algorithm is a hough algorithm. When the table line information in the picture to be identified is obtained, it is determined whether the picture to be identified is a grayscale image. If the picture to be identified is not a grayscale image, the picture to be identified is converted into a grayscale image; the grayscale image is denoised to obtain a denoised image; the denoised image is edge extracted by a gradient operator or a Laplace operator to obtain edge points; the edge points are mapped to the Hough space, the local maximum of the edge points is calculated, and the local maximum is filtered by a preset filtering threshold to obtain the target coordinates; a straight line is drawn according to the target coordinates, and the corner points are calibrated to obtain edge line information; then, the table line information is fitted according to the edge line information to obtain the target table line information.
[0084] This embodiment performs fitting of the table line information through an edge line detection algorithm, thereby optimizing the extraction of the table line information, and further making the target table line information obtained from the image to be identified more accurate.
[0085] In some optional implementations of this embodiment, the step of extracting text information from the preprocessed image includes:
[0086] Performing image text recognition on the preprocessed image to obtain rough text;
[0087] A stored text dictionary is obtained, and the rough text is corrected and structured based on the text dictionary to obtain the text information.
[0088] In this embodiment, the text dictionary is a dictionary that pre-stores various types of standard field information. When a pre-processed image is obtained, image text recognition, i.e., OCR recognition, is performed on the image to be processed to obtain the rough text in the image to be processed. The stored text dictionary is obtained, and the standard field information in the dictionary is matched with the rough text to obtain the matching field; the matching information corresponding to the matching field in the rough text is obtained, and the matching information is structured according to the matching field, that is, the text information corresponding to the pre-processed image is obtained. Furthermore, in order to make the text information more accurate, when the rough text is obtained, the rough text can be corrected first, and then the rough text after error correction can be structured to obtain the text information.
[0089] Specifically, a preset regular matching formula is obtained, wherein the regular matching formula includes a variety of different reference fields. The regular matching formula and the rough text are matched, and when the matching degree between the regular matching formula and the rough text is less than or equal to a preset threshold, it is determined that the regular matching formula and the rough text have failed to match. The text that failed to match is obtained, and the text that failed to match is the error correction text. The error correction text is searched according to a text dictionary to obtain the correct text corresponding to the error correction text; the error correction text in the rough text is replaced with the correct text to obtain the corrected rough text. Finally, the corrected rough text is structured according to the matching field to obtain more accurate text information.
[0090] This embodiment obtains text information by performing image text recognition and structuring on the pre-processed image, thereby achieving efficient and accurate extraction of text information in the pre-processed image.
[0091] In some optional implementations of this embodiment, before the step of classifying and identifying the verification code picture in the pre-processed picture according to the verification code classification model, the following steps are further included:
[0092] Obtaining a timestamp of the verification code image, determining whether the verification code image is valid according to the timestamp, and determining that the verification code image is a valid image if the timestamp is within a preset validity period range;
[0093] If the timestamp is not within the preset validity period, it is determined that the verification code image is an invalid image.
[0094] In this embodiment, before classifying and identifying the verification code picture in the preprocessed picture according to the verification code classification model, the timestamp of the verification code picture is obtained, and the timestamp is the time information corresponding to each verification code picture. A preset validity period range is obtained, and if the timestamp is within the preset validity period range, the verification code picture is determined to be a valid picture; if the timestamp is not within the preset validity period range, the verification code picture is determined to be an invalid picture. When the verification code picture is a valid picture, the verification code picture in the preprocessed picture is classified and identified according to the verification code classification model; when the verification code picture is an invalid picture, the invalid information of the verification code picture is fed back.
[0095] This embodiment obtains the timestamp of the verification code image and determines whether the verification code image is a valid image according to the timestamp, thereby saving image processing time and avoiding invalid login to the student status due to invalid verification of the verification code image.
[0096] In some optional implementations of this embodiment, before the step of obtaining the trained verification code classification model, the following steps are also included:
[0097] Collect multiple groups of website verification code images, classify the website verification code images, and obtain classification labels;
[0098] A preset basic verification classification model is trained according to the classification label and the website verification code image. When the training of the basic verification classification model is completed, the trained basic verification classification model is determined to be the verification code classification model.
[0099] In this embodiment, multiple groups of website verification code images are collected, and the website verification code images are classified to obtain classification labels corresponding to each website verification code image, such as verification code labels of different categories such as text verification code and letter verification code. The classification label and the website verification code image are input into the basic verification classification model, and the basic verification classification model is trained. When the basic verification classification model training is completed, the basic verification classification model is determined to be a trained verification code classification model. Specifically, the collected website verification code image is used as a positive sample of the basic verification model, and another group of images that do not include the verification code are collected, and the images that do not include the verification code are used as negative samples. The negative samples and positive samples constitute the training images. The training images are input into the basic verification classification model, and the input training images are detected according to the Faster-RCNN backbone network of the basic verification classification model to form candidate areas of the verification code. After that, the candidate areas are scored to obtain a scoring result, and the scoring result is Gaussian weighted to obtain the final weighted value. The weighted value is screened according to a preset threshold, and the candidate areas whose weighted values are greater than or equal to the preset threshold are selected as the preferred boxes. When the preferred box is obtained, the preferred box is input into the basic residual network (such as resnet50), and the feature values of each convolutional network layer in the basic residual network are calculated according to the preferred box, and then the feature values corresponding to each layer are fused to obtain a feature pyramid. The preferred box and the feature pyramid are input into the box classification and regression detection network, and the regression detection result is calculated, and the regression detection result is pooled to obtain the verification classification result.
[0100] When the verification classification result is obtained, the classification label corresponding to the training image is obtained, and the loss function is calculated based on the verification classification result and the classification label; the network parameters of the basic verification classification model are adjusted by the loss function until the loss function calculated by the network parameters of the adjusted basic verification classification model converges, and the adjusted basic verification classification model is determined to be the trained verification code classification model.
[0101] This embodiment obtains a verification code classification model by training a basic verification classification model, so that verification code images can be efficiently classified through the verification code classification model, further improving the efficiency and accuracy of student status authentication.
[0102] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiments can be implemented by instructing the relevant hardware through computer-readable instructions, and the computer-readable instructions can be stored in a computer-readable storage medium. When the program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, the aforementioned storage medium can be a non-volatile storage medium such as a disk, an optical disk, a read-only memory (ROM), or a random access memory (RAM).
[0103] It should be understood that, although the steps in the flowchart of the accompanying drawings are displayed in sequence as indicated by the arrows, these steps are not necessarily executed in sequence in the order indicated by the arrows. Unless otherwise specified herein, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Moreover, at least a part of the steps in the flowchart of the accompanying drawings may include multiple sub-steps or multiple stages, and these sub-steps or stages are not necessarily executed at the same time, but can be executed at different times, and their execution order is not necessarily sequential, but can be executed in turn or alternately with other steps or at least a part of the sub-steps or stages of other steps.
[0104] Further references Figure 3 , as a response to the above Figure 2 The present application provides an embodiment of a student status automatic authentication device, and the device embodiment is similar to Figure 2 Corresponding to the method embodiment shown, the device can be specifically applied to various electronic devices.
[0105] like Figure 3 As shown, the automatic student status authentication device 300 described in this embodiment includes: a pre-processing module 301, a classification module 302, a matching module 303 and a verification module 304. Among them:
[0106] The preprocessing module 301 is used to obtain a picture to be identified, and preprocess the picture to be identified to obtain a preprocessed picture;
[0107] In some optional implementations of this embodiment, the preprocessing module 301 includes:
[0108] A first recognition unit, configured to obtain a preset table line recognition model, and recognize table line information in the to-be-recognized picture based on the table line recognition model;
[0109] A screening unit is used to screen out the table line information from the image to be identified to obtain the pre-processed image.
[0110] In this embodiment, the image to be processed is a record form image including the user's account information, student information, academic information and verification code image information. When the image to be identified is received, the image to be processed is preprocessed to obtain a preprocessed image. The preprocessing includes table line removal and upsampling of the image to be identified.
[0111] The classification module 302 is used to extract the text information and the verification code image in the pre-processed image, obtain a trained verification code classification model, classify and identify the verification code image in the pre-processed image according to the verification code classification model, and obtain the verification code category of the verification code image;
[0112] In some optional implementations of this embodiment, the classification module 302 includes:
[0113] A first detection unit, configured to detect a candidate area of a table line in the to-be-recognized picture based on the table line recognition model to obtain a preferred candidate frame;
[0114] A calculation unit, used for inputting the preferred candidate box into the residual network in the table line recognition model for feature calculation, obtaining feature values of each convolution layer in the residual network, and constructing a feature pyramid based on the feature values;
[0115] The second detection unit is used to perform regression detection through the feature pyramid and the preferred candidate box to obtain the table line information in the image to be identified.
[0116] In some optional implementations of this embodiment, the second detection unit further includes:
[0117] The fitting unit is used to obtain a preset edge line detection algorithm, and fit the table line information according to the edge line detection algorithm to obtain the target table line information of the image to be identified.
[0118] In some optional implementations of this embodiment, the classification module 302 further includes:
[0119] A second recognition unit is used to perform image text recognition on the pre-processed image to obtain rough text;
[0120] The error correction unit is used to obtain a stored text dictionary, and perform error correction and structuring on the rough text based on the text dictionary to obtain the text information.
[0121] In this embodiment, when the pre-processed image is obtained, OCR (optical character recognition) is performed on the pre-processed image to obtain text information and verification code images in the pre-processed image. Among them, the text information includes account information, student information and academic information of multiple users, and the verification code image includes verification code information of the target website (such as China Higher Education Student Information and Career Center). A trained verification code classification model is obtained, and the verification code image is classified and identified according to the verification code classification model to obtain the verification code category corresponding to the verification code image, and the verification code category includes different categories such as letters and text. Among them, the verification code classification model can use a target detection convolutional neural network (such as RCNN, region with CNN feature), and the verification code image in the pre-processed image is detected by the target detection convolutional neural network, so as to identify the category to which the verification code image belongs.
[0122] A matching module 303 is used to match the corresponding verification code extraction model according to the verification code category, and extract the verification code information in the verification code image according to the verification code extraction model;
[0123] In this embodiment, the verification code extraction model is a pre-trained extraction model, and the verification code information in the verification code picture can be automatically extracted according to the verification code extraction model. Among them, due to the different complexity of verification code information of different categories, if the verification code information of different categories is extracted by the same verification code extraction model, the extracted verification code information will be inaccurate. Therefore, different verification code categories are associated with different verification code extraction models in advance. When the verification code category of the current verification code picture is obtained, the corresponding verification code extraction model is matched according to the verification code category, and different verification code categories correspond to different verification code extraction models. Based on the verification code extraction model, the verification code information in the verification code picture is extracted. Specifically, the verification code extraction model can adopt a deep learning model of CTPN+CRNN (scene text detection+convolutional recurrent neural network), collect multiple groups of verification codes of different categories as recognition training pictures, and train the general CTPN+CRNN deep learning model according to the recognition training pictures of different categories to obtain the verification code extraction model corresponding to each verification code category. Therefore, the accuracy of verification code recognition can be improved by extracting verification code models of corresponding categories.
[0124] It should be emphasized that in order to further ensure the privacy and security of the above verification code information, the above verification code information can also be stored in a node of a blockchain.
[0125] The blockchain referred to in this application is a new application model of computer technologies such as distributed data storage, peer-to-peer transmission, consensus mechanism, encryption algorithm, etc. Blockchain is essentially a decentralized database, a string of data blocks generated by cryptographic methods. Each data block contains a batch of network transaction information, which is used to verify the validity of its information (anti-counterfeiting) and generate the next block. Blockchain can include the underlying blockchain platform, platform product service layer, and application service layer.
[0126] The verification module 304 is used to obtain the network address of the target website, jump to the target website according to the network address, log in to the target website based on the verification code information and the text information, and automatically verify the student information in the text information according to the target website.
[0127] In this embodiment, when the verification code information in the verification code image is obtained, the network address of the target website is obtained, and the target website is automatically jumped to according to the network address; the verification code information and the account information in the text information are input into the login interface of the target website, and the automatic login to the target website is realized. After logging in to the target website, the real student status information and real academic information of the target website can also be queried, and the student status information and academic information in the text information are verified according to the real student status information and real academic information to determine whether the student status and academic information of the current user have been verified; wherein, if the real student status information and real academic information are successfully matched with the student status information and academic information in the text information, it is determined that the student status and academic information of the current user have been verified; if any one of the real student status information and real academic information and the student status information and academic information in the text information fails to match, it is determined that the student status or academic information corresponding to the current user has failed to be verified.
[0128] In some optional implementations of this embodiment, the above-mentioned student status automatic authentication device 300 further includes:
[0129] An acquisition module, used for acquiring a timestamp of the verification code image, determining whether the verification code image is valid according to the timestamp, and determining that the verification code image is a valid image if the timestamp is within a preset validity period range;
[0130] The confirmation module is used to determine that the verification code image is an invalid image if the timestamp is not within the preset validity period.
[0131] In this embodiment, before classifying and identifying the verification code picture in the preprocessed picture according to the verification code classification model, the timestamp of the verification code picture is obtained, and the timestamp is the time information corresponding to each verification code picture. A preset validity period range is obtained, and if the timestamp is within the preset validity period range, the verification code picture is determined to be a valid picture; if the timestamp is not within the preset validity period range, the verification code picture is determined to be an invalid picture. When the verification code picture is a valid picture, the verification code picture in the preprocessed picture is classified and identified according to the verification code classification model; when the verification code picture is an invalid picture, the invalid information of the verification code picture is fed back.
[0132] In some optional implementations of this embodiment, the above-mentioned student status automatic authentication device 300 further includes:
[0133] A collection module, used for collecting multiple groups of website verification code images, classifying the website verification code images, and obtaining classification labels;
[0134] The training module is used to train a preset basic verification classification model according to the classification label and the website verification code image, and when the training of the basic verification classification model is completed, determine that the trained basic verification classification model is the verification code classification model.
[0135] In this embodiment, multiple groups of website verification code images are collected, and the website verification code images are classified to obtain classification labels corresponding to each website verification code image, such as verification code labels of different categories such as text verification code and letter verification code. The classification label and the website verification code image are input into the basic verification classification model, and the basic verification classification model is trained. When the basic verification classification model training is completed, the basic verification classification model is determined to be a trained verification code classification model. Specifically, the collected website verification code image is used as a positive sample of the basic verification model, and another group of images that do not include the verification code are collected, and the images that do not include the verification code are used as negative samples. The negative samples and positive samples constitute the training images. The training images are input into the basic verification classification model, and the input training images are detected according to the Faster-RCNN backbone network of the basic verification classification model to form candidate areas of the verification code. After that, the candidate areas are scored to obtain a scoring result, and the scoring result is Gaussian weighted to obtain the final weighted value. The weighted value is screened according to a preset threshold, and the candidate areas whose weighted values are greater than or equal to the preset threshold are selected as the preferred boxes. When the preferred box is obtained, the preferred box is input into the basic residual network (such as resnet50), and the feature values of each convolutional network layer in the basic residual network are calculated according to the preferred box, and then the feature values corresponding to each layer are fused to obtain a feature pyramid. The preferred box and the feature pyramid are input into the box classification and regression detection network, and the regression detection result is calculated, and the regression detection result is pooled to obtain the verification classification result.
[0136] When the verification classification result is obtained, the classification label corresponding to the training image is obtained, and the loss function is calculated based on the verification classification result and the classification label; the network parameters of the basic verification classification model are adjusted by the loss function until the loss function calculated by the network parameters of the adjusted basic verification classification model converges, and the adjusted basic verification classification model is determined to be the trained verification code classification model.
[0137] The automatic student status authentication device proposed in this embodiment realizes end-to-end intelligent authentication of student status, improves the efficiency and accuracy of student status authentication, and reduces the authentication time when authenticating a large number of student status.
[0138] To solve the above technical problems, the present application also provides a computer device. Figure 4 , Figure 4 This is a basic structural block diagram of the computer device in this embodiment.
[0139] The computer device 6 includes a memory 61, a processor 62, and a network interface 63 that are interconnected through a system bus. It should be noted that the figure only shows a computer device 6 with components 61-63, but it should be understood that it is not required to implement all the components shown, and more or fewer components can be implemented instead. Among them, those skilled in the art can understand that the computer device here is a device that can automatically perform numerical calculations and / or information processing according to pre-set or stored instructions, and its hardware includes but is not limited to microprocessors, application specific integrated circuits (Application Specific Integrated Circuit, ASIC), programmable gate arrays (Field-Programmable Gate Array, FPGA), digital processors (Digital Signal Processor, DSP), embedded devices, etc.
[0140] The computer device may be a computing device such as a desktop computer, a notebook, a PDA, a cloud server, etc. The computer device may interact with a user through a keyboard, a mouse, a remote controller, a touch pad, or a voice control device.
[0141] The memory 61 includes at least one type of readable storage medium, and the readable storage medium includes flash memory, hard disk, multimedia card, card-type memory (for example, SD or DX memory, etc.), random access memory (RAM), static random access memory (SRAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), programmable read-only memory (PROM), magnetic memory, disk, optical disk, etc. In some embodiments, the memory 61 can be an internal storage unit of the computer device 6, such as a hard disk or memory of the computer device 6. In other embodiments, the memory 61 can also be an external storage device of the computer device 6, such as a plug-in hard disk equipped on the computer device 6, a smart memory card (Smart Media Card, SMC), a secure digital (Secure Digital, SD) card, a flash card (FlashCard), etc. Of course, the memory 61 can also include both the internal storage unit of the computer device 6 and its external storage device. In this embodiment, the memory 61 is generally used to store the operating system and various application software installed on the computer device 6, such as computer-readable instructions of the student status automatic authentication method, etc. In addition, the memory 61 can also be used to temporarily store various types of data that have been output or are to be output.
[0142] The processor 62 may be a central processing unit (CPU), a controller, a microcontroller, a microprocessor, or other data processing chips in some embodiments. The processor 62 is generally used to control the overall operation of the computer device 6. In this embodiment, the processor 62 is used to run computer-readable instructions stored in the memory 61 or process data, such as computer-readable instructions for running the automatic student status authentication method.
[0143] The network interface 63 may include a wireless network interface or a wired network interface. The network interface 63 is generally used to establish a communication connection between the computer device 6 and other electronic devices.
[0144] The computer device proposed in this embodiment realizes end-to-end intelligent authentication of student status, improves the efficiency and accuracy of student status authentication, and reduces the authentication time when authenticating a large number of student status.
[0145] The present application also provides another implementation, namely, providing a computer-readable storage medium, which stores computer-readable instructions, and the computer-readable instructions can be executed by at least one processor to enable the at least one processor to perform the steps of the automatic student status authentication method as described above.
[0146] The computer-readable storage medium proposed in this embodiment realizes end-to-end intelligent authentication of student status, improves the efficiency and accuracy of student status authentication, and reduces the authentication time when authenticating a large number of student status.
[0147] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present application, or the part that contributes to the prior art, can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk), and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present application.
[0148] Obviously, the embodiments described above are only some embodiments of the present application, rather than all embodiments. The preferred embodiments of the present application are given in the accompanying drawings, but they do not limit the patent scope of the present application. The present application can be implemented in many different forms. On the contrary, the purpose of providing these embodiments is to make the understanding of the disclosure of the present application more thorough and comprehensive. Although the present application is described in detail with reference to the aforementioned embodiments, for those skilled in the art, it is still possible to modify the technical solutions recorded in the aforementioned specific implementation methods, or to perform equivalent replacement of some of the technical features therein. Any equivalent structure made using the contents of the specification and drawings of this application, directly or indirectly used in other related technical fields, is similarly within the scope of patent protection of this application.
Claims
1. A method for automatic student status authentication, characterized in that: The steps include: Obtaining a picture to be identified, and preprocessing the picture to be identified to obtain a preprocessed picture; Extracting text information and verification code images from the preprocessed images, and obtaining a trained verification code classification model, classifying and identifying the verification code images in the preprocessed images according to the verification code classification model, and obtaining verification code categories of the verification code images; Matching a corresponding verification code extraction model according to the verification code category, and extracting verification code information in the verification code image according to the verification code extraction model; Obtaining a network address of a target website, jumping to the target website according to the network address, logging into the target website based on the verification code information and the text information, and automatically verifying the student status information in the text information according to the target website; The step of preprocessing the image to be identified to obtain a preprocessed image includes: Acquire a preset table line recognition model, and recognize table line information in the to-be-recognized picture based on the table line recognition model; Screening out the table line information from the to-be-recognized picture to obtain the preprocessed picture; The step of identifying the table line information in the to-be-identified picture based on the table line recognition model includes: Detecting a candidate area of table lines in the to-be-recognized picture based on the table line recognition model to obtain a preferred candidate frame; Inputting the preferred candidate box into the residual network in the table line recognition model for feature calculation, obtaining feature values of each convolutional layer in the residual network, and constructing a feature pyramid based on the feature values; Regression detection is performed through the feature pyramid and the preferred candidate box to obtain table line information in the image to be identified.
2. The method for automatic student status authentication according to claim 1, characterized in that: After the step of performing regression detection through the feature pyramid and the preferred candidate box to obtain the table line information in the image to be identified, the method further includes: A preset edge line detection algorithm is obtained, and the table line information is fitted according to the edge line detection algorithm to obtain the target table line information of the image to be identified.
3. The method for automatic student status authentication according to claim 1, characterized in that: The step of extracting text information from the preprocessed image comprises: Performing image text recognition on the preprocessed image to obtain rough text; A stored text dictionary is obtained, and the rough text is corrected and structured based on the text dictionary to obtain the text information.
4. The method for automatic student status authentication according to claim 1, characterized in that: Before the step of classifying and identifying the verification code pictures in the pre-processed pictures according to the verification code classification model, the method further includes: Obtaining a timestamp of the verification code image, determining whether the verification code image is valid according to the timestamp, and determining that the verification code image is a valid image if the timestamp is within a preset validity period range; If the timestamp is not within the preset validity period, it is determined that the verification code image is an invalid image.
5. The method for automatic student status authentication according to claim 1, characterized in that: Before the step of obtaining the trained verification code classification model, the method further includes: Collect multiple groups of website verification code images, classify the website verification code images, and obtain classification labels; A preset basic verification classification model is trained according to the classification label and the website verification code image. When the training of the basic verification classification model is completed, the trained basic verification classification model is determined to be the verification code classification model.
6. A device for automatic student status authentication, characterized in that: include: A preprocessing module is used to obtain a picture to be identified, and preprocess the picture to be identified to obtain a preprocessed picture; A classification module, used to extract text information and verification code images from the pre-processed images, and obtain a trained verification code classification model, and classify and identify the verification code images in the pre-processed images according to the verification code classification model to obtain the verification code category of the verification code images; A matching module, used to match the corresponding verification code extraction model according to the verification code category, and extract the verification code information in the verification code image according to the verification code extraction model; A verification module, used to obtain a network address of a target website, jump to the target website according to the network address, log in to the target website based on the verification code information and the text information, and automatically verify the student status information in the text information according to the target website; Among them, the preprocessing module includes: A first recognition unit, configured to obtain a preset table line recognition model, and recognize table line information in the to-be-recognized picture based on the table line recognition model; A screening unit, used to screen out the table line information from the to-be-recognized picture to obtain the pre-processed picture; Among them, the classification module includes: A first detection unit, configured to detect a candidate area of a table line in the to-be-recognized picture based on the table line recognition model to obtain a preferred candidate frame; A calculation unit, used for inputting the preferred candidate box into the residual network in the table line recognition model for feature calculation, obtaining feature values of each convolution layer in the residual network, and constructing a feature pyramid based on the feature values; The second detection unit is used to perform regression detection through the feature pyramid and the preferred candidate box to obtain the table line information in the image to be identified.
7. A computer device comprising a memory and a processor, wherein the memory stores computer-readable instructions, and when the processor executes the computer-readable instructions, the steps of the automatic student status authentication method as described in any one of claims 1 to 5 are implemented.
8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-readable instructions, which, when executed by a processor, implement the steps of the automatic student status authentication method according to any one of claims 1 to 5.
Citation Information
Patent Citations
System and method for testing WEB verification code
CN105187443A
Invoice checking method and device, computer equipment and readable storage medium
CN110175899A