Image and video detection method and device
By detecting and discriminating the network model to analyze the confidence prediction values of the facial area and local feature areas, the problem of difficulty in accurately detecting deep learning to generate synthetic pictures and videos in the prior art is solved, and the discrimination accuracy is improved.
Patent Information
- Application Number
- CN202010102318.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2020-02-19
- Publication Date
- 2025-02-21
- Estimated Expiration
- 2040-02-19
AI Technical Summary
It is difficult for the prior art to accurately detect synthetic pictures and synthetic videos based on deep learning, especially in the update and iteration of AI face swapping technologies such as DeepFake, the authenticity of synthetic videos is difficult to identify.
By inputting the facial area and local feature area in the picture or video, the confidence prediction values of the facial area and local feature area are detected respectively, and whether the picture or video is synthesized is identified based on these values.
The accuracy of identification of synthetic images and videos is improved, and the problem of low accuracy of synthetic images and video detection in the prior art is solved.
Smart Images

Figure CN113298747B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method and device for detecting images and videos. Background Art
[0002] With the development of AI face-changing technology, ordinary users can also easily realize batch synthesis of face pictures and videos. At the same time, the authenticity and credibility of face pictures and videos will be greatly reduced. In the process of face payment and photo submission, how to accurately detect face synthesis pictures and synthetic videos on the collected pictures is the key to preventing users from using false information for arbitrage.
[0003] In the prior art, there are mainly two synthetic image detection algorithms: a synthetic image detection algorithm based on dual-stream Faster R-CNN, and a synthetic image detection algorithm based on blink recognition.
[0004] In the process of realizing the present invention, the inventors found that there are at least the following problems in the prior art: The first algorithm is mostly used to identify pictures synthesized by traditional means, and can effectively identify traces of smearing and splicing of pictures caused by tools such as PS, and determine whether the picture is an artificially synthesized picture. However, the emerging deep learning-based synthetic picture generation algorithm in recent years obtains synthetic pictures through autonomous learning training of generative adversarial networks. There is no obvious difference in local information, so it is difficult for the algorithm to accurately detect synthetic pictures. In addition, in the update and iteration process of AI face-changing technologies such as DeepFake, the problem of synthetic videos not being able to blink has been gradually solved. The latest synthesis results can already synthesize realistic blinking frequencies, so the second algorithm cannot accurately detect it either. Summary of the invention
[0005] In view of this, the present invention provides a method and device for detecting images and videos, which can improve the accuracy of identifying composite images and composite videos.
[0006] To achieve the above objective, according to a first aspect of the present invention, a picture detection method is provided.
[0007] The image detection method of the present invention comprises: inputting an image into a detection network model to detect a facial region and a local feature region in the face in the image; inputting the facial region and the local feature region in the face in the image into a discrimination network model respectively to obtain a credibility prediction value of the facial region and a credibility prediction value of the local feature region in the face; and identifying whether the image is a synthetic image according to the credibility prediction value of the facial region and the credibility prediction value of the local feature region.
[0008] Optionally, identifying whether the picture is a composite picture based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area includes: determining the credibility prediction value of the picture based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area; comparing the credibility prediction value of the picture with a preset threshold; if the credibility prediction value of the picture is greater than the preset threshold, confirming that the picture is not a composite picture; if the credibility prediction value of the picture is less than or equal to the preset threshold, confirming that the picture is a composite picture.
[0009] Optionally, determining the credibility prediction value of the image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area includes: mapping a spatial vector point corresponding to the image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area; calculating a weighted Euclidean distance between the spatial vector point and the origin of the coordinate system, and using the weighted Euclidean distance as the credibility prediction value of the image.
[0010] Optionally, the local feature areas in the face include: an area where eyebrows are located, an area where eyes are located, an area where nose is located, and an area where mouth is located.
[0011] To achieve the above objective, according to a second aspect of the present invention, a video detection method is provided.
[0012] The video detection method of the present invention comprises: inputting multiple frames of pictures in a video into a detection network model to detect the facial area and the local feature area in the face of each frame of the multiple frames; inputting the facial area and the local feature area in the face of each frame of the pictures into a discrimination network model respectively to obtain the credibility prediction value of the facial area in the frame of the pictures and the credibility prediction value of the local feature area in the face; and identifying whether the video is a synthetic video according to the credibility prediction value of the facial area in each frame of the pictures and the credibility prediction value of the local feature area.
[0013] Optionally, identifying whether the video is a composite video based on the credibility prediction value of the facial area in each frame and the credibility prediction value of the local feature area includes: mapping the spatial vector points corresponding to the frame image based on the credibility prediction value of the facial area in each frame image and the credibility prediction value of the local feature area; determining the discreteness of the spatial vector points corresponding to the multiple frames of images; confirming that the video is a composite video when the discreteness is greater than a preset threshold; and confirming that the video is not a composite video when the discreteness is less than or equal to a preset threshold.
[0014] Optionally, determining the discreteness of the spatial vector points corresponding to the multiple frames of images includes: taking each spatial vector point as the center point of a cluster, calculating the sum of distances from other spatial vector points to the spatial vector point, and taking the sum of distances as the discreteness of the cluster with the spatial vector point as the center point; taking the minimum value of the discreteness of the clusters with each spatial vector point as the center point as the discreteness of the spatial vector points corresponding to the multiple frames of images.
[0015] Optionally, the local feature areas in the face include: an area where eyebrows are located, an area where eyes are located, an area where nose is located, and an area where mouth is located.
[0016] To achieve the above objective, according to a third aspect of the present invention, a picture detection device is provided.
[0017] The image detection device of the present invention comprises: a detection module, which is used to input an image into a detection network model to detect a facial area and a local feature area in the face in the image; a discrimination module, which is used to input the facial area and the local feature area in the face in the image into a discrimination network model respectively to obtain a credibility prediction value of the facial area and a credibility prediction value of the local feature area in the face; and an image recognition module, which is used to recognize whether the image is a synthetic image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area.
[0018] To achieve the above objective, according to a fourth aspect of the present invention, a video detection device is provided.
[0019] The video detection device of the present invention comprises: a detection module, which is used to input multiple frames of pictures in a video into a detection network model to detect the facial area and the local feature area in the face of each frame of the multiple frames; a discrimination module, which is used to input the facial area and the local feature area in the face of each frame of the picture into the discrimination network model respectively to obtain the credibility prediction value of the facial area in the frame of the picture and the credibility prediction value of the local feature area in the face; a video recognition module, which is used to identify whether the video is a synthetic video according to the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area.
[0020] To achieve the above objective, according to a fifth aspect of the present invention, an electronic device is provided.
[0021] The electronic device of the present invention comprises: one or more processors; and a storage device for storing one or more programs; when the one or more programs are executed by the one or more processors, the one or more processors implement the image detection method of the present invention or the video detection method of the present invention.
[0022] To achieve the above objective, according to a sixth aspect of the present invention, a computer readable medium is provided.
[0023] The computer-readable medium of the present invention stores a computer program thereon, and when the program is executed by a processor, the image detection method of the present invention or the video detection method of the present invention is implemented.
[0024] An embodiment of the above invention has the following advantages or beneficial effects: by inputting a picture into a detection network model to detect the facial area and the local feature area in the face in the picture, respectively inputting the facial area and the local feature area in the face in the picture into a discrimination network model to obtain a credibility prediction value of the facial area and a credibility prediction value of the local feature area in the face, and identifying whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area. These steps can improve the accuracy of identifying composite pictures.
[0025] The further effects of the above-mentioned non-conventional optional manner will be described below in conjunction with the specific implementation manner. BRIEF DESCRIPTION OF THE DRAWINGS
[0026] The accompanying drawings are used to better understand the present invention and do not constitute an improper limitation of the present invention.
[0027] Figure 1 is a schematic diagram of the main process of the image detection method according to the first embodiment of the present invention;
[0028] Figure 2 is a schematic diagram of the main flow of the image detection method according to the second embodiment of the present invention;
[0029] Figure 3 is a schematic diagram of the main flow of a video detection method according to a third embodiment of the present invention;
[0030] Figure 4 is a schematic diagram of the main flow of a video detection method according to a fourth embodiment of the present invention;
[0031] Figure 5 is a schematic diagram of main modules of a picture detection device according to a fifth embodiment of the present invention;
[0032] Figure 6 is a schematic diagram of main modules of a video detection device according to a sixth embodiment of the present invention;
[0033] Figure 7 is an exemplary system architecture diagram to which embodiments of the present invention may be applied;
[0034] Figure 8It is a schematic diagram of the structure of a computer system suitable for implementing an electronic device of an embodiment of the present invention. DETAILED DESCRIPTION
[0035] The following is a description of exemplary embodiments of the present invention in conjunction with the accompanying drawings, including various details of the embodiments of the present invention to facilitate understanding, which should be considered as merely exemplary. Therefore, it should be recognized by those of ordinary skill in the art that various changes and modifications may be made to the embodiments described herein without departing from the scope and spirit of the present invention. Similarly, for clarity and conciseness, the description of well-known functions and structures is omitted in the following description.
[0036] It should be pointed out that the embodiments of the present invention and the features in the embodiments may be combined with each other if there is no conflict.
[0037] The present invention proposes a new picture and video detection scheme, which introduces local facial features and global facial features, and uses a multi-module weighted fusion method to enhance the algorithm's identification ability, improve the accuracy of facial composite images, and solve the problem of low accuracy of composite image recognition in the prior art. The picture and video detection scheme provided by the present invention can be applied to various application scenarios such as real-name authentication, face payment, and identity document upload in e-commerce systems, and can also be applied to other application scenarios that require facial image detection.
[0038] Figure 1 FIG. 1 is a schematic diagram of the main flow of the image detection method according to the first embodiment of the present invention. Figure 1 As shown, the picture detection method of the embodiment of the present invention includes:
[0039] Step S101: input a picture into a detection network model to detect a facial area and a local feature area in the face in the picture.
[0040] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial region detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2-fold pooling layer. By inputting the image into the pre-trained MTCNN model, the facial region and the local feature region in the face can be segmented from the image. Among them, the local feature region in the face may include at least one of the following: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0041] In addition, the detection network model can also be a face and facial key feature point detection network model such as FaceNet model, YOLO v3 model, PCN model, RetinaNet model, etc. During specific implementation, the detection network model can be flexibly selected according to the resolution of different pictures and the computing power of the device.
[0042] Step S102: input the facial region and the local feature region in the face in the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region and the credibility prediction value of the local feature region in the face.
[0043] When predicting the credibility of the facial area in the picture and the local feature area in the face, discriminant network models with different structures can be adopted. For example, when predicting the credibility of the facial area in the picture, the VGG16 network model can be adopted; when predicting the credibility of the local feature area in the face, a network model composed of three convolutional layers and a fully connected layer can be adopted. In addition, when predicting the credibility of the facial area in the picture, network models of different depths such as AlexNet, GoogleNet, and ResNet can also be adopted. In addition, without affecting the implementation of the present invention, when predicting the credibility of the facial area in the picture and the local feature area in the face, a discriminant network model with the same structure can also be adopted.
[0044] In an optional example, the facial region in the image is input into a trained VGG16 network model to obtain a predicted authenticity value p0 of the facial region; the four local feature regions, namely, the region where the eyebrows are located, the region where the eyes are located, the region where the nose is located, and the region where the mouth is located, are respectively input into a trained network model consisting of three convolutional layers and a fully connected layer to obtain a predicted authenticity value p1 of the region where the eyebrows are located, a predicted authenticity value p2 of the region where the eyes are located, a predicted authenticity value p3 of the region where the nose is located, and a predicted authenticity value p4 of the region where the mouth is located. Among them, the predicted authenticity value p0 of the facial region is the result of judging the consistency features of the facial region image (such as lighting, tolerance, saturation, smoothness, etc.), and the higher p0 is, the better the basic attributes of the facial region image are, and the higher the credibility is; p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes, and the higher the values of p1~p4 are, the higher the credibility of the local facial features is.
[0045] Step S103: Identify whether the image is a composite image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area.
[0046] Further, step S103 may specifically include: determining the credibility prediction value of the image according to the credibility prediction value of the facial region and the credibility prediction value of the local feature region; comparing the credibility prediction value of the image with a preset threshold; confirming that the image is not a composite image when the credibility prediction value of the image is greater than the preset threshold; confirming that the image is a composite image when the credibility prediction value of the image is less than or equal to the preset threshold. Without affecting the implementation of the present invention, the preset threshold can be flexibly set according to the specific application scenario.
[0047] In an embodiment of the present invention, by detecting the facial area and the local feature area in the face in the picture, the facial area in the picture and the local feature area in the face are respectively input into the discriminant network model to obtain the credibility prediction value of the facial area and the credibility prediction value of the local feature area in the face, and identifying whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area. These steps can improve the identification accuracy of composite pictures and solve the problem of low accuracy of facial composite image detection in the prior art.
[0048] Figure 2 FIG. 2 is a schematic diagram of the main flow of the image detection method according to the second embodiment of the present invention. Figure 2 As shown, the picture detection method of the embodiment of the present invention includes:
[0049] Step S201: input the picture into the detection network model to detect the facial area and the local feature area in the face in the picture.
[0050] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial area detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2x pooling layer. By inputting the picture into the pre-trained MTCNN model, the facial area and the local feature area in the face can be segmented from the picture. In addition, the detection network model can also be a facial and facial key feature point detection network model such as the FaceNet model, the YOLO v3 model, the PCN model, the RetinaNet model, etc. In the specific implementation, the detection network model can be flexibly selected according to the resolution of different pictures and the computing power of the device.
[0051] In the embodiment of the present invention, considering that most face-changing algorithms do not involve the synthesis of ears and ears are often occluded in actual pictures, therefore, in the embodiment of the present invention, the local feature areas in the face include: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0052] Step S202: input the facial region and the local feature region in the face in the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region and the credibility prediction value of the local feature region in the face.
[0053] Among them, the discriminant network model for processing the facial area in the picture can be simply referred to as a "large-scale discriminator network", and the discriminant network model for processing the local feature area in the face can be simply referred to as a "small-scale discriminator network".
[0054] In an optional example, the large-scale discriminator network may use a trained VGG16 network model; the small-scale discriminator network may use a trained network model consisting of three convolutional layers and a fully connected layer. Further, in this optional example, the facial area in the image is input into the trained VGG16 network model to obtain the authenticity prediction value p0 of the facial area; the four local feature areas of the eyebrow area, the eye area, the nose area, and the mouth area are respectively input into a trained network model consisting of three convolutional layers and a fully connected layer to obtain the authenticity prediction value p1 of the eyebrow area, the authenticity prediction value p2 of the eye area, the authenticity prediction value p3 of the nose area, and the authenticity prediction value p4 of the mouth area. Among them, the authenticity prediction value p0 of the facial area is the result of judging the consistency features of the facial area image (such as lighting, tolerance, saturation, smoothness, etc.). The higher the p0, the better the basic attributes of the facial area image and the higher the credibility. p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes. The higher the values of p1~p4, the higher the credibility of the local facial features.
[0055] The following is an explanation of the training process of the small-scale discriminator network. The training process of the small-scale discriminator network mainly includes steps 1 to 4.
[0056] Step 1, construct a training sample set. For example, each batch of training sample sets may include 50 real pictures and 50 synthetic pictures. The training sample sets can be divided into four categories: the first training sample set, which is composed of pictures of the eyebrow area; the second training sample set, which is composed of pictures of the eye area; the third training sample set, which is composed of pictures of the nose area; and the fourth training sample set, which is composed of pictures of the mouth area.
[0057] Step 2: Input each batch of training samples into the small-scale discriminator network, and train each small-scale discriminator network to obtain prediction results. For example, input the first training sample set into the first small-scale discriminator network, the second training sample set into the second small-scale discriminator network, the third training sample set into the third small-scale discriminator network, and the fourth training sample set into the fourth small-scale discriminator network. During the training process, each small-scale discriminator network does not share parameters and is trained separately to ensure that each small-scale discriminator network learns and discriminates separate facial features.
[0058] Step 3: Compare the prediction results with the true source domain and calculate the loss function.
[0059] Step 4: Back-propagate the loss function through the stochastic gradient descent method to optimize the parameters of the small-scale discriminator network; then, input the next batch of training sample sets for training until the loss function converges.
[0060] Step S203: Mapping the space vector point corresponding to the image according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area.
[0061] For example, assuming that the credibility prediction value of the facial area is p0, the authenticity prediction value of the eyebrow area is p1, the authenticity prediction value of the eye area is p2, the authenticity prediction value of the nose area is p3, and the authenticity prediction value of the mouth area is p4, then these five values can be used as five-dimensional coordinates to obtain the spatial vector point P = (p0, p1, p2, p3, p4) corresponding to the image.
[0062] Step S204: Calculate the weighted Euclidean distance between the spatial vector point and the origin of the coordinate system, and use the weighted Euclidean distance as the credibility prediction value of the image.
[0063] In this step, assuming that the spatial vector point P corresponding to the image is (p0, p1, p2, p3, p4), the weighted Euclidean distance between the spatial vector point and the origin of the coordinate system can be calculated according to the following formula:
[0064]
[0065] Among them, α i (i=0-4) represents the weight coefficient, and d represents the weighted Euclidean distance between the spatial vector point and the origin of the coordinate system, that is, the credibility prediction value of the image.
[0066] It should be noted that in other embodiments of the present invention, the credibility prediction value of the image may be calculated in other ways. For example, the credibility prediction value of the image may be calculated according to the following formula:
[0067]
[0068] Among them, α i (i=0-4) represents the weight coefficient, and D represents the credibility prediction value of the image. In specific implementation, different weight coefficients can be assigned to the parameters according to different application scenarios. For example, considering that the degree of change of global facial features, eyes and mouth is usually greater than that of eyebrows and nose, α0, α2, and α4 can be set slightly larger, for example, α0 to α4 can be set to: 3, 1, 3, 1, 2.
[0069] Step S205: determine whether the credibility prediction value of the image is greater than a preset threshold.
[0070] The preset threshold value can be flexibly set according to the specific application scenario. For example, different preset threshold values can be set according to different risk levels. When the credibility prediction value of the image is greater than the preset threshold value, step S206 is executed; when the credibility prediction value of the image is less than or equal to the preset threshold value, step S207 is executed.
[0071] Step S206: Determine whether the picture is a composite picture.
[0072] Step S207: Determine whether the picture is a composite picture.
[0073] In an embodiment of the present invention, by segmenting a facial area and a local feature area in the face from a picture, then determining a credibility prediction value of the facial area and a credibility prediction value of the local feature area through a discriminant network model, and then obtaining a spatial vector point through mapping, and using the weighted Euclidean distance between the spatial vector point and the coordinate origin as the credibility prediction value of the picture, etc., the identification accuracy of the composite picture can be improved, and the problem of low accuracy in facial composite image detection existing in the prior art can be solved.
[0074] Figure 3 FIG. 4 is a schematic diagram of the main flow of the video detection method according to the third embodiment of the present invention. Figure 3 As shown, the video detection method of the embodiment of the present invention includes:
[0075] Step S301: input multiple frames of images in the video into a detection network model to detect the facial area and local feature areas in each frame of the multiple frames.
[0076] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial region detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2x pooling layer. By inputting multiple frames of images in the video into the pre-trained MTCNN model, the facial region and the local feature region in the face can be segmented from each frame. Among them, the local feature region in the face may include at least one of the following: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0077] In addition, the detection network model can also be a face and facial key feature point detection network model such as FaceNet model, YOLO v3 model, PCN model, RetinaNet model, etc. During specific implementation, the detection network model can be flexibly selected according to the resolution of different pictures and the computing power of the device.
[0078] Step S302: input the facial region and the local feature region in each frame of the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region in the frame of the image and the credibility prediction value of the local feature region in the face.
[0079] When predicting the credibility of a facial region in a frame of an image or a local feature region in a face, discriminant network models of different structures may be used. For example, when predicting the credibility of a facial region in a frame of an image, a VGG16 network model may be used; when predicting the credibility of a local feature region in the face in the frame of an image, a network model consisting of three convolutional layers and a fully connected layer may be used. In addition, when predicting the credibility of a facial region in a frame of an image, network models of different depths such as AlexNet, GoogleNet, and ResNet may also be used. In addition, without affecting the implementation of the present invention, when predicting the credibility of a facial region in a frame of an image or a local feature region in a face, a discriminant network model of the same structure may also be used.
[0080] In an optional example, the facial region in a frame of image is input into a trained VGG16 network model to obtain a predicted authenticity value p0 of the facial region; the four local feature regions of the eyebrow region, the eye region, the nose region, and the mouth region in the frame of image are respectively input into a trained network model composed of three convolutional layers and a fully connected layer to obtain a predicted authenticity value p1 of the eyebrow region, a predicted authenticity value p2 of the eye region, a predicted authenticity value p3 of the nose region, and a predicted authenticity value p4 of the mouth region. Among them, the predicted authenticity value p0 of the facial region is the result of judging the consistency features of the facial region image (such as illumination, tolerance, saturation, smoothness, etc.), and the higher p0 is, the better the basic attributes of the facial region image are, and the higher the credibility is; p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes, and the higher the values of p1~p4 are, the higher the credibility of the local facial features is.
[0081] Step S303: Identify whether the video is a synthetic video based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area in each frame of the picture.
[0082] In an embodiment of the present invention, when performing synthetic video detection, not only the global features of the face in multiple frames of pictures are taken into account, but also the local features of the face are taken into account. The facial area in each frame of the picture and the local feature area in the face are respectively input into the discriminant network model to obtain the credibility prediction value of the facial area in the frame of the picture and the credibility prediction value of the local feature area in the face, and synthetic video detection is performed based on the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area. This can improve the identification accuracy of the synthetic video and solve the problem of low accuracy of facial synthetic video detection in the prior art.
[0083] Figure 4 FIG. 4 is a schematic diagram of the main flow of the video detection method according to the fourth embodiment of the present invention. Figure 4 As shown, the video detection method of the embodiment of the present invention includes:
[0084] Step S401: input multiple frames of images in the video into a detection network model to detect the facial area and local feature areas in each frame of the multiple frames.
[0085] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial area detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2x pooling layer. By inputting multiple frames of images in the video into the pre-trained MTCNN model, the facial area and the local feature area in the face can be segmented from each frame. In addition, the detection network model can also be a facial and facial key feature point detection network model such as the FaceNet model, the YOLO v3 model, the PCN model, the RetinaNet model, etc. In the specific implementation, the detection network model can be flexibly selected according to the resolution of different images and the computing power of the device.
[0086] In the embodiment of the present invention, considering that most face-changing algorithms do not involve the synthesis of ears and ears are often occluded in actual pictures, therefore, in the embodiment of the present invention, the local feature areas in the face include: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0087] Step S402: input the facial region and the local feature region in each frame of the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region in the frame of the image and the credibility prediction value of the local feature region in the face.
[0088] Among them, the discriminant network model for processing the facial area in a frame of picture can be referred to as a "large-scale discriminator network", and the discriminant network model for processing the local feature area of the face in a frame of picture can be referred to as a "small-scale discriminator network".
[0089] In an optional example, the large-scale discriminator network may use a trained VGG16 network model; the small-scale discriminator network may use a trained network model consisting of three convolutional layers and a fully connected layer. Further, in this optional example, the facial area in a frame of the picture is input into the trained VGG16 network model to obtain the authenticity prediction value p0 of the facial area; the four local feature areas of the eyebrow area, the eye area, the nose area, and the mouth area in the frame of the picture are respectively input into a trained network model consisting of three convolutional layers and a fully connected layer to obtain the authenticity prediction value p1 of the eyebrow area, the authenticity prediction value p2 of the eye area, the authenticity prediction value p3 of the nose area, and the authenticity prediction value p4 of the mouth area. Among them, the authenticity prediction value p0 of the facial area is the result of judging the consistency features of the facial area image (such as lighting, tolerance, saturation, smoothness, etc.). The higher the p0, the better the basic attributes of the facial area image and the higher the credibility. p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes. The higher the values of p1~p4, the higher the credibility of the local facial features.
[0090] Step S403: Mapping the space vector point corresponding to each frame of the image according to the credibility prediction value of the facial region and the credibility prediction value of the local feature region in each frame of the image.
[0091] For example, assuming that the credibility prediction value of the facial area in a frame of image is p0, the authenticity prediction value of the eyebrow area is p1, the authenticity prediction value of the eye area is p2, the authenticity prediction value of the nose area is p3, and the authenticity prediction value of the mouth area is p4, then these five values can be used as five-dimensional coordinates to obtain the spatial vector point P = (p0, p1, p2, p3, p4) corresponding to the frame of image.
[0092] Step S404: Determine the discreteness of the space vector points corresponding to the multiple frames of images.
[0093] In an optional example, step S404 may specifically include: taking each spatial vector point as the center point of a cluster, calculating the sum of the distances from other spatial vector points to the spatial vector point, and taking the sum of the distances as the cluster discreteness with the spatial vector point as the center point; taking the minimum value of the cluster discreteness with each spatial vector point as the center point as the discreteness of the spatial vector point corresponding to the multiple frames of images.
[0094] For example, assuming that there are three frames of pictures in the video to be detected, and the spatial vector points corresponding to the three frames of pictures can be expressed as P1, P2, and P3, then P1 can be used as the cluster center point, and the sum of the distances from P2 and P3 to P1, V1, can be calculated; with P2 as the cluster center point, the sum of the distances from P1 and P3 to P2, V2, can be calculated; with P3 as the cluster center point, the sum of the distances from P1, P2 to P3, V3, can be calculated; and then the minimum value among V1, V2, and V3 can be used as the discreteness of the spatial vector points corresponding to the three frames of pictures. In specific implementation, when calculating the distance between spatial vector points, the Mahalanobis distance calculation formula or other distance calculation formulas can be used. In addition, without affecting the implementation of the present invention, in addition to using the method in the above optional example to calculate the discreteness, a hierarchical clustering algorithm, a graph cut algorithm, etc. can also be used to perform cluster analysis and discreteness calculation on the spatial vector points corresponding to the multiple frames of pictures.
[0095] Step S405: determine whether the discreteness is greater than a preset threshold.
[0096] The lower the value of the discreteness, the higher the credibility of the video; the higher the value of the discreteness, the lower the credibility of the video. The preset threshold can be flexibly set according to the specific application scenario. For example, different preset thresholds can be set according to different risk levels. When the discreteness of the spatial vector points corresponding to the multiple frames of images is greater than the preset threshold, step S406 is executed; when the discreteness of the spatial vector points corresponding to the multiple frames of images is less than or equal to the preset threshold, step S407 is executed.
[0097] Step S406: Determine whether the video is a composite video.
[0098] Step S407: Determine whether the video is a composite video.
[0099] In an embodiment of the present invention, by segmenting the facial area and the local feature area in the face from multiple frames of pictures in a video, and then determining the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area through a discriminant network model, and then obtaining the spatial vector point corresponding to the frame of the picture through mapping, and calculating the discreteness of the spatial vector points corresponding to multiple frames of pictures, etc., the identification accuracy of the synthetic video can be improved, and the problem of low accuracy in facial synthetic video detection existing in the prior art can be solved.
[0100] Figure 5 FIG. 4 is a schematic diagram of the main modules of the image detection device according to the fifth embodiment of the present invention. Figure 5 As shown, the image detection device 500 according to the embodiment of the present invention includes: a detection module 501 , a discrimination module 502 , and an image recognition module 503 .
[0101] The detection module 501 is used to input the image into the detection network model to detect the facial area and the local feature area in the face in the image.
[0102] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial region detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2-fold pooling layer. By inputting the image into the pre-trained MTCNN model, the facial region and the local feature region in the face can be segmented from the image. Among them, the local feature region in the face may include at least one of the following: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0103] In addition, the detection network model can also be a face and facial key feature point detection network model such as FaceNet model, YOLO v3 model, PCN model, RetinaNet model, etc. During specific implementation, the detection network model can be flexibly selected according to the resolution of different pictures and the computing power of the device.
[0104] The discriminant module 502 is used to input the facial region and the local feature region in the face in the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region and the credibility prediction value of the local feature region in the face.
[0105] When predicting the credibility of the facial area in the picture and the local feature area in the face, discriminant network models with different structures can be adopted. For example, when predicting the credibility of the facial area in the picture, the VGG16 network model can be adopted; when predicting the credibility of the local feature area in the face, a network model composed of three convolutional layers and a fully connected layer can be adopted. In addition, when predicting the credibility of the facial area in the picture, network models of different depths such as AlexNet, GoogleNet, and ResNet can also be adopted. In addition, without affecting the implementation of the present invention, when predicting the credibility of the facial area in the picture and the local feature area in the face, a discriminant network model with the same structure can also be adopted.
[0106] In an optional example, the facial region in the image is input into a trained VGG16 network model to obtain a predicted authenticity value p0 of the facial region; the four local feature regions, namely, the region where the eyebrows are located, the region where the eyes are located, the region where the nose is located, and the region where the mouth is located, are respectively input into a trained network model consisting of three convolutional layers and a fully connected layer to obtain a predicted authenticity value p1 of the region where the eyebrows are located, a predicted authenticity value p2 of the region where the eyes are located, a predicted authenticity value p3 of the region where the nose is located, and a predicted authenticity value p4 of the region where the mouth is located. Among them, the predicted authenticity value p0 of the facial region is the result of judging the consistency features of the facial region image (such as lighting, tolerance, saturation, smoothness, etc.), and the higher p0 is, the better the basic attributes of the facial region image are, and the higher the credibility is; p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes, and the higher the values of p1~p4 are, the higher the credibility of the local facial features is.
[0107] The picture identification module 503 is used to identify whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area.
[0108] Exemplarily, the picture recognition module 503 identifies whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area, which may specifically include: the picture recognition module 503 determines the credibility prediction value of the picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area; the picture recognition module 503 compares the credibility prediction value of the picture with a preset threshold; when the credibility prediction value of the picture is greater than the preset threshold, the picture recognition module 503 confirms that the picture is not a composite picture; when the credibility prediction value of the picture is less than or equal to the preset threshold, the picture recognition module 503 confirms that the picture is a composite picture. Without affecting the implementation of the present invention, the preset threshold can be flexibly set according to the specific application scenario.
[0109] In the device of the embodiment of the present invention, the facial area and the local feature area in the face in the picture are detected by the detection module, and the facial area and the local feature area in the face in the picture are respectively input into the discriminant network model by the discrimination module to obtain the credibility prediction value of the facial area and the credibility prediction value of the local feature area in the face. The picture recognition module identifies whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area, which can improve the identification accuracy of the composite picture and solve the problem of low accuracy of facial composite image detection in the prior art.
[0110] Figure 6FIG. 4 is a schematic diagram of the main modules of a video detection device according to a sixth embodiment of the present invention. Figure 6 As shown, the video detection device 600 according to the embodiment of the present invention includes: a detection module 601 , a discrimination module 602 , and a video recognition module 603 .
[0111] The detection module 601 is used to input multiple frames of pictures in the video into the detection network model to detect the facial area and local feature areas in each frame of the multiple frames.
[0112] Exemplarily, the detection network model can be a pre-trained MTCNN (multi-task convolutional neural network) model. The MTCNN model combines facial region detection with local feature detection in the face, and its network structure includes three 3x3 convolutional layers and a 2x pooling layer. By inputting multiple frames of images in the video into the pre-trained MTCNN model, the facial region and the local feature region in the face can be segmented from each frame. Among them, the local feature region in the face may include at least one of the following: the area where the eyebrows are located, the area where the eyes are located, the area where the nose is located, and the area where the mouth is located.
[0113] In addition, the detection network model can also be a face and facial key feature point detection network model such as FaceNet model, YOLO v3 model, PCN model, RetinaNet model, etc. During specific implementation, the detection network model can be flexibly selected according to the resolution of different pictures and the computing power of the device.
[0114] The discrimination module 602 is used to input the facial area and the local feature area in each frame of the image into the discrimination network model respectively to obtain the credibility prediction value of the facial area in the frame of the image and the credibility prediction value of the local feature area in the face.
[0115] When predicting the credibility of a facial region in a frame of an image or a local feature region in a face, discriminant network models of different structures may be used. For example, when predicting the credibility of a facial region in a frame of an image, a VGG16 network model may be used; when predicting the credibility of a local feature region in the face in the frame of an image, a network model consisting of three convolutional layers and a fully connected layer may be used. In addition, when predicting the credibility of a facial region in a frame of an image, network models of different depths such as AlexNet, GoogleNet, and ResNet may also be used. In addition, without affecting the implementation of the present invention, when predicting the credibility of a facial region in a frame of an image or a local feature region in a face, a discriminant network model of the same structure may also be used.
[0116] In an optional example, the facial region in a frame of image is input into a trained VGG16 network model to obtain a predicted authenticity value p0 of the facial region; the four local feature regions of the eyebrow region, the eye region, the nose region, and the mouth region in the frame of image are respectively input into a trained network model composed of three convolutional layers and a fully connected layer to obtain a predicted authenticity value p1 of the eyebrow region, a predicted authenticity value p2 of the eye region, a predicted authenticity value p3 of the nose region, and a predicted authenticity value p4 of the mouth region. Among them, the predicted authenticity value p0 of the facial region is the result of judging the consistency features of the facial region image (such as illumination, tolerance, saturation, smoothness, etc.), and the higher p0 is, the better the basic attributes of the facial region image are, and the higher the credibility is; p1~p4 are the results of judging the appearance features of local images such as eyebrows and eyes, and the higher the values of p1~p4 are, the higher the credibility of the local facial features is.
[0117] The video identification module 603 is used to identify whether the video is a synthetic video based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area in each frame of the picture.
[0118] Exemplarily, the video recognition module 603 identifies whether the video is a composite video based on the credibility prediction value of the facial area in each frame and the credibility prediction value of the local feature area. The specific steps include: the video recognition module 603 maps the spatial vector points corresponding to the frame image based on the credibility prediction value of the facial area in each frame image and the credibility prediction value of the local feature area; the video recognition module 603 determines the discreteness of the spatial vector points corresponding to the multiple frames of images; when the discreteness is greater than a preset threshold, the video recognition module 603 confirms that the video is a composite video; when the discreteness is less than or equal to the preset threshold, the video recognition module 603 confirms that the video is not a composite video.
[0119] Among them, the video recognition module 603 determines the discreteness of the spatial vector points corresponding to the multiple frames of pictures, which can specifically include: the video recognition module 603 takes each spatial vector point as the center point of a cluster, calculates the sum of the distances from other spatial vector points to the spatial vector point, and takes the sum of the distances as the discreteness of the cluster with the spatial vector point as the center point; the video recognition module 603 takes the minimum value of the discreteness of the cluster with each spatial vector point as the center point as the discreteness of the spatial vector points corresponding to the multiple frames of pictures.
[0120] In an embodiment of the present invention, when performing synthetic video detection, not only the global features of the face in multiple frames of pictures are considered, but also the local features of the face are considered. The facial area in each frame of the picture and the local feature area in the face are respectively input into the discriminant network model through the discrimination module to obtain the credibility prediction value of the facial area in the frame of the picture and the credibility prediction value of the local feature area in the face. The video recognition module performs synthetic video detection based on the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area, which can improve the identification accuracy of the synthetic video and solve the problem of low accuracy of facial synthetic video detection in the prior art.
[0121] Figure 7 An exemplary system architecture 700 to which the picture detection method or video detection method or picture detection device or video detection device according to the embodiment of the present invention can be applied is shown.
[0122] like Figure 7 As shown, system architecture 700 may include terminal devices 701, 702, 703, network 704 and server 705. Network 704 is used to provide a medium for communication links between terminal devices 701, 702, 703 and server 705. Network 704 may include various connection types, such as wired, wireless communication links or optical fiber cables, etc.
[0123] Users can use terminal devices 701, 702, and 703 to interact with server 705 through network 704 to receive or send messages, etc. Various communication client applications can be installed on terminal devices 701, 702, and 703, such as shopping applications, web browser applications, search applications, instant messaging tools, email clients, social platform software, etc.
[0124] The terminal devices 701 , 702 , and 703 may be various electronic devices having a display screen and supporting web browsing, including but not limited to smart phones, tablet computers, laptop computers, and desktop computers.
[0125] The server 705 may be a server that provides various services, such as a background management server that provides support for shopping websites browsed by users using the terminal devices 701, 702, and 703. The background management server may analyze and process the received facial images or videos, and feed back the processing results (such as facial image detection results) to the terminal device.
[0126] It should be noted that the image detection method or video detection method provided in the embodiment of the present invention is generally executed by the server 705 , and accordingly, the image detection device or video detection device is generally disposed in the server 705 .
[0127] It should be understood that Figure 7 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.
[0128] Reference below Figure 8 , which shows a schematic diagram of the structure of a computer system 800 of an electronic device suitable for implementing an embodiment of the present invention. Figure 8 The computer system shown is only an example and should not bring any limitation to the functions and scope of use of the embodiments of the present invention.
[0129] like Figure 8 As shown, the computer system 800 includes a central processing unit (CPU) 801, which can perform various appropriate actions and processes according to a program stored in a read-only memory (ROM) 802 or a program loaded from a storage part 808 into a random access memory (RAM) 803. In the RAM 803, various programs and data required for the operation of the system 800 are also stored. The CPU 801, the ROM 802, and the RAM 803 are connected to each other via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.
[0130] The following components are connected to the I / O interface 805: an input section 806 including a keyboard, a mouse, etc.; an output section 807 including a cathode ray tube (CRT), a liquid crystal display (LCD), etc., and a speaker, etc.; a storage section 808 including a hard disk, etc.; and a communication section 809 including a network interface card such as a LAN card, a modem, etc. The communication section 809 performs communication processing via a network such as the Internet. A drive 810 is also connected to the I / O interface 805 as needed. A removable medium 811, such as a magnetic disk, an optical disk, a magneto-optical disk, a semiconductor memory, etc., is installed on the drive 810 as needed, so that a computer program read therefrom is installed into the storage section 808 as needed.
[0131] In particular, according to the embodiments disclosed in the present invention, the process described above with reference to the flowchart can be implemented as a computer software program. For example, the embodiments disclosed in the present invention include a computer program product, which includes a computer program carried on a computer-readable medium, and the computer program includes a program code for executing the method shown in the flowchart. In such an embodiment, the computer program can be downloaded and installed from the network through the communication part 809, and / or installed from the removable medium 811. When the computer program is executed by the central processing unit (CPU) 801, the above-mentioned functions defined in the system of the present invention are executed.
[0132] It should be noted that the computer-readable medium shown in the present invention may be a computer-readable signal medium or a computer-readable storage medium or any combination of the above two. The computer-readable storage medium may be, for example, but not limited to, an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, device or device, or any combination of the above. More specific examples of computer-readable storage media may include, but are not limited to: an electrical connection with one or more wires, a portable computer disk, a hard disk, a random access memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disk read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the above. In the present invention, a computer-readable storage medium may be any tangible medium containing or storing a program that can be used by or in combination with an instruction execution system, device or device. In the present invention, a computer-readable signal medium may include a data signal propagated in a baseband or as part of a carrier wave, which carries a computer-readable program code. This propagated data signal may take a variety of forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination of the above. Computer-readable signal media may also be any computer-readable medium other than computer-readable storage media, which may send, propagate or transmit a program for use by or in conjunction with an instruction execution system, apparatus or device. The program code contained on the computer-readable medium may be transmitted using any appropriate medium, including but not limited to: wireless, wire, optical cable, RF, etc., or any suitable combination of the above.
[0133] The flow chart and block diagram in the accompanying drawings illustrate the possible architecture, function and operation of the system, method and computer program product according to various embodiments of the present invention. In this regard, each box in the flow chart or block diagram can represent a module, a program segment, or a part of a code, and the above-mentioned module, program segment, or a part of a code contains one or more executable instructions for realizing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two boxes represented in succession can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram or flow chart, and the combination of the boxes in the block diagram or flow chart can be implemented with a dedicated hardware-based system that performs a specified function or operation, or can be implemented with a combination of dedicated hardware and computer instructions.
[0134] The modules involved in the embodiments of the present invention may be implemented by software or hardware. The modules described may also be set in a processor, for example, it may be described as: a processor includes a detection module, a discrimination module and a recognition module. The names of these modules do not constitute a limitation on the modules themselves in some cases, for example, the detection module may also be described as "a module for segmenting a facial area and a local feature area in a face from a picture".
[0135] As another aspect, the present invention also provides a computer-readable medium, which may be included in the device described in the above embodiment; or it may exist independently without being assembled into the device. The above computer-readable medium carries one or more programs, and when the above one or more programs are executed by a device, the device executes the following process: inputting a picture into a detection network model to detect the facial area and the local feature area in the face in the picture; inputting the facial area and the local feature area in the face in the picture into a discriminant network model respectively to obtain the credibility prediction value of the facial area and the credibility prediction value of the local feature area in the face; according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area, identifying whether the picture is a synthetic picture.
[0136] The above specific implementations do not constitute a limitation on the protection scope of the present invention. It should be understood by those skilled in the art that various modifications, combinations, sub-combinations and substitutions may occur depending on design requirements and other factors. Any modification, equivalent substitution and improvement made within the spirit and principle of the present invention shall be included in the protection scope of the present invention.
Claims
1. A picture detection method, characterized in that: The method comprises: Inputting the image into the detection network model to detect the facial area and the local feature area in the face in the image; Inputting the facial region and the local feature region in the face in the image into the discriminant network model respectively to obtain the credibility prediction value of the facial region and the credibility prediction value of the local feature region in the face; According to the credibility prediction value of the facial area and the credibility prediction value of the local feature area, identify whether the image is a composite image; specifically including: mapping the spatial vector point corresponding to the image according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area; calculating the weighted Euclidean distance between the spatial vector point and the origin of the coordinate system, and using the weighted Euclidean distance as the credibility prediction value of the image.
2. The method according to claim 1, characterized in that The identifying whether the picture is a composite picture according to the credibility prediction value of the facial area and the credibility prediction value of the local feature area comprises: Determine the credibility prediction value of the image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area; compare the credibility prediction value of the image with a preset threshold; when the credibility prediction value of the image is greater than the preset threshold, confirm that the image is not a composite image; when the credibility prediction value of the image is less than or equal to the preset threshold, confirm that the image is a composite image.
3. The method according to claim 1, characterized in that The local feature areas in the face include: an area where eyebrows are located, an area where eyes are located, an area where nose is located, and an area where mouth is located.
4. A video detection method, characterized in that: The method comprises: Inputting multiple frames of pictures in the video into the detection network model to detect the facial area and local feature areas in each frame of the multiple frames; Inputting the facial region and the local feature region in each frame of the picture into the discriminant network model respectively to obtain the credibility prediction value of the facial region in the frame of the picture and the credibility prediction value of the local feature region in the face; According to the credibility prediction value of the facial area in each frame and the credibility prediction value of the local feature area, identify whether the video is a composite video; specifically including: mapping the spatial vector points corresponding to the frame image according to the credibility prediction value of the facial area in each frame image and the credibility prediction value of the local feature area; determining the discreteness of the spatial vector points corresponding to the multiple frames of images; when the discreteness is greater than a preset threshold, confirming that the video is a composite video; when the discreteness is less than or equal to the preset threshold, confirming that the video is not a composite video.
5. The method according to claim 4, characterized in that The determining of the discreteness of the space vector points corresponding to the multiple frames of pictures comprises: Each spatial vector point is taken as the center point of a cluster, the sum of the distances from other spatial vector points to the spatial vector point is calculated, and the sum of the distances is taken as the discreteness of the cluster with the spatial vector point as the center point; the minimum value of the discreteness of the cluster with each spatial vector point as the center point is taken as the discreteness of the spatial vector point corresponding to the multiple frames of images.
6. The method according to claim 4, characterized in that The local feature areas in the face include: an area where eyebrows are located, an area where eyes are located, an area where nose is located, and an area where mouth is located.
7. A picture detection device, characterized in that: The device comprises: A detection module, used for inputting an image into a detection network model to detect a facial region and a local feature region in the face in the image; A discriminant module, used for inputting the facial region and the local feature region in the face in the picture into a discriminant network model respectively, so as to obtain a credibility prediction value of the facial region and a credibility prediction value of the local feature region in the face; The image recognition module is used to identify whether the image is a composite image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area; specifically, it is used to map the space vector point corresponding to the image based on the credibility prediction value of the facial area and the credibility prediction value of the local feature area; calculate the weighted Euclidean distance between the space vector point and the origin of the coordinate system, and use the weighted Euclidean distance as the credibility prediction value of the image.
8. A video detection device, characterized in that: The device comprises: A detection module, used to input multiple frames of images in the video into a detection network model to detect the facial area and local feature areas in each frame of the multiple frames; A discriminant module, used for inputting the facial region and the local feature region in each frame of the picture into the discriminant network model respectively, so as to obtain the credibility prediction value of the facial region in the frame of the picture and the credibility prediction value of the local feature region in the face; A video recognition module is used to identify whether the video is a composite video based on the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area; specifically, it is used to map the spatial vector points corresponding to the frame of the picture based on the credibility prediction value of the facial area in each frame of the picture and the credibility prediction value of the local feature area; determine the discreteness of the spatial vector points corresponding to the multiple frames of the picture; when the discreteness is greater than a preset threshold, confirm that the video is a composite video; when the discreteness is less than or equal to the preset threshold, confirm that the video is not a composite video.
9. An electronic device, characterized in that: include: one or more processors; a storage device for storing one or more programs, When the one or more programs are executed by the one or more processors, the one or more processors implement the method according to any one of claims 1 to 3.
10. A computer readable medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, the method according to any one of claims 1 to 3 is implemented.
Citation Information
Patent Citations
Side face recognition method based on kernel standard correlation analysis
CN107292299A
Pupil-based living body detection method and device, server and storage medium
CN109684945A