Image processing method and device

By establishing the correlation between the visible area and the invisible area of ​​the target object in image processing, and using the attention mechanism and feature vectors to perform image repair, the problem of poor image repair effect in the existing technology is solved, and the image processing is improved. accuracy and performance of neural network models.

CN113222830BActive Publication Date: 2024-10-15BEIJING ZITIAO NETWORK TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110246084.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-03-05
Publication Date
2024-10-15
Estimated Expiration
2041-03-05

AI Technical Summary

Technical Problem

Existing image processing methods fail to effectively capture the areas and content that need to be completed in the image during the image repair process, resulting in a decline in the processing performance of the neural network model and affecting the results of tasks such as target tracking, target detection, and image segmentation.

Method used

By obtaining the mask of the visible area of ​​the image to be processed, the correlation between the visible area and the invisible area of ​​the target object is established, an attention mechanism is introduced to accurately infer the content of the invisible area of ​​the target object, and feature vectors and mask features are used The vectors are subjected to dot multiplication and matrix operations to generate a correlation matrix diagram to represent the relationship, thereby completing the invisible areas of the target object.

Benefits of technology

It improves the accuracy and timeliness of image restoration, improves the processing performance of the neural network model, and ensures the reliability of tasks such as target tracking, target detection, and image segmentation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113222830B_ABST
    Figure CN113222830B_ABST
Patent Text Reader

Abstract

The present disclosure relates to an image processing method and device. The method comprises: obtaining a mask of a visible area of ​​an image to be processed, wherein the image to be processed contains a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object that is not blocked by the occluder, or the visible area is an area of ​​the image to be processed other than an area of ​​the target object blocked by the occluder; obtaining a correlation between the visible area of ​​the image to be processed and an invisible area of ​​the target object according to the image to be processed and the mask of the visible area; and completing the content of the invisible area of ​​the target object according to the image to be processed and the correlation. Thus, based on the correlation between the visible area of ​​the processed image and the invisible area of ​​the target object, the content of the invisible area of ​​the target object is accurately inferred, and tasks such as target tracking, target detection, and image segmentation are completed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present disclosure relates to the field of image processing technology, and in particular to an image processing method and device. Background Art

[0002] In the process of image acquisition, affected by factors such as lighting, equipment, and algorithms, images are easily damaged or interfered by noise, resulting in the image being unable to correctly express the content. Therefore, image inpainting has become one of the important steps in computer vision task preprocessing, and is directly related to the results of tasks such as target tracking, target detection, and image segmentation.

[0003] At present, neural network models are often used to complete images in the image restoration process. Neural network models usually directly apply the attention mechanism without considering the content of the image that needs to be completed in the specific task, resulting in the inability to successfully capture the area of ​​the image that needs to be completed, and the inability to accurately infer the content of the image that needs to be completed, which reduces the processing performance of the neural network model and is not conducive to achieving tasks such as target tracking, target detection, and image segmentation. Summary of the invention

[0004] In order to solve the above technical problem or at least partially solve the above technical problem, the present disclosure provides an image processing method and device.

[0005] In a first aspect, the present disclosure provides an image processing method, comprising:

[0006] Obtaining a mask of a visible area of ​​the image to be processed, wherein the image to be processed includes a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object not blocked by the occluder, or the visible area is an area of ​​the image to be processed excluding an area of ​​the target object blocked by the occluder;

[0007] According to the image to be processed and the mask of the visible area, a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object is obtained, where the invisible area of ​​the target object is an area of ​​the target object blocked by the occluder;

[0008] According to the image to be processed and the relevant relationship, the content of the invisible area of ​​the target object is completed.

[0009] Through the method provided in the first aspect, the factors that the invisible area of ​​the target object and the visible area of ​​the image to be processed have a correlation, and the invisible area of ​​the target object and the background area in the image to be processed have no correlation are fully taken into consideration. The mask of the visible area of ​​the image to be processed can be introduced into the attention mechanism, so that the attention mechanism can determine the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object based on the mask of the visible area of ​​the image to be processed, so as to accurately infer the content of the invisible area of ​​the target object based on the correlation between the visible area of ​​the processed image and the invisible area of ​​the target object, thereby realizing the completion of the content of the invisible area of ​​the target object in the image to be processed, improving the accuracy and timeliness of completing the content of the invisible area of ​​the target object, and facilitating the reliable completion of tasks such as target tracking, target detection, and image segmentation.

[0010] In a possible design, according to the image to be processed and the mask of the visible area, the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object is obtained, including: obtaining a first feature map corresponding to the image to be processed; according to a first feature vector corresponding to the first feature map, a first mask feature vector corresponding to the mask of the visible area, a second feature vector corresponding to the first feature map, and a second mask feature vector corresponding to the mask of the visible area, obtaining a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector, wherein the first feature vector and the second feature vector have different semantic information, and the first mask feature vector and the second mask feature vector have different dimensional orders; according to the first feature and the second feature, a correlation matrix diagram is obtained, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0011] In a possible design, according to the first feature vector corresponding to the first feature map, the first mask feature vector corresponding to the mask of the visible area, the second feature vector corresponding to the first feature map, and the second mask feature vector corresponding to the mask of the visible area, a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector are obtained, including: performing a dot product of the first feature vector corresponding to the first feature map and the first mask feature vector corresponding to the mask of the visible area to obtain a first dot product result for representing the first feature; performing a dot product of the second feature vector corresponding to the first feature map and the second mask feature vector corresponding to the mask of the visible area to obtain a second dot product result for representing the second feature; and obtaining a correlation matrix diagram according to the first feature and the second feature, including: performing a matrix multiplication operation on the first dot product result and the second dot product result to obtain a correlation matrix diagram. In a possible design, the method also includes: obtaining a mask of an invisible area of ​​a target object of an image to be processed; obtaining a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area, including: obtaining a first feature map corresponding to the image to be processed; obtaining a third feature of the visible area corresponding to the fourth feature vector and a fourth feature of the invisible area corresponding to the fifth feature vector according to a fourth feature vector corresponding to the first feature map, a third mask feature vector corresponding to the mask of the visible area, a fifth feature vector corresponding to the first feature map, and a fourth mask feature vector corresponding to the mask of the invisible area, wherein the fourth feature vector and the fifth feature vector have different semantic information, and the third mask feature vector and the fourth mask feature vector have different dimensional orders; obtaining a correlation matrix diagram according to the third feature and the fourth feature, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0012] In one possible design, according to the fourth eigenvector corresponding to the first feature map, the third mask eigenvector corresponding to the mask of the visible area, the fifth eigenvector corresponding to the first feature map, and the fourth mask eigenvector corresponding to the mask of the invisible area, the third feature of the visible area corresponding to the fourth eigenvector and the fourth feature of the invisible area corresponding to the fifth eigenvector are obtained, including: performing a dot product of the fourth eigenvector corresponding to the first feature map and the third mask eigenvector corresponding to the mask of the visible area to obtain a third dot product result for representing the third feature; performing a dot product of the fifth eigenvector corresponding to the first feature map and the fourth mask eigenvector corresponding to the mask of the invisible area to obtain a fourth dot product result for representing the fourth feature; and obtaining a correlation matrix diagram according to the third feature and the fourth feature, including: performing a matrix multiplication operation on the third dot product result and the fourth dot product result to obtain a correlation matrix diagram.

