A detection method, device and equipment of a substation and a storage medium

By replacing the point cloud data and using a point cloud segmentation network based on the multi-layer semantic model Transformer, the problem of insufficient point cloud data samples at substation sites was solved, improving the accuracy and stability of semantic recognition.

CN116468945BActive Publication Date: 2026-02-10GUANGDONG POWER GRID CO LTD +1
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202310432679.0
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-04-20
Publication Date
2026-02-10
Estimated Expiration
2043-04-20

AI Technical Summary

Technical Problem

The insufficient number of cloud data samples at substation sites leads to low accuracy in neural network recognition, and traditional segmentation methods ignore the contextual relationship between points and distant ends, affecting the accuracy of semantic recognition.

Method used

By replacing some points in the original point cloud data of the substation with reference point cloud data, sample point cloud data is generated. Then, a multi-layer semantic model Transformer point cloud segmentation network is used for training and recognition to expand the receptive field and capture the far-end contextual relationships of the points.

Benefits of technology

It improves the accuracy and stability of point cloud segmentation networks, increases the number of samples, reduces the risk of overfitting, and improves the accuracy of semantic recognition.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN116468945B_ABST
    Figure CN116468945B_ABST
Patent Text Reader

Abstract

The application discloses a detection method, device and equipment of a transformer substation and a storage medium, and the method comprises the following steps: replacing part of point cloud data of the transformer substation with part of reference point cloud data to obtain sample point cloud data; determining a point cloud segmentation network with a multi-layer semantic model; inputting the sample point cloud data into the point cloud segmentation network to identify the semantics of the sample point cloud data in the transformer substation; training the point cloud segmentation network according to the semantics of the sample point cloud data; if the training is completed, inputting target point cloud data of the transformer substation into the point cloud segmentation network to identify the semantics of the target point cloud data in the transformer substation. The original point cloud data is enhanced, the sample quantity is increased, the performance of the point cloud segmentation network is improved, the point cloud segmentation network is based on a hierarchical semantic model, the acceptance domain of the point cloud segmentation network to points can be expanded, the long-distance context relationship of the points can be effectively obtained, and the accuracy and stability of the point cloud segmentation network are improved.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of power grids, and particularly to a detection method, device and equipment of a substation and a storage medium. BACKGROUND

[0002] In a power system, a substation is an important node for power transmission and conversion. There are many and various devices in a substation, and there are dangerous factors such as high voltage and large current in live parts. In order to ensure the safe operation of a substation, a radar sensor is usually used to scan point cloud data of the substation, the point cloud data is input into a neural network to identify semantics of each device in the substation, and live parts of each device in the substation are distinguished.

[0003] However, the number of substations owned by an area is limited, and the labeling of point cloud data is a relatively complex and tedious work, resulting in a small number of samples of point cloud data of the substation, which affects the performance of the trained neural network. In addition, due to the large scale of the devices in the substation, the relationship between a point and its surrounding local area is usually considered when the point cloud data is segmented, which affects the understanding ability of the neural network, and the accuracy of semantic recognition is low. SUMMARY

[0004] The present application provides a detection method, device and equipment of a substation and a storage medium to solve the problem of how to improve the accuracy of identifying semantics of a substation using point cloud data.

[0005] According to an aspect of the present application, a detection method of a substation is provided, comprising:

[0006] replacing part of points in original point cloud data of a substation with part of points in reference point cloud data to obtain sample point cloud data;

[0007] determining a point cloud segmentation network with a multi-layer semantic model Transformer;

[0008] inputting the sample point cloud data into the point cloud segmentation network to identify semantics of the sample point cloud data in the substation;

[0009] training the point cloud segmentation network according to the semantics of the sample point cloud data;

[0010] if the training is completed, inputting target point cloud data of a substation into the point cloud segmentation network to identify semantics of the target point cloud data in the substation.

[0011] Optionally, the replacing part of points in original point cloud data of a substation with part of points in reference point cloud data to obtain sample point cloud data comprises:

[0012] Normalizing raw point cloud data of a substation so that coordinates of the raw point cloud data are unified to one coordinate origin, the raw point cloud data being labeled with multiple labels;

[0013] If the normalization is completed, selecting at least one label as a target label;

[0014] Erasing points belonging to the target label from the raw point cloud data;

[0015] Screening points belonging to the target label from reference point cloud data;

[0016] Adding the points screened from the reference point cloud data to the raw point cloud data after erasing, to obtain sample point cloud data.

[0017] Optionally, the erasing points belonging to the target label from the raw point cloud data comprises:

[0018] Determining a first proportion;

[0019] Erasing points belonging to the target label from the raw point cloud data at a first proportion.

[0020] Optionally, the screening points belonging to the target label from reference point cloud data comprises:

[0021] Determining a second proportion;

[0022] Randomly screening points belonging to the target label from reference point cloud data at a second proportion.

[0023] Optionally, the point cloud segmentation network comprises a point cloud core point convolution layer and eight layers of semantic model Transformers;

[0024] The inputting the sample point cloud data into the point cloud segmentation network and identifying semantics of the sample point cloud data in the substation comprises:

[0025] Inputting the sample point cloud data into the point cloud core point convolution layer for convolution processing, and sequentially performing standardization operation and activation operation to obtain point cloud structure information;

[0026] Inputting the point cloud structure information into one layer of semantic model Transformers for processing to obtain first point cloud features;

[0027] Down-sampling the first point cloud features and sequentially inputting them into two layers of semantic model Transformers for processing to obtain second point cloud features;

[0028] The second point cloud feature is down-sampled and sequentially input into a four-layer semantic model Transformer for processing to obtain a third point cloud feature;

[0029] The third point cloud feature is down-sampled and input into a one-layer semantic model Transformer for processing to obtain a fourth point cloud feature;

[0030] The fourth point cloud feature is up-sampled to obtain a fifth point cloud feature;

[0031] The third point cloud feature and the fifth point cloud feature are fused and up-sampled to obtain a sixth point cloud feature;

[0032] The second point cloud feature and the sixth point cloud feature are fused and up-sampled to obtain the semantics of the sample point cloud data in the transformer substation.

[0033] Optionally, the semantic model Transformer in the first layer has a window attention layer, which performs the following operations:

[0034] The feature input into the window attention layer is linearly transformed by three weights to obtain a first request vector, a first key vector and a first value vector;

[0035] The similarity between the first request vector and the first key vector is calculated;

[0036] The similarity is normalized to a preset first range to obtain a first attention weight;

[0037] The first attention weight is applied to the first value vector.

[0038] Optionally, the semantic model Transformer in the second layer to the eighth layer has a spatial attention layer, which performs the following operations:

[0039] A distance matrix between points in the sample point cloud data is calculated;

[0040] The distance matrix is converted into edge features;

[0041] The feature input into the spatial attention layer is linearly transformed to obtain a second request vector and a second value vector;

