A method for deep edge extraction and a computer-readable storage medium

By training a deep edge extraction network and combining a multi-level residual module and an attention mechanism, the problem of misidentifying texture edges as depth edges was solved, achieving accurate extraction of depth edges and improving the performance of the stereo matching algorithm.

CN116563321BActive Publication Date: 2026-05-26PEKING UNIV SHENZHEN GRADUATE SCHOOL
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
PEKING UNIV SHENZHEN GRADUATE SCHOOL
Filing Date
2023-04-10
Publication Date
2026-05-26

Smart Images

  • Figure CN116563321B_ABST
    Figure CN116563321B_ABST
Patent Text Reader

Abstract

This invention proposes a depth edge extraction method. Based on a pre-trained depth edge extraction network, depth edges are extracted from the acquired image to be detected, resulting in a first depth edge map. The depth edge detection network is then trained using a loss function, which includes a first loss function, a second loss function, and hyperparameters. The first loss function constrains the loss between the ground truth depth edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network. The second loss function constrains the loss between the texture edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network. The hyperparameters adjust the weights of the first and second loss functions. This edge extraction method can accurately obtain depth edges in the image to be detected, effectively avoiding texture edges in the depth edge map and improving the performance of visual algorithms requiring depth edges.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of stereo matching technology, specifically to a depth edge extraction method and a computer-readable storage medium. Background Technology

[0002] Edge detection is a fundamental problem that needs to be solved in various fields. For example, in higher-level vision tasks such as object detection and semantic segmentation, edge detection is a key step. Similarly, in stereo matching, edge detection can be used to optimize algorithms and make stereo matching algorithms perform better. In the disparity map obtained in stereo matching, there is an edge blurring problem. The blurring of disparity edges seriously affects the accuracy of the disparity map. However, depth edges can be represented as disparity edges in the disparity map. Therefore, how to accurately obtain depth edges is a problem worth studying.

[0003] However, current depth edge extraction methods still have many problems. For example, they often mistakenly treat texture edges as depth edges, resulting in a large number of texture edges in the generated depth edge results. In visual algorithms that require depth edges, a large number of texture edges will affect the performance of the algorithm. Summary of the Invention

[0004] The depth edge extraction method provided by this invention can accurately obtain the depth edges in the image to be detected, effectively avoid texture edges in the depth edge map, and improve the performance of visual algorithms that require depth edges.

[0005] According to a first aspect, one embodiment provides a depth edge extraction method, comprising: acquiring an image to be detected; performing depth edge extraction on the image to be detected based on a pre-trained depth edge extraction network to obtain a first depth edge map; and outputting the first depth edge map; wherein the depth edge extraction network is trained by training the depth edge detection network through a loss function, wherein the loss function includes: a first loss function, a second loss function, and hyperparameters, the first loss function constraining the loss between the ground truth depth edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network, the second loss function constraining the loss between the texture edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network, and the hyperparameters adjusting the weights of the first loss function and the second loss function.

[0006] In some embodiments, the second loss function includes a first loss sub-value, a second loss sub-value, and a third loss sub-value. The first loss sub-value represents the loss between the texture edge map of the training sample and the ground truth map of the depth edge of the training sample. The second loss sub-value represents the loss between the texture edge map of the training sample and the texture edge map of the training sample extracted by the depth edge extraction network.

[0007] In some embodiments, the loss function is obtained by the following formula: L = λL de +(1-λ)L a Where L is the loss function, L de Let L be the first loss function. a The second loss function is denoted by λ, which is a hyperparameter. The first loss function is obtained through the following calculation method: Where, Δx=Y i -f(x i ), Y i Let f(x) be the ground truth map of the depth edges of the training samples. i The first loss function is the depth edge map of the training samples extracted by the depth edge extraction network, and the second loss function is the object detection regression loss function.

[0008] L a =smoothL1|1-g(E,Y) i )|+smoothL1|0-g(E,E)|+g(E,f(x i ), where Y i E is the ground truth image of the depth edges of the training sample; E is the texture edge image of the training sample; f(x) i ) represents the depth edge map of the training sample extracted by the depth edge extraction network; i represents the depth edge map of the training sample extracted by the i-th depth edge extraction network / the ground truth depth edge map of the training sample; smoothL1 is the object detection regression loss function; smoothL1|1-g(E, Y) i )| represents the first loss sub-value, g(E, Y) i ) is the evaluation value between the depth edge ground truth map and the texture edge map of the training sample;