[0013] In one possible design, the content of the invisible area of ​​the target object is completed according to the image to be processed and the correlation relationship, including: obtaining the second feature map corresponding to the image to be processed according to the correlation matrix diagram and the third feature vector corresponding to the first feature map; and completing the content of the invisible area of ​​the target object according to the second feature map.

[0014] In a possible design, a second feature map corresponding to the image to be processed is obtained according to the correlation matrix map and the third eigenvector corresponding to the first feature map, including: performing matrix multiplication and normalization processing on the correlation matrix map and the third eigenvector corresponding to the first feature map to obtain a second processed feature vector, and the second processed feature vector is used to enhance the features corresponding to the content of the invisible area of ​​the target object; performing dimensionality transformation processing on the second processed feature vector to obtain a second feature map.

[0015] In one possible design, the method also includes: performing convolution processing on the first feature map using a convolution operation, and vectorizing the first feature map after the convolution processing to obtain a third feature vector; or, performing vectorization processing on the first feature map to obtain a third feature vector; wherein the number of channels of the third feature vector is the same as the number of channels of the first feature map.

[0016] In one possible design, the method also includes: performing channel number dimensionality reduction processing on the first feature map using a convolution operation, and performing vectorization processing on the first feature map after the dimensionality reduction processing to obtain a first eigenvector, a second eigenvector, a fourth eigenvector or a fifth eigenvector corresponding to the first feature map; wherein the second eigenvector and the first eigenvector have the same number of channels, and the fourth eigenvector and the fifth eigenvector have the same number of channels.

[0017] In a second aspect, the present disclosure provides an image processing device, comprising:

[0018] An acquisition module, used to acquire a mask of a visible area of ​​an image to be processed, wherein the image to be processed includes a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object not blocked by the occluder, or the visible area is an area of ​​the image to be processed except an area of ​​the target object blocked by the occluder;

[0019] The acquisition module is further used to acquire the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area, wherein the invisible area of ​​the target object is the area of ​​the target object blocked by the occluder;

[0020] The processing module is used to complete the content of the invisible area of ​​the target object according to the image to be processed and the relevant relationship.

[0021] In a possible design, an acquisition module is specifically used to acquire a first feature map corresponding to an image to be processed; a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector are obtained according to a first feature vector corresponding to the first feature map, a first mask feature vector corresponding to a mask of a visible area, a second feature vector corresponding to the first feature map, and a second mask feature vector corresponding to the mask of the visible area, wherein the first feature vector and the second feature vector have different semantic information, and the first mask feature vector and the second mask feature vector have different dimensional orders; a correlation matrix diagram is obtained according to the first feature and the second feature, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0022] In one possible design, the acquisition module is specifically used to perform a dot product on a first feature vector corresponding to the first feature map and a first mask feature vector corresponding to the mask of the visible area to obtain a first dot product result for representing the first feature; perform a dot product on a second feature vector corresponding to the first feature map and a second mask feature vector corresponding to the mask of the visible area to obtain a second dot product result for representing the second feature; perform a matrix multiplication operation on the first dot product result and the second dot product result to obtain a correlation matrix diagram.

[0023] In a possible design, the acquisition module is further used to acquire a mask of an invisible region of a target object of the image to be processed;

[0024] The acquisition module is specifically used to acquire a first feature map corresponding to the image to be processed; according to the fourth eigenvector corresponding to the first feature map, the third mask feature vector corresponding to the mask of the visible area, the fifth eigenvector corresponding to the first feature map, and the fourth mask feature vector corresponding to the mask of the invisible area, the third feature of the visible area corresponding to the fourth eigenvector and the fourth feature of the invisible area corresponding to the fifth eigenvector are obtained, the semantic information of the fourth eigenvector is different from that of the fifth eigenvector, and the dimensional order of the third mask feature vector is different from that of the fourth mask feature vector; according to the third feature and the fourth feature, a correlation matrix diagram is obtained, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0025] In one possible design, the acquisition module is specifically used to perform a dot product on the fourth eigenvector corresponding to the first feature map and the third mask eigenvector corresponding to the mask of the visible area to obtain a third dot product result for representing the third feature; perform a dot product on the fifth eigenvector corresponding to the first feature map and the fourth mask eigenvector corresponding to the mask of the invisible area to obtain a fourth dot product result for representing the fourth feature; perform a matrix operation on the third dot product result and the fourth dot product result to obtain a correlation matrix diagram.

[0026] In one possible design, the processing module is specifically used to obtain a second feature map corresponding to the image to be processed based on the correlation matrix map and the third feature vector corresponding to the first feature map; and complete the content of the invisible area of ​​the target object based on the second feature map.

[0027] In one possible design, a processing module is used to perform matrix multiplication and normalization processing on the correlation matrix graph and the third eigenvector corresponding to the first feature graph to obtain a second processed eigenvector, and the second processed eigenvector is used to enhance the features corresponding to the content of the invisible area of ​​the target object; and perform dimensionality transformation processing on the second processed eigenvector to obtain a second feature graph.

[0028] In one possible design, the processing module is further used to perform convolution processing on the first feature map using a convolution operation, and vectorize the first feature map after the convolution processing to obtain a third feature vector; or, vectorize the first feature map to obtain the third feature vector; wherein the number of channels of the third feature vector is the same as the number of channels of the first feature map.

