A method and apparatus for detecting a still image rephotographing

By using RGB three-channel separation, depth map prediction, and HSV and YCBCR color models to expand silent image features and performing feature channel overlay processing, the problem of insufficient information load in silent image re-photographing detection is solved, and the detection accuracy is improved.

CN116229109BActive Publication Date: 2026-01-09ZHAOLIAN CONSUMER FINANCE CO LTD
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310016523.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-01-06
Publication Date
2026-01-09
Estimated Expiration
2043-01-06

AI Technical Summary

Technical Problem

In silent image reproduction detection, the information capacity of a single RGB channel image is insufficient, making it difficult for AI to capture specific features and reducing detection accuracy.

Method used

By expanding feature information through RGB three-channel separation, depth map prediction, HSV color model and YCBCR color model, and performing feature channel overlay processing, multi-dimensional image information is extracted.

Benefits of technology

It improves the accuracy of silent image re-photographing detection and solves the problem of insufficient image information capacity of a single RGB channel.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116229109B_ABST
    Figure CN116229109B_ABST
Patent Text Reader

Abstract

Embodiments of the present application disclose a kind of mute image flip detection method and device.The method comprises: obtaining the image to be detected, the image to be detected includes the mute flip image of user;The RGB three channel separation of the image to be detected is carried out, and first image is obtained, first image includes R channel image, G channel image and B channel image;The image to be detected and first image are input into first model to carry out depth map prediction, and pseudo depth image is obtained;First image is input into HSV color model, and second image is obtained, first image is input into YCBCR color model, and third image is obtained;According to first image, pseudo depth image, second image and third image, determine identification detection result.By expanding the characteristic information of mute flip image and carrying out feature channel superposition processing, the problem of insufficient information load of single RGB channel image can be solved, and the accuracy of mute image flip detection is improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computer, and in particular to a method and device for detecting a still image. BACKGROUND

[0002] With the continuous development of artificial intelligence (AI) technology and digital image processing technology, live body detection is widely used in the field of Internet finance, wherein, the live body detection is mainly divided into dynamic live body detection and static live body detection. The dynamic live body detection is to extract features from a depth map to obtain a detection result. However, it is difficult to obtain the depth map data, and the data volume is small. The static live body detection is to extract features from a still image of a user to obtain a detection result. However, there is no change in the pixel points of the still image, which makes it difficult for AI to capture specific features, and thus it is difficult to detect the still live body. SUMMARY

[0003] The technical problem to be solved by the embodiments of the present application is to provide a method and device for detecting a still image, which can solve the problem of insufficient information load of a single RGB channel image by expanding the feature information of the still image and performing feature channel superposition processing, and improve the accuracy of the still image detection.

[0004] In a first aspect, the embodiments of the present application provide a method for detecting a still image, comprising:

[0005] obtaining a to-be-detected image, wherein the to-be-detected image comprises a still image of a user;

[0006] separating the to-be-detected image into RGB three channels to obtain a first image, wherein the first image comprises an R channel image, a G channel image and a B channel image;

[0007] inputting the to-be-detected image and the first image into a first model to perform depth map prediction and obtain a pseudo-depth image;

[0008] inputting the first image into an HSV color model to obtain a second image, and inputting the first image into a YCBCR color model to obtain a third image, wherein the second image comprises an H channel image, an S channel image and a V channel image, and the third image comprises a Y channel image, a CB channel image and a CR channel image;

[0009] determining a recognition result according to the first image, the pseudo-depth image, the second image and the third image.

[0010] The image processing method of the RGB three-channel separation, the depth map prediction, the HSV color model and the YCBCR color model is beneficial to mining other dimension information of the to-be-detected image, fully utilizes various information of the image through a multi-channel superposition layer mode for feature extraction, can solve the problem of insufficient information load of a single RGB channel image, and improves the accuracy of the silent image reprint detection.

[0011] In a possible design, the first image, the pseudo-depth image, the second image and the third image are subjected to feature transformation to obtain a first matrix, a second matrix, a third matrix and a fourth matrix; the first matrix, the second matrix, the third matrix and the fourth matrix are subjected to feature fusion to obtain a feature splicing matrix; and the feature splicing matrix is input into a second model to determine the identification detection result. Through the multi-channel superposition layer mode for expanding feature information of the to-be-detected image, the problem of insufficient information load of a single RGB channel image can be solved, and the accuracy of the silent image reprint detection is improved.