[0042] The edge features are linearly transformed to obtain a second key vector;

[0043] An attention score is calculated using the second request vector and the second key vector;

[0044] normalize the attention score into a preset second range to obtain a second attention weight;

[0045] apply the second attention weight to the second value vector.

[0046] Optionally, the training of the point cloud segmentation network according to the semantics of the sample point cloud data comprises:

[0047] a loss value is calculated by a loss function as follows:

[0048]

[0049] wherein, Loss represents the loss value, N represents the number of sample point cloud data, M represents the number of semantics, i represents the i-th sample point cloud data, j represents the j-th semantics, represents a real semantics labeled on the sample point cloud data, represents a semantics predicted by the point cloud segmentation network on the sample point cloud data, and γ represents a balance factor;

[0050] the point cloud segmentation network is updated according to the loss value;

[0051] whether a preset iteration condition is met is determined, if yes, it is determined that the training of the point cloud segmentation network is completed, and if no, the sample point cloud data is input into the point cloud segmentation network, and the semantics of the sample point cloud data in the substation is identified.

[0052] According to another aspect of the present application, a detection device of a substation is provided, comprising:

[0053] a point cloud data replacement module, configured to replace part of points in original point cloud data of a substation with part of points in reference point cloud data to obtain sample point cloud data;

[0054] a point cloud segmentation network determination module, configured to determine a point cloud segmentation network with a multi-layer semantic model Transformer;

[0055] a sample semantic segmentation module, configured to input the sample point cloud data into the point cloud segmentation network to identify the semantics of the sample point cloud data in the substation;

[0056] a point cloud segmentation network training module, configured to train the point cloud segmentation network according to the semantics of the sample point cloud data;

[0057] a target semantic segmentation module, configured to input target point cloud data of a substation into the point cloud segmentation network to identify the semantics of the target point cloud data in the substation if the training is completed.

[0058] Optionally, the point cloud data replacement module comprises:

[0059] a normalization processing module configured to perform normalization processing on raw point cloud data of a substation to unify coordinates of the raw point cloud data to one coordinate origin, the raw point cloud data being labeled with a plurality of labels;

[0060] a label selection module configured to select at least one label as a target label if the normalization processing is completed;

[0061] a point erasing module configured to erase points belonging to the target label from the raw point cloud data;

[0062] a point screening module configured to screen points belonging to the target label from reference point cloud data;

[0063] a point adding module configured to add the points screened from the reference point cloud data to the raw point cloud data from which the points are erased to obtain sample point cloud data.

[0064] Optionally, the point erasing module is further configured to:

[0065] determine a first proportion;

[0066] erasing points belonging to the target label from the raw point cloud data at random at a proportion of the first proportion.

[0067] Optionally, the point screening module is further configured to:

[0068] determine a second proportion;

[0069] screen points belonging to the target label from the reference point cloud data at random at a proportion of the second proportion.

[0070] Optionally, the point cloud segmentation network comprises a point cloud core point convolution layer and eight layers of semantic models Transformer.

[0071] The sample semantic segmentation module comprises:

[0072] a first encoding module configured to input the sample point cloud data into the point cloud core point convolution layer to perform convolution processing, and sequentially perform standardization operation and activation operation to obtain point cloud structure information; and input the point cloud structure information into one layer of semantic models Transformer to process to obtain first point cloud features;

[0073] a second encoding module configured to perform down-sampling on the first point cloud features, and sequentially input the first point cloud features into two layers of semantic models Transformer to process to obtain second point cloud features;

[0074] a third encoding module, configured to down-sample the second point cloud feature and sequentially input the down-sampled second point cloud feature into a four-layer semantic model Transformer for processing to obtain a third point cloud feature;

[0075] a fourth encoding module, configured to down-sample the third point cloud feature and input the down-sampled third point cloud feature into a one-layer semantic model Transformer for processing to obtain a fourth point cloud feature;

[0076] a first decoding module, configured to up-sample the fourth point cloud feature to obtain a fifth point cloud feature;

[0077] a second decoding module, configured to fuse the third point cloud feature and the fifth point cloud feature and up-sample the fused third point cloud feature and fifth point cloud feature to obtain a sixth point cloud feature;

[0078] a third decoding module, configured to fuse the second point cloud feature and the sixth point cloud feature and up-sample the fused second point cloud feature and sixth point cloud feature to obtain semantics of the sample point cloud data in the transformer substation.

[0079] Optionally, the semantic model Transformer in the first layer has a window attention layer, and the window attention layer performs the following operations:

[0080] linearly transforms a feature input into the window attention layer by three weights to obtain a first request vector, a first key vector and a first value vector;

[0081] calculates a similarity between the first request vector and the first key vector;

[0082] normalizes the similarity to a preset first range to obtain a first attention weight;

[0083] applies the first attention weight to the first value vector.

[0084] Optionally, the semantic model Transformer in the second layer to the eighth layer has a spatial attention layer, and the spatial attention layer performs the following operations:

[0085] calculates a distance matrix between points in the sample point cloud data;

[0086] converts the distance matrix into an edge feature;

[0087] linearly transforms a feature input into the spatial attention layer to obtain a second request vector and a second value vector;

[0088] linearly transforms the edge feature to obtain a second key vector;

[0089] calculates an attention score using the second request vector and the second key vector;

[0090] normalizing the attention score into a preset second range to obtain a second attention weight;

[0091] applying the second attention weight to the second value vector.

[0092] Optionally, the point cloud segmentation network training module 304 comprises:

[0093] a loss value calculation module configured to calculate a loss value by using a loss function as follows:

[0094]

[0095] wherein, Loss represents the loss value, N represents the number of sample point cloud data, M represents the number of semantics, i represents the i-th sample point cloud data, j represents the j-th semantic, represents a real semantic labeled by the sample point cloud data, represents a semantic predicted by the point cloud segmentation network for the sample point cloud data, and γ represents a balance factor;

[0096] a point cloud segmentation network updating module configured to update the point cloud segmentation network according to the loss value;

[0097] an iteration condition judging module configured to judge whether a preset iteration condition is met; if yes, a training completion determining module is executed, and if no, the sample semantic segmentation module 303 is executed;

[0098] the training completion determining module is configured to determine that the point cloud segmentation network is trained.

[0099] According to another aspect of the present application, an electronic device is provided, which comprises:

[0100] at least one processor; and

[0101] a memory connected to the at least one processor in communication; wherein,

[0102] the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the detection method of the substation according to any one of the embodiments of the present application.

[0103] According to another aspect of the present application, a computer readable storage medium is provided, which stores a computer program for enabling a processor to implement the detection method of the substation according to any one of the embodiments of the present application when executed.