[0029] In one possible design, the processing module is also used to use a convolution operation to reduce the number of channels of the first feature map, and to vectorize the first feature map after the dimensionality reduction to obtain a first eigenvector, a second eigenvector, a fourth eigenvector or a fifth eigenvector corresponding to the first feature map; wherein the second eigenvector and the first eigenvector have the same number of channels, and the fourth eigenvector and the fifth eigenvector have the same number of channels.

[0030] The beneficial effects of the image processing device provided in the above-mentioned second aspect and each possible design of the above-mentioned second aspect can be referred to the beneficial effects brought about by the above-mentioned first aspect and each possible implementation method of the first aspect, and will not be repeated here.

[0031] In a third aspect, the present disclosure provides an electronic device, comprising: a memory and a processor; the memory is used to store program instructions; the processor is used to call the program instructions in the memory so that the electronic device executes the image processing method in the first aspect and any possible design of the first aspect.

[0032] In a fourth aspect, the present disclosure provides a computer storage medium, including computer instructions, which, when executed on an electronic device, enables the electronic device to execute the image processing method in the first aspect and any possible design of the first aspect.

[0033] In a fifth aspect, the present disclosure provides a computer program product. When the computer program product runs on a computer, it enables the computer to execute the image processing method in the first aspect and any possible design of the first aspect.

[0034] In a sixth aspect, the present disclosure provides a chip system, the chip system comprising: a processor; when the processor executes computer instructions stored in a memory, the electronic device executes the image processing method in the first aspect and any possible design of the first aspect. BRIEF DESCRIPTION OF THE DRAWINGS

[0035] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the present disclosure and, together with the description, serve to explain the principles of the present disclosure.

[0036] In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, for ordinary technicians in this field, other drawings can be obtained based on these drawings without paying any creative labor.

[0037] Figure 1 A flowchart of an image processing method provided by an embodiment of the present disclosure;

[0038] Figure 2 A schematic diagram of the structures of 19 parts of a human body provided in an embodiment of the present disclosure;

[0039] Figure 3A A working principle diagram of the image processing method provided by the embodiment of the present disclosure;

[0040] Figure 3B A flowchart of an image processing method provided by an embodiment of the present disclosure;

[0041] Figure 4A A working principle diagram of the image processing method provided by the embodiment of the present disclosure;

[0042] Figure 4B A flowchart of an image processing method provided by an embodiment of the present disclosure;

[0043] Figure 5 A flowchart of an image processing method provided by an embodiment of the present disclosure;

[0044] Figure 6 A schematic diagram of the structure of an image processing device provided in an embodiment of the present disclosure. DETAILED DESCRIPTION

[0045] In order to more clearly understand the above-mentioned objectives, features and advantages of the present disclosure, the scheme of the present disclosure will be further described below. It should be noted that the embodiments of the present disclosure and the features in the embodiments can be combined with each other without conflict.

[0046] In the following description, many specific details are set forth to facilitate a full understanding of the present disclosure, but the present disclosure may also be implemented in other ways different from those described herein; it is obvious that the embodiments in the specification are only part of the embodiments of the present disclosure, rather than all of the embodiments.

[0047] Exemplarily, the present disclosure provides an image processing method, apparatus, device, computer storage medium and computer program product, which introduce the correlation between the area of ​​the target object not obscured by the occluder and the area of ​​the target object obscured by the occluder into the attention mechanism, guide the neural network model to capture the attention on the correlation between the area of ​​the target object obscured by the occluder and the area of ​​the target object not obscured by the occluder, weaken the features on the background area, thereby completing the content of the area of ​​the target object obscured by the occluder, improving the accuracy of inferring the content of the area of ​​the target object obscured by the occluder, improving the processing performance of the neural network model, and also facilitating the realization of tasks such as target tracking, target detection, and image segmentation.

[0048] The image processing method of the present disclosure is performed by an electronic device. The electronic device may be a tablet computer, a mobile phone (such as a folding screen mobile phone, a large screen mobile phone, etc.), a wearable device, a vehicle-mounted device, an augmented reality (AR) / virtual reality (VR) device, a laptop computer, an ultra-mobile personal computer (UMPC), a netbook, a personal digital assistant (PDA), a smart TV, a smart screen, a high-definition TV, a 4K TV, a smart speaker, a smart projector, and other Internet of Things (IOT) devices. The present disclosure does not impose any restrictions on the specific types of electronic devices.

[0049] Based on the foregoing description, the present disclosure will use an electronic device as an example in an embodiment to elaborate on the image processing method provided by the present disclosure in detail in combination with the accompanying drawings and application scenarios.

[0050] See also Figure 1 , Figure 1 Schematic diagram of the process flow of the image processing method provided by the embodiment of the present disclosure. Figure 1 As shown, the image processing method provided by the present disclosure may include:

[0051] S101: Obtain a mask of a visible area of ​​an image to be processed.

[0052] The electronic device may obtain an image to be processed. The image to be processed includes a target object, and a portion of the target object is blocked by an obstruction. The present disclosure does not limit parameters such as the size, format, and content of the image to be processed. Furthermore, the target object may include, but is not limited to, a human body, an animal, or an object.

[0053] The electronic device may process the visible area of ​​the image to be processed and obtain a mask of the visible area of ​​the image to be processed.

[0054] The visible area is the area of ​​the target object that is not blocked by the occluder. That is, in the image to be processed, the area related to the target object may include: the visible area of ​​the target object and the invisible area of ​​the target object. The present disclosure does not limit the size, shape, position and other parameters of the area of ​​the target object that is not blocked by the occluder and the area of ​​the target object that is blocked by the occluder.

[0055] Alternatively, the visible area is the area of ​​the image to be processed except the area where the target object is blocked by the occluder. That is, the image to be processed includes two areas, namely, the area where the target object is blocked by the occluder (the invisible area of ​​the target object), and the area except the area where the target object is blocked by the occluder (the background area and the visible area of ​​the target object).

[0056] Based on the above description, since there is no correlation between the background area and the invisible area of ​​the target object, and there is a correlation between the visible area of ​​the target object and the invisible area of ​​the target object, the electronic device can determine the mask of the visible area of ​​the target object as the mask of the visible area of ​​the image to be processed, which is conducive to intuitively representing the visible area of ​​the target object, and can also determine the mask of the visible area of ​​the target object and the mask of the background area as the mask of the visible area of ​​the image to be processed, which is conducive to highlighting the visible area of ​​the target object and increasing the redundancy of the calculation.

[0057] The mask of the visible area of ​​the image to be processed may be understood as a code formed by dividing each part of the visible area of ​​the image to be processed, and each part corresponds to 0 or 1.