[0012] In another possible design, a length of the first image and a width of the first image are determined, the length of the first image is taken as a row number of the first matrix, the width of the first image is taken as a column number of the first matrix, pixels of the R channel image are taken as elements of a first channel in the first matrix, pixels of the G channel image are taken as elements of a second channel in the first matrix, and pixels of the B channel image are taken as elements of a third channel in the first matrix, to obtain the first matrix; a length of the pseudo-depth image and a width of the pseudo-depth image are determined, the length of the pseudo-depth image is taken as a row number of the second matrix, the width of the pseudo-depth image is taken as a column number of the second matrix, and pixels of the pseudo-depth image are taken as elements of a first channel in the second matrix, to obtain the second matrix; a length of the second image and a width of the second image are determined, the length of the second image is taken as a row number of the third matrix, the width of the second image is taken as a column number of the third matrix, pixels of the H channel image are taken as elements of a first channel in the third matrix, pixels of the S channel image are taken as elements of a second channel in the third matrix, and pixels of the V channel image are taken as elements of a third channel in the third matrix, to obtain the third matrix; a length of the third image and a width of the third image are determined, the length of the third image is taken as a row number of the fourth matrix, the width of the third image is taken as a column number of the fourth matrix, pixels of the Y channel image are taken as elements of a first channel in the fourth matrix, pixels of the CB channel image are taken as elements of a second channel in the fourth matrix, and pixels of the CR channel image are taken as elements of a third channel in the fourth matrix, to obtain the fourth matrix. Feature conversion is performed on the first image, the pseudo-depth image, the second image, and the third image into a numerical form recognizable by a computer, which facilitates subsequent feature channel superposition processing and recognition detection processing.

[0013] In another possible design, feature channel superposition processing is performed on the first matrix, the second matrix, the third matrix, and the fourth matrix, and the feature splicing matrix is obtained by matrix merging. In this way, feature channel superposition is used, original feature information of the image to be detected is not affected, feature information of other dimensions is expanded, the problem of insufficient information load of a single RGB channel image is solved, and accuracy of the still image reprint detection is improved.

[0014] In another possible design, face detection is performed on the to-be-detected image to determine position information of a face region in the to-be-detected image; the position information of the face region in the to-be-detected image and the first image are input into the first model, and each pixel in the face region in the first image is predicted to obtain the pseudo-depth image. By performing depth map prediction on each pixel value in the face region in the to-be-detected image, the depth of field between the face and the camera is obtained, the feature space of the silent selfie image is expanded, that is, the feature dimension of the data is artificially increased, thereby solving the problem of difficulty in obtaining depth map data and small data volume in reality, and the accuracy of the silent image selfie detection is improved.

[0015] In another possible design, the R channel image, the G channel image, and the B channel image are input into the HSV color model to be converted to obtain the H channel image, the S channel image, and the V channel image; the R channel image, the G channel image, and the B channel image are input into the YCBCR color model to be converted to obtain the Y channel image, the CB channel image, and the CR channel image. The feature space of the RGB channel image is expanded by using the HSV color model and the YCBCR color model, so as to solve the problem of insufficient information load of a single RGB channel image.

[0016] In a second aspect, an embodiment of the present application provides a silent image selfie detection device, including:

[0017] An acquisition module is configured to acquire a to-be-detected image, where the to-be-detected image includes a silent selfie image of a user.

[0018] A processing module is configured to perform RGB three-channel separation on the to-be-detected image to obtain a first image, where the first image includes an R channel image, a G channel image, and a B channel image.

[0019] The processing module is further configured to input the to-be-detected image and the first image into a first model to perform depth map prediction and obtain a pseudo-depth image.

[0020] The processing module is further configured to input the first image into an HSV color model to obtain a second image, and input the first image into a YCBCR color model to obtain a third image, where the second image includes an H channel image, an S channel image, and a V channel image, and the third image includes a Y channel image, a CB channel image, and a CR channel image.

[0021] The processing module is further configured to determine a recognition detection result according to the first image, the pseudo-depth image, the second image, and the third image.

[0022] In a possible design, the processing module is further configured to perform feature transformation on the first image, the pseudo-depth image, the second image, and the third image to obtain a first matrix, a second matrix, a third matrix, and a fourth matrix; perform feature fusion on the first matrix, the second matrix, the third matrix, and the fourth matrix to obtain a feature splicing matrix; and input the feature splicing matrix into a second model to determine the recognition detection result.

[0023] In another possible design, the processing module is further configured to determine a length of the first image and a width of the first image, determine the length of the first image as a row number of the first matrix, determine the width of the first image as a column number of the first matrix, determine pixels of the R-channel image as elements of a first channel in the first matrix, determine pixels of the G-channel image as elements of a second channel in the first matrix, and determine pixels of the B-channel image as elements of a third channel in the first matrix, to obtain the first matrix; determine a length of the pseudo-depth image and a width of the pseudo-depth image, determine the length of the pseudo-depth image as a row number of the second matrix, determine the width of the pseudo-depth image as a column number of the second matrix, and determine pixels of the pseudo-depth image as elements of a first channel in the second matrix, to obtain the second matrix; determine a length of the second image and a width of the second image, determine the length of the second image as a row number of the third matrix, determine the width of the second image as a column number of the third matrix, determine pixels of the H-channel image as elements of a first channel in the third matrix, determine pixels of the S-channel image as elements of a second channel in the third matrix, and determine pixels of the V-channel image as elements of a third channel in the third matrix, to obtain the third matrix; and determine a length of the third image and a width of the third image, determine the length of the third image as a row number of the fourth matrix, determine the width of the third image as a column number of the fourth matrix, determine pixels of the Y-channel image as elements of a first channel in the fourth matrix, determine pixels of the CB-channel image as elements of a second channel in the fourth matrix, and determine pixels of the CR-channel image as elements of a third channel in the fourth matrix, to obtain the fourth matrix.

[0024] In another possible design, the processing module is further configured to perform feature channel superposition processing on the first matrix, the second matrix, the third matrix, and the fourth matrix, and obtain the feature splicing matrix by matrix merging.