[0009] smoothL1|0-g(E, E)| is the second loss sub-value, g(E, E) is the evaluation value between the texture edge map of the training sample and the texture edge map of the training sample; g(E, f(x)| is the second loss sub-value. iThe third loss sub-value is the evaluation value between the depth edge map of the training sample extracted by the depth edge extraction network and the texture edge map corresponding to the training sample.

[0010] In some embodiments, the training method of the deep edge extraction network further includes: acquiring a sample set, the sample set including at least the Sceneflow dataset and the KITTI2005 dataset; randomly dividing the sample set into a training sample set and a test sample set, the training sample set being 80% of the sample set and the test sample set being 20% ​​of the sample set; setting the batch size of the training sample set to 10 during training; the training period of the deep edge extraction network is 10, wherein the first learning rate is the same for the first 5 training periods and the second learning rate is the same for the last 5 training periods, the first learning rate is 0.01 and the second learning rate is 0.001, and the first learning rate and the second learning rate can be adjusted after multiple training iterations.

[0011] In some embodiments, the training method for each training sample in the training sample set includes:

[0012] The depth edges of the training samples are labeled to obtain a ground truth map of the depth edges of the training samples; the depth edges of the training samples are extracted using the depth edge extraction network to obtain a depth edge map of the training samples; texture edges of the training samples are extracted to obtain a texture edge map of the training samples; a first loss sub-value is obtained using a texture edge correction method based on the texture edge map of the training samples and the ground truth map of the depth edges of the training samples; a second loss sub-value is obtained using a texture edge correction method based on the texture edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network; a third loss sub-value is obtained using a texture edge correction method based on the texture edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network.

[0013] In some embodiments, the texture edge correction method includes: using a multi-level residual module to compare the texture edge map of the training sample with the ground truth map of the depth edge of the training sample / the texture edge map of the training sample with the texture edge of the training sample / the texture edge map of the training sample with the depth edge extracted by the depth edge extraction network to obtain a first loss value / a second loss value / a third loss value; and introducing an attention mechanism after each level of residual module.

[0014] In some embodiments, the attention mechanism is implemented based on an attention module, which includes three convolutional layers. The attention module is represented as follows: x o =(w q ·xi )*(w k ·x i )*(w v ·x i ), where w q w k w v These are the pre-defined kernel weights for the three convolutional layers, x o Let x be the output matrix of the attention module. i The input matrix of the attention module is denoted by '·', where the operator '*' represents convolution and the operator '*' represents matrix multiplication.

[0015] In some embodiments, the test sample set is used to test the performance of the deep edge extraction network to obtain the error rate of the deep edge extraction network, and the value of the hyperparameter is adjusted according to the error rate of the deep edge extraction network.

[0016] In some embodiments, the depth edge extraction network includes: a downsampling layer, a convolutional layer, and an upsampling layer; the downsampling layer is used to extract depth edge features from the image to be detected to generate a downsampling feature map; the convolutional layer is used to extract depth edge features from the downsampling feature map to generate a second depth edge feature map; the upsampling layer is used to restore the size of the second depth edge feature map to be the same as that of the image to be detected to obtain a first depth edge feature map.

[0017] According to a second aspect, one embodiment provides a computer-readable storage medium storing a program that can be executed by a processor to implement the depth edge extraction method as described above.

[0018] According to the method of the above embodiments, a pre-trained depth edge extraction network is used to extract depth edges from the acquired image to be detected to obtain a first depth edge map. The depth edge detection network is trained using a loss function, which includes a first loss function, a second loss function, and hyperparameters. The first loss function is used to constrain the loss between the ground truth depth edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network. The second loss function is used to constrain the loss between the texture edge map of the training samples and the depth edge map of the training samples extracted by the depth edge extraction network. The hyperparameters are used to adjust the weights of the first loss function and the second loss function. This edge extraction method can accurately obtain the depth edges in the image to be detected, effectively avoid texture edges in the depth edge map, and improve the performance of stereo matching. Attached Figure Description

[0019] Figure 1 The image to be detected;

[0020] Figure 2 This is the texture edge map of the image to be detected;

[0021] Figure 3 This is the depth edge map of the image to be detected;

[0022] Figure 4 This is a schematic diagram of a depth edge extraction method;

[0023] Figure 5 This is a schematic diagram of the deep edge extraction network and its structure during training.

[0024] Figure 6 The image to be detected;

[0025] Figure 7 Extracted by existing deep edge extraction networks Figure 6 Depth edge map;

[0026] Figure 8 For edge extraction extracted using the depth edge extraction network provided by this invention Figure 6 Depth edge map;

[0027] Figure 9 This is a schematic diagram of the structure of a depth edge correction module according to one embodiment;

[0028] Figure 10 This is a schematic diagram of the structure of a computer-readable storage medium. Detailed Implementation

[0029] The present invention will now be described in further detail with reference to specific embodiments and accompanying drawings. Similar elements in different embodiments are referred to by associated similar element reference numerals. In the following embodiments, many details are described to facilitate a better understanding of this application. However, those skilled in the art will readily recognize that some features may be omitted in different situations, or may be replaced by other elements, materials, or methods. In some cases, certain operations related to this application are not shown or described in the specification. This is to avoid obscuring the core parts of this application with excessive description. For those skilled in the art, detailed description of these related operations is not necessary; they can fully understand the related operations based on the description in the specification and general technical knowledge in the art.

[0030] Furthermore, the features, operations, or characteristics described in the specification can be combined in any suitable manner to form various embodiments. At the same time, the steps or actions in the method description can be rearranged or adjusted in a manner obvious to those skilled in the art. Therefore, the various orders in the specification and drawings are only for the clear description of a particular embodiment and do not imply a necessary order, unless otherwise stated that a particular order must be followed.

[0031] The serial numbers assigned to components in this document, such as "first" and "second," are used only to distinguish the described objects and have no sequential or technical meaning. The terms "connection" and "linkage" used in this application, unless otherwise specified, include both direct and indirect connections (linkages).

[0032] In depth edge detection, texture edges have always been a significant factor affecting the detection results, such as... Figure 1-3 As shown ( Figure 1 The image shown is the one to be detected. Figure 2 It shows Figure 1 Texture edge map, Figure 3 It shows Figure 1 The depth edge map (texture edge) is not the same as the depth edge. Texture edges are caused by discontinuities in pixel values. As long as there is a gradient between any two adjacent pixel values ​​in the image, a texture edge can be considered to exist at that pixel. Depth edges are generated when different targets are at different depths. Target depth refers to the distance between the target and the camera. That is, if different targets are at different distances from the camera, they will generate depth edges. It is worth noting that texture edges and depth edges do not have an exact inclusion relationship, because pixel values ​​with gradients are not necessarily at depth edges. Similarly, pixel values ​​at different depths do not necessarily have gradients.

[0033] The proposed deep edge extraction method uses a pre-trained deep edge extraction network to extract deep edges from the acquired image to be detected, obtaining a first deep edge map. The deep edge detection network is then trained using a loss function, which includes a first loss function, a second loss function, and hyperparameters. The first loss function constrains the loss between the ground truth deep edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The second loss function constrains the loss between the texture edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The hyperparameters adjust the weights of the first and second loss functions.

[0034] Please refer to Figure 4 One embodiment of the present invention provides a depth edge extraction method, comprising:

[0035] S10: Acquire the image to be detected.

[0036] S20: Based on a pre-trained deep edge extraction network, perform deep edge extraction on the image to be detected to obtain a first deep edge map.

[0037] In some embodiments, such as Figure 5As shown, the main body of the deep edge extraction network is a U-shaped network, including: a downsampling layer 10, a convolutional layer 20, and an upsampling layer 30; the downsampling layer 10 is used to extract deep edge features from the image to be detected to generate a downsampling feature map; the convolutional layer 20 is used to extract deep edge features from the downsampling feature map to generate a second deep edge feature map; the upsampling layer 30 is used to restore the size of the second deep edge feature map to be the same as that of the image to be detected to obtain a first deep edge feature map.

[0038] In some embodiments, the deep edge extraction network is trained by training the deep edge detection network through a loss function, wherein the loss function includes a first loss function, a second loss function, and hyperparameters. The first loss function is used to constrain the loss between the ground truth deep edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The second loss function is used to constrain the loss between the texture edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The hyperparameters are used to adjust the weights of the first loss function and the second loss function.

[0039] In some embodiments, the second loss function includes a first loss sub-value, a second loss sub-value, and a third loss sub-value. The first loss sub-value represents the loss between the texture edge map of the training sample and the ground truth map of the depth edge of the training sample. The second loss sub-value represents the loss between the texture edge map of the training sample and the texture edge map of the training sample extracted by the depth edge extraction network.

[0040] like Figure 6-8 As shown, the depth edge detection network trained using the loss function constructed in this invention can accurately obtain the depth edges in the image to be detected, effectively avoid texture edges in the depth edge map, and improve the performance of visual algorithms that require depth edges.

[0041] In some embodiments, the texture edge correction method includes: using a multi-level residual module to compare the texture edge map of the training sample with the ground truth map of the depth edge of the training sample, the texture edge map of the training sample with the texture edge map of the training sample, and the texture edge map of the training sample with the depth edge extracted by the depth edge extraction network to obtain a first loss value, a second loss value, and a third loss value; an attention mechanism is introduced after each level of the residual module, which can focus on areas that may differ in the fused feature map, better fuse the two feature maps, and better evaluate the degree of texture edge contained in each depth edge.

[0042] In some embodiments, such as Figure 5As shown, a depth edge correction module 40 and a texture edge extraction module 50 are introduced when training the depth edge extraction network. The texture edge extraction module 50 uses the Canny algorithm to extract texture edges and generate texture edge maps for training samples, as shown below. Figure 9 As shown, the main structure of the deep edge correction module 40 is a Siamese network. The deep edge correction module 40 includes a first branch 41 and a second branch 42. Both the first branch 41 and the second branch 42 are composed of concatenated convolutional blocks of three scales. The scale difference between adjacent convolutional blocks is twice. The input of the first branch 41 is the deep edge map / texture edge map / deep edge ground truth map of the training sample extracted by the deep edge extraction network. The input of the second branch 42 is the texture edge map of the training sample. The feature extraction parts of the first branch 41 and the second branch 42 share parameters. After the two branches obtain feature maps, they are concatenated and input into the correction processing module 43 to obtain the loss value, which is used to evaluate the degree to which the deep edge contains texture edges. The correction processing module 43 includes a six-level residual module. An attention mechanism is introduced after each level of the residual module. The correction processing module 43 adaptively focuses on the features that need attention in the feature map, that is, the places in the deep edge map of the training sample extracted by the deep edge extraction network where texture edges are prone to appear incorrectly, so that the correction processing module 43 can learn the differences between them more accurately.

[0043] In some embodiments, the attention mechanism is implemented based on an attention module, which consists of three convolutional layers. The attention module is represented as follows:

[0044] x o =(w q ·x i )*(w k ·x i )*(w v ·x i )

[0045] Among them, w q w k w v These are the pre-defined kernel weights for the three convolutional layers, x o Let x be the output matrix of the attention module. i This is the input matrix for the attention module. The operator '·' represents convolution, and the operator '*' represents matrix multiplication.

[0046] In some embodiments, the loss function is obtained by the following formula:

[0047] L=λL de +(1-λ)L a

[0048] Where L is the loss function, Lde Let L be the first loss function. a Let λ be the second loss function, and λ be a hyperparameter.

[0049] The first loss function is obtained through the following calculation method:

[0050]

[0051] Where, Δx=Y i -f(x i ), Y i For the depth edge ground truth map of the training samples, f(x) i ) represents the depth edge map of the training samples extracted by the depth edge extraction network, and smoothL1 is the object detection regression loss function;

[0052] The second loss function is obtained through the following calculation method:

[0053] L a =smoothL1|1-g(E,Y) i )|+smoothL1|0-g(E,E)|+g(E,f(x i ))