[0058] For example, assuming that the visible area of ​​the image to be processed is the visible area of ​​the target object, and when the target object is a human body, the electronic device can divide the human body into N parts, and mark the N parts respectively with a number 0 or 1 to obtain a mask of the human body, that is, a mask of the visible area of ​​the image to be processed, where N is a positive integer.

[0059] See also Figure 2 , when N = 19, such as Figure 2As shown, the 19 parts of the human body may include: head a1, neck a2, left shoulder a3, right shoulder a4, left upper arm a5, right upper arm a6, left lower arm a7, right lower arm a8, left hand a9, right hand a10, left hip a11, right hip a12, left thigh a13, right thigh a14, left calf a15, right calf a16, left foot a17, right foot a18 and body a19, and the mask of the human body is a code formed by the 19 parts of the human body corresponding to the numbers 0 or 1. In addition, the present disclosure is not limited to dividing the human body into 19 parts.

[0060] S102: Obtain a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area.

[0061] Since the mask of the visible area of ​​the image to be processed can represent the visible area of ​​the image to be processed, and the area in the image to be processed except the visible area of ​​the image to be processed is the invisible area of ​​the target object, the electronic device can obtain the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object based on the image to be processed and the mask of the visible area of ​​the image to be processed.

[0062] The present disclosure does not limit the representation of the above correlation. In addition, the above correlation can also be used to represent the correlation between the image to be processed and the invisible area of ​​the target object, and can also be used to represent the correlation between the image to be processed and the visible area of ​​the image to be processed.

[0063] S103: Completing the content of the invisible area of ​​the target object according to the image to be processed and the correlation relationship.

[0064] Based on the correlation and the image to be processed, the electronic device can associate the characteristics of the visible area of ​​the target object with the characteristics of the invisible area of ​​the target object, infer the content of the invisible area of ​​the target object through the visible area of ​​the target object, and thus complete the content of the invisible area of ​​the target object, so as to output the image to be processed after the invisible area of ​​the target object is completed.

[0065] In addition, the electronic device can also obtain a mask of the complete area of ​​the target object based on the correlation and the image to be processed, and can also obtain a parsed mask of the complete area of ​​the target object.

[0066] The image processing method provided by the present disclosure can introduce a mask of the visible area of ​​the image to be processed into the attention mechanism by fully considering the factors that the invisible area of ​​the target object and the visible area of ​​the image to be processed are correlated, and that the invisible area of ​​the target object and the background area in the image to be processed are not correlated, so that the attention mechanism can determine the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object based on the mask of the visible area of ​​the image to be processed, so as to accurately infer the content of the invisible area of ​​the target object based on the correlation between the visible area of ​​the processed image and the invisible area of ​​the target object, thereby realizing the completion of the content of the invisible area of ​​the target object in the image to be processed, improving the accuracy and timeliness of completing the content of the invisible area of ​​the target object, and facilitating the reliable completion of tasks such as target tracking, target detection, and image segmentation.

[0067] Based on the description of step S102 above, the electronic device may adopt various implementation methods to obtain the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area.

[0068] Next, combine Figure 3A-3B as well as Figure 4A-4B , two feasible implementation methods for an electronic device to obtain the correlation between a visible area of ​​an image to be processed and an invisible area of ​​a target object are introduced.

[0069] See also Figure 3A and Figure 3B , Figure 3A A working principle diagram of the image processing method provided by the embodiment of the present disclosure, Figure 3B Schematic diagram of the process flow of the image processing method provided by the embodiment of the present disclosure. Figure 3A and Figure 3B As shown, the image processing method of the present disclosure may include:

[0070] S201. Obtain a first feature map corresponding to an image to be processed.

[0071] The electronic device may use a neural network model to perform multi-layer convolution processing on the image to be processed to obtain a first feature map corresponding to the image to be processed. For ease of explanation, Figure 3A F i is the first feature map, the first feature map F i The size can be written as C×H×W, where C is the channel height, H is the length, and W is the width.

[0072] S202, according to the first feature vector corresponding to the first feature map, the first mask feature vector corresponding to the mask of the visible area, the second feature vector corresponding to the first feature map, and the second mask feature vector corresponding to the mask of the visible area, obtain the first feature of the visible area corresponding to the first feature vector and the second feature of the visible area corresponding to the second feature vector. The electronic device can use a convolution operation to reduce the number of channels of the first feature map, and vectorize the first feature map after the dimensionality reduction process to obtain the first feature vector corresponding to the first feature map. For ease of explanation, Figure 3A F i q1 is the first eigenvector, the first eigenvector F i q1 The size can be recorded as C / 8×HW.

[0073] Accordingly, the electronic device may sample the mask of the visible area of ​​the image to be processed to keep the same size as the first feature vector to obtain the first mask feature vector. Figure 3A M p1 is the first mask feature vector, the first mask feature vector M p1 The size can be recorded as 1×HW.

[0074] The electronic device may use a convolution operation to perform channel number dimensionality reduction processing on the first feature map, and perform vectorization processing on the first feature map after dimensionality reduction processing to obtain a second feature vector corresponding to the first feature map. For ease of explanation, Figure 3A F i k1 is the second eigenvector, the second eigenvector F i k1 The size can be recorded as HW×C / 8.

[0075] Accordingly, the electronic device may sample the mask of the visible area of ​​the image to be processed to keep the same size as the second feature vector to obtain the second mask feature vector. Figure 3A M p2 is the second mask feature vector, the second mask feature vector M p2 The size can be recorded as HW×1.

[0076] Among them, the semantic information of the first feature vector is different from that of the second feature vector, and the dimension order of the first mask feature vector is different from that of the second mask feature vector. The semantic information here can be understood as different angles of the first feature map, such as brightness and color. The dimension order can be understood as different orders of length, width and height, such as the order of length, width and height, and the order of height, length and width.

[0077] It can be seen that the first mask feature vector corresponds to the visible area of ​​the target object, or the first mask feature vector corresponds to the visible area of ​​the target object and the background area. The second mask feature vector corresponds to the visible area of ​​the target object, or the second mask feature vector corresponds to the visible area of ​​the target object and the background area.

[0078] Among them, the second eigenvector has the same number of channels as the first eigenvector, which is beneficial to reducing the amount of calculation. The above-mentioned vectorization processing can be understood as a flattening processing, which is beneficial to reducing the amount of calculation. In general, the dimensionality reduction processing in the process of obtaining the first eigenvector and the second eigenvector can adopt a layer of convolution processing.