[0104] In the embodiment, part of points in the original point cloud data of the substation is replaced by part of points in the reference point cloud data to obtain sample point cloud data; a point cloud segmentation network with a multi-layer semantic model Transformer is determined; the sample point cloud data is input into the point cloud segmentation network to identify the semantics of the sample point cloud data in the substation; the point cloud segmentation network is trained according to the semantics of the sample point cloud data; if the training is completed, the target point cloud data of the substation is input into the point cloud segmentation network to identify the semantics of the target point cloud data in the substation. The embodiment enhances the original point cloud data by replacing part of the points, increases the sample quantity, thereby improving the performance of the point cloud segmentation network, and the point cloud segmentation network based on the hierarchical semantic model Transformer can expand the acceptance domain of the point cloud segmentation network to the points, effectively obtain the remote context relationship of the points, and improve the accuracy and stability of the point cloud segmentation network.

[0105] It should be understood that the content described in this part is not intended to identify key or important features of the embodiments of the present application, nor is it used to limit the scope of the present application. Other features of the present application will become apparent from the following description. BRIEF DESCRIPTION OF DRAWINGS

[0106] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced below. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can also be obtained by those skilled in the art without creative labor.

[0107] Figure 1 is a flow chart of a detection method of a substation according to the first embodiment of the present application;

[0108] Figure 2 is an architecture diagram of a point cloud segmentation network according to the first embodiment of the present application;

[0109] Figure 3 is a structural schematic diagram of a detection device of a substation according to the second embodiment of the present application;

[0110] Figure 4 is a structural schematic diagram of an electronic device according to the third embodiment of the present application. DETAILED DESCRIPTION

[0111] In the following, the technical solutions in the embodiments of the present application will be described clearly and completely in conjunction with the drawings in the embodiments of the present application, so that those skilled in the art can better understand the present application. Obviously, the described embodiments are only a part of the embodiments of the present application, rather than all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative work should fall within the scope of the present application.

[0112] It should be noted that the terms "first", "second" and the like in the description and claims of the present application and the above drawings are used to distinguish similar objects, and do not necessarily indicate a specific order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "include" and "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device including a series of steps or units does not have to be limited to those steps or units clearly listed, but can include other steps or units not clearly listed or inherent to these processes, methods, products or devices.

[0113] Embodiment one

[0114] Figure 1 A flowchart of a substation detection method provided by the first embodiment of the present application is shown in the figure. The method can be executed by a substation detection device, which can be realized in the form of hardware and / or software, and can be configured in an electronic device. As shown in the figure, the method comprises: Figure 1

[0115] Step 101: replace part of the points in the original point cloud data of the substation with part of the points in the reference point cloud data to obtain sample point cloud data.

[0116] In this embodiment, a radar (such as a laser radar, etc.), a camera or other sensors can be used to scan the three-dimensional point cloud data of the substation, which is recorded as the original point cloud data. The point cloud data is a collection of massive points expressing the target space distribution and target surface characteristics under the same space reference system. After obtaining the spatial coordinates of each sampling point on the object surface, the collection of points is obtained, which is called "point cloud".

[0117] In a three-dimensional space, each point in the point cloud data is a three-dimensional point. The information contained in the point cloud data includes at least the position of each point, i.e. the coordinates (x, y, z) in the three-dimensional space. In addition to this, the information contained in the point cloud data can also include color information, light intensity, category label, normal vector, gray value and other information.​

[0118] In the embodiment, the point cloud data of other substations can be scanned in advance, denoted as reference point cloud data, wherein the points of the reference point cloud data are labeled with labels (i.e., semantics in the substation, especially live components), and the current substation is at least partially the same or similar to other substations in the type of equipment, the layout of equipment, etc., so that the original point cloud data of the current substation can be partially replaced with the reference point cloud data of other substations.

[0119] Then, the original point cloud data is replaced with part of the points in the reference point cloud data, and the original point cloud data after the replaced part is denoted as sample point cloud data, so as to enhance the original point cloud data.

[0120] Replacing part of the points in the original point cloud data can generate more challenging samples, because it uses more difficult-to-predict part of the image to train the model; generate a more smooth decision boundary, which helps to improve the generalization performance of the point cloud segmentation network; improve the diversity of data enhancement, reduce the risk of overfitting, and improve the robustness of the point cloud segmentation network.

[0121] In an embodiment of the application, step 101 can include the following steps:

[0122] Step 1011, normalizing the original point cloud data of the substation to unify the coordinates of the original point cloud data to one coordinate origin.

[0123] In the embodiment, for the convenience of operation, the original point cloud data of the substation can be normalized, and in the process of normalization, the coordinates of the original point cloud data are unified to one coordinate origin.

[0124] Step 1012, if the normalization is completed, at least one label is selected as the target label.

[0125] Suppose the original point cloud data A is represented as Where N A is the total number of points in the original point cloud data, (x i ,y i ,z i ) is the coordinates of the point, l i is the label of the point, l i ∈L, and the label set L = 0, 1, 2, ….

[0126] That is, the original point cloud data is labeled with multiple labels (i.e., semantics in the substation, especially live components).

[0127] If the normalization of the original point cloud data is completed, at least one label can be randomly selected from the label set L of the point cloud data A as the target label k, k ∈ L.

[0128] Generally, a label is randomly selected from the label set L of the point cloud data A as a target label k, k∈L.

[0129] Step 1013, erasing part of the points belonging to the target label in the original point cloud data.

[0130] In this embodiment, the points belonging to the target label are screened out from the original point cloud data, and part of the points belonging to the target label are erased.

[0131] In a specific implementation, a first proportion a can be determined, where a∈[0,1], and part of the points belonging to the target label k in the original point cloud data A are randomly erased, that is, the number of erased points is aN A .

[0132] Then, the remaining original point cloud data A' after erasing can be expressed as:

[0133]

[0134] where N' A is the total number of points in the original point cloud data A' after erasing.

[0135] Step 1014, screening part of the points belonging to the target label from the reference point cloud data.

[0136] Step 1015, adding the points screened from the reference point cloud data to the remaining original point cloud data after erasing to obtain sample point cloud data.

[0137] In this embodiment, the points belonging to the target label are screened out from the reference point cloud data, and these points are added to the remaining original point cloud data after erasing.

[0138] In a specific implementation, a second proportion β can be determined, where β∈[0,1], and part of the points belonging to the target label k are randomly screened from the reference point cloud data.

[0139] At this time, the original point cloud data to which the points of the reference point cloud data are added can be recorded as sample point cloud data.

[0140] Suppose the reference point cloud data B is expressed as where N B is the total number of points in the original point cloud data, (x i , y i , z i ) is the coordinate of the point, l i is the label of the point, l i ∈L, and the label set L=0,1,2,....

[0141] Then, the sample point cloud data C can be expressed as:

[0142]

[0143] wherein N C is the total number of points in the sample point cloud data.

[0144] In general, the above process is converted into a formula, which can be expressed as:

[0145] A' = erase(A, k)

