Method for detecting fake video, and recognition device and server
By filtering suspicious frames on the recognition device side and using a lightweight model for high-performance detection on the server side, the security problem of fake video detection in facial recognition technology is solved, and fast and accurate fake video recognition is achieved.
Patent Information
- Application Number
- PCT/CN2024/128709
- Authority / Receiving Office
- WO · WO
- Patent Type
- Applications
- Current Assignee / Owner
- Priority Date
- 2024-08-02
- Filing Date
- 2024-10-31
- Publication Date
- 2026-02-05
AI Technical Summary
Existing facial recognition technology cannot effectively detect deepfake videos, posing a security risk, especially since the facial capture SDK cannot determine whether the camera data stream is actually captured.
A lightweight detection model is deployed on the identification device side to screen suspicious frames and send them to the server for high-performance detection. The model combines multi-task model and neural network to detect anomalies in the video to determine whether the video is fake.
It improves the speed and accuracy of detecting fake videos, reduces data traffic, and increases the speed and accuracy of prediction results.
Smart Images

Figure CN2024128709_05022026_PF_FP_ABST
Abstract
Description
Method for detecting fake video, identification device and server
[0001] The present application claims priority to the Chinese patent application No. 202411063826.2, filed on August 2, 2024, and entitled "Method for detecting fake video, identification device and server", the content of which is incorporated herein by reference in its entirety. TECHNICAL FIELD
[0002] Embodiments of the present specification belong to the technical field of image processing, and particularly relate to a fake video detection method, an identification device and a server. BACKGROUND
[0003] Face recognition technology has been widely applied in recent years and has become an important biometric means. Face recognition technology recognizes individual identity by capturing and analyzing facial images. Its workflow usually includes the following steps: detecting and locating the face region from the image or video stream; extracting the feature points of the face, such as the positions of the eyes, nose and mouth and their relative distances; matching the extracted features with known facial features in the database to determine the identity.
[0004] With the development of deepfake technology, malicious parties can fake videos for face recognition through deepfake technology, bypass the camera of the mobile device (such as a mobile phone) by camera injection, and inject pre-generated or real-time generated deepfake video streams into the system. In the current system, the face capture SDK determines multiple high-quality images from the video source on the client side, and sends the multiple high-quality images to the server for face recognition. Among them, the face capture SDK cannot determine whether the camera data stream is truly captured by the camera. The server is relatively difficult to detect fake videos through deepfake detection technology with respect to the multiple high-quality images sent by the client. Therefore, the current face recognition technology has certain insecurity.
[0005] SUMMARY
[0006] The purpose of the present application is to provide a method for detecting fake videos to improve the speed and accuracy of detecting fake videos.
[0007] The first aspect of the present specification provides a method for detecting fake videos, executed by an identification device, comprising:
[0008] For n frames in a target video, an abnormal score output by each detection network with respect to each frame in the n frames is obtained through one or more detection networks, wherein the one or more detection networks correspond to one or more abnormal situations included in an existing fake video;
[0009] selecting one or more first frames from the n frames according to the abnormal scores of the n frames;
[0010] sending the one or more first frames to a server for determining whether the target video is a fake video.
[0011] In an embodiment, the identification device is configured to perform face recognition, and the one or more detection networks include a first detection network, and the first abnormal score output by the first detection network with respect to a frame image indicates a degree of face distortion in the frame image.
[0012] The selecting one or more first frames from the n frames according to the abnormal scores of the n frames includes:
[0013] selecting m first frames from the n frames according to the first abnormal scores of the n frames output by the first detection network.
[0014] In an embodiment, the one or more detection networks include one or more second detection networks, and the one or more second detection networks correspond to at least one of the following abnormal situations: a frame or multiple frames in a video include a frame border; a frame or multiple frames in a video include face replacement abnormality; a frame or multiple frames in a video include a watermark; backgrounds of consecutive multiple frames in a video are discontinuous; backgrounds of multiple frames in a video come from the same image.
[0015] In an embodiment, the one or more detection networks include multiple second detection networks, and the selecting one or more first frames from the n frames according to the abnormal scores of the n frames includes, for each frame in the n frames, obtaining an abnormal score output by each second detection network, obtaining a weighted sum of the abnormal scores of the multiple second detection networks to obtain a second abnormal score of the frame, and selecting k first frames from the n frames according to the second abnormal scores of the frames.
[0016] In an embodiment, the first detection model and the multiple second detection networks constitute a multi-task model, and the multi-task model is trained based on multiple first training samples, the first training samples include a video and first label values corresponding to the first detection model and each detection network in the multiple second detection networks, and the first label values include corresponding abnormal scores of each frame of the video.
[0017] In an embodiment, the first detection model is trained based on multiple second training samples, the second training samples include a video and second label values, and the second label values include abnormal scores of each frame of the video.
[0018] A second aspect of the present specification provides a fake video detection method, executed by a server, including:
[0019] receive, from a recognition device, one or more first frames, the one or more first frames being frames in a target video and selected by one or more detection networks in the recognition device, the one or more detection networks corresponding to one or more abnormal situations included in existing fake videos;
[0020] process the one or more first frames to determine whether the target video is a fake video.
[0021] In an implementation, the processing the one or more first frames to determine whether the target video is a fake video includes processing the one or more first frames based on one or more third detection networks locally to determine whether the target video is a fake video, the one or more third detection networks corresponding to the one or more abnormal situations.
[0022] A third aspect of the present specification provides a recognition device, comprising:
[0023] an obtaining unit configured to, for n frames in a target video, obtain, by one or more detection networks, an abnormal score output by each detection network with respect to each frame in the n frames, wherein the one or more detection networks correspond to one or more abnormal situations included in existing fake videos;
[0024] a selecting unit configured to select one or more first frames from the n frames according to the abnormal scores of the n frames;
[0025] a sending unit configured to send the one or more first frames to a server for determining whether the target video is a fake video.
[0026] A fourth aspect of the present specification provides a server, comprising:
[0027] a receiving unit configured to receive, from a recognition device, one or more first frames, the one or more first frames being frames in a target video and selected by one or more detection networks in the recognition device, the one or more detection networks corresponding to one or more abnormal situations included in existing fake videos;
[0028] a processing unit configured to process the one or more first frames to determine whether the target video is a fake video.
[0029] A fifth aspect of the present specification provides a computing device, comprising a memory and a processor, the memory storing executable code, and the processor executing the executable code to implement the method in the first aspect or the second aspect.
[0030] The sixth aspect of the specification provides a computer program product comprising computer programs / instructions which, when executed by a processor, implement the steps of the method of the first aspect or the second aspect.
[0031] In the embodiments of the specification, on the identification device side, suspicious frames in the video are screened out by a lightweight detection model and sent to the server, and the high-performance detection model on the server side detects these images to determine whether the video is a fake video, thereby balancing the prediction speed and prediction accuracy. BRIEF DESCRIPTION OF DRAWINGS
[0032] In order to more clearly illustrate the technical solutions of the embodiments of the specification, the drawings needed in the embodiment description will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments described in the specification, and for those skilled in the art, other drawings can also be obtained without creative labor.
[0033] FIG. 1 is an architecture diagram of a fake video detection system in an embodiment of the specification;
[0034] FIG. 2 is a flowchart of a method for detecting fake videos in an embodiment of the specification;
[0035] FIG. 3 is a schematic diagram of a multi-task model in an embodiment of the specification;
[0036] FIG. 4 is a schematic diagram of a process of detecting a video by a detection network 11 in an embodiment of the specification;
[0037] FIG. 5 is a schematic diagram of an abnormal situation in a fake video in an embodiment of the specification;
[0038] FIG. 6 is a schematic diagram of another abnormal situation in a fake video in an embodiment of the specification;
[0039] FIG. 7 is an architecture diagram of an identification device in an embodiment of the specification;
[0040] FIG. 8 is an architecture diagram of a server in an embodiment of the specification. DETAILED DESCRIPTION
[0041] In order for those skilled in the art to better understand the technical solutions in the specification, the technical solutions in the embodiments of the specification will be described clearly and completely below in conjunction with the drawings in the embodiments of the specification. Obviously, the described embodiments are only some embodiments of the specification, not all embodiments. Based on the embodiments in the specification, all other embodiments obtained by those skilled in the art without creative labor should be within the scope of protection of the specification.
[0042] In order to solve the security problem in object recognition caused by deepfake technology, an embodiment of the present specification provides a method for detecting a fake video, wherein, on the side of a recognition device, a suspicious frame in a video is screened out by a lightweight detection model, and is sent to a server, and the server side uses a high-performance detection model to detect the suspicious frame, so as to determine whether the video is a fake video, thereby balancing the prediction speed and the prediction accuracy.
[0043] FIG. 1 is an architecture diagram of a fake video detection system in an embodiment of the present specification. As shown in FIG. 1, the system includes a recognition device 100 and a server 200. In the scenario of face recognition, the recognition device 100 is, for example, a mobile phone, a tablet, a face recognition device in an airport or a train station, etc. It can be understood that the scheme in the embodiments of the present specification is not limited to the scenario of face recognition, but can be applied to other object recognition scenarios, such as scenarios of identification of certificates, evidence, etc. through a recognition device.
[0044] A plurality of lightweight detection networks for detecting suspicious frames in a video can be deployed in the recognition device 100, such as detection network 11, detection network 12, etc. These detection networks can be neural networks such as convolutional neural networks (CNN) and recurrent neural networks (RNN). Each detection network can correspond to an abnormal situation in a fake video, i.e., different detection networks are used to detect different abnormal situations in a fake video. The above-mentioned abnormal situations can include, for example, the following abnormal situations: a frame or multiple frames in a video include a frame; a frame or multiple frames in a video include face replacement abnormalities; a frame or multiple frames in a video include a watermark; the background of consecutive multiple frames in a video is discontinuous; the background of multiple frames in a video comes from the same image.
[0045] The plurality of detection networks can be separate models or can jointly constitute a multi-task model. For a video to be detected, a frame or multiple suspicious frames can be selected from the video by the plurality of detection networks in the recognition device 100, and the recognition device 100 sends the selected frame or multiple suspicious frames to the server 200, which determines whether the video is a fake video based on a local high-performance model. The server 200 includes, for example, a plurality of detection networks such as detection network 21 and detection network 22. Similarly to the side of the recognition device, the plurality of detection networks can correspond to a plurality of abnormal situations in a fake video. After the server 200 detects whether the video is a fake video by using the local model, the detection result is returned to the recognition device 100.
[0046] A flowchart of a method for detecting a fake video in an embodiment of the present specification will be described in detail below with reference to FIG. 2.
[0047] As shown in FIG. 2, at step S201, the recognition device obtains, for n frames in a video, an anomaly score output by each detection network with respect to each frame of the n frames through one or more detection networks.
[0048] As described above, the recognition device 100 can include multiple neural networks such as the detection network 11, the detection network 12, etc. In an embodiment, the multiple neural networks can include a CNN. The CNN can include the following multiple layers: a convolutional layer that forms a feature map by sliding and performing convolution operations on an input image using a convolution kernel; an activation layer that can use, for example, a ReLU activation function to increase the nonlinearity of the network; a pooling layer, also known as a down-sampling layer, for reducing the dimensionality of the feature map and enhancing the generalization ability of the model; a fully connected layer that makes a decision based on the features extracted by the convolutional layer or the pooling layer; and an output layer that can be included in the CNN to generate a prediction result based on the output of the fully connected layer.
[0049] In the convolutional layer, one convolution kernel corresponds to one neuron in the neural network, and each value included in the convolution kernel corresponds to a parameter in the neuron. The fully connected layer includes multiple neurons, each neuron includes a weight and a bias as parameters, and each neuron is connected to the output of each neuron of the previous layer. The CNN can be trained based on training samples to adjust the parameters in each neuron in the CNN, wherein the training samples can include a video and a label value, and the label value can include a score of each frame in the video.
[0050] In another embodiment, the multiple neural networks can include an RNN.
[0051] An RNN is a type of neural network for processing sequence data. The RNN can include an input layer, a hidden layer, and an output layer. In the input layer, the parameters include an input weight matrix W xh , the parameters in the hidden layer include a hidden layer weight matrix W hh and a hidden layer bias b h , and the parameters in the output layer include an output layer weight matrix W hy and an output layer bias b y . The RNN can be trained based on training samples to adjust the parameters included in the RNN, wherein the training samples can include a video and a label value, and the label value can include a score of each frame in the video.
[0052] The input of the RNN is usually sequence data, which can be represented as X = (x1, x2, …, x T , where xt represents the input at time step t, x t is typically in the form of a vector. The output of an RNN can be a sequence, e.g., Y = (y1, y2,..., y T ), or a result based on the sequence Y.
[0053] In the calculation of an RNN, for time step t, the output of the hidden layer is: h t = σ(W xh x t + W hh h t-1 + b h )
[0054] where h t-1 is the output of the hidden layer at the previous time step, and σ() is an activation function, such as tanh or ReLU.
[0055] The output of the output layer is: y t = W hy h t + b y
[0056] In an implementation, to facilitate the processing of video data by the RNN, the features of each frame in the video can first be extracted by a CNN to obtain a sequence of vectors corresponding to the frames, e.g., (x1, x2,..., x T ), which is input into the RNN, and the RNN outputs a sequence (y1, y2,..., y T ), and the prediction scores of the frames can be obtained based on each y t .
[0057] In an implementation, the multiple detection networks in the recognition device can together constitute a multi-task model as shown in FIG. 3. The multi-task model can include a shared layer 10. In an implementation, the shared layer 10 can include a shared convolutional layer to extract general image features of the video, which can include multiple convolutional layers and pooling layers. The shared layer can also include an RNN and its variants (such as LSTM and GRU) to capture general sequential features of the frames in the video.
[0058] After the shared layer 10 obtains the feature data of the frames of the video based on the input video, the feature data of the frames is input to each detection network to perform model prediction respectively.
[0059] In the identification device, each detection network is lightweight, i.e., compared with the detection network on the server side, the detection network deployed in the identification device can include fewer layers, and each layer includes fewer parameters, so that the detection network can be run in the identification device without requiring high computing power, and the prediction result can be output quickly.
[0060] The detection network 11 is used to detect the degree of facial distortion of each frame in the video, for example. The training sample used to train the detection network 11 can include a video and a label value of each frame in the video. The video includes a frame with a normal face and a frame with a distorted face, for example. The label value of the frame with a normal face is set to 0, and the label value of the frame with a distorted face is set to 1. By training the detection network 11 in this way, the detection network 11 can output an anomaly score for each frame in the video. The anomaly score is between 0 and 1, indicating the degree of facial distortion of the frame. The closer the anomaly score is to 1, the higher the degree of facial distortion of the frame. FIG. 4 is a schematic diagram of a process of detecting a video by using the detection network 11. As shown in FIG. 4, a frame (e.g., the second frame) with a distorted face is included in multiple frames in the video. By inputting the video (or frame features corresponding to each frame in the video) into the detection network 11, the detection network 11 outputs an anomaly score for each frame. For example, the score of the second frame is close to 1, and the scores of other frames are close to 0.
[0061] In an embodiment, the detection network 12 in the identification device 100 is used to detect whether a frame in the video includes a border as shown in FIG. 5. As shown in FIG. 5, the left and right sides and the upper and lower sides of the face in the frame of the video have relatively wide borders, which indicates that the video can be a video injected by a user into the identification device 100, rather than a video taken by the identification device 100 itself, because the video taken by the identification device 100 does not include any border, and the edited video can form a border of the video due to adjustment of the format and size in the editing process. Therefore, by using the detection network 12 to detect whether a frame in the video includes a border, the detection result can be used as a judgment factor for determining whether the video is a fake video.
[0062] The training sample used to train the detection network 12 can include a video and a label value of each frame in the video. The video includes a frame with a border and a frame without a border, for example. The label value of the frame without a border is set to 0, and the label value of the frame with a border is set to 1. By training the detection network 12 in this way, the detection network 12 can output an anomaly score for each frame in the video. The anomaly score is between 0 and 1, indicating the possibility of the frame having a border. The closer the anomaly score is to 1, the higher the possibility of the frame having a border.
[0063] In another implementation, the detection network 13 in the recognition device 100 is configured to detect whether the video includes an abnormality caused by the face image replacement operation, such as a shadow abnormality, a lighting abnormality, an unnatural transition, and the like. For example, in the person image shown in FIG. 6, the image within the box of the person image does not match the image at other positions of the person image, and the shadow does not conform to the natural law, which is an image abnormality caused by the replacement of the face image. Therefore, by using the detection network 13 to detect whether the frame in the video has the abnormality, the detection result can be used as a judgment factor for determining whether the video is a fake video.
[0064] The training sample used to train the detection network 13 can include a video and a label value of each frame in the video. For example, the video includes frames without face replacement operation and frames with face replacement operation, the label value of the frame without face replacement operation is set to 0, and the label value of the frame with face replacement operation is set to 1. By training the detection network 13 in this way, the detection network 13 can output an abnormality score for each frame in the video, the abnormality score is between 0 and 1, and is used to indicate the possibility of face replacement operation in the frame. The closer the abnormality score is to 1, the higher the possibility of face replacement operation in the frame.
[0065] In another implementation, the detection network 14 in the recognition device 100 is configured to detect whether the background change in the video is abnormal. Normally, the background of two consecutive frames usually changes slightly, and the change is smooth, for example, due to the movement of the camera or the fine adjustment of the viewing angle, the background can have a slight displacement or rotation. If there is a large change in the background between a frame and the next frame in the video, it means that the video is likely to be a fake video. Therefore, by using the detection network 14 to detect the background change in the video, the detection result can be used as a judgment factor for determining whether the video is a fake video.
[0066] The training sample used to train the detection network 14 can include a video and a label value of each frame in the video. For example, the video includes multiple frames with smooth background change and two frames with background mutation, the label value of each frame with smooth background change is set to 0, and the label values of the two frames with background mutation are both set to 1. By training the detection network 14 in this way, the detection network 14 can output an abnormality score for each frame in the video, the abnormality score is between 0 and 1, and is used to indicate the abnormality degree of the background change in the frame. The closer the abnormality score is to 1, the higher the possibility of abnormality of the background change in the frame.
[0067] In another embodiment, the detection network 15 in the recognition device 100 is used to detect whether the background in a video is derived from the same image. Normally, the background of two consecutive frames usually has slight changes and is not exactly the same, for example, due to the movement of the camera or the slight adjustment of the viewing angle, the background can have slight displacement or rotation. If the background in one frame of the video is exactly the same as the background in the next frame, it indicates that the video is likely to be a fake video based on an image, for example, a video of a person making facial movements (such as opening his mouth, blinking, etc.) based on a facial image of the person. Therefore, by using the detection network 15 to detect whether the background in the video is derived from the same image, the detection result can be used as a judgment factor for determining whether the video is a fake video.
[0068] The training sample used to train the detection network 15 can include a video and label values of each frame in the video, wherein the video includes, for example, multiple frames with smooth changes in the background and two frames with the same background, the label values of the frames with smooth changes in the background are set to 0, and the label values of the two frames with the same background are both set to 1. By training the detection network 15 in this way, the detection network 15 can output an anomaly score for each frame in the video, the anomaly score is between 0 and 1, and is used to indicate the possibility that the frame has the same background as the adjacent frame. The closer the anomaly score is to 1, the higher the possibility that the frame has the same background as the adjacent frame.
[0069] In another embodiment, in the network structure as shown in FIG. 3, multiple detection networks together constitute a multi-task model, and the multiple detection networks in the multi-task model can be trained simultaneously through multiple training samples. Specifically, the training sample can include a video and label information, the label information includes label values corresponding to each detection network, and the label values include anomaly scores corresponding to each frame of the video.
[0070] It can be understood that the detection network 11 to the detection network 15 are described as examples in the foregoing, and the embodiments of the present disclosure are not limited thereto. For example, a detection network that outputs an anomaly score of each frame to indicate the possibility that each frame includes a watermark, etc. can also be deployed on the recognition device side.
[0071] In step S203, the recognition device selects one or more frames from the n frames according to the anomaly scores of the n frames.
[0072] In an embodiment, the recognition device can select one or more frames (for example, 2 frames) with the highest anomaly scores from the n frames according to the anomaly scores of each frame output by the detection network 11, that is, one or more frames with the highest degree of face distortion, as the frames to be sent to the server.
[0073] In an embodiment, the identification device can perform a weighted summation on the anomaly scores of each frame output by each detection network to obtain a comprehensive anomaly score of each frame, and select one or more frames with the highest comprehensive anomaly scores as the frames to be sent to the server.
[0074] In an embodiment, as shown in FIG. 3, the identification device can first select one or more first frames from the n frames based on the anomaly scores Scorel of each frame output by the detection network 11 as the frames to be sent to the server. In addition, the identification device can perform a weighted summation on the anomaly scores Score2 to Score5 of each frame output by the detection networks 12 to 15 respectively to obtain a comprehensive anomaly score Score6 of each frame, and then select one or more second frames from the n frames based on the comprehensive anomaly scores Score6 of each frame as the frames to be sent to the server. The identification device can remove the duplicate frames from the first frames and the second frames, and take the remaining frames as the frames to be sent to the server. In this embodiment, the server can make a model prediction by combining the first frames and the second frames, so as to obtain a more accurate prediction result.
[0075] In step S205, the identification device sends the one or more frames selected as described above to the server.
[0076] In this way, the identification device has screened multiple frames in the video through the local detection network, and sent one or more frames with the highest suspiciousness to the server, without the need to send the entire video to the server, thereby saving data traffic and improving the speed of the server returning the prediction result.
[0077] In step S207, the server processes the one or more frames received based on one or more detection networks to determine whether the video is a fake video.
[0078] In an embodiment, a single detection model can be deployed in the server, which includes more network layers and more neurons in each layer than the detection model on the side of the identification device, so as to achieve better prediction performance. Each training sample used to train the detection model can include a video and a label value indicating whether the video is a fake video. In the training sample including a fake video, the fake video can include at least one of the abnormal situations described above, such as face distortion, including a frame in the video, face replacement abnormality, background abnormality, etc.
[0079] In another implementation, multiple networks can be deployed in the server, e.g., detection network 21, detection network 22, etc. as shown in FIG. 1, where each detection network corresponds to one abnormal case in the fake video, and each detection network includes more network layers and more neurons in each network layer compared to the detection network in the identification device, to provide better model performance. Similar to the identification device, the multiple networks deployed in the server can be multiple separate models, or can constitute a multi-task model. In the case where the multiple networks deployed in the server are multiple separate models, each model can output a probability that the video is a fake video, and the server can determine whether the video is a fake video by synthesizing the outputs of the respective models. In the case where the multiple networks deployed in the server constitute a multi-task model, the multiple networks can respectively output a probability that the video is a fake video, and the output layer in the multi-task model can determine whether the video is a fake video by synthesizing the outputs of the respective networks.
[0080] FIG. 7 is an architecture diagram of an identification device in an embodiment of the present specification, including:
[0081] The obtaining unit 71 is configured to, for n frames in a target video, obtain, by one or more detection networks, an abnormal score output by each detection network with respect to each frame in the n frames, where the one or more detection networks correspond to one or more abnormal cases included in an existing fake video.
[0082] The selecting unit 72 is configured to select one or more first frames from the n frames according to the abnormal scores of the n frames.
[0083] The sending unit 73 is configured to send the one or more first frames to a server for determining whether the target video is a fake video.
[0084] FIG. 8 is an architecture diagram of a server in an embodiment of the present specification, including:
[0085] The receiving unit 81 is configured to receive one or more first frames from an identification device, where the one or more first frames are frames in a target video and are selected by one or more detection networks in the identification device, and the one or more detection networks correspond to one or more abnormal cases included in an existing fake video.
[0086] The processing unit 82 is configured to process the one or more first frames to determine whether the target video is a fake video.
[0087] The embodiments of the present specification also provide a computer-readable storage medium having a computer program stored thereon, which causes a computer to execute the method shown in FIG. 2 when the computer program is executed in the computer.
[0088] The embodiments of the present specification also provide a computing device, comprising a memory and a processor, wherein the memory stores executable code, and the processor executes the executable code to implement the method shown in FIG. 2.
[0089] The embodiments of the present specification also provide a computer program product, comprising computer programs / instructions, which, when executed by a processor, implement the steps of the method shown in FIG. 2.
[0090] In the 1990s, it was quite obvious to distinguish whether an improvement in a technology was in hardware (e.g., improvement in circuit structures of diodes, transistors, switches, etc.) or in software (improvement in method flow). However, as technology has evolved, many improvements in method flow today can be considered as direct improvements in hardware circuit structures. Designers almost always obtain the corresponding hardware circuit structures by programming the improved method flow into hardware circuits. Therefore, it cannot be said that an improvement in a method flow cannot be implemented by hardware entity modules. For example, a programmable logic device (PLD) (e.g., a field programmable gate array (FPGA)) is an integrated circuit whose logic function is determined by user programming of the device. A digital system is "integrated" on a PLD by the designer programming it, rather than by asking a chip manufacturer to design and fabricate a custom integrated circuit chip. Moreover, instead of manually fabricating integrated circuit chips, this programming is now mostly implemented by "logic compiler" software, which is similar to software compilers used in program development, and the original code to be compiled is written in a specific programming language, which is called a hardware description language (HDL), and there are many such languages, such as ABEL (Advanced Boolean Expression Language), AHDL (Altera Hardware Description Language), Confluence, CUPL (Cornell University Programming Language), HDCal, JHDL (Java Hardware Description Language), Lava, Lola, MyHDL, PALASM, RHDL (Ruby Hardware Description Language), etc., and the most commonly used are VHDL (Very-High-Speed Integrated Circuit Hardware Description Language) and Verilog. Those skilled in the art should be aware that, as long as the method flow is logically programmed in the above-mentioned hardware description languages and programmed into an integrated circuit, a hardware circuit implementing the logical method flow can be easily obtained.
[0091] The controller can be implemented in any suitable manner. For example, it can take the form of a microprocessor or processor and a computer-readable medium storing computer-readable program code (e.g., software or firmware) executable by the (micro)processor, logic gates, switches, application-specific integrated circuits (ASICs), programmable logic controllers, and embedded microcontrollers. Examples of controllers include, but are not limited to, the following microcontrollers: ARC 625D, Atmel AT91SAM, Microchip PIC18F26K20, and Silicon Labs C8051F320. A memory controller can also be implemented as part of the control logic of the memory. Those skilled in the art will also recognize that, in addition to implementing the controller in purely computer-readable program code form, the same functionality can be achieved by logically programming the method steps to make the controller take the form of logic gates, switches, application-specific integrated circuits, programmable logic controllers, and embedded microcontrollers. Therefore, such a controller can be considered a hardware component, and the means included therein for implementing various functions can also be considered as structures within the hardware component. Alternatively, the means for implementing various functions can be considered as both software modules implementing the method and structures within the hardware component.
[0092] The systems, devices, modules, or units described in the above embodiments can be implemented by computer chips or physical entities, or by products with certain functions. A typical implementation device is a server system. Of course, this application does not exclude the possibility that, with the future development of computer technology, the computer implementing the functions of the above embodiments can be, for example, a personal computer, a laptop computer, an in-vehicle human-machine interaction device, a cellular phone, a camera phone, a smartphone, a personal digital assistant, a media player, a navigation device, an email device, a game console, a tablet computer, a wearable device, or any combination of these devices.
[0093] While one or more embodiments of this specification provide the operational steps of the methods described in the embodiments or flowcharts, more or fewer operational steps may be included based on conventional or non-inventive means. The order of steps listed in the embodiments is merely one possible order of execution among many steps and does not represent the only possible order. In actual device or end product execution, the methods shown in the embodiments or drawings may be executed sequentially or in parallel (e.g., in a parallel processor or multi-threaded processing environment, or even a distributed data processing environment). The terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, product, or apparatus 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, product, or apparatus. Without further limitations, the presence of other identical or equivalent elements in the process, method, product, or apparatus that includes the elements is not excluded. For example, the use of terms such as "first," "second," etc., is to denote names and does not indicate any particular order.
[0094] For ease of description, the above devices are described in terms of function, divided into various modules. Of course, when implementing one or more of these specifications, the functions of each module can be implemented in one or more software and / or hardware components, or a module that performs the same function can be implemented by a combination of multiple sub-modules or sub-units. The device embodiments described above are merely illustrative. For example, the division of units is only a logical functional division; in actual implementation, there may be other division methods. For example, multiple units or components may be combined or integrated into another system, or some features may be ignored or not executed. Furthermore, the coupling or direct coupling or communication connection shown or discussed may be through some interfaces, indirect coupling or communication connection between devices or units, and may be electrical, mechanical, or other forms.
[0095] This invention is described with reference to flowchart illustrations and / or block diagrams of methods, apparatus (systems), and computer program products according to embodiments of the invention. It will be understood that each block of the flowchart illustrations and / or block diagrams, and combinations of blocks in the flowchart illustrations and / or block diagrams, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, special-purpose computer, embedded processor, or other programmable data processing apparatus to produce a machine, such that the instructions, which execute via the processor of the computer or other programmable data processing apparatus, create means for implementing the functions specified in one or more blocks of the flowchart illustrations and / or one or more blocks of the block diagrams.
[0096] These computer program instructions may also be stored in a computer-readable storage medium that can direct a computer or other programmable data processing device to function in a particular manner, such that the instructions stored in the computer-readable storage medium produce an article of manufacture including instruction means that implement the functions specified in one or more flowcharts and / or one or more block diagrams.
[0097] These computer program instructions may also be loaded onto a computer or other programmable data processing apparatus to cause a series of operational steps to be performed on the computer or other programmable apparatus to produce a computer-implemented process, such that the instructions, which execute on the computer or other programmable apparatus, provide steps for implementing the functions specified in one or more flowcharts and / or one or more block diagrams.
[0098] In a typical configuration, a computing device includes one or more processors (CPU), input / output interfaces, network interfaces, and memory.
[0099] Memory may include non-persistent storage in computer-readable media, such as random access memory (RAM) and / or non-volatile memory, such as read-only memory (ROM) or flash RAM. Memory is an example of computer-readable media.
[0100] Computer-readable media includes both permanent and non-permanent, removable and non-removable media that can store information by any method or technology. Information can be computer-readable instructions, data structures, modules of programs, or other data. Examples of computer storage media include, but are not limited to, phase-change memory (PRAM), static random access memory (SRAM), dynamic random access memory (DRAM), other types of random access memory (RAM), read-only memory (ROM), electrically erasable programmable read-only memory (EEPROM), flash memory or other memory technologies, CD-ROM, digital versatile optical disc (DVD) or other optical storage, magnetic tape, magnetic disk storage, graphene storage or other magnetic storage devices, or any other non-transferable medium that can be used to store information accessible by a computing device. As defined herein, computer-readable media does not include transient computer-readable media, such as modulated data signals and carrier waves.
[0101] Those skilled in the art will understand that one or more embodiments of this specification can be provided as a method, system, or computer program product. Therefore, one or more embodiments of this specification may take the form of a completely hardware embodiment, a completely software embodiment, or an embodiment combining software and hardware aspects. Furthermore, one or more embodiments of this specification may take the form of a computer program product implemented on one or more computer-usable storage media (including, but not limited to, disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.
[0102] One or more embodiments of this specification can be described in the general context of computer-executable instructions, such as program modules, that are executed by a computer. Generally, program modules include routines, programs, objects, components, data structures, etc., that perform a particular task or implement a particular abstract data type. One or more embodiments of this specification can also be practiced in distributed computing environments where tasks are performed by remote processing devices connected via a communication network. In distributed computing environments, program modules can reside in local and remote computer storage media, including storage devices.
[0103] The various embodiments in this specification are described in a progressive manner. Similar or identical parts between embodiments can be referred to mutually. Each embodiment focuses on describing the differences from other embodiments. In particular, system embodiments are basically similar to method embodiments, so the description is relatively simple; relevant parts can be referred to the descriptions in the method embodiments. In the description of this specification, the terms "one embodiment," "some embodiments," "example," "specific example," or "some examples," etc., refer to specific features, structures, materials, or characteristics described in connection with that embodiment or example, which are included in at least one embodiment or example of this specification. In this specification, the illustrative expressions of the above terms do not necessarily refer to the same embodiment or example. Furthermore, the specific features, structures, materials, or characteristics described can be combined in any suitable manner in one or more embodiments or examples. Moreover, without contradiction, those skilled in the art can combine and integrate the different embodiments or examples described in this specification and the features of different embodiments or examples.
[0104] The above description is merely an embodiment of one or more embodiments of this specification and is not intended to limit the scope of these embodiments. Various modifications and variations can be made to these embodiments by those skilled in the art. Any modifications, equivalent substitutions, improvements, etc., made within the spirit and principles of this specification should be included within the scope of the claims.
Claims
1. A method for detecting a fake video, performed by a recognition device, comprising: obtaining, by one or more detection networks, for n frames in a target video, an anomaly score output by each detection network with respect to each frame in the n frames, wherein the one or more detection networks correspond to one or more abnormal situations included in an existing fake video; selecting one or more first frames from the n frames according to the anomaly scores of the n frames; sending the one or more first frames to a server for determining whether the target video is a fake video. 2.The method of claim 1, wherein the recognition device is configured to perform face recognition, and the one or more detection networks include a first detection network configured to output a first anomaly score with respect to a frame image, the first anomaly score being indicative of a degree of face distortion in the frame image, the selecting one or more first frames from the n frames according to the anomaly scores of the n frames comprises: selecting m first frames from the n frames according to the first anomaly scores of the n frames output by the first detection network. 3.The method of claim 2, wherein the one or more detection networks include one or more second detection networks corresponding to at least one of the following abnormal situations: a frame or multiple frames in a video include a frame border; a frame or multiple frames in a video include a face replacement abnormality; a frame or multiple frames in a video include a watermark; a background of consecutive multiple frames in a video is discontinuous; a background of multiple frames in a video is from the same image. 4.The method of claim 3, wherein the one or more detection networks include multiple second detection networks, and the selecting one or more first frames from the n frames according to the anomaly scores of the n frames comprises, for each frame in the n frames, obtaining an anomaly score output by each second detection network, obtaining a weighted sum of the anomaly scores of the multiple second detection networks to obtain a second anomaly score of the frame, and selecting k first frames from the n frames according to the second anomaly scores of the frames. 5.The method of claim 4, wherein the first detection model and the multiple second detection networks constitute a multi-task model, and the multi-task model is trained based on a plurality of first training samples, the first training samples including a video and first label values corresponding to the first detection model and each detection network in the multiple second detection networks, the first label values including corresponding anomaly scores of each frame of the video. 6.The method of claim 2, wherein the first detection model is trained based on a plurality of second training samples, the second training samples including a video and second label values, the second label values including anomaly scores of each frame of the video. 7.A method for detecting a fake video, performed by a server, comprising: receiving one or more first frames from a recognition device, the one or more first frames being frames in a target video and being selected by one or more detection networks in the recognition device, the one or more detection networks corresponding to one or more abnormal situations included in an existing fake video; processing the one or more first frames to determine whether the target video is a fake video.
8. The method of claim 7, the processing the one or more first frames to determine whether the target video is a fake video comprising: processing the one or more first frames to determine whether the target video is a fake video based on one or more third detection networks locally, the one or more third detection networks corresponding to the one or more abnormal situations.
9. An identification device comprising: an obtaining unit configured to, for n frames in a target video, obtain, by one or more detection networks corresponding to one or more abnormal situations included in existing fake videos, an abnormal score output by each detection network with respect to each of the n frames; a selecting unit configured to select one or more first frames from the n frames according to the abnormal scores of the n frames; a sending unit configured to send the one or more first frames to a server for determining whether the target video is a fake video.
10. A server comprising: a receiving unit configured to receive one or more first frames from an identification device, the one or more first frames being frames in a target video and selected by one or more detection networks in the identification device, the one or more detection networks corresponding to one or more abnormal situations included in existing fake videos; a processing unit configured to process the one or more first frames to determine whether the target video is a fake video.
11. A computing device comprising a memory and a processor, the memory having stored therein executable code which, when executed by the processor, implements the method of any one of claims 1-8.
Citation Information
Patent Citations
A method and apparatus for generating information
CN109308490A
Method and device for detecting illegal and criminal behaviors based on edge calculation
CN114821936A
Forgery video detection method and device, electronic equipment and storage medium
CN117252797A
Face video depth forgery detection method and device
CN117542124A
Method for detecting counterfeit video, identification device and server
CN118840696A