[0079] It should be noted that the present disclosure is not limited to obtaining the first feature vector, the second feature vector, the first mask feature vector and the second mask feature vector in the above manner. For example, after obtaining the first mask feature vector, the electronic device may determine the transpose of the first mask feature vector as the second mask feature vector.

[0080] Thus, the electronic device can obtain the first feature and the second feature based on the first feature vector, the first mask feature vector, the second feature vector and the second mask feature vector. Figure 3A The electronic device may use a neural network model to perform a dot product process on the first feature vector and the first mask feature vector to obtain a first dot product result for representing the first feature. Thus, the features of the visible area of ​​the image to be processed are filtered out. The first dot product result is used to represent the first feature of the visible area corresponding to the first feature vector.

[0081] In some embodiments, the combination Figure 3A The electronic device may use a neural network model to perform a dot product process on the second feature vector and the second mask feature vector to obtain a second dot product result for representing the second feature. Thus, the feature in the visible area of ​​the target object is determined. The second dot product result is used to represent the second feature of the visible area corresponding to the second feature vector.

[0082] For ease of explanation, Figure 3A In the figure, the dot multiplication process is illustrated by taking a dot in a circle as an example, which indicates the multiplication of corresponding elements of two matrices.

[0083] S203. Obtain a correlation matrix diagram according to the first feature and the second feature.

[0084] The electronic device can perform a matrix multiplication operation on the first dot product result and the second dot product result, and calculate the correlation between each spatial position point in the first dot product result and all spatial position points in the second dot product result, so that the visible area of ​​the image to be processed corresponding to the first dot product result and the visible area of ​​the image to be processed corresponding to the second dot product result can be more correlated, which in turn highlights the invisible area of ​​the target object, so as to obtain a correlation matrix diagram to characterize the correlation between the invisible area of ​​the target object and the visible area of ​​the image to be processed.

[0085] The spatial position point here is a point in a feature map (H×W×C, H represents length, W represents width, and C represents the number of channels). The coordinates of the spatial position point are expressed as (i, j), and the size of the spatial position point is 1×1×C.

[0086] For ease of explanation, Figure 3A In the example above, a cross in a circle is used to illustrate the matrix multiplication operation. i1 For the correlation matrix diagram, the correlation matrix diagram A i1 The size can be expressed as HW×HW.

[0087] In addition, after performing the matrix multiplication operation, the electronic device can perform normalization processing in a certain dimension (such as using a Softmax function) to obtain a correlation matrix diagram.

[0088] In summary, the electronic device can represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object through a correlation matrix diagram.

[0089] See also Figure 4A and Figure 4B , Figure 4A A working principle diagram of the image processing method provided by the embodiment of the present disclosure, Figure 4B Schematic diagram of the process flow of the image processing method provided by the embodiment of the present disclosure. Figure 4A and Figure 4B As shown, the image processing method of the present disclosure may include:

[0090] S301: Obtain a mask of an invisible area of ​​a target object in an image to be processed.

[0091] The electronic device may process the invisible area of ​​the target object to obtain a mask of the invisible area of ​​the target object. The specific implementation process of obtaining the mask of the invisible area of ​​the target object may refer to the description of the mask of the visible area of ​​the image to be processed, which will not be repeated here.

[0092] S302: Obtain a first feature map corresponding to the image to be processed.

[0093] The specific implementation process of step S302 can be found in Figure 3A The description of step S201 in is not repeated here. For the sake of convenience, Figure 4A F i is the first feature map, the first feature map F i The size can be written as C×H×W, where C is the channel height, H is the length, and W is the width.

[0094] S303. Obtain a third feature of the visible area corresponding to the fourth eigenvector and a fourth feature of the invisible area corresponding to the fifth eigenvector according to the fourth eigenvector corresponding to the first eigenmap, the third mask eigenvector corresponding to the mask of the visible area, the fifth eigenvector corresponding to the first eigenmap, and the fourth mask eigenvector corresponding to the mask of the invisible area.

[0095] The electronic device may use a convolution operation to perform channel number dimensionality reduction processing on the first feature map, and perform vectorization processing on the first feature map after dimensionality reduction processing to obtain a fourth eigenvector corresponding to the first feature map. For ease of explanation, Figure 4A F i q2 is the fourth eigenvector, the fourth eigenvector F i q2 The size can be recorded as C / 8×HW.

[0096] Accordingly, the electronic device may sample the mask of the visible area of ​​the image to be processed to keep the same size as the fourth eigenvector to obtain a third mask eigenvector. Figure 4A M p3 is the third mask feature vector, the third mask feature vector M p3 The size can be recorded as 1×HW.

[0097] The electronic device may use a convolution operation to perform channel number dimensionality reduction processing on the first feature map, and perform vectorization processing on the first feature map after dimensionality reduction processing to obtain a fifth eigenvector corresponding to the first feature map. For ease of explanation, Figure 4A F i k2 is the fifth eigenvector, the fifth eigenvector F i k2 The size can be recorded as HW×C / 8.

[0098] Accordingly, the electronic device may sample the mask of the visible area of ​​the image to be processed to keep the same size as the fifth feature vector, and obtain a fourth mask feature vector. Figure 4A M p4 is the fourth mask feature vector, the fourth mask feature vector M p4 The size can be recorded as HW×1.

[0099] Among them, the semantic information of the fourth eigenvector is different from that of the fifth eigenvector, and the dimensional order of the third mask eigenvector is different from that of the fourth mask eigenvector. The semantic information here can be understood as different angles of the first feature map, such as brightness and color. The dimensional order can be understood as different orders of length, width and height, such as the order of length, width and height, and the order of height, length and width.

[0100] It can be seen that the third mask feature vector corresponds to the visible area of ​​the target object, or the third mask feature vector corresponds to the visible area and the background area of ​​the target object. The fourth mask feature vector corresponds to the invisible area of ​​the target object.

[0101] Among them, the fourth eigenvector and the fifth eigenvector have the same number of channels, which is conducive to reducing the amount of calculation. The above-mentioned vectorization processing can be understood as a flattening processing, which is conducive to reducing the amount of calculation. In general, the dimensionality reduction processing in the process of obtaining the fourth eigenvector and the fifth eigenvector can adopt a layer of convolution processing.