[0146] C = add(A', B, k)

[0147] erase(A, k) = (x i , y i , z i , l i ) e A | l i ≠ k

[0148] add(A', B, k) = (x i , y i , z i , l i ) e A' U (x j , y j , z j , l j ) e B | l j = k

[0149] wherein erase represents erasing, and add represents adding.

[0150] Further, since the point cloud data has unordered nature and large data volume, the direct processing manner can consume high calculation cost when searching the neighborhood, and thus the sample point cloud data can be down-sampled, and the sample point cloud data after down-sampling is the input of the point cloud segmentation network, that is, the sample point cloud data after down-sampling is the sample for training the point cloud segmentation network, and the operation on the whole sample point cloud data is converted to the points obtained by down-sampling, so as to reduce the data volume and reduce the calculation amount.

[0151] wherein the down-sampling manner includes voxel grid down-sampling, random down-sampling, non-uniform grid down-sampling, and the like.

[0152] Step 102, determining the point cloud segmentation network with the multi-layer semantic model Transformer.

[0153] Generally, the equipment scale of a substation is large, and the distance between points can be far apart. When dividing the point cloud data, the traditional method usually considers the relationship between a point and its surrounding local area, which may not capture the connection between distant points in the same component, ignores the connection between a point and its distant context, and limits the understanding of the point cloud data.

[0154] In this embodiment, the structure of the semantic model Transformer based on the hierarchical structure is adopted to expand the receptive field of the point cloud segmentation network, which helps to obtain the connection between the point and its distant context, so as to better segment the components of the substation equipment and improve the point cloud segmentation precision.

[0155] Further, the semantic model Transformer is a kind of neural network that learns context and thus learns meaning by tracking relationships in sequential data. The structure of the semantic model Transformer mainly includes an attention mechanism and a feedforward neural network.

[0156] For example, the structure of the semantic model Transformer includes an attention layer, an MLP (Multilayer Perceptron), a residual connection, and a Dropout.

[0157] Step 103, input the sample point cloud data into the point cloud segmentation network, and identify the semantics of the sample point cloud data in the substation.

[0158] In a specific implementation, the point cloud segmentation network includes an encoder Encoder and a decoder Decoder. The encoder Encoder is used to transform an indefinite-length input sequence into a fixed-length context variable and encode the input sequence information in the context variable. The encoder Encoder is usually a multi-layer semantic model Transformer, which transforms the hidden state of each time step into a context variable through a self-defined function.

[0159] The initial time step of the decoder Decoder is input from a specific symbol. For a sequence in an output, when the decoder Decoder searches for the symbol at a certain time step, the output sequence is completed.

[0160] The context variable output by the encoder Encoder encodes the information of the entire input sequence. Given the output sequence in the sample, for each time step, the conditional probability output by the decoder Decoder will be calculated based on the previous output sequence and the context variable.

[0161] The decoder Decoder is usually a multi-layer RNN (Recurrent Neural Network), and for a time step of an output sequence, the decoder Decoder takes the output of the previous time step and a background variable as input, and transforms them and the hidden state of the previous time step into a hidden state of the current time step.

[0162] The sample point cloud data is input into the point cloud segmentation network, the sample point cloud data is encoded based on the multi-layer semantic model Transformer in the encoder Encoder, and the encoded features are decoded in the decoder Decoder, so as to output the semantics of the sample point cloud data in the transformer substation.

[0163] In an embodiment of the present application, as shown in Figure 2 The point cloud segmentation network includes a point cloud kernel point convolution layer (Kernel Point Convolution, KPConv) and an eight-layer semantic model Transformer, and the structures of the layers of the semantic model Transformer can be the same or different, and the present embodiment does not limit this.

[0164] According to the structure of the point cloud segmentation network, the encoding process of the point cloud segmentation network can be divided into four stages, the first stage includes a KPConv layer and a layer of semantic model Transformer, the second stage includes downsampling and two layers of semantic model Transformer, the third stage includes downsampling and four layers of semantic model Transformer, and the fourth stage includes downsampling and a layer of semantic model Transformer.

[0165] In the present embodiment, step 103 can include the following steps:

[0166] Step 1031, input the sample point cloud data into the point cloud kernel point convolution layer for convolution processing, and sequentially perform normalization operation and activation operation to obtain point cloud structure information.

[0167] As shown in Figure 2 In the first stage, the sample point cloud data is input into the KPConv layer, and the KPConv layer can dynamically generate an adaptive convolution kernel according to the local density of the input sample point cloud data, so as to adapt to sample point cloud data of different sizes and densities to aggregate local point cloud structure information.

[0168] Further, the KPConv layer determines a sphere with a point as the center of the sphere; a plurality of core points are determined in the sphere, each core point has a weight matrix; for any point falling within the sphere, the weight matrix of the point is calculated by using a kernel function, and the feature of the point is transformed by using the matrix; for each point falling within the sphere, a new feature is obtained by using the method in the previous step, and finally the features are accumulated as the feature of the point.

[0169] For the cloud structure information output by the KPConv layer, a normalization operation can be performed on the cloud structure information by using an operator such as BN (batch normalization).

[0170] For the cloud structure information output by the normalization operation, an activation operation can be performed on the cloud structure information by using an activation function such as Leaky ReLU (Leaky Linear rectification function). In the process of back propagation, the gradient can also be calculated for the part of the LeakyReLU activation function input less than zero, avoiding the gradient direction sawtooth problem.

[0171] In step 1032, the point cloud structure information is input into a semantic model Transformer for processing to obtain a first point cloud feature.

[0172] As shown in FIG. 1, in the first stage, the point cloud structure information is input into a semantic model Transformer, and the semantic model Transformer processes the point cloud structure information according to its own structure to obtain a first point cloud feature. Figure 2

[0173] Further, the semantic model Transformer in the first stage has a window attention layer, which is a type of attention layer. The window attention layer performs the following operations:

[0174] The input feature of the window attention layer is linearly transformed by three weights to obtain a first request vector query, a first key vector key, and a first value vector value.

[0175] The similarity between the first request vector query and the first key vector key is calculated by dot product.

[0176] The similarity is normalized to a preset first range (such as [0, 1]) by using a function such as softmax to obtain a first attention weight.

[0177] ​The first attention weights are applied to the first value vector (value) through matrix multiplication and other methods to obtain the features output by the window attention layer.

[0178] In this embodiment, the window attention layer can effectively process local structures and regional features without being disturbed by global information.

[0179] Step 1033: Downsample the first point cloud features and input them sequentially into the two-layer semantic model Transformer for processing to obtain the second point cloud features.

[0180] like Figure 2 As shown, in the second stage, the first point cloud features can be downsampled to increase the receptive field, so that the subsequent structure can learn more global information. The downsampled first point cloud features are then sequentially input into the two-layer semantic model Transformer for processing to obtain the second point cloud features.

[0181] For the two-layer semantic model Transformer, the input of the first semantic model Transformer is the downsampled second point cloud feature, the input of the last semantic model Transformer is the downsampled second point cloud feature, and the input of the next semantic model Transformer is the output of the previous semantic model Transformer.

[0182] Step 1034: Downsample the second point cloud features and input them sequentially into the four-layer semantic model Transformer for processing to obtain the third point cloud features.

[0183] like Figure 2 As shown, in the third stage, the second point cloud features can be downsampled to increase the receptive field, so that the subsequent structure can learn more global information. The downsampled second point cloud features are then sequentially input into the four-layer semantic model Transformer for processing to obtain the third point cloud features.

[0184] For the four-layer semantic model Transformer, the input to the first semantic model Transformer is the downsampled second point cloud feature, the input to the last semantic model Transformer is the downsampled second point cloud feature, and the input to each subsequent semantic model Transformer is the output of the previous semantic model Transformer.

[0185] Step 1035: Downsample the third point cloud features and input them into a semantic model Transformer for processing to obtain the fourth point cloud features.

[0186] likeFigure 2 As shown, in the fourth stage, the third point cloud feature can be downsampled to increase the receptive field, so that the subsequent structure can learn more global information. The downsampled third point cloud feature is then input into a semantic model Transformer. The semantic model Transformer processes the downsampled third point cloud feature information according to its own structure to obtain the fourth point cloud feature.

[0187] Furthermore, in the semantic model Transformer from the second to the eighth layer, each semantic model Transformer has a spatial attention layer. The spatial attention layer is one type of attention layer, and it performs the following operations:

[0188] Calculate the distance matrix (i.e., represent the distance between points in matrix form) between points (including coordinates (x, y, z)) in the sample point cloud data.

[0189] Convert the distance matrix into edge features edge_weights = exp(-distance_matrix / 0.1).

[0190] A linear transformation is performed on the features of the input space attention layer to obtain the second request vector query and the second value vector value.

[0191] Apply a linear transformation to the edge features to obtain the second key vector, key.

[0192] The attention score is calculated using the second request vector (query) and the second key vector (key) through methods such as product.

[0193] The attention scores are normalized to a preset second range (such as [0, 1]) using functions such as softmax, thus obtaining the second attention weight.

[0194] The second attention weights are applied to the second value vector (value) through multiplication and other methods to obtain the features output by the spatial attention layer.

[0195] Inter-attention layers consider the information of each point in the point cloud from a global perspective, thereby capturing global dependencies across the entire feature map.

[0196] Step 1036: Upsample the fourth point cloud feature to obtain the fifth point cloud feature.

[0197] Step 1037: Fuse the third point cloud feature with the fifth point cloud feature and upsample to obtain the sixth point cloud feature.

[0198] Step 1038: Fuse the second point cloud features with the sixth point cloud features and upsample them to obtain the semantics of the sample point cloud data in the substation.

[0199] During the decoding process, multi-level features of each point are learned. At each level, different branches (such as PointNet) are used to expand the feature space (such as bilinear interpolation, deconvolution, unpooling, etc.) to achieve upsampling. The expanded features are then decomposed and reconstructed into an upsampled point cloud.

[0200] Furthermore, considering that directly upsampling the features of the last layer would result in the loss of many details and blurred edges, the features from the encoding process are introduced during the decoding process. By combining the features of the last layer (which has rich global information) with the predictions from shallower layers (which have more local details), detailed information can be recovered and the accuracy of semantic segmentation can be improved.

[0201] Furthermore, such as Figure 2 As shown, the fourth point cloud feature is upsampled to obtain the fifth point cloud feature.

[0202] The third and fifth point cloud features are fused and cropped using functions such as Add and Concat during the encoding process. The features after fusion and cropping of the third and fifth point cloud features are then upsampled to obtain the sixth point cloud feature.

[0203] By using functions such as Add and Concat, the second and sixth point cloud features in the encoding process are fused and cropped. Then, the features after the second and sixth point cloud features are fused and cropped are upsampled to obtain the semantics of the sample point cloud data in the substation.

[0204] Step 104: Train the point cloud segmentation network based on the semantics of the sample point cloud data.

[0205] The semantics of the sample point cloud data in the substation are the result of the cloud segmentation network prediction. The quality of the semantics of the sample point cloud data in the substation is analyzed, and the point cloud segmentation network is trained accordingly.

[0206] In one embodiment of the present invention, step 104 may include the following steps:

[0207] Step 1041: Calculate the loss value using the following loss function:

[0208]

[0209] Where Loss represents the loss value, N represents the number of sample point cloud data, M represents the number of semantics, i represents the i-th sample point cloud data, and j represents the j-th semantic. This represents the true semantic meaning of the annotations on the sample point cloud data. γ represents the semantics of the point cloud segmentation network's prediction of sample point cloud data, and γ represents the balance factor.

[0210] Generally, the samples used to train point cloud segmentation networks are often imbalanced, meaning that the number of point clouds in some categories is much less than the number of point clouds in other categories. This causes the point cloud segmentation network to favor the category with a larger number of samples.

[0211] In this embodiment, the loss function includes two parts: the first part is the cross-entropy loss, which measures the expected encoding length required to represent a sample according to the true distribution; the second part is the Dice loss (coefficient difference loss), which is a statistic used to evaluate the similarity between two samples and measures the overlap between the two samples.

[0212] Between the two loss components, the relative contributions of cross-entropy loss and Dice loss can be balanced by adjusting the balance factor, so that minority and majority samples can be handled more evenly during training. This ensures that samples of all classes are adequately trained, thereby improving the reliability and generalization ability of the point cloud segmentation network.

[0213] Step 1042: Update the point cloud segmentation network based on the loss value.

[0214] During the backpropagation process of the point cloud segmentation network, the loss value can be substituted into optimization algorithms such as SGD (stochastic gradient descent) and Adam (adaptive momentum) to calculate the update magnitude of the parameters in the point cloud segmentation network, and the parameters in the point cloud segmentation network are updated according to the update magnitude.

[0215] Step 1043: Determine whether the preset iteration conditions are met; if yes, proceed to step 1044; otherwise, return to step 1043.

[0216] Step 1044: Determine that the point cloud segmentation network has completed training.

[0217] In this embodiment, iteration conditions can be preset as conditions for stopping training. For example, the number of iterations reaches a threshold, the change in the loss value is less than the threshold for several consecutive iterations, etc. In each round of iteration training, it is determined whether the iteration conditions are met.

[0218] If the iteration conditions are met, the point cloud segmentation network can be considered to have completed training. At this point, the parameters of the point cloud segmentation network are output and persisted to the database.

[0219] If the iteration conditions are not met, the next round of iteration training can be started, and step 1043 can be executed again. This iterative training can be repeated until the point cloud segmentation network training is completed.

[0220] Step 105: If training is complete, input the target point cloud data of the substation into the point cloud segmentation network and identify the semantics of the target point cloud data in the substation.

[0221] Once the point cloud segmentation network has been trained, it can be deployed on devices such as servers and robots. These devices can use sensors such as radar (e.g., lidar) and cameras to scan 3D point cloud data of the substation, which is denoted as target point cloud data. The target point cloud data is then input into the point cloud segmentation network. In the encoder, the target point cloud data is encoded based on a multi-layer semantic model, Transformer. In the decoder, the encoded features are decoded to output the semantics of the target point cloud data in the substation.

[0222] In this embodiment, some points in the original point cloud data of the substation are replaced with some points in the reference point cloud data to obtain sample point cloud data; a point cloud segmentation network with a multi-layer semantic model Transformer is determined; the sample point cloud data is input into the point cloud segmentation network to identify the semantics of the sample point cloud data in the substation; the point cloud segmentation network is trained based on the semantics of the sample point cloud data; if training is complete, the target point cloud data of the substation is input into the point cloud segmentation network to identify the semantics of the target point cloud data in the substation. This embodiment enhances the original point cloud data by replacing some points, increasing the number of samples, thereby improving the performance of training the point cloud segmentation network. Furthermore, the point cloud segmentation network, based on the hierarchical semantic model Transformer, can expand the receptive domain of the point cloud segmentation network for points, effectively obtaining the far-end contextual relationships of points, and improving the accuracy and stability of the point cloud segmentation network.

[0223] Example 2

[0224] Figure 3 This is a schematic diagram of the structure of a substation detection device provided in Embodiment 2 of the present invention. Figure 3 As shown, the device includes:

[0225] The point cloud data replacement module 301 is used to replace some points in the original point cloud data of the substation with some points in the reference point cloud data to obtain sample point cloud data.

[0226] Point cloud segmentation network determination module 302 is used to determine a point cloud segmentation network with a multi-layer semantic model Transformer;

[0227] The sample semantic segmentation module 303 is used to input the sample point cloud data into the point cloud segmentation network and identify the semantics of the sample point cloud data in the substation.

[0228] Point cloud segmentation network training module 304 is used to train the point cloud segmentation network based on the semantics of the sample point cloud data;

[0229] The target semantic segmentation module 305 is used to input the target point cloud data of the substation into the point cloud segmentation network and identify the semantics of the target point cloud data in the substation if training is completed.

[0230] In one embodiment of the present invention, the point cloud data replacement module 301 includes:

[0231] The normalization processing module is used to normalize the raw point cloud data of the substation so that the coordinates of the raw point cloud data are unified to a single coordinate origin. The raw point cloud data is labeled with various tags.

[0232] The label selection module is used to select at least one label as the target label if the normalization process is completed.

[0233] The point erasure module is used to erase points belonging to the target label from the original point cloud data.

[0234] The point filtering module is used to filter out some points belonging to the target label from the reference point cloud data;

[0235] The point addition module is used to add the points selected from the reference point cloud data to the original point cloud data after erasing, thereby obtaining sample point cloud data.

[0236] In one embodiment of the present invention, the dot erasure module is further configured to:

[0237] Determine the first proportion;

[0238] Points belonging to the target label that are randomly erased in the original point cloud data at a first proportion.

[0239] In one embodiment of the present invention, the point filtering module is further configured to:

[0240] Determine the second ratio;

[0241] Randomly select points from the reference point cloud data that account for the second proportion and belong to the target label.

[0242] In one embodiment of the present invention, the point cloud segmentation network includes a point cloud core point convolutional layer and an eight-layer semantic model Transformer;

[0243] The sample semantic segmentation module 303 includes:

[0244] The first encoding module is used to input the sample point cloud data into the convolutional layer of the point cloud core points for convolution processing, and to perform normalization and activation operations in sequence to obtain point cloud structure information; and to input the point cloud structure information into a semantic model Transformer for processing to obtain the first point cloud feature.

[0245] The second encoding module is used to downsample the first point cloud features and input them sequentially into the two-layer semantic model Transformer for processing to obtain the second point cloud features.

[0246] The third encoding module is used to downsample the second point cloud features and input them sequentially into the four-layer semantic model Transformer for processing to obtain the third point cloud features.

[0247] The fourth encoding module is used to downsample the third point cloud features and input them into a semantic model Transformer for processing to obtain the fourth point cloud features.

[0248] The first decoding module is used to upsample the fourth point cloud feature to obtain the fifth point cloud feature;

[0249] The second decoding module is used to fuse the third point cloud feature with the fifth point cloud feature and upsample it to obtain the sixth point cloud feature.

[0250] The third decoding module is used to fuse the second point cloud feature with the sixth point cloud feature and upsample them to obtain the semantics of the sample point cloud data in the substation.

[0251] In one embodiment of the present invention, the semantic model Transformer in the first layer has a window attention layer, which performs the following operations:

[0252] By applying a linear transformation of the features of the input window attention layer using three weights, a first request vector, a first key vector, and a first value vector are obtained.

[0253] Calculate the similarity between the first request vector and the first key vector;

[0254] The similarity is normalized to a preset first range to obtain the first attention weight;

[0255] Apply the first attention weight to the first value vector.

[0256] In one embodiment of the present invention, the semantic model Transformer in layers two through eight has a spatial attention layer that performs the following operations:

[0257] Calculate the distance matrix between points in the sample point cloud data;

[0258] Convert the distance matrix into edge features;

[0259] A linear transformation is performed on the features input to the spatial attention layer to obtain a second request vector and a second value vector;

[0260] A linear transformation is performed on the edge features to obtain the second key vector;

[0261] The attention score is calculated using the second request vector and the second key vector;

[0262] The attention score is normalized to a preset second range to obtain the second attention weight;

[0263] The second attention weight is applied to the second value vector.

[0264] In one embodiment of the present invention, the point cloud segmentation network training module 304 includes:

[0265] The loss calculation module is used to calculate the loss value using the following loss function:

[0266]

[0267] Where Loss represents the loss value, N represents the number of sample point cloud data, M represents the number of semantics, i represents the i-th sample point cloud data, and j represents the j-th semantic. This represents the true semantic meaning of the annotations on the sample point cloud data. The semantics of the point cloud segmentation network's prediction of the sample point cloud data are represented by γ, where γ represents the balance factor.

[0268] A point cloud segmentation network update module is used to update the point cloud segmentation network based on the loss value;

[0269] The iteration condition judgment module is used to determine whether the preset iteration conditions are met; if yes, the training completion determination module is executed; if no, the execution of the sample semantic segmentation module 303 is returned.

[0270] The training completion determination module is used to determine whether the point cloud segmentation network has completed training.

[0271] The substation detection device provided in this embodiment of the invention can execute the substation detection method provided in any embodiment of the invention, and has the corresponding functional modules and beneficial effects for executing the substation detection method.

[0272] Example 3

[0273] Figure 4 A schematic diagram of an electronic device 10 that can be used to implement embodiments of the present invention is shown. The electronic device is intended to represent various forms of digital computers, such as laptop computers, desktop computers, workstations, personal digital assistants, servers, blade servers, mainframe computers, and other suitable computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular phones, smartphones, wearable devices (e.g., helmets, glasses, watches, etc.), and other similar computing devices. The components shown herein, their connections and relationships, and their functions are merely illustrative and are not intended to limit the implementation of the invention described and / or claimed herein.

[0274] like Figure 4 As shown, the electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12 or a random access memory (RAM) 13, communicatively connected to the at least one processor 11. The memory stores computer programs executable by the at least one processor. The processor 11 can perform various appropriate actions and processes based on the computer program stored in the ROM 12 or loaded from storage unit 18 into the RAM 13. The RAM 13 may also store various programs and data required for the operation of the electronic device 10. The processor 11, ROM 12, and RAM 13 are interconnected via a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0275] Multiple components in electronic device 10 are connected to I / O interface 15, including: input unit 16, such as keyboard, mouse, etc.; output unit 17, such as various types of displays, speakers, etc.; storage unit 18, such as disk, optical disk, etc.; and communication unit 19, such as network card, modem, wireless transceiver, etc. Communication unit 19 allows electronic device 10 to exchange information / data with other devices through computer networks such as the Internet and / or various telecommunications networks.

[0276] Processor 11 can be a variety of general-purpose and / or special-purpose processing components with processing and computing capabilities. Some examples of processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. Processor 11 performs the various methods and processes described above, such as substation detection methods.

[0277] In some embodiments, the substation detection method may be implemented as a computer program tangibly contained in a computer-readable storage medium, such as storage unit 18. In some embodiments, part or all of the computer program may be loaded and / or installed on electronic device 10 via ROM 12 and / or communication unit 19. When the computer program is loaded into RAM 13 and executed by processor 11, one or more steps of the substation detection method described above may be performed. Alternatively, in other embodiments, processor 11 may be configured to perform the substation detection method by any other suitable means (e.g., by means of firmware).

[0278] Various embodiments of the systems and techniques described above herein can be implemented in digital electronic circuit systems, integrated circuit systems, field-programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SoCs), payload-programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof. These various embodiments may include implementations in one or more computer programs that can be executed and / or interpreted on a programmable system including at least one programmable processor, which may be a dedicated or general-purpose programmable processor, capable of receiving data and instructions from a storage system, at least one input device, and at least one output device, and transmitting data and instructions to the storage system, the at least one input device, and the at least one output device.