[0025] In another possible design, the processing module is further configured to perform face detection on the to-be-detected image to determine position information of a face region in the to-be-detected image; and input the position information of the face region in the to-be-detected image and the first image into the first model to perform prediction on each pixel of the face region in the first image, and obtain the pseudo-depth image.

[0026] In another possible design, the processing module is further configured to input the R channel image, the G channel image, and the B channel image into the HSV color model to convert and obtain the H channel image, the S channel image, and the V channel image; and input the R channel image, the G channel image, and the B channel image into the YCBCR color model to convert and obtain the Y channel image, the CB channel image, and the CR channel image.

[0027] The operation and beneficial effects of the silent image copy detection apparatus can be referred to the operation and beneficial effects of the method in the first aspect, and the repeated parts will not be described herein.

[0028] In a third aspect, the present application provides a silent image copy detection system, which includes an image acquisition module and an image detection module. The image acquisition module is configured to import a to-be-detected image, and the image detection module is configured to acquire the to-be-detected image, execute instructions such as image processing, pseudo-depth image prediction, and multi-layer superposition in the first aspect, and perform recognition and detection on a silent copy image.

[0029] In a fourth aspect, the present application provides a silent image copy detection system, which includes a processor, a memory, and a communication bus. The memory is configured to store computer execution instructions, the processor is configured to execute the computer execution instructions stored in the memory to enable the silent image copy detection system to perform the method in any one of the first aspect, and the communication bus is configured to realize connection and communication between the processor and the memory.

[0030] In a fifth aspect, the present application provides a silent image copy detection system, which can perform the method in the first aspect. The function of the silent image copy detection system can be realized by hardware, or realized by hardware executing corresponding software. The hardware or software includes one or more modules corresponding to the above functions. The system can be software and / or hardware.

[0031] In a sixth aspect, the present application provides a computer readable storage medium, which is configured to store a computer program. When the computer program is executed, the method in any one of the first aspect is realized.

[0032] In a seventh aspect, an embodiment of the present application provides a computer program product including a computer program, when the computer program is executed, causes the method according to any one of the first aspect to be implemented. BRIEF DESCRIPTION OF DRAWINGS

[0033] In order to more clearly illustrate the technical solutions in the embodiments of the present application or the background art, the drawings needed to be used in the embodiments of the present application or the background art will be described below.

[0034] Figure 1 is a structural schematic diagram of a silent image flip detection system provided by an embodiment of the present application;

[0035] Figure 2 is a flowchart of a silent image flip detection method provided by an embodiment of the present application;

[0036] Figure 3 is a flowchart of a predicted depth map provided by an embodiment of the present application;

[0037] Figure 4 is a structural schematic diagram of a silent image flip detection device provided by an embodiment of the present application;

[0038] Figure 5 is a structural schematic diagram of a server provided by an embodiment of the present application. DETAILED DESCRIPTION

[0039] Some terms involved in the present application will be described below to facilitate understanding by those skilled in the art.

[0040] 1. Depth map, each pixel value of an image represents the distance between a point in a scene and a camera.

[0041] 2. Pseudo depth map, each pixel value of an image is predicted by an algorithm, representing the distance between a point in a scene and a camera.

[0042] 3. HSV color model, a method of representing a point in the RGB color model in the original coordinate system, H represents hue, S represents saturation, and V represents lightness.

[0043] 4. YCBCR color model, commonly used in image continuous processing or digital photography systems, Y represents the luma component of color, CB represents the blue concentration offset component, and CR represents the red concentration offset component.

[0044] The embodiments of the present application will be described below in combination with the drawings in the embodiments of the present application.

[0045] AsFigure 1 As shown in Figure 1 is a structural schematic diagram of a silent image retake detection system provided by an embodiment of the present application. The silent image retake detection system comprises an image acquisition module 101 and an image detection module 102. Detailed descriptions of each module are as follows.

[0046] The image acquisition module 101 is configured to import a to-be-detected image, wherein the to-be-detected image is a silent retake image of a user, and the silent retake image comprises facial features of the user.

[0047] The image detection module 102 is configured to acquire the to-be-detected image from the image acquisition module 101, perform RGB three-channel separation on the to-be-detected image to obtain a first image, wherein the first image comprises an R channel image, a G channel image and a B channel image; input the to-be-detected image and the first image into a first model to perform depth map prediction and obtain a pseudo depth image; input the first image into an HSV color model to obtain a second image, and input the first image into a YCBCR color model to obtain a third image, wherein the second image comprises an H channel image, an S channel image and a V channel image, and the third image comprises a Y channel image, a CB channel image and a CR channel image; perform feature transformation on the first image, the pseudo depth image, the second image and the third image to obtain a first matrix, a second matrix, a third matrix and a fourth matrix; perform feature channel superposition processing on the first matrix, the second matrix, the third matrix and the fourth matrix to obtain a feature splicing matrix; and input the feature splicing matrix into a second model to determine an identification detection result.

[0048] It should be noted that the silent image retake detection system described above can be a system for interacting with a user. The system can be a software system, a hardware system or a combination of software and hardware. The present application does not make specific limitations in this regard. It should also be noted that Figure 1 only shows a structural schematic diagram of the silent image retake detection system. In actual applications, the silent image retake detection system of Figure 1 may be transformed accordingly.