[0102] It should be noted that the present disclosure is not limited to the above-mentioned method for obtaining the fourth eigenvector, the fifth eigenvector, the third mask eigenvector and the fourth mask eigenvector. For example, after obtaining the third mask eigenvector, the electronic device may determine the transpose of the third mask eigenvector as the fourth mask eigenvector.

[0103] Thus, the electronic device can obtain the third feature and the fourth feature based on the fourth feature vector, the third mask feature vector, the fifth feature vector and the fourth mask feature vector.

[0104] In some embodiments, the combination Figure 4A The electronic device may use a neural network model to perform a dot product process on the fourth eigenvector and the third mask eigenvector to obtain a third dot product result for representing the third feature. Thus, the features of the visible area of ​​the image to be processed are filtered out. The third dot product result is used to represent the third feature of the visible area corresponding to the fourth eigenvector.

[0105] In some embodiments, the combination Figure 4A The electronic device may use a neural network model to perform a dot product on the fifth feature vector and the fourth mask feature vector to obtain a fourth dot product result for representing the fourth feature. Thus, the feature in the invisible area of ​​the target object is determined. The fourth dot product result is used to represent the fourth feature of the visible area corresponding to the fifth feature vector.

[0106] For ease of explanation, Figure 4A In the figure, the dot multiplication process is illustrated using an example of a point in a circle.

[0107] S304. Obtain a correlation matrix diagram according to the third feature and the fourth feature.

[0108] The electronic device can perform a matrix multiplication operation on the third dot product result and the fourth dot product result, and calculate the correlation between each spatial position point in the third dot product result and all spatial position points in the fourth dot product result, so that the visible area of ​​the object to be processed corresponding to the third dot product result and the invisible area of ​​the target object corresponding to the second dot product result can be more uncorrelated, effectively highlighting the invisible area of ​​the target object to obtain a correlation matrix diagram to characterize the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0109] The spatial position point here is a point in a feature map (H×W×C, H represents length, W represents width, and C represents the number of channels). The coordinates of the spatial position point are expressed as (i, j), and the size of the spatial position point is 1×1×C.

[0110] For ease of explanation, Figure 4A In the example above, a cross in a circle is used to illustrate the matrix multiplication operation. i2 For the correlation matrix diagram, the correlation matrix diagram A i2 The size can be expressed as HW×HW.

[0111] In addition, after performing the matrix multiplication operation, the electronic device can perform normalization processing in a certain dimension (such as using a Softmax function) to obtain a correlation matrix diagram.

[0112] In summary, the electronic device can represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object through a correlation matrix diagram.

[0113] Based on the description of step S103 above, the electronic device may adopt a variety of implementation methods to complete the content of the invisible area of ​​the target object according to the image to be processed and the relevant relationship.

[0114] Next, combine Figure 5 , introduces the specific implementation method of electronic equipment to complete the content of the invisible area of ​​the target object.

[0115] See also Figure 5 , Figure 5 Schematic diagram of the process flow of the image processing method provided by the embodiment of the present disclosure. Figure 5 As shown, the image processing method of the present disclosure may include:

[0116] S400: Obtain a third eigenvector corresponding to the first eigenmap.

[0117] The electronic device may obtain the third eigenvector in a variety of ways. The electronic device may obtain the third eigenvector in a variety of ways. For ease of explanation, Figure 3A and Figure 4A Fi v is the third eigenvector, the third eigenvector F i v The size can be recorded as HW×C.

[0118] In some embodiments, the electronic device may perform convolution processing on the first feature map using a convolution operation, and perform vectorization processing on the first feature map after the convolution processing to obtain a second feature vector.

[0119] In other embodiments, the electronic device may perform vectorization processing on the first feature map to obtain a second feature vector.

[0120] S401. Obtain a second feature map corresponding to the image to be processed according to the correlation matrix map and the third feature vector corresponding to the first feature map.

[0121] The electronic device may perform matrix multiplication and normalization processing on the correlation matrix diagram and the third eigenvector to obtain a processed eigenvector, wherein the processed eigenvector is used to enhance the features corresponding to the content of the invisible area of ​​the target object.

[0122] The electronic device performs dimension transformation (reshape), transposition and splitting of spatial dimensions on the processed feature vector, and transfers the features of the visible area of ​​the target object to the invisible area of ​​the target object to obtain a second feature map.

[0123] For ease of explanation, Figure 3A and Figure 4A F i o is the second feature map, the second feature map F i o The dimensions can be written as C×H×W.

[0124] In this way, an attention mechanism can be formed with the first feature map as input and the second feature map as output, so that the inputs of multiple layers of the neural network focus on the second feature map, wherein the sizes of the first feature map and the second feature map remain the same, and the attention mechanism can be seamlessly inserted into different stages of the neural network model without adjusting the spatial dimension of the output feature map and without affecting the update iteration of the remaining stages, thereby simplifying the operation of the output feature map.

[0125] S402: Complete the content of the invisible area of ​​the target object according to the second feature map.

[0126] The electronic device may adopt a neural network model, which can enhance the features of the invisible area of ​​the target object based on the second feature map so as to infer the content of the invisible area of ​​the target object and reduce the amount of calculation for inferring the content of the invisible area of ​​the target object.

[0127] In summary, the electronic device can complete the content of the invisible area of ​​the target object based on the second feature map converted from the first feature map.

[0128] Exemplarily, the present disclosure provides an image processing device.

[0129] See also Figure 6 , Figure 6 The image processing device of the present disclosure can be set in an electronic device to achieve the above Figure 1-4B The image processing method of the embodiment corresponds to the operation of the electronic device. Figure 6 As shown, the image processing device 600 provided by the present disclosure may include: an acquisition module 601 and a processing module 602 .

[0130] An acquisition module 601 is used to acquire a mask of a visible area of ​​an image to be processed, wherein the image to be processed includes a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object not blocked by the occluder, or the visible area is an area of ​​the image to be processed except an area of ​​the target object blocked by the occluder;

[0131] The acquisition module 601 is further used to acquire the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area, where the invisible area of ​​the target object is the area of ​​the target object blocked by the occluder;

[0132] The processing module 602 is used to complete the content of the invisible area of ​​the target object according to the image to be processed and the relevant relationship.