[0279] Computer programs used to implement the methods of the present invention may be written in any combination of one or more programming languages. These computer programs may be provided to a processor of a general-purpose computer, a special-purpose computer, or other programmable data processing device, such that when executed by the processor, the computer programs cause the functions / operations specified in the flowcharts and / or block diagrams to be performed. The computer programs may be executed entirely on a machine, partially on a machine, or as a standalone software package, partially on a machine and partially on a remote machine, or entirely on a remote machine or server.

[0280] In the context of this invention, a computer-readable storage medium can be a tangible medium that may contain or store a computer program for use by or in conjunction with an instruction execution system, apparatus, or device. A computer-readable storage medium may include, but is not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination thereof. Alternatively, a computer-readable storage medium may be a machine-readable signal medium. More specific examples of machine-readable storage media include electrical connections based on one or more wires, portable computer disks, hard disks, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fibers, portable compact disk read-only memory (CD-ROM), optical storage devices, magnetic storage devices, or any suitable combination thereof.

[0281] To provide interaction with a user, the systems and techniques described herein can be implemented on an electronic device having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user; and a keyboard and pointing device (e.g., a mouse or trackball) through which the user provides input to the electronic device. Other types of devices can also be used to provide interaction with the user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form (including sound input, voice input, or tactile input).