[0049] As shown in Figure 2 , a flowchart of a silent image retake detection method provided by an embodiment of the present application is shown. The method comprises but is not limited to the following steps: Figure 2

[0050] Step S201: Acquire a to-be-detected image.

[0051] The to-be-detected image comprises a silent retake image of a user, and the silent retake image comprises complete facial features.

[0052] ​In an implementation, a user uploads an image to be detected. Specifically, the silent image flipping detection system provides an image uploading interface, which includes an image uploading button. The user can click the image uploading button to upload a pre-prepared silent flipping image to the silent image flipping detection system.

[0053] In another implementation, the image to be detected is obtained from a database (including a local database or a database of other devices). Further, a required silent flipping image is searched to obtain the image to be detected. For example, if the user requirement is to detect and identify a human face feature, a silent flipping image containing a human face feature can be obtained from a local database or a network as the image to be detected.

[0054] In the embodiment of the present application, a photographer can take a photo of a user to obtain a non-dynamic two-dimensional single-frame image. If the two-dimensional single-frame image contains complete human face features, the two-dimensional single-frame image is determined as the image to be detected. The image to be detected is a non-first-hand taken two-dimensional single-frame image. The photographer can obtain the image to be detected by taking a photo of a flipped person's mobile phone, television, or photo through a mobile phone.

[0055] Step S202: performing RGB three-channel separation on the image to be detected to obtain a first image.

[0056] The first image includes an R channel image, a G channel image, and a B channel image.

[0057] Specifically, the R channel color vector, the G channel color vector, and the B channel color vector corresponding to each pixel in the image to be detected are extracted to obtain the R channel image, the G channel image, and the B channel image, respectively.

[0058] Step S203: inputting the image to be detected and the first image into a first model to perform depth map prediction to obtain a pseudo-depth image.

[0059] Specifically, the image to be detected is subjected to face detection to determine the position information of the face region in the image to be detected. The position information of the face region in the image to be detected and the first image are input into the first model to predict each pixel in the face region in the first image to obtain the pseudo-depth image.

[0060] In the embodiment of the present application, the depth map can show the distance of an object from the camera perspective. When a photo is taken in a real environment, there is a depth of field information between the face and the camera. However, the face in the silent flipping image is flat and does not have depth of field information, which makes it difficult to detect a silent live flipping. By expanding the feature space of the silent flipping image, i.e., artificially increasing the feature dimension of the data, the AI model has more mining space. Figure 3 As shown in Figure 3is a flowchart of predicting a depth map provided by an embodiment of the present application, and the specific process includes: inputting a to-be-detected image into a face detection neural network DBFACENET, obtaining position information of a face region in the to-be-detected image through a face detection frame, inputting the position information, an R channel image, a G channel image and a B channel image into a prediction model 3DDFA NET for depth map prediction, and predicting each pixel value of the face region in the R channel image, the G channel image and the B channel image to obtain a pseudo depth image. Wherein, the depth map is predicted for a non-rephotographed image, the pixel value in the non-rephotographed image ranges from greater than or equal to 0 to less than or equal to 1, and the pixel value in the rephotographed image is 0 by default.

[0061] Optionally, the DBFACE NET algorithm can be replaced by other face detection methods, for example, a DLIB software library.

[0062] Optionally, the 3DDFA NET network can be replaced by other depth map prediction methods, for example, a PRNET model.

[0063] Step S204: inputting the first image into an HSV color model to obtain a second image, and inputting the first image into a YCBCR color model to obtain a third image.

[0064] Wherein, the second image includes an H channel image, an S channel image and a V channel image, and the third image includes a Y channel image, a CB channel image and a CR channel image.

[0065] Specifically, the R channel image, the G channel image and the B channel image are inputted into the HSV color model to be converted to obtain the H channel image, the S channel image and the V channel image; and the R channel image, the G channel image and the B channel image are inputted into the YCBCR color model to be converted to obtain the Y channel image, the CB channel image and the CR channel image.

[0066] In the embodiment of the present application, a first color vector corresponding to a pixel in the first image is extracted, the first color vector includes an R channel color vector, a G channel color vector and a B channel color vector, the first color vector is inputted into the HSV color model to calculate a second color vector corresponding to a pixel in the second image, the second color vector includes an H channel color vector, an S channel color vector and a V channel color vector; and the first color vector is inputted into the YCBCR color model to calculate a third color vector corresponding to a pixel in the third image, the third color vector includes a Y channel color vector, a CB channel color vector and a CR channel color vector. Wherein, the second color vector satisfies:

[0067] R'=R / 255

[0068] G'=G / 255

[0069] B' = B / 255

