Image quality inspection methods, devices, terminal equipment, and storage media
By acquiring video stream image frames in a dual-recording scenario and employing a multi-dimensional verification method for face recognition and pedestrian association, face replacement can be detected in real time, solving the problem of low image quality inspection accuracy and improving the accuracy and efficiency of detection.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-08-11
- Publication Date
- 2026-04-03
AI Technical Summary
In dual-recording scenarios, existing technologies have low image quality inspection accuracy, making it difficult to effectively prevent personnel changes during video recording. Furthermore, frame detection is prone to low pass rates or missing replacement personnel due to face occlusion or failure to detect faces.
By acquiring several image frames from the video stream, a preset queue strategy is used for face recognition and pedestrian association. Combined with frame detection and document detection, multi-dimensional verification is achieved, and face replacement is analyzed in real time to improve the accuracy of image quality inspection.
It effectively improves the image quality inspection accuracy in dual-recording scenarios, enables real-time detection of personnel changes during the process, increases the pass rate of frame detection, and reduces false positives and false negatives.
Smart Images

Figure CN117011919B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of artificial intelligence technology, and in particular to an image quality inspection method, apparatus, terminal device, and storage medium. Background Technology
[0002] In banks, dual recording is a security management measure that is typically used for important transactions and business processes, such as business transactions, identity verification, and authorization.
[0003] However, on the one hand, current facial recognition for dual-recording video image review only performs facial recognition at the beginning or at certain specific time points, which is difficult to effectively avoid situations where personnel are changed during the video recording process; on the other hand, current frame detection for dual-recording video image review usually adopts the method of counting faces. If personnel are changed during the process, or if the customer covers their face, looks down, turns their head, or is far away from the camera, the face may not be detected and the count may be incorrect, resulting in a low pass rate or missing replacement personnel.
[0004] Therefore, it is necessary to propose a solution to improve the accuracy of image quality inspection in dual-recording scenarios. Summary of the Invention
[0005] The main purpose of this application is to provide an image quality inspection method, apparatus, terminal device, and storage medium, aiming to solve the technical problem of low image quality inspection accuracy in dual-recording scenarios.
[0006] To achieve the above objectives, this application provides an image quality inspection method, the image quality inspection method comprising:
[0007] Acquire several image frames from the video stream;
[0008] According to a preset queue strategy, face recognition is performed on the image frames to obtain the face recognition information corresponding to the video stream;
[0009] Based on the preset pedestrian association strategy and the face recognition information, the image frame is subjected to frame detection to obtain frame detection information;
[0010] Based on the frame detection information, face replacement detection is performed on the image frame to obtain the image quality inspection result.
[0011] Optionally, the step of performing face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream includes:
[0012] According to the preset face clarity condition, the face in the image frame is detected to obtain a face recognition queue, which includes at least two first face images;
[0013] Call the preset separate thread to recognize the first face image and determine whether the first face image has been successfully recognized;
[0014] If the first face image is successfully recognized, the corresponding face background information is obtained;
[0015] If the first face image recognition fails, then corresponding recognition failure information is generated based on the face clarity condition.
[0016] Optionally, the step of detecting faces in the image frame according to a preset face clarity condition to obtain a face recognition queue includes:
[0017] The image frame is fed into a preset face tracker to determine the tracking identifier and bounding box position information corresponding to each of the first face images;
[0018] The tracking identifier and the bounding box position information are fed into a preset occlusion classifier to obtain occlusion information;
[0019] The tracking marker, bounding box position information, and occlusion information are fed into a preset face clarity analyzer to detect whether the corresponding first face image is clear.
[0020] If the first face image is clear, it is placed into the face recognition queue.
[0021] Optionally, the step of performing frame detection on the image frame according to a preset pedestrian association strategy and the face recognition information to obtain frame detection information includes:
[0022] Based on the face clarity condition, the faces in the image frame are detected to obtain an updated face recognition queue, which includes at least two second face images.
[0023] When it is detected that the second face image has corresponding face background information but no pedestrian background information, the image frames are respectively subjected to face and pedestrian cross-comparison comparison to obtain the association result;
[0024] When the association result is successfully compared with the facial background information, the association result is used as the pedestrian background information;
[0025] When the face background information is detected to be the same as the second face image, the frame information is obtained;
[0026] When it is detected that the face background information is different from the second face image, the pedestrian image in the image frame is acquired, and it is detected whether the pedestrian image is the same as the pedestrian background information;
[0027] If the pedestrian image is detected to be the same as the pedestrian background photo information, then the frame information is obtained;
[0028] If the pedestrian image is detected to be different from the pedestrian background image information, then out-of-frame information is obtained.
[0029] Optionally, the step of performing face replacement detection on the image frame based on the frame detection information to obtain the image quality inspection result includes:
[0030] Obtain the number of people in the image frame and the number of people in the historical frames;
[0031] When the number of people in the detected image is the same as the number of people in the historical frame, and the in-frame detection information is the out-of-frame information, and the number of image frames exceeds a preset frame range, backend face comparison is performed on the image frames to obtain the image quality inspection result.
[0032] Optionally, after the step of performing frame-in-frame detection on the image frame according to the preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information, and before the step of performing face replacement detection on the image frame according to the frame-in-frame detection information to obtain image quality inspection results, the method further includes:
[0033] A document detection thread is created to perform document detection on the image frame, obtain the document recognition confidence score, and determine whether the document recognition confidence score exceeds a preset confidence threshold.
[0034] If the confidence level of the document recognition exceeds the confidence level threshold, the document recognition information is considered successful.
[0035] If the confidence level of document recognition does not exceed the confidence level threshold, then obtain the number of consecutive document recognitions and determine whether the number of consecutive document recognitions exceeds the preset consecutive threshold.
[0036] If so, then obtaining the document identification information indicates successful identification;
[0037] If not, the document identification information obtained indicates that identification failed.
[0038] Optionally, the image quality inspection method further includes:
[0039] Upon obtaining any one of the face recognition information, frame detection information, document recognition information, or image quality inspection results, generate and send the corresponding operation instruction.
[0040] This application also proposes an image quality inspection device, which includes:
[0041] The acquisition module is used to acquire several image frames from the video stream;
[0042] The recognition module is used to perform face recognition on the image frame according to a preset queue strategy to obtain face recognition information corresponding to the video stream;
[0043] The bounding box detection module is used to perform bounding box detection on the image frame according to the preset pedestrian association strategy and the face recognition information to obtain bounding box detection information.
[0044] The replacement detection module is used to perform face replacement detection on the image frame based on the frame detection information to obtain the image quality inspection result.
[0045] This application also proposes a terminal device, which includes a memory, a processor, and an image quality inspection program stored in the memory and executable on the processor. When the image quality inspection program is executed by the processor, it implements the steps of the image quality inspection method described above.
[0046] This application also proposes a computer-readable storage medium storing an image quality inspection program, which, when executed by a processor, implements the steps of the image quality inspection method described above.
[0047] The image quality inspection method, apparatus, terminal device, and storage medium proposed in this application acquire several image frames from a video stream; perform face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; perform frame-in-frame detection on the image frames according to a preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information; and perform face replacement detection on the image frames according to the frame-in-frame detection information to obtain an image quality inspection result. Based on this application's solution, multi-dimensional verification is used to verify the identity of faces in several image frames. That is, face recognition information is obtained based on face recognition, and then combined with pedestrian association strategies and face recognition information to perform frame-in-frame detection of faces in the video stream. This can effectively improve the technical problem of low image quality inspection accuracy in dual-recording scenarios and enhance the image quality inspection accuracy. Attached Figure Description
[0048] Figure 1 This is a schematic diagram of the functional modules of the terminal equipment to which the image quality inspection device of this application belongs;
[0049] Figure 2 This is a flowchart illustrating a first exemplary embodiment of the image quality inspection method of this application;
[0050] Figure 3 This is a flowchart illustrating a second exemplary embodiment of the image quality inspection method of this application;
[0051] Figure 4 This is a flowchart illustrating a third exemplary embodiment of the image quality inspection method of this application;
[0052] Figure 5 This is a flowchart illustrating a fourth exemplary embodiment of the image quality inspection method of this application;
[0053] Figure 6 This is a flowchart illustrating a fifth exemplary embodiment of the image quality inspection method of this application;
[0054] Figure 7 This is a flowchart illustrating the sixth exemplary embodiment of the image quality inspection method of this application.
[0055] The realization of the purpose, functional features and advantages of this application will be further explained in conjunction with the embodiments and with reference to the accompanying drawings. Detailed Implementation
[0056] It should be understood that the specific embodiments described herein are merely illustrative of this application and are not intended to limit this application.
[0057] The main solution of this application embodiment is as follows: acquiring several image frames of a video stream; performing face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; performing frame-in-frame detection on the image frames according to a preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information; and performing face replacement detection on the image frames according to the frame-in-frame detection information to obtain image quality inspection results. Based on this application solution, identity verification of faces in several image frames is performed through multi-dimensional verification. That is, face recognition information is obtained based on face recognition, and then combined with pedestrian association strategy and face recognition information to perform frame-in-frame detection of faces in the video stream. This can effectively improve the technical problem of low image quality inspection accuracy in dual-recording scenarios and improve image quality inspection accuracy.
[0058] This application addresses the issue of image quality inspection accuracy in dual-recording scenarios. Current methods for reviewing dual-recording video images often employ offline processing. This approach requires item-by-item quality inspection after video recording, and segmented processing is used to reduce latency. To avoid requiring customers to return for a second recording and wait for the dual-recording review to complete, a poor user experience is introduced. To solve this problem, this invention proposes a real-time video image quality inspection solution that can obtain video review results immediately after video recording ends.
[0059] Current facial recognition methods for dual-recording video image review only perform facial recognition at the beginning or at certain specific time points, which cannot effectively prevent situations where personnel are changed during the video recording process. This invention adopts a real-time comparison method. If personnel are changed during the process, corresponding prompts will be given during interaction, and this will also be reflected in the final quality inspection result. Current frame detection for dual-recording video image review typically uses face counting. If personnel are changed during the process, or if the customer obscures their face, looks down, turns their head, or is far from the camera, faces may not be detected and incorrectly counted, leading to low pass rates or missed replacement personnel. This invention uses a novel frame detection logic with a high pass rate and can effectively avoid missing situations where personnel are changed during the process. Current dual-recording video image review does not consider the special case where only part of the face is exposed in certain scenarios, does not analyze facial features, and does not indicate whether facial recognition failure is due to masks in the final result. This invention can effectively analyze this non-compliance phenomenon.
[0060] Therefore, the embodiments of this application, starting from the practical problem of video image quality inspection accuracy, design a real-time system for video image quality inspection in dual-recording scenarios, including: real-time face recognition, real-time frame detection, real-time document detection, real-time determination of whether the person has been switched during recording, and real-time determination of facial feature clarity, etc. It collects images from the terminal camera in real time, performs frame extraction processing, analyzes single-frame images in real time, analyzes all the mentioned quality inspection items, and asynchronously returns quality inspection information and information that needs to be prompted in the interaction design. When video recording ends, the AI quality inspection results and terminal tracking information are sent to the backend service. The backend service organizes the quality inspection information and terminal tracking information, stores the corresponding data in the database, and displays the organized results on the front end.
[0061] Specifically, refer to Figure 1 , Figure 1 This is a schematic diagram of the functional modules of the terminal device to which the image quality inspection device of this application belongs. The image quality inspection device can be an independent device capable of image quality inspection, and it can be implemented on the terminal device in the form of hardware or software. The terminal device can be a smart mobile terminal with data processing capabilities, such as a mobile phone or tablet computer, or it can be a fixed terminal device or server with data processing capabilities.
[0062] In this embodiment, the terminal device to which the image quality inspection device belongs includes at least an output module 110, a processor 120, a memory 130, and a communication module 140.
[0063] The memory 130 stores the operating system and image quality inspection program. The image quality inspection device can: acquire several image frames from the video stream; perform face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; perform frame detection on the image frames according to a preset pedestrian association strategy and face recognition information to obtain frame detection information; and perform face replacement detection on the image frames based on the frame detection information, storing the resulting image quality inspection results in the memory 130. The output module 110 can be a display screen, etc. The communication module 140 can include a WIFI module, a mobile communication module, and a Bluetooth module, etc., and communicates with external devices or servers through the communication module 140.
[0064] When the image quality inspection program in memory 130 is executed by the processor, it performs the following steps:
[0065] Acquire several image frames from the video stream;
[0066] According to a preset queue strategy, face recognition is performed on the image frames to obtain the face recognition information corresponding to the video stream;
[0067] Based on the preset pedestrian association strategy and the face recognition information, the image frame is subjected to frame detection to obtain frame detection information;
[0068] Based on the frame detection information, face replacement detection is performed on the image frame to obtain the image quality inspection result.
[0069] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0070] According to the preset face clarity condition, the face in the image frame is detected to obtain a face recognition queue, which includes at least two first face images;
[0071] Call the preset separate thread to recognize the first face image and determine whether the first face image has been successfully recognized;
[0072] If the first face image is successfully recognized, the corresponding face background information is obtained;
[0073] If the first face image recognition fails, then corresponding recognition failure information is generated based on the face clarity condition.
[0074] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0075] The image frame is fed into a preset face tracker to determine the tracking identifier and bounding box position information corresponding to each of the first face images;
[0076] The tracking identifier and the bounding box position information are fed into a preset occlusion classifier to obtain occlusion information;
[0077] The tracking marker, bounding box position information, and occlusion information are fed into a preset face clarity analyzer to detect whether the corresponding first face image is clear.
[0078] If the first face image is clear, it is placed into the face recognition queue.
[0079] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0080] Based on the face clarity condition, the faces in the image frame are detected to obtain an updated face recognition queue, which includes at least two second face images.
[0081] When it is detected that the second face image has corresponding face background information but no pedestrian background information, the image frames are respectively subjected to face and pedestrian cross-comparison comparison to obtain the association result;
[0082] When the association result is successfully compared with the facial background information, the association result is used as the pedestrian background information;
[0083] When the face background information is detected to be the same as the second face image, the frame information is obtained;
[0084] When it is detected that the face background information is different from the second face image, the pedestrian image in the image frame is acquired, and it is detected whether the pedestrian image is the same as the pedestrian background information;
[0085] If the pedestrian image is detected to be the same as the pedestrian background photo information, then the frame information is obtained;
[0086] If the pedestrian image is detected to be different from the pedestrian background image information, then out-of-frame information is obtained.
[0087] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0088] Obtain the number of people in the image frame and the number of people in the historical frames;
[0089] When the number of people in the detected image is the same as the number of people in the historical frame, and the in-frame detection information is the out-of-frame information, and the number of image frames exceeds a preset frame range, backend face comparison is performed on the image frames to obtain the image quality inspection result.
[0090] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0091] A document detection thread is created to perform document detection on the image frame, obtain the document recognition confidence score, and determine whether the document recognition confidence score exceeds a preset confidence threshold.
[0092] If the confidence level of the document recognition exceeds the confidence level threshold, the document recognition information is considered successful.
[0093] If the confidence level of document recognition does not exceed the confidence level threshold, then obtain the number of consecutive document recognitions and determine whether the number of consecutive document recognitions exceeds the preset consecutive threshold.
[0094] If so, then obtaining the document identification information indicates successful identification;
[0095] If not, the document identification information obtained indicates that identification failed.
[0096] Furthermore, when the image quality inspection program in memory 130 is executed by the processor, it also performs the following steps:
[0097] Upon obtaining any one of the face recognition information, frame detection information, document recognition information, or image quality inspection results, generate and send the corresponding operation instruction.
[0098] This embodiment, through the above-described scheme, specifically acquires several image frames from a video stream; performs face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; performs frame-in-frame detection on the image frames according to a preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information; and performs face replacement detection on the image frames according to the frame-in-frame detection information to obtain image quality inspection results. Based on this application's scheme, identity verification of faces in several image frames is performed through multi-dimensional verification. That is, face recognition information is obtained based on face recognition, and then combined with pedestrian association strategies and face recognition information to perform frame-in-frame detection of faces in the video stream. This can effectively improve the technical problem of low image quality inspection accuracy in dual-recording scenarios and enhance image quality inspection accuracy.
[0099] Based on, but not limited to, the terminal device architecture described above, this application proposes method embodiments.
[0100] Reference Figure 2 , Figure 2 This is a flowchart illustrating a first exemplary embodiment of the image quality inspection method of this application. The image quality inspection method includes:
[0101] Step S210: Acquire several image frames from the video stream;
[0102] The execution subject of the method in this embodiment can be an image quality inspection device, an image quality inspection terminal device, or a server. This embodiment takes an image quality inspection device as an example. The image quality inspection device can be integrated into terminal devices such as smartphones and tablets with data processing functions.
[0103] This embodiment mainly aims to improve the accuracy of image quality inspection, especially in dual-recording scenarios.
[0104] Specifically, a video stream consists of a series of continuous images. In a dual-recording scenario, by acquiring several image frames from the video stream, continuous image data can be obtained, providing a data source for subsequent processing.
[0105] Step S220: According to the preset queue strategy, perform face recognition on the image frame to obtain the face recognition information corresponding to the video stream;
[0106] Specifically, to optimize the utilization of computing resources, balance the processing load, or ensure the rationality of task processing, queuing strategies can be used to manage the processing order of tasks, such as in the case of concurrent processing and task scheduling. For example, if processing capacity is limited, image frames can be queued and face recognition performed at a certain rate to avoid resource overload; or image frames can be processed in chronological order to ensure the timeliness of data.
[0107] The queue can be either First-In-First-Out (FIFO) or Last-In-First-Out (LIFO), depending on the task priority and processing requirements.
[0108] Step S230: Based on the preset pedestrian association strategy and the face recognition information, perform frame detection on the image frame to obtain frame detection information;
[0109] Specifically, in object detection tasks, some special cases may arise, such as target occlusion or the target portion appearing at the image edge, which may cause the bounding box to not completely contain the target. Bounding box detection refers to drawing bounding boxes in an image to mark pedestrians or target objects associated with faces. By using pre-defined pedestrian association strategies and face recognition information, performing bounding box detection on image frames can help quickly locate and associate target objects in the image, and provide target regions for subsequent face swapping detection.
[0110] Pedestrian association strategies refer to a method used in object detection or tracking to associate the same pedestrians or targets in different frames, determining the similarity relationship between pedestrians and target faces in different frames. In video processing, since targets may appear, disappear, be occluded, or move in different frames, it is necessary to find the correspondence between the same pedestrians in different frames. This can be achieved by marking face-related pedestrian or target regions in the video stream, providing target regions for subsequent face swapping detection, and facilitating target tracking or analysis.
[0111] Step S240: Based on the frame detection information, perform face replacement detection on the image frame to obtain the image quality inspection result.
[0112] Specifically, face swapping detection detects whether there is face swapping in an image (i.e., replacing the original face with another face), and is used to discover the behavior of target faces in an image, reducing the risk of false positives.
[0113] This embodiment, through the above-described scheme, specifically acquires several image frames from a video stream; performs face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; performs frame-in-frame detection on the image frames according to a preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information; and performs face replacement detection on the image frames according to the frame-in-frame detection information to obtain image quality inspection results. Based on this application's scheme, identity verification of faces in several image frames is performed through multi-dimensional verification. That is, face recognition information is obtained based on face recognition, and then combined with pedestrian association strategies and face recognition information to perform frame-in-frame detection of faces in the video stream. This can effectively improve the technical problem of low image quality inspection accuracy in dual-recording scenarios and enhance image quality inspection accuracy.
[0114] Reference Figure 3 , Figure 3 This is a flowchart illustrating a second exemplary embodiment of the image quality inspection method of this application. Based on the above... Figure 2 In the embodiment shown, step S220 involves performing face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream, including:
[0115] Step S310: Detect faces in the image frame according to preset face clarity conditions to obtain a face recognition queue, wherein the face recognition queue includes at least two first face images;
[0116] Specifically, the clarity condition can be that the face is not wearing a mask, looking down, or tilting its head. If a face is detected that is not wearing a mask, looking down, or tilting its head, it means that the face meets the clarity condition. Face images that meet the clarity condition are then selected and added to the face recognition queue. The face recognition queue contains at least two first face images, indicating that there are at least two face images that meet the clarity condition.
[0117] It should be noted that this application embodiment takes into account that at least two people are required to complete the dual recording scenario. Therefore, by setting up a face recognition queue and performing face recognition when there are two different people in the face recognition queue, it is possible to avoid the situation where at least one person is not ready to record, which can improve the efficiency of image quality inspection.
[0118] Further, step S310, based on preset face clarity conditions, detects faces in the image frame to obtain a face recognition queue, including:
[0119] Step S311: The image frame is transmitted to a preset face tracker to determine the tracking identifier and bounding box position information corresponding to each of the several first face images.
[0120] Step S312: Input the tracking identifier and the box position information into a preset occlusion classifier to obtain occlusion information;
[0121] Step S313: The tracking marker, frame position information, and occlusion information are input into a preset face clarity analyzer to detect whether the corresponding first face image is clear.
[0122] Step S314: If the first face image is clear, then it is placed into the face recognition queue.
[0123] For example, firstly, the interface accepts video frame image information from the caller and passes the image to the face detector and face tracker. The face detector and tracker return face bounding box information and ID information, where the face bounding box information is the upper left corner coordinates (x1, y1) and lower right corner coordinates (x2, y2) of the face in the image, as well as the tracking ID assigned to different people.
[0124] Then, the obtained face frame information and ID information are passed into the mask classifier to determine whether the face is wearing a mask;
[0125] Then, the position information, ID information, and mask information of the face bounding box are input into the face quality analyzer to analyze whether the face is clear. If the face quality analyzer determines that the face features are clear, the corresponding face is added to the face recognition queue. Clear faces are not filtered for those wearing masks.
[0126] Step S320: Call the preset separation thread to recognize the first face image and determine whether the first face image has been successfully recognized;
[0127] Specifically, for each first face image, a pre-defined separation thread, i.e., a face recognition algorithm, is invoked to recognize these images. This separation thread can be an independent computing unit used to process face image recognition tasks in parallel. By determining whether the face image has been successfully recognized, the identity of the face can be accurately identified.
[0128] For example, when the face recognition queue Q reaches the face recognition requirement, the backend face recognition service is invoked for face verification. The face recognition requirement is that there are at least two clear faces of different people (i.e., two different IDs) in queue Q. The backend face recognition is invoked using a separate thread to prevent frontend display lag due to interface latency.
[0129] Step S330: If the first face image is successfully recognized, the corresponding face background information is obtained;
[0130] Specifically, if the separation thread successfully performs face recognition on the first face image and determines the identity of the face, it can obtain the corresponding facial background information. This information may include the facial background image, identity identifier, name, and related attributes.
[0131] For example, if the face recognition recorded in the current frame is successful after N image frames, the face at the time of successful recognition by calling the backend service is saved as the face background photo for face verification in the box detection stage.
[0132] Step S340: If the first face image recognition fails, then generate corresponding recognition failure information based on the face clarity condition.
[0133] Specifically, if the separation thread fails to recognize the first face image, indicating that the identity of the face cannot be determined, corresponding recognition failure information can be generated based on the face clarity condition. For example, the recognition failure information can describe the reason for the failure, including unclear image, excessive face angle, severe occlusion, etc. In addition, faces or pedestrians appearing in the current frame will be recorded as face background images to provide more accurate identity recognition data for the next stage of bounding box detection and face swapping detection.
[0134] For example, if the thread that calls the backend face recognition service in the current frame does not return a result, the interface returns an identifier code indicating that face recognition is incomplete; if the thread that calls the backend face recognition service in the current frame returns a result, the interface returns the backend face recognition result. Then, the frontend displays the result of face recognition success or failure.
[0135] It should be noted that in the face recognition quality inspection process, if face recognition is successful or the preset number of backend face recognition attempts is exceeded, the interface will directly return the current face recognition status. If face recognition is successful, a face recognition success identifier will be returned; if face recognition fails, a failure identifier will be returned. For example, if the face is determined to be wearing a mask in the case of face recognition failure, the reason for face recognition failure will be recorded as wearing a mask.
[0136] This embodiment addresses the issue of failed face recognition by employing face detection and recognition technologies to acquire clear face images. Furthermore, a pre-defined separate thread allows for parallel processing of multiple face images to obtain background image information or recognition failure information. This effectively improves the low image quality inspection accuracy in dual-recording scenarios, thereby enhancing the overall image quality inspection accuracy.
[0137] Reference Figure 4 , Figure 4 This is a flowchart illustrating a third exemplary embodiment of the image quality inspection method of this application. Based on the above... Figure 2 In the embodiment shown, step S230 involves performing frame detection on the image frame based on a preset pedestrian association strategy and the face recognition information to obtain frame detection information, including:
[0138] Step S410: Based on the face clarity condition, detect the face in the image frame to obtain an updated face recognition queue, wherein the updated face recognition queue includes at least two second face images;
[0139] Specifically, based on the preset face clarity condition, face detection is performed on the image frame, and face images that do not meet the clarity condition are filtered out to obtain an updated face recognition queue, wherein the updated queue contains at least two second face images.
[0140] For example, the interface accepts video frame image information from the caller, passes the image to the face detector and face tracker, and the face detector and tracker return face bounding box information and ID information. The face bounding box information is the coordinates of the top left corner (x1, y1) and the bottom right corner (x2, y2) of the face in the image, as well as the tracking ID assigned to different people. Then, the obtained face bounding box information and ID information are passed to the mask classifier to determine whether the face is wearing a mask. Then, the position information of the face bounding box, ID information, and mask information are passed to the face quality analyzer to analyze whether the face quality is clear. Then, if the face quality analyzer analyzes the face features as clear, the corresponding face is put into the face recognition queue Q, where the face features are clear and faces wearing masks are not filtered.
[0141] Step S420: When it is detected that the second face image has corresponding face background information but no pedestrian background information, face and pedestrian cross-comparison comparison is performed on the image frames respectively to obtain the association result;
[0142] Specifically, pedestrian bottom image information can refer to a bottom photo of a pedestrian, also known as a full-body or half-body photo of a pedestrian, used to identify and associate pedestrians.
[0143] For example, it is determined whether different individuals in the face recognition queue have facial background photos. If not, the faces of two different individuals in the video frame are saved as background photos. Then, it is determined whether different individuals have pedestrian background photos. If the pedestrian background photos of existing individuals do not exist, and all facial background photos exist, a new thread is created to perform face detection and pedestrian detection on the current frame image, and the pedestrians and faces are associated using the intersection-union (IoU) of faces and pedestrians. The face in the current frame is compared with the facial background photos. If the comparison is successful, the pedestrian background photo of the corresponding individual is saved; otherwise, the process waits for subsequent frames to be saved.
[0144] Step S430: When the association result is successfully compared with the face background information, the association result is used as the pedestrian background information;
[0145] Specifically, when the association result is successfully compared with the facial background image information, it indicates that the association result is reliable, and it is then used as the pedestrian background image information. This means that there is a correlation between the face detected in the image and the corresponding pedestrian.
[0146] Step S440: When the face background information is detected to be the same as the second face image, the frame information is obtained;
[0147] Specifically, if the background image of a face is detected to match the second face image, it indicates that the face image is a valid face and is consistent with the background image of the face. The bounding box information of the face image can then be obtained to mark the face position.
[0148] Step S450: When it is detected that the face background information is different from the second face image, the pedestrian image in the image frame is acquired, and it is detected whether the pedestrian image is the same as the pedestrian background information.
[0149] Specifically, if the background image of a person's face is detected to be mismatched with the second face image, it indicates that the face image may have been tampered with or has a problem. The pedestrian image in the image frame can be obtained and compared with the background image of the pedestrian to determine whether they match.
[0150] Step S460: If the pedestrian image is detected to be the same as the pedestrian background photo information, then the frame information is obtained;
[0151] Specifically, if a pedestrian image is detected to match the pedestrian background image information, it means that the pedestrian image is valid and consistent with the pedestrian background image information. The in-frame information of the pedestrian image can be obtained and used to mark the pedestrian's position.
[0152] Step S470: If the pedestrian image is detected to be different from the pedestrian background image information, then out-of-frame information is obtained.
[0153] Specifically, if a pedestrian image is detected to be mismatched with the pedestrian background image information, it indicates that there may be a problem with the pedestrian image or that it does not match the background image information, and the identity of the pedestrian cannot be confirmed. Therefore, out-of-frame information is obtained, indicating that the pedestrian image cannot be accurately located in the image.
[0154] For example, determine whether the current frame ID has been changed or added. If the ID has been changed or added, start a new thread to verify identity. When both facial features and pedestrian features are present, identity verification first compares the face in queue Q with the background image of the face. If the face comparison is successful, a matching frame identifier is returned. If the face comparison fails, pedestrian detection is performed on the current frame to obtain a pedestrian image, and then the pedestrian image is compared with the background image of the pedestrian. If the pedestrian comparison is successful, a matching frame identifier is returned; if it fails, the corresponding out-of-frame identifier is returned based on the identity of the person who failed.
[0155] When neither facial features nor pedestrian features are available, the system counts faces to determine the number of faces in the current frame. If the number of faces is less than the preset number of people, an out-of-frame identifier is returned; otherwise, an in-frame identifier is returned. Based on the identifier, the front-end displays the corresponding prompt information.
[0156] This embodiment, through the above-described scheme, specifically by associating faces and pedestrians to obtain pedestrian background image information, enables the effective preservation and tracking of facial information and identity. By comparing the background image information of the face with a second face image, the identity of the face can be confirmed, thereby improving the accuracy and reliability of image recognition and association, and providing more reliable data support for subsequent processing and analysis.
[0157] Reference Figure 5 , Figure 5 This is a flowchart illustrating a fourth exemplary embodiment of the image quality inspection method of this application. Based on the above... Figure 2 In the illustrated embodiment, step S240 involves performing face replacement detection on the image frame based on the frame detection information to obtain an image quality inspection result, including:
[0158] Step S510: Obtain the number of people in the image frame and the number of people in the historical frame;
[0159] Specifically, for the image frame, it is necessary to obtain the number of people in the current frame and the number of people in historical frames. The number of people in the current image frame refers to the number of people appearing in the current image frame, which can be obtained through methods such as face detection or object detection. The number of people in historical frames refers to the number of people appearing in image frames within a previous period of time, which is usually obtained by saving and recording relevant information from historical frames.
[0160] Step S520: When the number of people in the image is the same as the number of people in the historical frame, and the frame detection information is the frame out information, and the number of image frames exceeds a preset frame number range, backend face comparison is performed on the image frames to obtain the image quality inspection result.
[0161] Specifically, if the number of people in the current image is the same as the number of people in a historical frame, and the in-frame detection information is the out-of-frame information, this indicates that the face or target object in the current image frame has exceeded the preset bounding box. Out-of-frame information typically means that the target has left the expected detection range, possibly due to target movement, disappearance, or occlusion. In specific scenarios, if the number of image frames exceeds a preset frame count range, i.e., the number of historical frames has accumulated to a certain level, back-end face comparison can be performed. Back-end face comparison refers to further face or target detection on the image frames at the back end of the image data processing stage to obtain more accurate face or target information, providing more complete and accurate results for image quality inspection.
[0162] For example, firstly, the in-frame detection quality inspection information and the number of people in the current frame are obtained. If the number of people in the current frame is the same as the number of people in the historical frames, and the corresponding person's status is out of frame for more than frame number T1, then it is considered that the corresponding person has been replaced. Therefore, face detection is performed on the current frame, and the face is compared with the corresponding person's face in the backend where there is a risk of replacement. If no one in the current frame successfully matches the backend face, then the person is considered to have been replaced; if at least one person in the current frame successfully matches the corresponding person's face in the backend, then no replacement is considered. Finally, the quality inspection results of mid-process personnel replacement are recorded.
[0163] Furthermore, after step S520, a facial feature clarity inspection can be performed on several image frames. Specific steps may include the following:
[0164] First, if the identity recognition is successful in the face recognition stage, the person's facial features are recorded as clear. If the identity recognition fails in the face recognition stage, the video frame image is sent to the face detection and face tracker, which returns the face tracking ID and bounding box position information.
[0165] Then, the face tracking ID and bounding box position information are fed into the mask classifier to determine whether the face is wearing a mask;
[0166] Then, the bounding box location information, ID information, and mask information are input into the face quality analyzer to analyze whether the face quality is clear. The analysis includes: frontal view, resolution, contrast, brightness, and mask status. If there are instances of non-frontal views, low resolution, low contrast, low brightness, or the presence of a mask, the face is considered unclear.
[0167] Then, based on the ID information, the corresponding identity in the face recognition result is associated, and the number of clear frames of the face features is recorded. If the number of clear frames exceeds the preset threshold T, the face features of the person with the corresponding identity are recorded as clear. If the threshold is not reached by the end of the video recording, the face features of the person with the corresponding identity are considered unclear.
[0168] Finally, record the quality inspection results of the corresponding personnel's clear facial features.
[0169] Furthermore, during the video image quality inspection process, embedded point information monitoring can also be performed. The specific steps are as follows:
[0170] First, when initializing the handle, obtain the current CPU configuration information, as well as information such as the current CPU utilization and memory utilization.
[0171] If the remainder when the video frame count is divided by the preset frame interval T2 is 0, then the current CPU usage, memory usage, and other information are acquired and recorded. Here, T2 is the set frame interval, meaning that information is collected once every T2 frames.
[0172] Finally, after the video recording ended, the maximum, minimum, and average values of CPU and memory usage were calculated from the multiple data collection sessions.
[0173] This embodiment uses the above-described scheme to detect and count the number of people in an image frame to determine whether there is a risk of face replacement. If a risk of face replacement is detected, a backend face comparison is performed on the image frame to determine whether face replacement has occurred, thereby ensuring image quality and data reliability.
[0174] Reference Figure 6 , Figure 6 This is a flowchart illustrating a fifth exemplary embodiment of the image quality inspection method of this application. Based on the above... Figure 2 , 3In the illustrated embodiment, after step S230, performing frame-in-frame detection on the image frame according to the preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information, and before step S240, performing face replacement detection on the image frame according to the frame-in-frame detection information to obtain the image quality inspection result, the method further includes:
[0175] Step S610: Create an ID detection thread to perform ID detection on the image frame, obtain ID recognition confidence, and determine whether the ID recognition confidence exceeds a preset confidence threshold.
[0176] Specifically, the system can create an ID detection thread to perform ID detection on image frames. This thread uses a pre-trained model or algorithm to detect the presence of ID documents (such as ID cards, bank cards, etc.) in the image. The detection result provides the location of the ID document and a confidence score, indicating the reliability of the detection result. After obtaining the confidence score, the system needs to evaluate it by comparing it to a preset confidence threshold. If the confidence score exceeds the preset threshold, the detection result is considered reliable, and further processing can proceed.
[0177] Step S620: If the confidence level of the document recognition exceeds the confidence level threshold, the document recognition information is obtained as successful recognition;
[0178] Specifically, if the confidence level of document recognition exceeds the preset confidence threshold, that is, the document detection result is reliable, then the document recognition information can be marked as "recognition successful", indicating that the document was successfully detected in the image frame.
[0179] Step S630: If the document recognition confidence level does not exceed the confidence level threshold, then obtain the number of consecutive document recognitions and determine whether the number of consecutive document recognitions exceeds the preset consecutive threshold.
[0180] Specifically, if the document recognition confidence level fails to reach the preset confidence threshold, it indicates that the document detection result is not reliable enough. The system will count the number of times the document recognition confidence level fails to exceed the threshold in multiple consecutive image frames, forming the document consecutive recognition count. The document consecutive recognition count indicates that no reliable document has been successfully detected in consecutive frames.
[0181] Step S640: If yes, then obtaining the document identification information indicates successful identification;
[0182] Specifically, if the number of consecutive document recognitions exceeds the preset consecutive threshold, it means that no credible document has been successfully detected in multiple consecutive image frames. The system will mark the document recognition information as "recognition successful", indicating that the system has failed to detect credible documents multiple times in a row and can take corresponding processing measures.
[0183] Step S650: If not, the document identification information is obtained as identification failure.
[0184] Specifically, if the number of consecutive document recognitions does not exceed the preset consecutive threshold, that is, if a credible document is successfully detected in at least one frame in a series of consecutive frames, the system will mark the document recognition information as "recognition failed", indicating that a credible document was successfully detected in some image frames.
[0185] For example, firstly, the interface accepts video frame images, creates a new thread to perform document detection. If the document detection thread does not return a result, it returns an identifier corresponding to "document detection failed." If the document detection thread returns a result, it determines whether document recognition was successful based on the detection result. The returned document detection result includes the position information of the document frame and the corresponding confidence score. If the document recognition confidence score is greater than F, the recognition is considered successful; otherwise, a count of successful document recognitions is performed. When the consecutive count of successful document recognitions exceeds M, the document recognition is considered successful. Then, the corresponding identifier is returned based on the document recognition result. Finally, the document detection result is recorded, and the front end displays the corresponding recognition result. It should be noted that in the document detection process, if document recognition is successful, the interface directly returns a "document recognition successful" identifier.
[0186] This embodiment, through the above-described scheme, specifically uses an ID detection thread to perform ID detection on image frames. Based on confidence thresholds and continuity thresholds, it derives ID recognition information for subsequent processing and decision-making. This process can effectively determine whether a credible ID exists in an image frame and make appropriate judgments of success or failure based on the circumstances.
[0187] Reference Figure 7 , Figure 7 This is a flowchart illustrating a sixth exemplary embodiment of the image quality inspection method of this application. Based on the above... Figure 2 , 6 The image quality inspection method shown in the embodiment further includes:
[0188] Step S710: Upon obtaining any one of the face recognition information, frame detection information, document recognition information, or image quality inspection results, generate and send the corresponding operation instruction.
[0189] Specifically, multiple steps acquire different information, including facial recognition information, in-frame detection information, document recognition information, and image quality inspection results. Based on this information, the system generates corresponding operation instructions according to pre-set rules and conditions, and then sends these instructions to the system's subsequent processing or other related systems to achieve specific functions or objectives.
[0190] Based on facial recognition information, the system can generate operation instructions. For example: if facial recognition is successful, an instruction to allow access can be generated; if facial recognition fails, an instruction to deny access can be generated; if the bounding box detection information indicates that the target has exceeded the preset bounding box, an alarm instruction can be generated, such as continuing target tracking or facial feature extraction; if document recognition is successful, access control instructions can be generated, such as authorizing the use of certain devices or systems; if document recognition fails, security measure instructions can be generated, such as prompting for resubmission of documents or temporarily restricting services; if the image quality inspection is qualified, normal operation instructions can be generated, such as allowing further analysis or processing; if the image quality inspection is unqualified, processing instructions can be generated, such as re-acquiring the image or triggering the corresponding abnormal handling process.
[0191] This embodiment, through the above-described solution, specifically by applying image processing and facial recognition technologies in a banking scenario, generates and sends corresponding operation instructions based on different information. The application of these technologies can enhance the bank's customer experience, strengthen security management, and further improve the bank's operational efficiency and service level.
[0192] Furthermore, in conjunction with the first, second, third, fourth, fifth, and sixth embodiments described above, a flowchart illustrating a seventh exemplary embodiment of the image quality inspection method of this application is presented.
[0193] First, initialize the information required for quality inspection and create a quality inspection handle. The quality inspection information includes business information, customer information, model information, and configuration parameter information. The quality inspection handle is an object that can be used to perform video quality inspection, and it contains the interface functions of each quality inspection item.
[0194] Then, the camera video stream is acquired and decoded into single-frame images.
[0195] Then, the quality inspection interface is called to perform video quality inspection and analysis on the single-frame image. First, face recognition quality inspection is performed, followed by frame detection, document detection, facial feature clarity analysis, and quality inspection for mid-process personnel changes. After processing the single-frame image, the video quality inspection results for the current frame are saved. Simultaneously, information such as CPU usage is monitored using embedded points.
[0196] Then, the video recording ends, the backend service interface is called, the quality inspection results and data tracking information are sent to the backend service, and the quality inspection handle is destroyed.
[0197] Finally, the backend service stores the quality inspection results and event tracking information in the database and displays the results on the front end.
[0198] The quality inspection items follow a specific order. First, facial recognition is inspected, and a photo of successfully identified individuals is saved as the background image for subsequent comparisons. Next, checks are performed on frame detection, ID verification, facial feature clarity, and personnel replacement. Frame detection uses the background image from the facial recognition stage to verify if anyone has left the frame. Personnel replacement utilizes the frame detection result; if someone is not in the frame but the number of people meets the quality inspection requirements, it's considered a risk of personnel replacement. A second verification by backend facial recognition then confirms the personnel replacement, reducing the risk of misjudgment.
[0199] Furthermore, embodiments of this application also propose an image quality inspection device, which includes:
[0200] The acquisition module is used to acquire several image frames from the video stream;
[0201] The recognition module is used to perform face recognition on the image frame according to a preset queue strategy to obtain face recognition information corresponding to the video stream;
[0202] The bounding box detection module is used to perform bounding box detection on the image frame according to the preset pedestrian association strategy and the face recognition information to obtain bounding box detection information.
[0203] The replacement detection module is used to perform face replacement detection on the image frame based on the frame detection information to obtain the image quality inspection result.
[0204] The principle and implementation process of image quality inspection in this embodiment are explained in the above embodiments and will not be repeated here.
[0205] Furthermore, this application also proposes a terminal device, which includes a memory, a processor, and an image quality inspection program stored in the memory and executable on the processor. When the image quality inspection program is executed by the processor, it implements the steps of the image quality inspection method described above.
[0206] Since this image quality inspection program employs all the technical solutions of all the aforementioned embodiments when executed by the processor, it possesses at least all the beneficial effects brought about by all the technical solutions of all the aforementioned embodiments, which will not be elaborated upon here.
[0207] Furthermore, embodiments of this application also propose a computer-readable storage medium storing an image quality inspection program, which, when executed by a processor, implements the steps of the image quality inspection method described above.
[0208] Since this image quality inspection program employs all the technical solutions of all the aforementioned embodiments when executed by the processor, it possesses at least all the beneficial effects brought about by all the technical solutions of all the aforementioned embodiments, which will not be elaborated upon here.
[0209] Compared to existing technologies, the image quality inspection method, apparatus, terminal device, and storage medium proposed in this application acquire several image frames from a video stream; perform face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; perform frame-in-frame detection on the image frames according to a preset pedestrian association strategy and the face recognition information to obtain frame-in-frame detection information; and perform face replacement detection on the image frames according to the frame-in-frame detection information to obtain image quality inspection results. Based on the solution of this application, the identity verification of faces in several image frames is performed through multi-dimensional verification. That is, face recognition information is obtained based on face recognition, and then combined with pedestrian association strategy and face recognition information to perform frame-in-frame detection of faces in the video stream. This can effectively improve the technical problem of low image quality inspection accuracy in dual-recording scenarios and improve the image quality inspection accuracy.
[0210] It should be noted that, in this document, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or system that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such a process, method, article, or system. Unless otherwise specified, an element defined by the phrase "comprising one..." does not exclude the presence of other identical elements in the process, method, article, or system that includes that element.
[0211] The sequence numbers of the embodiments in this application are for descriptive purposes only and do not represent the superiority or inferiority of the embodiments.
[0212] Through the above description of the embodiments, those skilled in the art can clearly understand that the methods of the above embodiments can be implemented by means of software plus necessary general-purpose hardware platforms. Of course, they can also be implemented by hardware, but in many cases the former is a better implementation method. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, can be embodied in the form of a software product. This computer software product is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes several instructions to cause a terminal device (which may be a mobile phone, computer, server, controlled terminal, or network device, etc.) to execute the methods of each embodiment of this application.
[0213] The above are merely preferred embodiments of this application and do not limit the patent scope of this application. Any equivalent structural or procedural transformations made using the content of this application's specification and drawings, or direct or indirect applications in other related technical fields, are similarly included within the patent protection scope of this application.
Claims
1. An image quality inspection method, characterized in that, The image quality inspection method includes the following steps: Acquire several image frames from the video stream; According to a preset queue strategy, face recognition is performed on the image frames to obtain face recognition information corresponding to the video stream; this includes: detecting faces in the image frames according to preset face clarity conditions to obtain a face recognition queue, the face recognition queue including at least two first face images; calling a preset separate thread to recognize the first face images and determining whether the first face images are successfully recognized; if the first face images are successfully recognized, obtaining the corresponding face background information; if the first face images fail to be recognized, generating corresponding recognition failure information according to the face clarity conditions. According to a preset pedestrian association strategy and the face recognition information, in-frame detection is performed on the image frame to obtain in-frame detection information; this includes: detecting faces in the image frame according to the face clarity condition to obtain an updated face recognition queue, the updated face recognition queue including at least two second face images; when it is detected that the second face image has corresponding face background information but no pedestrian background information, face and pedestrian cross-comparison association is performed on the image frame to obtain an association result; when the association result is successfully compared with the face background information, the association result is used as the pedestrian background information; when it is detected that the face background information is the same as the second face image, in-frame information is obtained; when it is detected that the face background information is different from the second face image, a pedestrian image in the image frame is obtained, and it is detected whether the pedestrian image is the same as the pedestrian background information; if it is detected that the pedestrian image is the same as the pedestrian background information, the in-frame information is obtained; if it is detected that the pedestrian image is different from the pedestrian background information, out-of-frame information is obtained. Based on the frame detection information, face replacement detection is performed on the image frame to obtain the image quality inspection result; The step of detecting faces in the image frame and obtaining a face recognition queue based on preset face clarity conditions includes: The image frame is fed into a preset face tracker to determine the tracking identifier and bounding box position information corresponding to each of the first face images; The tracking identifier and the bounding box position information are fed into a preset occlusion classifier to obtain occlusion information; The tracking marker, bounding box position information, and occlusion information are fed into a preset face clarity analyzer to detect whether the corresponding first face image is clear. If the first face image is clear, it is placed into the face recognition queue.
2. The image quality inspection method as described in claim 1, characterized in that, The step of performing face replacement detection on the image frame based on the frame detection information to obtain the image quality inspection result includes: Obtain the number of people in the image frame and the number of people in the historical frames; When the number of people in the detected image is the same as the number of people in the historical frame and the in-frame detection information is the out-of-frame information, and the number of image frames exceeds a preset frame number range, backend face comparison is performed on the image frames to obtain the image quality inspection result.
3. The image quality inspection method as described in claim 1, characterized in that, After the step of performing bounding box detection on the image frame according to the preset pedestrian association strategy and the face recognition information to obtain bounding box detection information, and before the step of performing face replacement detection on the image frame according to the bounding box detection information to obtain image quality inspection results, the method further includes: A document detection thread is created to perform document detection on the image frame, obtain the document recognition confidence score, and determine whether the document recognition confidence score exceeds a preset confidence threshold. If the confidence level of the document recognition exceeds the confidence level threshold, the document recognition information is considered successful. If the confidence level of document recognition does not exceed the confidence level threshold, then obtain the number of consecutive document recognitions and determine whether the number of consecutive document recognitions exceeds the preset consecutive threshold. If so, then obtaining the document identification information indicates successful identification; If not, the document identification information obtained indicates that identification failed.
4. The image quality inspection method as described in claim 1 or 3, characterized in that, The image quality inspection method further includes: Upon obtaining any one of the face recognition information, frame detection information, document recognition information, or image quality inspection results, generate and send the corresponding operation instruction.
5. An image quality inspection device, characterized in that, The image quality inspection device includes: The acquisition module is used to acquire several image frames from the video stream; The recognition module is used to perform face recognition on the image frames according to a preset queue strategy to obtain face recognition information corresponding to the video stream; the recognition module is also used to detect faces in the image frames according to preset face clarity conditions to obtain a face recognition queue, the face recognition queue including at least two first face images; call a preset separation thread to recognize the first face images and determine whether the first face images are successfully recognized; if the first face images are successfully recognized, obtain the corresponding face background information; if the first face images fail to be recognized, generate corresponding recognition failure information according to the face clarity conditions; the recognition module is also used to pass the image frames to a preset face tracker to determine the tracking identifiers and bounding box position information corresponding to each of the several first face images; pass the tracking identifiers and bounding box position information to a preset occlusion classifier to obtain occlusion information; pass the tracking identifiers, bounding box position information, and occlusion information to a preset face clarity analyzer to detect whether the corresponding first face images are clear; if the first face images are clear, put them into the face recognition queue; The bounding box detection module is used to perform bounding box detection on the image frame according to a preset pedestrian association strategy and the face recognition information to obtain bounding box detection information; the bounding box detection module is also used to detect faces in the image frame according to the face clarity condition to obtain an updated face recognition queue, the updated face recognition queue including at least two second face images; when it is detected that the second face image has corresponding face background information but no pedestrian background information, the image frame is subjected to face and pedestrian intersection-union comparison (IUCN) association respectively to obtain an association result; in the association result When a successful comparison with the facial background image information is achieved, the association result is used as the pedestrian background image information. If the facial background image information is detected to be identical to the second facial image, in-frame information is obtained. If the facial background image information is detected to be different from the second facial image, a pedestrian image is acquired from the image frame, and it is detected whether the pedestrian image is identical to the pedestrian background image information. If the pedestrian image is detected to be identical to the pedestrian background image information, in-frame information is obtained. If the pedestrian image is detected to be different from the pedestrian background image information, out-of-frame information is obtained. The replacement detection module is used to perform face replacement detection on the image frame based on the frame detection information to obtain the image quality inspection result.
6. A terminal device, characterized in that, The terminal device includes a memory, a processor, and an image quality inspection program stored in the memory and executable on the processor. When the image quality inspection program is executed by the processor, it implements the steps of the image quality inspection method as described in any one of claims 1-4.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores an image quality inspection program, which, when executed by a processor, implements the steps of the image quality inspection method as described in any one of claims 1-4.
Citation Information
Patent Citations
Double-recording video quality inspection method anddevice, medium and electronic device
CN109360205A
Image processing method, device and system and storage medium
CN110263680A