[0282] The systems and technologies described herein can be implemented in computing systems that include backend components (e.g., as data servers), or computing systems that include middleware components (e.g., application servers), or computing systems that include frontend components (e.g., user computers with graphical user interfaces or web browsers through which users can interact with implementations of the systems and technologies described herein), or any combination of such backend, middleware, or frontend components. The components of the system can be interconnected via digital data communication of any form or medium (e.g., communication networks). Examples of communication networks include local area networks (LANs), wide area networks (WANs), blockchain networks, and the Internet.

[0283] A computing system can include clients and servers. Clients and servers are generally located far apart and typically interact through communication networks. The client-server relationship is created by computer programs running on the respective computers and having a client-server relationship with each other. The server can be a cloud server, also known as a cloud computing server or cloud host, which is a hosting product within the cloud computing service system to address the shortcomings of traditional physical hosts and VPS services, such as high management difficulty and weak business scalability.

[0284] Example 4

[0285] This invention also provides a computer program product, which includes a computer program that, when executed by a processor, implements the substation detection method provided in any embodiment of this invention.

[0286] In implementing the computer program product, computer program code for performing the operations of this invention can be written in one or more programming languages ​​or a combination thereof. Programming languages ​​include object-oriented programming languages ​​such as Java, Smalltalk, and C++, as well as conventional procedural programming languages ​​such as C or similar languages. The program code can be executed entirely on the user's computer, partially on the user's computer, as a standalone software package, partially on the user's computer and partially on a remote computer, or entirely on a remote computer or server. In cases involving remote computers, the remote computer can be connected to the user's computer via any type of network—including a local area network (LAN) or a wide area network (WAN)—or can be connected to an external computer (e.g., via the Internet using an Internet service provider).