[0070] V = max(R', G', B')

[0071] when V is not equal to 0,

[0072] S = (V - min(R', G', B')) / V

[0073] when V is equal to 0,

[0074] = 0

[0075] when V is equal to R',

[0076] H = 60 x (G' - B') / (V - min(R', G', B'))

[0077] when V is equal to G',

[0078] H = 120 + 60 x (B' - R') / (V - min(R', G', B'))

[0079] when V is equal to B',

[0080] H = 240 + 60 x (R' - G') / (V - min(R', G', B'))

[0081] wherein R' represents a normalized R channel color vector, G' represents a normalized G channel color vector, B' represents a normalized B channel color vector, H represents an H channel color vector, S represents an S channel color vector, and V represents a V channel color vector.

[0082] The third color vector satisfies:

[0083] Y = 0.257 x R + 0.564 x G + 0.098 x B + 16

[0084] CB = -0.148 x R - 0.291 x G + 0.439 x B + 128

[0085] CR = 0.439 x R - 0.368 x G - 0.071 x B + 128

[0086] wherein R represents an R channel color vector, G represents a G channel color vector, B represents a B channel color vector, Y represents a Y channel color vector, CB represents a CB channel color vector, and CR represents a CR channel color vector.

[0087] Step S205: determining the recognition detection result according to the first image, the pseudo-depth image, the second image, and the third image.

[0088] Specifically, the length of the first image and the width of the first image are determined, the length of the first image is taken as the number of rows of the first matrix, the width of the first image is taken as the number of columns of the first matrix, the pixels of the R channel image are taken as the elements of the first channel in the first matrix, the pixels of the G channel image are taken as the elements of the second channel in the first matrix, and the pixels of the B channel image are taken as the elements of the third channel in the first matrix, to obtain the first matrix; the length of the pseudo-depth image and the width of the pseudo-depth image are determined, the length of the pseudo-depth image is taken as the number of rows of the second matrix, the width of the pseudo-depth image is taken as the number of columns of the second matrix, and the pixels of the pseudo-depth image are taken as the elements of the first channel in the second matrix, to obtain the second matrix; the length of the second image and the width of the second image are determined, the length of the second image is taken as the number of rows of the third matrix, the width of the second image is taken as the number of columns of the third matrix, the pixels of the H channel image are taken as the elements of the first channel in the third matrix, the pixels of the S channel image are taken as the elements of the second channel in the third matrix, and the pixels of the V channel image are taken as the elements of the third channel in the third matrix, to obtain the third matrix; the length of the third image and the width of the third image are determined, the length of the third image is taken as the number of rows of the fourth matrix, the width of the third image is taken as the number of columns of the fourth matrix, the pixels of the Y channel image are taken as the elements of the first channel in the fourth matrix, the pixels of the CB channel image are taken as the elements of the second channel in the fourth matrix, and the pixels of the CR channel image are taken as the elements of the third channel in the fourth matrix, to obtain the fourth matrix; the first matrix, the second matrix, the third matrix and the fourth matrix are subjected to feature channel superposition processing, and a feature splicing matrix is obtained through matrix merging; and the feature splicing matrix is input into the second model to determine the recognition detection result.

[0089] In the embodiments of the present application, the matrix size of the first matrix is (255, 255, 3), that is, (length of the first image, width of the first image, number of RGB channels), the matrix size of the second matrix is (255, 255, 1), that is, (length of the pseudo-depth image, width of the pseudo-depth image, number of pseudo-depth channels), the matrix size of the third matrix is (255, 255, 3), that is, (length of the second image, width of the second image, number of HSV channels), the matrix size of the fourth matrix is (255, 255, 3), that is, (length of the third image, width of the third image, number of YCBCR channels), the feature channel superposition processing is the superposition of matrix dimensions, the number of channels is superimposed through matrix merging, to obtain the feature splicing matrix, and the matrix size of the feature splicing matrix is (255, 255, 10). The feature splicing matrix is input into a residual network (RESNET) for feature extraction, and the recognition detection result is determined.

[0090] Optionally, the residual network can be replaced by other image feature extraction algorithms, such as VGGNET network and INCEPTION network.

[0091] In the embodiment of the present application, the other dimension information of the image to be detected is expanded by the methods of RGB three-channel separation, depth map prediction, HSV color model and YCBCR color model, the multi-channel image layers are superimposed and then the features are extracted, which can solve the problem of insufficient information load of single RGB channel image and improve the accuracy of silent image reprint detection.

[0092] As shown in Figure 4 , Figure 4 is a structural schematic diagram of a silent image reprint detection device provided by the embodiment of the present application, wherein the silent image reprint detection device comprises an acquisition module 401 and a processing module 402. The detailed description of each unit is as follows.

[0093] The acquisition module 401 is configured to acquire an image to be detected.

[0094] The image to be detected comprises a silent reprint image of a user.

[0095] The processing module 402 is configured to separate the image to be detected by RGB three channels to obtain a first image, and the first image comprises an R channel image, a G channel image and a B channel image.

[0096] The processing module 402 is further configured to input the image to be detected and the first image into a first model to perform depth map prediction and obtain a pseudo-depth image.

[0097] Specifically, the image to be detected is subjected to face detection to determine the position information of the face region in the image to be detected; the position information of the face region in the image to be detected and the first image are input into the first model to predict each pixel of the face region in the first image, and a pseudo-depth image is obtained.

[0098] The processing module 402 is further configured to input the first image into an HSV color model to obtain a second image, and input the first image into a YCBCR color model to obtain a third image.

[0099] The second image comprises an H channel image, an S channel image and a V channel image, and the third image comprises a Y channel image, a CB channel image and a CR channel image.

[0100] Specifically, a first color vector corresponding to a pixel in the first image is extracted, the first color vector including an R channel color vector, a G channel color vector and a B channel color vector, the first color vector is input into an HSV color model, a second color vector corresponding to the pixel in the second image is calculated, the second color vector including an H channel color vector, an S channel color vector and a V channel color vector; the first color vector is input into a YCBCR color model, a third color vector corresponding to the pixel in the third image is calculated, the third color vector including a Y channel color vector, a CB channel color vector and a CR channel color vector. The second color vector satisfies:

[0101] R'=R / 255

[0102] G'=G / 255

[0103] B'=B / 255

[0104] V=max(R',G',B')

[0105] when V is not equal to 0,

[0106] S=(V-min(R',G',B')) / V

[0107] when V is equal to 0,

[0108] =0

[0109] when V is equal to R',

[0110] H=60×(G'-B') / (V-min(R',G',B'))

[0111] when V is equal to G',

[0112] H=120+60×(B'-R') / (V-min(R',G',B'))

[0113] when V is equal to B',

[0114] H=240+60×(R'-G') / (V-min(R',G',B'))

[0115] wherein R' represents the normalized R channel color vector, G' represents the normalized G channel color vector, B' represents the normalized B channel color vector, H represents the H channel color vector, S represents the S channel color vector, and V represents the V channel color vector.

[0116] The third color vector satisfies:

[0117] Y=0.257×R+0.564×G+0.098×B+16

[0118] CB = -0.148 x R - 0.291 x G + 0.439 x B + 128

[0119] CR = 0.439 x R - 0.368 x G - 0.071 x B + 128

[0120] wherein R represents an R channel color vector, G represents a G channel color vector, B represents a B channel color vector, Y represents a Y channel color vector, CB represents a CB channel color vector, and CR represents a CR channel color vector.

[0121] Optionally, the processing module 402 is further configured to store the first image, the pseudo-depth image, the second image, and the third image obtained after step S204.

[0122] The processing module 402 is further configured to determine the recognition detection result according to the first image, the pseudo-depth image, the second image, and the third image.

[0123] Specifically, the first image, the pseudo-depth image, the second image, and the third image are subjected to feature transformation to obtain a first matrix, a second matrix, a third matrix, and a fourth matrix; the first matrix, the second matrix, the third matrix, and the fourth matrix are subjected to feature fusion to obtain a feature splicing matrix; and the feature splicing matrix is input into the second model to determine the recognition detection result.

[0124] In an embodiment, the length of the first image and the width of the first image are determined, the length of the first image is taken as the number of rows of the first matrix, the width of the first image is taken as the number of columns of the first matrix, the pixels of the R channel image are taken as the elements of the first channel in the first matrix, the pixels of the G channel image are taken as the elements of the second channel in the first matrix, and the pixels of the B channel image are taken as the elements of the third channel in the first matrix to obtain the first matrix; the length of the pseudo-depth image and the width of the pseudo-depth image are determined, the length of the pseudo-depth image is taken as the number of rows of the second matrix, the width of the pseudo-depth image is taken as the number of columns of the second matrix, and the pixels of the pseudo-depth image are taken as the elements of the first channel in the second matrix to obtain the second matrix; the length of the second image and the width of the second image are determined, the length of the second image is taken as the number of rows of the third matrix, the width of the second image is taken as the number of columns of the third matrix, the pixels of the H channel image are taken as the elements of the first channel in the third matrix, the pixels of the S channel image are taken as the elements of the second channel in the third matrix, and the pixels of the V channel image are taken as the elements of the third channel in the third matrix to obtain the third matrix; and the length of the third image and the width of the third image are determined, the length of the third image is taken as the number of rows of the fourth matrix, the width of the third image is taken as the number of columns of the fourth matrix, the pixels of the Y channel image are taken as the elements of the first channel in the fourth matrix, the pixels of the CB channel image are taken as the elements of the second channel in the fourth matrix, and the pixels of the CR channel image are taken as the elements of the third channel in the fourth matrix to obtain the fourth matrix.

[0125] It should be noted that the processing module 402 is configured to perform the actions or steps performed by the image detection module 102 in the above method embodiments. The acquisition module 401 is configured to perform the actions or steps performed by the image acquisition module 101 in the above method embodiments. The implementation of each module can also correspond to the description of the corresponding method embodiments shown in the above method embodiments, and the methods and functions performed by the image acquisition module 101 and the image detection module 102 in the above embodiments are performed. Figure 2

[0126] The foregoing describes in detail the silent image flipping detection system provided by the present application, and how to realize the silent image flipping detection process by using the system. The following describes the deployment mode of the silent image flipping detection system. Figure 5

[0127] As shown in Figure 5 Figure 5 is a structural schematic diagram of a server provided by an embodiment of the present application. The server includes a processor 501, a memory 502, and a transceiver 503. The processor 501, the memory 502, and the transceiver 503 can communicate with each other through a communication bus 504 to transfer instructions and / or data signals. The memory 502 is configured to store a computer program, and the processor 501 is configured to call and run the computer program from the memory 502 to control the transceiver 503 to transceive signals.

[0128] The processor 501 can correspond to the processing module 402 in Figure 4 The processor 501 and the memory 502 can be combined into one processing device. The processor 501 is configured to execute program codes stored in the memory 502 to implement the above functions. In a specific implementation, the memory 502 can be integrated in the processor 501 or independent of the processor 501.

[0129] The transceiver 503 can also be referred to as a transceiving unit or a transceiving module. The transceiver 503 can include a receiver (or receiver circuit) and a transmitter (or transmitter circuit). The receiver is configured to receive signals, and the transmitter is configured to send signals.

[0130] It should be understood that the server shown in Figure 5 is capable of implementing each process of the silent image flipping detection system in the method embodiments shown in Figure 2 The operations and / or functions of each module in the server are respectively implemented to realize the corresponding processes in the above method embodiments. For details, reference can be made to the description in the above method embodiments. To avoid repetition, the detailed description is appropriately omitted here.

[0131] ​​​The processor 501 can be a central processing unit, a general-purpose processor, a digital signal processor, an application-specific integrated circuit (ASIC), a field-programmable gate array (FPGA), or other programmable logic devices, transistor logic devices, hardware components, or any combination thereof. It can implement or execute various exemplary modules described in conjunction with the disclosure of this application. The processor 501 can also be a combination that implements computing functions, such as a combination of one or more microprocessors, a combination of a digital signal processor and a microprocessor, etc. The communication bus 504 can be a peripheral component interconnect standard PCI bus or an extended industry standard structure EISA bus, etc. The bus can be divided into an address bus, a data bus, a control bus, etc. For ease of representation, Figure 5 The bus is represented by a single thick line, but this does not imply that there is only one bus or one type of bus. The communication bus 504 is used to implement communication between these components. In this embodiment, the memory 502 may include volatile memory, such as nonvolatile random access memory (NVRAM), phase change RAM (PRAM), magnetoresistive RAM (MRAM), etc., and may also include non-volatile memory, such as at least one disk storage device, electrically erasable programmable read-only memory (EEPROM), flash memory devices, such as NOR flash memory or NAND flash memory, and semiconductor devices, such as solid-state disks (SSDs). Optionally, the memory 502 may also be at least one storage device located remotely from the aforementioned processor 501. Optionally, the memory 502 may also store a set of computer program code or configuration information. Optionally, the processor 501 may also execute the program stored in the memory 502. The transceiver 503 is used for communication of instructions or data with other components. The processor, in conjunction with the memory and the transceiver, can execute any of the methods and functions of the silent image reproduction detection system described in the above embodiments.

[0132] According to the method provided in the embodiments of this application, this application also provides a computer program product, which includes: a computer program that, when run on a computer, causes the computer to perform... Figure 1 or Figure 2 The method of any one of the embodiments shown.

[0133] According to the method provided in the embodiments of the present application, the present application further provides a computer readable medium storing a computer program, which, when executed on a computer, causes the computer to perform the method of any one of the embodiments shown in the above. Figure 1 or Figure 2 the method of any one of the embodiments shown in the above.

[0134] In the above embodiments, the implementation can be achieved by software, hardware, firmware or any combination thereof, entirely or partially. When implemented by software, the implementation can be in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer instructions are loaded and executed on a computer, the entire or partial processes or functions described in the embodiments of the present application are generated. The computer can be a general purpose computer, a special purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer readable storage medium or transferred from one computer readable storage medium to another computer readable storage medium, for example, the computer instructions can be transferred from one website, computer, server or data center to another website, computer, server or data center through wired (such as coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (such as infrared, wireless, microwave, etc.) manner. The computer readable storage medium can be any available medium that can be accessed by a computer or a data storage device such as a server, data center, etc. integrated with one or more available media. The readable medium can be a magnetic medium (such as floppy disk, hard disk, magnetic tape), optical medium (such as high-density digital video disc (digital video disc, DVD)), or semiconductor medium (such as solid state disc (solid state disc, SSD)) and the like.

[0135] The "multiple" appearing in the embodiments of the present application refers to two or more.

[0136] The first, second and the like appearing in the embodiments of the present application are only for illustration and differentiation of the described objects, and there is no order, nor does it represent a special limitation on the number of the described objects in the embodiments of the present application, and cannot constitute any limitation on the embodiments of the present application.

[0137] The above specific embodiments further illustrate the purpose, technical solutions and beneficial effects of the present application. Any modification, equivalent replacement, improvement and the like made within the principles of the present application shall be included in the protection scope of the present application.

Claims

1. A method for detecting a silent image retake, the method comprising: The method comprises the following steps: acquiring a to-be-detected image, wherein the to-be-detected image comprises a still flip image of a user; performing RGB three-channel separation on the to-be-detected image to obtain a first image, wherein the first image comprises an R channel image, a G channel image and a B channel image; inputting the to-be-detected image and the first image into a first model to perform depth map prediction and obtain a pseudo-depth image; inputting the first image into an HSV color model to obtain a second image, and inputting the first image into a YCBCR color model to obtain a third image, wherein the second image comprises an H channel image, an S channel image and a V channel image, and the third image comprises a Y channel image, a CB channel image and a CR channel image; determining a recognition detection result according to the first image, the pseudo-depth image, the second image and the third image.

2. The method of claim 1, wherein, The step of determining the recognition detection result according to the first image, the pseudo-depth image, the second image and the third image comprises the following steps: performing feature transformation on the first image, the pseudo-depth image, the second image and the third image to obtain a first matrix, a second matrix, a third matrix and a fourth matrix; performing feature fusion on the first matrix, the second matrix, the third matrix and the fourth matrix to obtain a feature splicing matrix; inputting the feature splicing matrix into a second model to determine the recognition detection result.

3. The method of claim 2, wherein, The step of performing feature transformation on the first image, the pseudo-depth image, the second image and the third image to obtain a first matrix, a second matrix, a third matrix and a fourth matrix comprises the following steps: determining the length of the first image and the width of the first image, taking the length of the first image as the row number of the first matrix, taking the width of the first image as the column number of the first matrix, taking the pixels of the R channel image as the elements of the first channel in the first matrix, taking the pixels of the G channel image as the elements of the second channel in the first matrix, and taking the pixels of the B channel image as the elements of the third channel in the first matrix to obtain the first matrix; determining the length of the pseudo-depth image and the width of the pseudo-depth image, taking the length of the pseudo-depth image as the row number of the second matrix, taking the width of the pseudo-depth image as the column number of the second matrix, and taking the pixels of the pseudo-depth image as the elements of the first channel in the second matrix to obtain the second matrix; determining the length of the second image and the width of the second image, taking the length of the second image as the row number of the third matrix, taking the width of the second image as the column number of the third matrix, taking the pixels of the H channel image as the elements of the first channel in the third matrix, taking the pixels of the S channel image as the elements of the second channel in the third matrix, and taking the pixels of the V channel image as the elements of the third channel in the third matrix to obtain the third matrix; determining a length of the third image and a width of the third image, taking the length of the third image as a row number of the fourth matrix, taking the width of the third image as a column number of the fourth matrix, taking pixels of the Y channel image as elements of a first channel in the fourth matrix, taking pixels of the CB channel image as elements of a second channel in the fourth matrix, and taking pixels of the CR channel image as elements of a third channel in the fourth matrix, to obtain the fourth matrix.

4. The method of claim 2, wherein, The feature fusion of the first matrix, the second matrix, the third matrix and the fourth matrix comprises: The feature channel superposition processing of the first matrix, the second matrix, the third matrix and the fourth matrix is performed to obtain the feature splicing matrix through matrix merging.

5. The method of claim 1, wherein, The depth map prediction of the to-be-detected image and the first image in the first model comprises: performing face detection on the to-be-detected image to determine position information of a face region in the to-be-detected image; inputting the position information of the face region in the to-be-detected image and the first image into the first model to perform prediction on each pixel of the face region in the first image, to obtain the pseudo-depth image.

6. The method of claim 1, wherein, The input of the first image into the HSV color model to obtain a second image and the input of the first image into the YCBCR color model to obtain a third image comprise: inputting the R channel image, the G channel image and the B channel image into the HSV color model to convert to obtain the H channel image, the S channel image and the V channel image; inputting the R channel image, the G channel image and the B channel image into the YCBCR color model to convert to obtain the Y channel image, the CB channel image and the CR channel image.

7. A silent image rephotographing detection apparatus characterized by comprising: comprise: an acquisition module configured to acquire a to-be-detected image, the to-be-detected image comprising a still flip image of a user in silence; a processing module configured to perform RGB three-channel separation on the to-be-detected image to obtain a first image, the first image comprising an R channel image, a G channel image and a B channel image; The processing module is further configured to perform depth map prediction on the to-be-detected image and the first image in a first model to obtain a pseudo-depth image. The processing module is further configured to input the first image into an HSV color model to obtain a second image, and input the first image into a YCBCR color model to obtain a third image, the second image comprising an H channel image, an S channel image and a V channel image, and the third image comprising a Y channel image, a CB channel image and a CR channel image. The processing module is further configured to determine an identification detection result according to the first image, the pseudo-depth image, the second image and the third image.

8. The apparatus of claim 7, wherein the processing module is further configured to perform feature transformation on the first image, the pseudo-depth image, the second image and the third image to obtain a first matrix, a second matrix, a third matrix and a fourth matrix. The processing module is further configured to perform feature fusion on the first matrix, the second matrix, the third matrix, and the fourth matrix to obtain a feature splicing matrix. The processing module is further configured to input the feature splicing matrix into a second model to determine the recognition detection result.

9. The apparatus of claim 7, wherein, The processing module is further configured to perform face detection on the to-be-detected image to determine position information of a face region in the to-be-detected image. The processing module is further configured to input the position information of the face region in the to-be-detected image and the first image into the first model to perform prediction on each pixel of the face region in the first image to obtain the pseudo-depth image.

10. A silent image rephotographing detection apparatus characterized by comprising: The apparatus includes a processor and a memory, the memory is configured to store a computer program, and the processor is configured to call the computer program to perform the method of any one of claims 1-6.

Citation Information

Patent Citations

  • Anti-counterfeiting method for face detection and face recognition device with anti-counterfeiting function

    CN110008878A

  • Facial liveness detection method, terminal device and computer-readable storage medium

    WO2022199395A1