[0054] Among them, Y i E is the ground truth image of the depth edges of the training samples; E is the texture edge image of the training samples; f(x) i ) represents the depth edge map of the training sample extracted by the depth edge extraction network; i represents the depth edge map of the training sample extracted by the i-th depth edge extraction network / the ground truth depth edge map of the training sample; smoothL1 is the object detection regression loss function; smoothL1|1-g(E, Y) i )| represents the first loss sub-value, g(E, Y) i ) represents the evaluation value between the ground truth depth edge map and the texture edge map of the training samples. To accurately evaluate texture edges, g(E, Y) is included in the first loss function. i The loss is calculated by comparing g(E, E) with the maximum value of 1; smoothL1|0-g(E, E)| is the second loss sub-value, where g(E, E) is the evaluation value between the texture edge map of the training sample and the texture edge map of the training sample. In order to accurately evaluate depth edges, the second loss sub-value calculates a loss between g(E, E) and the minimum value of 0; g(E, f(x)|0-g(E, E ... i The third loss sub-value is the evaluation value between the depth edge map of the training sample extracted by the depth edge detection network and the texture edge map of the training sample.

[0055] The smoothL1 loss function is used in this invention because it can keep the gradient stable in the early stage while reducing the network's sensitivity to noise, and can keep the gradient smooth in the later stage of training.

[0056] In some embodiments, the training method for the deep edge extraction network further includes:

[0057] S21: Obtain a sample set, which should include at least the Sceneflow dataset and the KITTI2005 dataset.

[0058] S22: Randomly divide the sample set into a training sample set and a test sample set, with the training sample set comprising 80% of the sample set and the test sample set comprising 20% ​​of the sample set.

[0059] S23: Set the batch size of the training sample set to 10 during training.

[0060] S24: The training period for the deep edge extraction network is 10, with the first learning rate being the same for the first 5 training periods and the second learning rate being the same for the last 5 training periods. The first learning rate is 0.01 and the second learning rate is 0.001. The first and second learning rates can be adjusted after multiple training sessions.

[0061] In some embodiments, the training method for each training sample in the training sample set includes:

[0062] S210: Label the depth edges of the training samples to obtain the ground truth map of the depth edges of the training samples.

[0063] S211: The training samples are processed by a depth edge extraction network to obtain the depth edge map of the training samples.

[0064] S212: Extract texture edges from the training samples to obtain texture edge maps of the training samples. In this embodiment, the Canny algorithm is used to extract texture edges to generate texture edge maps.

[0065] S213: Based on the texture edge map and the depth edge ground truth map of the training samples, the first loss sub-value is obtained through the texture edge correction method. Here, the texture edge map and the depth edge ground truth map of the training samples are used as inputs to the texture edge correction method, which causes a small first loss sub-value to be output to indicate the degree to which the depth edge map does not contain texture edges.

[0066] S214: Based on the texture edge map and the depth edge ground truth map of the training samples, the second loss sub-value is obtained through the texture edge correction method. Here, the texture edge map and the depth edge ground truth map of the training samples are used as inputs to the texture edge correction method, which prompts the output of a larger second loss sub-value to indicate the degree to which the depth edge map contains all texture edges.

[0067] S215: Based on the texture edge map of the training sample and the depth edge map of the training sample extracted by the depth edge extraction network, the third loss value is obtained through texture edge correction.

[0068] After training the depth edge extraction network multiple times using the above training method, the loss value of the depth edge result map can be accurately obtained and the texture edges in the depth edge map can be corrected.

[0069] In some embodiments, a test sample set is used to test the performance of the deep edge extraction network to obtain the error rate of the deep edge extraction network, and the values ​​of the hyperparameters are adjusted according to the error rate of the deep edge extraction network.

[0070] S30: Output the first depth edge map.

[0071] like Figure 10 As shown, another embodiment of the present invention provides a computer-readable storage medium 60 on which a program is stored, the program being executable by a processor 70 to implement the depth edge extraction method as described above.

[0072] The above examples illustrate the present invention only to aid in understanding it and are not intended to limit the scope of the invention. Those skilled in the art can make various simple deductions, modifications, or substitutions based on the principles of this invention.

Claims

1. A method for extracting deep edges, characterized in that, include: Obtain the image to be detected; The image to be detected is subjected to depth edge extraction based on a pre-trained depth edge extraction network to obtain a first depth edge map; Output the edge map of the first depth; The deep edge extraction network was trained in the following manner: The deep edge detection network is trained using a loss function, which includes a first loss function, a second loss function, and hyperparameters. The first loss function constrains the loss between the ground truth deep edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The second loss function constrains the loss between the texture edge map of the training samples and the deep edge map of the training samples extracted by the deep edge extraction network. The hyperparameters adjust the weights of the first and second loss functions. The second loss function includes a first loss sub-value, a second loss sub-value, and a third loss sub-value. The first loss sub-value represents the loss between the texture edge map of the training samples and the ground truth deep edge map of the training samples. The second loss sub-value represents the loss between the texture edge map of the training samples and the texture edge map of the training samples. The third loss sub-value represents the loss between the deep edge map of the training samples extracted by the deep edge extraction network and the texture edge map of the training samples. The loss function is calculated as follows: The formula yields: in, For loss function, For the first loss function, For the second loss function, For hyperparameters; The first loss function is obtained through the following calculation method: in, , This is the depth edge ground truth map of the training samples. For the depth The edge extraction network extracts the depth edge map of the training samples. The regression loss function for target detection; The second loss function is obtained through the following calculation method: in, This is the depth edge ground truth map of the training samples; The texture edges of the training samples picture; The depth edge map of the training sample extracted by the depth edge extraction network; For the first The depth edge map of the training sample extracted by the depth edge extraction network / the depth edge ground truth map of the training sample; The regression loss function for target detection; The first loss sub-value, The evaluation value is the difference between the depth edge ground truth map and the texture edge map of the training sample. For the second loss sub-value, The evaluation value is the difference between the texture edge map of the training sample and the texture edge map of the training sample. The third loss sub-value is the evaluation value between the depth edge map of the training sample extracted by the depth edge extraction network and the texture edge map corresponding to the training sample.

2. The method as described in claim 1, characterized in that, The training methods for the deep edge extraction network also include: Obtain a sample set, which includes at least the Sceneflow dataset and the KITTI2005 dataset; The sample set is randomly divided into a training sample set and a test sample set, wherein the training sample set comprises 80% of the sample set and the test sample set comprises 20% of the sample set. During training, the batch size of the training sample set is set to 10; The deep edge extraction network is trained for 10 periods, with the first learning rate being the same for the first 5 training periods and the second learning rate being the same for the last 5 training periods. The first learning rate is 0.01 and the second learning rate is 0.

001. The first learning rate and the second learning rate can be adjusted after multiple training sessions.

3. The method as described in claim 2, characterized in that, The training method for each training sample in the training sample set includes: The depth edges of the training samples are labeled to obtain the depth edge ground truth map of the training samples; The training samples are processed by the depth edge extraction network to obtain the depth edge map of the training samples. Texture edge extraction is performed on the training samples to obtain the texture edge map of the training samples; Based on the texture edge map and the depth edge ground truth map of the training samples, the first loss sub-value is obtained through texture edge correction. Based on the texture edge map of the training sample, a second loss sub-value is obtained through texture edge correction. Based on the texture edge map of the training sample and the depth edge map of the training sample extracted by the depth edge extraction network, a third loss value is obtained through texture edge correction.

4. The method as described in claim 3, characterized in that, The texture edge correction method includes: A multi-level residual module is used to generate the texture edge map and depth map of the training samples. The edge ground truth map / texture edge map of the training sample and the texture edge map of the training sample / the texture edge map of the training sample and the depth edge map extracted by the depth edge extraction network are compared to obtain the first loss sub-value / second loss sub-value / third loss sub-value; An attention mechanism is introduced after each residual module.

5. The method as described in claim 4, characterized in that, The attention mechanism is implemented based on an attention module, which consists of three convolutional layers. The attention module is represented as follows: in, , , These are the pre-defined kernel weights for the three convolutional layers. The output matrix of the attention module. The input matrix of the attention module is denoted by '∙', where '∙' represents convolution and '*' represents matrix multiplication.

6. The method as described in claim 2, characterized in that, The test sample set is used to test the performance of the deep edge extraction network to obtain the error rate of the deep edge extraction network, and the value of the hyperparameter is adjusted according to the error rate of the deep edge extraction network.

7. The method as described in claim 1, characterized in that, The deep edge extraction network includes: Downsampling layer, convolutional layer, and upsampling layer; The downsampling layer is used to extract depth edge features from the image to be detected in order to generate downsampling data. Sample feature map; The convolutional layer is used to extract depth edge features from the downsampled feature map to generate a second depth. Edge feature map; The upsampling layer is used to restore the size of the second depth edge feature map to be the same as that of the image to be sampled. The same images are detected to obtain the first depth edge feature map.

8. A computer-readable storage medium, characterized in that, The medium stores a program. The program can be executed by a processor to implement the depth edge extraction method as described in any one of claims 1-7.