[0287] It should be understood that the various forms of processes shown above can be used, with steps reordered, added, or deleted. For example, the steps described in this invention can be executed in parallel, sequentially, or in different orders, as long as the desired result of the technical solution of this invention can be achieved, and this is not limited herein.

[0288] The specific embodiments described above do not constitute a limitation on the scope of protection of this invention. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this invention should be included within the scope of protection of this invention.

Claims

1. A method for detecting substations, characterized in that, include: The original point cloud data of the substation is partially replaced with a portion of the reference point cloud data to obtain sample point cloud data. The reference point cloud data is scanned point cloud data of other substations. The points in the reference point cloud data are labeled. The current substation and other substations are at least partially the same or similar in terms of equipment type and equipment layout, so that the original point cloud data of the current substation can be partially replaced with the reference point cloud data of other substations. A point cloud segmentation network with a multi-layer semantic model Transformer is determined; wherein, the point cloud segmentation network includes: a convolutional layer of the core points of the point cloud and an eight-layer semantic model Transformer; Inputting the sample point cloud data into the point cloud segmentation network and identifying the semantics of the sample point cloud data in the substation includes: The sample point cloud data is input into the convolutional layer of the point cloud core points for convolution processing, and normalization and activation operations are performed sequentially to obtain point cloud structure information. The point cloud structure information is input into a semantic model Transformer for processing to obtain a first point cloud feature. The first point cloud feature is downsampled and sequentially input into a two-layer semantic model Transformer for processing to obtain a second point cloud feature. The second point cloud feature is downsampled and sequentially input into a four-layer semantic model Transformer for processing to obtain a third point cloud feature. The third point cloud feature is downsampled and input into a one-layer semantic model Transformer for processing to obtain a fourth point cloud feature. The fourth point cloud feature is upsampled to obtain a fifth point cloud feature. The third and fifth point cloud features are fused and upsampled to obtain a sixth point cloud feature. The second and sixth point cloud features are fused and upsampled to obtain the semantics of the sample point cloud data in the substation. The semantic model Transformer in the first layer includes a window attention layer, which performs the following operations: linearly transforming the features input to the window attention layer with three weights to obtain a first request vector, a first key vector, and a first value vector; calculating the similarity between the first request vector and the first key vector; normalizing the similarity to a preset first range to obtain a first attention weight; and applying the first attention weight to the first value vector. The point cloud segmentation network is trained based on the semantics of the sample point cloud data; If training is complete, the target point cloud data of the substation is input into the point cloud segmentation network to identify the semantics of the target point cloud data in the substation. The step of replacing some points in the original point cloud data of the substation with some points in the reference point cloud data to obtain sample point cloud data includes: The original point cloud data of the substation is normalized so that the coordinates of the original point cloud data are unified to a single coordinate origin. The original point cloud data is labeled with multiple tags. If the normalization process is completed, at least one label is selected as the target label; Points belonging to the target label in the erased portion of the original point cloud data; Select a subset of points belonging to the target label from the reference point cloud data; The points selected from the reference point cloud data are added to the original point cloud data after erasing, to obtain sample point cloud data.