[0133] In some embodiments, the acquisition module 601 is specifically used to obtain a first feature map corresponding to the image to be processed; according to the first feature vector corresponding to the first feature map, the first mask feature vector corresponding to the mask of the visible area, the second feature vector corresponding to the first feature map, and the second mask feature vector corresponding to the mask of the visible area, a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector are obtained, the semantic information of the first feature vector and the second feature vector are different, and the dimensional order of the first mask feature vector and the second mask feature vector are different; according to the first feature and the second feature, a correlation matrix diagram is obtained, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0134] In one possible design, the acquisition module 601 is specifically used to perform a dot product operation on a first feature vector corresponding to the first feature map and a first mask feature vector corresponding to the mask of the visible area to obtain a first dot product result for representing the first feature; perform a dot product operation on a second feature vector corresponding to the first feature map and a second mask feature vector corresponding to the mask of the visible area to obtain a second dot product result for representing the second feature; and perform a matrix multiplication operation on the first dot product result and the second dot product result to obtain a correlation matrix diagram.

[0135] In a possible design, the acquisition module 601 is further used to acquire a mask of an invisible region of a target object of the image to be processed;

[0136] The acquisition module 601 is specifically used to acquire a first feature map corresponding to the image to be processed; according to the fourth eigenvector corresponding to the first feature map, the third mask feature vector corresponding to the mask of the visible area, the fifth eigenvector corresponding to the first feature map, and the fourth mask feature vector corresponding to the mask of the invisible area, the third feature of the visible area corresponding to the fourth eigenvector and the fourth feature of the invisible area corresponding to the fifth eigenvector are obtained, the semantic information of the fourth eigenvector is different from that of the fifth eigenvector, and the dimensional order of the third mask feature vector is different from that of the fourth mask feature vector; according to the third feature and the fourth feature, a correlation matrix diagram is obtained, and the correlation matrix diagram is used to represent the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

[0137] In one possible design, the acquisition module 601 is specifically used to perform a dot product on the fourth eigenvector corresponding to the first feature map and the third mask eigenvector corresponding to the mask of the visible area to obtain a third dot product result for representing the third feature; perform a dot product on the fifth eigenvector corresponding to the first feature map and the fourth mask eigenvector corresponding to the mask of the invisible area to obtain a fourth dot product result for representing the fourth feature; perform a matrix operation on the third dot product result and the fourth dot product result to obtain a correlation matrix diagram.

[0138] In one possible design, the processing module 602 is specifically used to obtain a second feature map corresponding to the image to be processed based on the correlation matrix map and the third feature vector corresponding to the first feature map; and complete the content of the invisible area of ​​the target object based on the second feature map.

[0139] In one possible design, the processing module 602 is used to perform matrix multiplication and normalization processing on the correlation matrix graph and the third eigenvector corresponding to the first feature graph to obtain a second processed eigenvector, and the second processed eigenvector is used to enhance the features corresponding to the content of the invisible area of ​​the target object; and perform dimensionality transformation processing on the second processed eigenvector to obtain a second feature graph.

[0140] In one possible design, the processing module 602 is further used to perform convolution processing on the first feature map using a convolution operation, and vectorize the first feature map after the convolution processing to obtain a third feature vector; or, vectorize the first feature map to obtain the third feature vector; wherein the number of channels of the third feature vector is the same as the number of channels of the first feature map.

[0141] In one possible design, the processing module 602 is also used to use a convolution operation to reduce the number of channels of the first feature map, and to vectorize the first feature map after the dimensionality reduction to obtain a first eigenvector, a second eigenvector, a fourth eigenvector or a fifth eigenvector corresponding to the first feature map; wherein the second eigenvector and the first eigenvector have the same number of channels, and the fourth eigenvector and the fifth eigenvector have the same number of channels.

[0142] The image processing device provided by the present disclosure can execute the above method embodiments. Its specific implementation principles and technical effects can be found in the above method embodiments, and the present disclosure will not repeat them here.

[0143] Exemplarily, the present disclosure provides an electronic device, comprising: one or more processors; a memory; and one or more computer programs; wherein the one or more computer programs are stored in the memory; when the one or more processors execute the one or more computer programs, the electronic device implements the image processing method of the foregoing embodiments.

[0144] Illustratively, the present disclosure provides a chip system, which is applied to an electronic device including a memory and a sensor; the chip system includes: a processor; when the processor executes the image processing method of the above embodiment.

[0145] Exemplarily, the present disclosure provides a computer-readable storage medium having a computer program stored thereon, and when the computer program is executed by a processor in an electronic device, the image processing method of the foregoing embodiment is implemented.

[0146] Exemplarily, the present disclosure provides a computer program product. When the computer program product is run on a computer, the computer is enabled to execute the image processing method of the foregoing embodiment.

[0147] In the above embodiments, all or part of the functions can be implemented by software, hardware, or a combination of software and hardware. When implemented using software, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, the process or function according to the embodiment of the present disclosure is generated in whole or in part. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable device. The computer instructions can be stored in a computer-readable storage medium. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or a data center that includes one or more available media integrated. Available media can be magnetic media, (e.g., floppy disks, hard disks, tapes), optical media (e.g., DVDs), or semiconductor media (e.g., solid state disks (SSDs)), etc.

[0148] It should be noted that, in this article, relational terms such as "first" and "second" are only used to distinguish one entity or operation from another entity or operation, and do not necessarily require or imply any such actual relationship or order between these entities or operations. Moreover, the terms "include", "comprise" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, the elements defined by the sentence "comprise a ..." do not exclude the existence of other identical elements in the process, method, article or device including the elements.

[0149] The above are only specific embodiments of the present disclosure, so that those skilled in the art can understand or implement the present disclosure. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein can be implemented in other embodiments without departing from the spirit or scope of the present disclosure. Therefore, the present disclosure will not be limited to these embodiments herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. An image processing method, characterized in that: include: Obtaining a mask of a visible area of ​​an image to be processed, wherein the image to be processed includes a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object that is not blocked by the occluder, or the visible area is an area of ​​the image to be processed excluding an area of ​​the target object blocked by the occluder; According to the image to be processed and the mask of the visible area, obtaining a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object, wherein the invisible area of ​​the target object is an area of ​​the target object blocked by an occluder; The correlation relationship is represented by a correlation matrix diagram; the correlation matrix diagram is obtained according to the feature vector information corresponding to the image to be processed and the mask feature vector information corresponding to the mask of the visible area; The content of the invisible area of ​​the target object is completed according to the image to be processed and the correlation relationship.