2. The method according to claim 1, characterized in that, The points belonging to the target label in the erased portion of the original point cloud data include: Determine the first proportion; Points belonging to the target label that are randomly erased at a first proportion in the original point cloud data; The step of filtering out a portion of the points belonging to the target label from the reference point cloud data includes: Determine the second ratio; Randomly select points from the reference point cloud data that account for the second proportion and belong to the target label.

3. The method according to claim 1, characterized in that, The semantic model Transformer, from the second to the eighth layers, includes a spatial attention layer that performs the following operations: Calculate the distance matrix between points in the sample point cloud data; Convert the distance matrix into edge features; A linear transformation is performed on the features input to the spatial attention layer to obtain a second request vector and a second value vector; A linear transformation is performed on the edge features to obtain the second key vector; The attention score is calculated using the second request vector and the second key vector; The attention score is normalized to a preset second range to obtain the second attention weight; The second attention weight is applied to the second value vector.

4. The method according to any one of claims 1-3, characterized in that, The step of semantically training the point cloud segmentation network based on the sample point cloud data includes: The loss value is calculated using the following loss function: Where Loss represents the loss value, N represents the number of sample point cloud data, M represents the number of semantics, i represents the i-th sample point cloud data, and j represents the j-th semantic. This represents the true semantic meaning of the annotations on the sample point cloud data. The semantics of the point cloud segmentation network's prediction of the sample point cloud data are represented by γ, where γ represents the balance factor. The point cloud segmentation network is updated based on the loss value; Determine whether the preset iteration conditions are met; if yes, determine that the point cloud segmentation network has completed training; otherwise, return to the step of inputting the sample point cloud data into the point cloud segmentation network and identifying the semantics of the sample point cloud data in the substation.

5. A detection device for a substation, characterized in that, include: The point cloud data replacement module is used to replace some points in the original point cloud data of a substation with some points in the reference point cloud data to obtain sample point cloud data; wherein, the reference point cloud data is scanned point cloud data of other substations; the points in the reference point cloud data are labeled, and the current substation and other substations are at least partially the same or similar in terms of equipment type and equipment layout, so that the original point cloud data of the current substation can be partially replaced with the reference point cloud data of other substations. The point cloud segmentation network determination module is used to determine the point cloud segmentation network with a multi-layer semantic model Transformer; The sample semantic segmentation module includes: a first encoding module, a second encoding module, a third encoding module, a fourth encoding module, a first decoding module, a second decoding module, and a third decoding module; The first encoding module is used to input the sample point cloud data into the convolutional layer of the point cloud core points for convolution processing, and to perform normalization and activation operations in sequence to obtain point cloud structure information; and to input the point cloud structure information into a semantic model Transformer for processing to obtain the first point cloud feature; The second encoding module is used to downsample the first point cloud features and input them sequentially into a two-layer semantic model Transformer for processing to obtain the second point cloud features; The third encoding module is used to downsample the second point cloud features and input them sequentially into the four-layer semantic model Transformer for processing to obtain the third point cloud features. The fourth encoding module is used to downsample the third point cloud features and input them into a semantic model Transformer for processing to obtain the fourth point cloud features. The first decoding module is used to upsample the fourth point cloud feature to obtain the fifth point cloud feature; The second decoding module is used to fuse the third point cloud feature with the fifth point cloud feature and upsample them to obtain the sixth point cloud feature; The third decoding module is used to fuse the second point cloud feature and the sixth point cloud feature and upsample them to obtain the semantics of the sample point cloud data in the substation. The semantic model Transformer in the first layer includes a window attention layer, which performs the following operations: linearly transforming the features input to the window attention layer with three weights to obtain a first request vector, a first key vector, and a first value vector; calculating the similarity between the first request vector and the first key vector; normalizing the similarity to a preset first range to obtain a first attention weight; and applying the first attention weight to the first value vector. A point cloud segmentation network training module is used to train the point cloud segmentation network based on the semantics of the sample point cloud data. The target semantic segmentation module is used to input the target point cloud data of the substation into the point cloud segmentation network and identify the semantics of the target point cloud data in the substation if training is completed. The point cloud data replacement module includes: The normalization processing module is used to normalize the raw point cloud data of the substation so that the coordinates of the raw point cloud data are unified to a single coordinate origin. The raw point cloud data is labeled with various tags. The label selection module is used to select at least one label as the target label if the normalization process is completed. The point erasure module is used to erase points belonging to the target label from the original point cloud data. The point filtering module is used to filter out some points belonging to the target label from the reference point cloud data; The point addition module is used to add the points selected from the reference point cloud data to the original point cloud data after erasing, thereby obtaining sample point cloud data.

6. An electronic device, characterized in that, The electronic device includes: At least one processor; and A memory communicatively connected to the at least one processor; wherein, The memory stores a computer program that can be executed by the at least one processor, the computer program being executed by the at least one processor to enable the at least one processor to perform the substation detection method according to any one of claims 1-4.

7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, implements the substation detection method according to any one of claims 1-4.

Citation Information

Patent Citations

  • Radar segmentation method fusing space attention and self-attention transformation network

    CN114119615A

  • Radar point cloud data processing method and device, equipment and storage medium

    CN114296083A