2. The method according to claim 1, characterized in that The acquiring, according to the image to be processed and the mask of the visible area, a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object comprises: Obtaining a first feature map corresponding to the image to be processed; Obtaining, according to a first feature vector corresponding to the first feature map, a first mask feature vector corresponding to the mask of the visible area, a second feature vector corresponding to the first feature map, and a second mask feature vector corresponding to the mask of the visible area, a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector, wherein the first feature vector and the second feature vector have different semantic information, and the first mask feature vector and the second mask feature vector have different dimensional orders; A correlation matrix diagram is obtained according to the first feature and the second feature, and the correlation matrix diagram is used to represent the correlation relationship between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

3. The method according to claim 2, characterized in that The obtaining, according to a first feature vector corresponding to the first feature map, a first mask feature vector corresponding to the mask of the visible area, a second feature vector corresponding to the first feature map, and a second mask feature vector corresponding to the mask of the visible area, a first feature of the visible area corresponding to the first feature vector and a second feature of the visible area corresponding to the second feature vector, comprises: Performing a dot product on a first feature vector corresponding to the first feature map and a first mask feature vector corresponding to the mask of the visible area to obtain a first dot product result for representing the first feature; Performing a dot product on a second feature vector corresponding to the first feature map and a second mask feature vector corresponding to the mask of the visible area to obtain a second dot product result for representing the second feature; The step of obtaining the correlation matrix diagram according to the first feature and the second feature includes: Perform a matrix multiplication operation on the first dot product result and the second dot product result to obtain the correlation matrix diagram.

4. The method according to claim 1, characterized in that: The method further comprises: Obtaining a mask of an invisible area of ​​a target object of the image to be processed; The acquiring, according to the image to be processed and the mask of the visible area, a correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object comprises: Obtaining a first feature map corresponding to the image to be processed; Obtaining, according to a fourth feature vector corresponding to the first feature map, a third mask feature vector corresponding to the mask of the visible area, a fifth feature vector corresponding to the first feature map, and a fourth mask feature vector corresponding to the mask of the invisible area, a third feature of the visible area corresponding to the fourth feature vector and a fourth feature of the invisible area corresponding to the fifth feature vector, wherein the fourth feature vector and the fifth feature vector have different semantic information, and the third mask feature vector and the fourth mask feature vector have different dimensional orders; A correlation matrix diagram is obtained according to the third feature and the fourth feature, and the correlation matrix diagram is used to represent the correlation relationship between the visible area of ​​the image to be processed and the invisible area of ​​the target object.

5. The method according to claim 4, characterized in that The method of obtaining, according to the first feature vector corresponding to the first feature map, the first mask feature vector corresponding to the mask of the visible area, the second feature vector corresponding to the first feature map, and the third mask feature vector corresponding to the mask of the invisible area, the third feature of the visible area corresponding to the fourth feature vector and the fourth feature of the invisible area corresponding to the fifth feature vector, comprises: Performing a dot product on a fourth feature vector corresponding to the first feature map and a third mask feature vector corresponding to the mask of the visible area to obtain a third dot product result for representing the third feature; Performing a dot product on a fifth eigenvector corresponding to the first feature map and a fourth mask eigenvector corresponding to the mask of the invisible area to obtain a fourth dot product result for representing the fourth feature; The step of obtaining a correlation matrix diagram according to the third feature and the fourth feature includes: A matrix multiplication operation is performed on the third dot product result and the fourth dot product result to obtain the correlation matrix diagram.

6. The method according to any one of claims 1 to 5, characterized in that: The step of completing the content of the invisible area of ​​the target object according to the image to be processed and the correlation relationship includes: Obtaining a second feature map corresponding to the image to be processed according to the correlation matrix map and a third feature vector corresponding to the first feature map; The content of the invisible area of ​​the target object is completed according to the second feature map.

7. The method according to claim 6, characterized in that The step of obtaining a second feature map corresponding to the image to be processed according to the correlation matrix map and the third feature vector corresponding to the first feature map comprises: Performing matrix multiplication and normalization processing on the correlation matrix graph and the third eigenvector corresponding to the first eigenvector to obtain a second processed eigenvector, wherein the second processed eigenvector is used to enhance the features corresponding to the content of the invisible area of ​​the target object; Performing dimension transformation processing on the second processed feature vector to obtain the second feature map.

8. The method according to claim 6, characterized in that The method further comprises: Performing convolution processing on the first feature map by using a convolution operation, and performing vectorization processing on the first feature map after the convolution processing to obtain the third feature vector; or, Performing vectorization processing on the first feature map to obtain the third feature vector; The number of channels of the third feature vector is the same as the number of channels of the first feature map.

9. The method according to any one of claims 2 to 5, characterized in that: The method further comprises: Performing channel number dimensionality reduction processing on the first feature map by using a convolution operation, and performing vectorization processing on the first feature map after the dimensionality reduction processing to obtain a first eigenvector, a second eigenvector, a fourth eigenvector, or a fifth eigenvector corresponding to the first feature map; The second eigenvector has the same number of channels as the first eigenvector, and the fourth eigenvector has the same number of channels as the fifth eigenvector.

10. An image processing device, characterized in that: The device comprises: An acquisition module, configured to acquire a mask of a visible area of ​​an image to be processed, wherein the image to be processed includes a target object, a part of the target object is blocked by an occluder, and the visible area is an area of ​​the target object not blocked by the occluder, or the visible area is an area of ​​the image to be processed excluding an area of ​​the target object blocked by the occluder; The acquisition module is further used to acquire the correlation between the visible area of ​​the image to be processed and the invisible area of ​​the target object according to the image to be processed and the mask of the visible area; the correlation is represented by a correlation matrix diagram; the correlation matrix diagram is obtained according to the feature vector information corresponding to the image to be processed and the mask feature vector information corresponding to the mask of the visible area; A processing module is used to complete the content of the invisible area of ​​the target object according to the image to be processed and the correlation relationship.

11. An electronic device, comprising: one or more processors; Memory; and one or more computer programs; wherein the one or more computer programs are stored in the memory; characterized in that when the one or more processors execute the one or more computer programs, the electronic device implements the image processing method as described in any one of claims 1-9.

12. A computer storage medium, characterized in that: The method comprises computer instructions, which, when executed on an electronic device, enable the electronic device to execute the image processing method according to any one of claims 1 to 9.

13. A computer program product, characterized in that When the computer program product is run on a computer, the computer is enabled to execute the image processing method according to any one of claims 1 to 9.