An active electric field positioning method, training method and system based on a graph neural network
Patent Information
- Application Number
- CN202611078135.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-07-20
- Publication Date
- 2026-10-27
AI Technical Summary
[0005]本发明要解决的技术问题是:针对现有主动电场定位方案将电极测量数据表示为一维向量而无法显式利用电极空间拓扑关系的问题,提出一种能够保留电极空间邻接关系并基于图神经网络实现目标三维定位的方法、训练方法及系统
[0017]1. 由于将电极映射为图节点并依据空间邻接关系构建边,因此能够显式保留电极阵列的物理拓扑结构。
Smart Images

Figure CN122986940A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of electrical measurement and target localization technology, and in particular to a method, training method and system for performing graph structure modeling of active electric field electrode array signals and realizing three-dimensional target localization based on graph neural networks. Background Technology
[0002] Active electric field localization technology establishes an excitation electric field in a medium, uses arrayed electrodes to measure the field changes caused by target disturbances, and then inverts the target position. Traditional localization algorithms usually rely on accurate physical models, have limited generalization ability to complex fields, and are computationally time-consuming, making it difficult to meet real-time requirements.
[0003] In related research or engineering implementation, a method can be adopted to concatenate the differential voltage values measured by multiple electrodes into a one-dimensional feature vector in a predetermined order, and then input it into a fully connected neural network for position regression. Although this approach can achieve end-to-end positioning, because the input features are represented as a one-dimensional vector, the inherent spatial adjacency relationships and inter-layer topological relationships between electrodes are not explicitly represented. Therefore, in scenarios where electric field propagation and target disturbance are highly dependent on spatial distribution, there are problems such as limited positioning accuracy, insufficient adaptability to array structure changes, and poor model robustness.
[0004] Therefore, how to effectively integrate the spatial topology information of the electrodes into the data representation and model structure has become a key issue in improving the performance of active electric field positioning. Summary of the Invention
[0005] The technical problem to be solved by this invention is: addressing the issue that existing active electric field positioning schemes represent electrode measurement data as one-dimensional vectors and cannot explicitly utilize the topological relationships of the electrode space, this invention proposes a method, training method, and system that can preserve the adjacency relationships of the electrode space and achieve three-dimensional positioning of the target based on graph neural networks.
[0006] To address the aforementioned technical problems, this invention provides an active electric field localization method based on a graph neural network. The method includes: acquiring multiple voltage signals collected by an electrode array arranged in a monitoring area after an alternating electric field is established by an excitation source; preprocessing the multiple voltage signals to obtain voltage features corresponding to each electrode, the voltage features including local differential voltage features based on the voltage amplitudes of spatially adjacent electrodes; mapping each electrode to a node in graph structure data according to its spatial position, and constructing edges between nodes based on the spatial adjacency relationships between electrodes; constructing node features based on the voltage features and the spatial position information of the corresponding electrodes to obtain graph structure data G=(V,E,H), where V represents the set of nodes, E represents the set of edges, and H represents the node feature matrix; inputting the graph structure data into a pre-trained graph neural network model, aggregating neighborhood information of the node features through the graph neural network model to form a graph-level representation; and regressing the three-dimensional coordinates of the target based on the graph-level representation.
[0007] Furthermore, the preprocessing includes at least one of filtering, frequency domain analysis, and differential processing. The frequency domain analysis is used to extract the voltage amplitude at the excitation frequency from the acquired signal to suppress noise and interference in the non-excitation frequency band; the differential processing is used to calculate the voltage amplitude difference between each electrode and its spatially adjacent electrodes, and the resulting local differential voltage characteristics can characterize the local electric field gradient change caused by the target disturbance.
[0008] Furthermore, the node features include a first type of feature and a second type of feature. The first type of feature includes the voltage characteristics and spatial coordinates of the corresponding electrode, used to describe the local electric field response and spatial location on a single electrode node; the second type of feature is a context feature extracted from the global or local voltage signal, including at least one of global signal strength, inter-layer signal ratio, signal peak location identifier, and distance to the excitation source, used to help characterize the overall influence and layer position of the target within the monitoring area. The inter-layer signal ratio is determined based on the ratio of the voltage amplitudes of the corresponding electrodes in the upper and lower layers, used to characterize the relative position of the target in the vertical direction.
[0009] Furthermore, the spatial adjacency relationship includes at least one of the following: adjacency relationship between electrodes in the same layer, correspondence relationship between electrodes in upper and lower layers, adjacency relationship determined based on a distance threshold, and adjacency relationship determined based on K nearest neighbors. In one specific embodiment, electrodes in the same layer are linked together in a chain according to their physical arrangement, and electrodes in upper and lower layers corresponding to spatial projection positions are linked together to form an interlayer connection, thereby simultaneously characterizing both the adjacency relationship within the same layer and the correspondence relationship between layers. For electrodes located at the array boundary, the corresponding differential voltage characteristics can be obtained by using cyclic adjacency, mirroring, or zero-padding.
[0010] Furthermore, the graph neural network model includes a node encoding layer, one or more graph messaging layers, a global pooling layer, and a regression output layer. The node encoding layer performs feature transformation on the input node features, mapping them to a hidden feature space suitable for graph messaging. The graph messaging layer aggregates the features of neighboring nodes based on the edge set and updates the node representation, thereby explicitly incorporating the spatial correlation of the electric field perturbation into the node representation. The global pooling layer employs attention pooling, global average pooling, or global max pooling to aggregate all node representations into a graph-level representation. The regression output layer is a multilayer perceptron, used to output the target's three-dimensional coordinates based on the graph-level representation.
[0011] Furthermore, in the graph messaging layer, for the l-th layer, its node update formula can be abstractly expressed as:
[0012] (1)
[0013] in, This represents the electric field perturbation feature vector of electrode node i after message passing in the l-th layer graph, which incorporates spatial neighborhood information; Represents a node The set of neighbors; This represents the local electric field perturbation characteristic vector output by electrode node i in the previous layer. This represents the local electric field perturbation feature vector output by the neighboring electrode node j in the previous layer; Differentiable aggregation functions are used to fuse feature vectors reflecting spatial electric field gradient information detected by all electrodes in the set of neighboring electrode nodes. and The transformation function can be learned. Through the above message passing mechanism, the representation of each electrode node gradually integrates the electric field disturbance information detected by other electrodes in its spatial neighborhood. The final graph-level representation can comprehensively reflect the spatial distribution of target disturbances sensed by the entire electrode array.
[0014] This invention also provides a graph neural network training method for active electric field localization. The training method includes: after establishing an alternating electric field from an excitation source, acquiring multiple voltage signals output by an electrode array when the target is located at multiple known spatial positions; preprocessing the multiple voltage signals to obtain voltage features corresponding to each electrode, and associating and saving the voltage features with known three-dimensional position labels of the target; constructing each set of acquired data into a graph structure sample with position labels based on the spatial position and spatial adjacency relationship of each electrode; constructing a training dataset from multiple graph structure samples; training a graph neural network model using the training dataset, enabling the graph neural network model to learn the mapping relationship between the graph structure data and the three-dimensional position of the target; and obtaining graph neural network model parameters for executing the above-described active electric field localization method.
[0015] This invention also provides an active electric field localization system based on a graph neural network, comprising an electrode array, an excitation source, a signal processing module, a graph data construction module, and a localization output module. The electrode array is used to acquire multiple voltage signals generated after a target is disturbed by an alternating electric field; the excitation source is used to establish an alternating electric field within the monitoring area; the signal processing module is used to preprocess the multiple voltage signals to obtain voltage features corresponding to each electrode; the graph data construction module is used to map each electrode as a graph node according to its spatial position, construct graph edges according to the spatial adjacency relationship between electrodes, and generate node features based on the voltage features and electrode spatial position information to obtain graph structure data; the localization output module is used to input the graph structure data into a pre-trained graph neural network model and output the three-dimensional coordinates of the target.
[0016] Compared with the prior art, the beneficial effects of the present invention are as follows:
[0017] 1. By mapping the electrodes as graph nodes and constructing edges based on spatial adjacency, the physical topology of the electrode array can be explicitly preserved.
[0018] 2. Because graph neural networks aggregate neighborhood node information under edge connection constraints, they can explicitly extract the correlation features of spatial electric field disturbances, which further improves the target 3D positioning accuracy compared with fully connected neural networks that do not introduce topological priors.
[0019] 3. By using graph-level representation for 3D coordinate regression, the ability to adapt to different target locations and complex field conditions is improved while maintaining end-to-end reasoning capabilities.
[0020] 4. Since the online localization phase can directly call the pre-trained model without explicitly solving complex inverse problems, it has better real-time performance and is suitable for engineering deployment. Attached Figure Description
[0021] Figure 1 This is a schematic diagram of the hardware platform structure of the active electric field positioning system according to an embodiment of the present invention;
[0022] Figure 2 This is a schematic diagram of the graph data construction process according to an embodiment of the present invention;
[0023] Figure 3 This is a schematic diagram of the graph neural network model structure according to an embodiment of the present invention;
[0024] Figure 4 This is a schematic diagram illustrating the deployment of the present invention in an obstacle avoidance and detection scenario for unmanned surface vessels. Detailed Implementation
[0025] The present invention will now be described in further detail with reference to the accompanying drawings. It should be understood that the embodiments described herein are for illustrative purposes only and are not intended to limit the scope of protection of the present invention. All technical solutions implemented based on the core concept of the present invention fall within the scope of protection of the present invention.
[0026]
Example 1
[0027] This embodiment is a preferred implementation of the active electric field localization method and training method based on graph neural networks of the present invention, and is carried out according to the following steps:
[0028] S1. Data Acquisition and Preprocessing
[0029] This step is based on Figure 1 The hardware platform shown includes a monitoring pool 1, an array of 32 electrodes arranged in two layers 2, an excitation source 3, a signal acquisition module 4, and a target object 5. The excitation source 3 outputs a 200Hz sine wave signal with a peak-to-peak value of 10Vpp to establish an alternating electric field within the pool. The target to be located is a 100mm × 100mm aluminum plate, which moves within a monitoring area of 21-66cm on the X-axis, 20-47cm on the Y-axis, and 5-32cm on the Z-axis using a three-axis displacement device.
[0030] When the target object 5 is located at a known position, the raw voltage signals of each electrode are acquired. After bandpass filtering and fast Fourier transform, the amplitude of the excitation frequency point is extracted. Then, for each electrode, differential calculation is performed based on its voltage amplitude with the spatially adjacent electrodes to prepare for constructing the local differential features of each node in subsequent steps. All acquired signals are processed in this way and associated with the corresponding target 3D position labels to form the original dataset.
[0031] S2, Graph Data Construction
[0032] Each set of differential voltage data and related spatial and contextual information is constructed into a graph-structured data G=(V,E,H), according to the following rules, combined with... Figure 2 illustrate.
[0033] Node set V: 32 electrodes correspond one-to-one with 32 nodes, of which the upper 16 electrodes correspond to nodes v1 to v2 respectively. 16 The lower 16 electrodes correspond to nodes v. 17 to v 32 Each node retains the spatial coordinate information of its corresponding electrode, enabling the graph structure data to characterize the spatial arrangement of the electrode array.
[0034] Node Features H: Each node corresponds to a 9-dimensional feature vector, including normalized 3D spatial coordinates, 2D normalized differential voltage features, global signal strength, inter-layer signal ratio, peak indicator, and normalized distance to the excitation source. Its corresponding 2D normalized differential voltage features can be calculated as follows: 1) Calculate the voltage amplitude difference ΔV between it and its preceding adjacent electrode; 2) Calculate the voltage amplitude difference ΔV between it and its subsequent adjacent electrode.
[0035] Among them, the global signal strength can be the mean, maximum, sum or norm of the voltage amplitude of all electrodes at the excitation frequency; the interlayer signal ratio can be the ratio of the voltage amplitude of the electrodes corresponding to the spatial projection positions of the upper and lower layers, with a preset small amount added to the denominator to avoid division by zero; the peak value can be a binary identifier indicating whether the current node corresponds to the electrode with the maximum voltage amplitude; the normalized distance to the excitation source can be the value obtained by normalizing the Euclidean distance between the spatial coordinates of the current electrode and the center coordinates of the excitation source.
[0036] Therefore, although there are 32 signals globally, this differential strategy, tailored to the adaptive graph structure, generates differential features for each node that characterize the gradient of its local neighborhood field. This is different from the method of directly splicing multiple voltage signals into a one-dimensional global vector.
[0037] Edge set E: Undirected edges are constructed using a combination of intra-layer chain connections and inter-layer correspondence connections. Specifically, the 16 electrodes in the upper layer are sequentially linked according to their physical arrangement, and the 16 electrodes in the lower layer are also sequentially linked according to their physical arrangement. Simultaneously, for the i-th electrode in the upper layer and the i-th electrode in the lower layer corresponding to its spatial projection position, inter-layer correspondence connections are established, where i = 1, 2, ..., 16. This method allows the graph structure data to simultaneously represent the intra-layer adjacency relationships and the topological correspondences between the upper and lower layers of the electrode array.
[0038] In other implementations, supplementary edges can be established using the K-nearest neighbor method or a connection method based on a distance threshold. For example, an edge can be established when the spatial distance between two electrodes is less than a set threshold, or an edge can be established between each electrode and its K nearest neighbor electrodes to accommodate electrode arrays of different shapes and densities.
[0039] S3, Model Building and Training
[0040] In this embodiment, 1000 valid samples were collected and randomly divided into training, validation, and test sets in a 7:1.5:1.5 ratio. To eliminate the randomness of a single partition, five different random seeds were used to partition the data and train independently. The final results are reported as mean ± standard deviation. The AdamW optimizer was used during training with an initial learning rate of 0.001, a batch size of 32, and a total of 20 training epochs. A learning rate decay and an early stopping mechanism based on validation set loss were introduced, and the Huber loss function was used.
[0041] The constructed graph neural network model consists of, in sequence: a node encoding layer, two graph message passing layers with residual connections (as shown in the graph convolutional layer), a global attention pooling layer, and two fully connected regression output layers, such as... Figure 3 As shown. The node encoding layer maps 9-dimensional node features to a hidden feature space; the graph message passing layer aggregates neighbor node information through a message passing mechanism; the global attention pooling layer aggregates all node representations into a graph-level representation; and the regression output layer maps the graph-level representation into the target's three-dimensional coordinates.
[0042] In contrast, the Fully Connected Neural Network (FCNN) baseline model uses the same training, validation, and test set partitioning as the Graph Neural Network (GNN) model. The input features of FCNN are electrode differential voltages arranged in a fixed order and related contextual features. The loss function, optimizer, training epochs, and evaluation metrics are consistent with the GNN model to evaluate the contribution of graph structure modeling to localization performance.
[0043] S4, Positioning Prediction
[0044] For the test set samples, preprocess and construct the graph structure according to the above process, input them into the trained GNN model, and directly output the target's 3D coordinates. In the online localization stage, there is no need to retrain the model; only the real-time acquired signals need to undergo the same preprocessing, normalization, and graph construction as in the training stage, and then be input into the pre-trained and fixed graph neural network model to complete the coordinate output.
[0045] The average and standard deviation were calculated by running the test five times with different random seeds. The coefficient of determination R², mean absolute error (MAE), and root mean square error (RMSE) were used as evaluation indicators. All units are in centimeters. The quantitative comparison results are shown in Table 1.
[0046] Table 1 Comparison of Localization Performance between GNN and FCNN
[0047] Model coordinate axes R² (mean ± standard deviation) MAE (mean ± standard deviation) RMSE (mean ± standard deviation) FCNN X 0.9854 ± 0.0040 1.3100 ± 0.1248 1.7703 ± 0.2508 FCNN Y 0.9873 ± 0.0022 0.7481 ± 0.0947 0.9871 ± 0.0990 FCNN Z 0.9748 ± 0.0027 0.9848 ± 0.0891 1.3291 ± 0.1122 GNN X 0.9889 ± 0.0017 1.1304 ± 0.1584 1.5563 ± 0.1215 GNN Y 0.9912 ± 0.0017 0.6220 ± 0.0621 0.8156 ± 0.0767 GNN Z 0.9788 ± 0.0039 0.8527 ± 0.0927 1.2124 ± 0.1018
[0048] The results show that the GNN method has lower MAE and RMSE on all coordinate axes than FCNN, especially the Y-axis MAE is reduced by about 17% and the Z-axis RMSE is reduced by about 8.8%, and the standard deviation of each index is generally smaller, which verifies the effect of the spatial topological prior introduced by the graph structure on improving localization accuracy and stability.
[0049]
Example 2
[0050] This embodiment is an engineering implementation of the present invention in an obstacle avoidance and detection scenario for unmanned surface vessels and autonomous underwater robots. The core method is the same as in Embodiment 1. Under known laboratory conditions, the model is trained offline using the training method described in Embodiment 1. After training, the model parameters are solidified and lightweighted for adaptation to embedded platforms.
[0051] like Figure 4 As shown, the electrode array 2 is fixed to the underwater robot body 6, and the excitation source 3, signal acquisition module 4, and onboard embedded computer 7 are integrated. During navigation, the underwater robot collects voltage signals, constructs graph data, inputs the trained model, and outputs the three-dimensional coordinates of underwater obstacles 8 in real time. The embedded platform can be an ARM processor platform or a GPU edge computing platform. The model inference cycle is less than the preset control cycle to meet the real-time requirements of navigation control. The output obstacle three-dimensional coordinates are sent to the path planning module or obstacle avoidance control module to generate control commands.
[0052] The above description is merely a preferred embodiment of the present invention, and the scope of protection of the present invention is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in the present invention should be included within the scope of protection of the present invention.
Claims
1. An active electric field localization method based on graph neural networks, characterized in that, Includes the following steps: 1) Acquire multiple voltage signals obtained by the electrode array arranged in the monitoring area after the excitation source establishes an alternating electric field; 2) Preprocess the multi-channel voltage signals and extract local differential voltage features for each electrode based on the voltage amplitudes of its spatially adjacent electrodes; 3) Based on the spatial location of each electrode, map each electrode to a node in the graph structure data, and construct edges between nodes according to the spatial adjacency relationship between electrodes; wherein, the spatial adjacency relationship includes at least the chain adjacency relationship between electrodes in the same layer; 4) Based on the local differential voltage characteristics and the spatial location information of the corresponding electrodes, construct node features to obtain graph structure data G=(V,E,H), where V represents the set of nodes, E represents the set of edges, and H represents the node feature matrix; 5) Input the graph structure data into a pre-trained graph neural network model, and use the graph neural network model to aggregate neighborhood information of node features and form a graph-level representation; 6) The three-dimensional coordinates of the target are output based on the graph-level characterization.
2. The method according to claim 1, characterized in that, The node features include a first type of feature and a second type of feature; the first type of feature includes the local differential voltage feature of the corresponding electrode and its spatial coordinates; the second type of feature is a context feature extracted from the global or local voltage signal, including at least one of global signal strength, inter-layer signal ratio, signal peak position identifier, and distance to the excitation source; wherein, the inter-layer signal ratio is determined according to the ratio of the voltage amplitudes of the corresponding electrodes in the upper and lower layers; for any electrode node, its local differential voltage feature includes the difference between the voltage amplitude of the electrode and the voltage amplitude of the previous and next electrodes along the chain adjacency direction; for electrodes located at the array boundary, the corresponding local differential voltage feature is obtained by cyclic adjacency, mirroring, or zero-padding.
3. The method according to claim 1, characterized in that, The electrode array includes at least two layers of electrodes, and the spatial adjacency relationship also includes the corresponding connection between electrodes of different layers, that is, the upper layer electrode and the lower layer electrode corresponding to the spatial projection position are connected; the graph edge construction also includes: when the spatial distance between two electrodes is less than a set threshold, or when one electrode is one of the K nearest neighbors of the other electrode, a supplementary edge is established between the two electrodes.
4. The method according to claim 1, characterized in that, The electrode array includes 32 electrodes arranged in two layers, with 16 electrodes in each layer. Each electrode corresponds to a graph node, and the graph structure data includes 32 nodes. Adjacent electrodes in the same layer are linked together according to their physical arrangement. Interlayer connections are established between the upper layer electrodes and the electrodes corresponding to their spatial projection positions in the lower layer. The linked connections and the interlayer connections together constitute the edge set in the graph structure data.
5. The method according to claim 1, characterized in that, The graph neural network model includes a node encoding layer, one or more graph message passing layers, a global pooling layer, and a regression output layer. The node encoding layer performs feature transformation on the input node features. The graph message passing layer aggregates the features of neighboring nodes based on the edge set and updates the node representation. The global pooling layer uses attention pooling, global average pooling, global max pooling, or a combination thereof to aggregate multiple node representations into a graph-level representation. The regression output layer is a multilayer perceptron, used to output the target's three-dimensional coordinates based on the graph-level representation. In the graph message passing layer, for the l-th layer, its node update formula can be abstractly expressed as: (1) in, This represents the node representation of electrode node i after message passing in the l-th layer graph. Represents a node The set of neighbors; This represents the local electric field perturbation characteristic vector output by electrode node i in the previous layer. This represents the local electric field perturbation feature vector output by the neighboring electrode node j in the previous layer; Differentiable aggregation functions are used to fuse feature vectors reflecting spatial electric field gradient information detected by all electrodes in the set of neighboring electrode nodes. and This represents a learnable transformation function.
6. A graph neural network training method for active electric field localization, characterized in that, include: 1) After the alternating electric field is established by the excitation source, the multiple voltage signals output by the electrode array are collected when the target is located at multiple known spatial positions; 2) Preprocess the multi-channel voltage signals, extract local differential voltage features based on the voltage amplitudes of their spatially adjacent electrodes for each electrode, and associate and save the local differential voltage features with the known three-dimensional location labels of the target; 3) Based on the spatial location and spatial adjacency of each electrode, each set of collected data is constructed into a graph structure sample with location labels; wherein, the spatial adjacency relationship includes at least the chain adjacency relationship between electrodes in the same layer; 4) Construct a training dataset from multiple graph structure samples; 5) Train the graph neural network model using the training dataset, so that the graph neural network model learns the mapping relationship between graph structure data and the target three-dimensional position; during training, the loss function is constructed using mean absolute error loss, mean squared error loss, Huber loss or a combination thereof, and the model parameters are updated using stochastic gradient descent optimizer, Adam optimizer or AdamW optimizer; 6) Obtain the graph neural network model parameters for performing the active electric field localization method according to any one of claims 1 to 5.
7. An active electric field localization system based on graph neural networks, characterized in that, It includes an electrode array, an excitation source, a signal processing module, a graph data construction module, and a positioning output module; 1) The electrode array is used to acquire multiple voltage signals formed after the target is disturbed by the alternating electric field; 2) The excitation source is used to establish an alternating electric field within the monitoring area; 3) The signal processing module is used to preprocess the multi-channel voltage signals and extract local differential voltage features based on the voltage amplitudes of its spatially adjacent electrodes for each electrode; 4) The graph data construction module is used to map each electrode as a graph node according to the spatial position of each electrode, construct graph edges according to the spatial adjacency relationship between electrodes, and generate node features according to the local differential voltage characteristics and electrode spatial position information to obtain graph structure data; wherein, the spatial adjacency relationship includes at least the chain adjacency relationship between electrodes in the same layer; 5) The positioning output module is used to input the graph structure data into the pre-trained graph neural network model and output the three-dimensional coordinates of the target.
8. An electronic device, characterized in that, It includes a processor and a memory, wherein the memory stores program instructions that, when executed by the processor, implement the method according to any one of claims 1 to 6.
9. A computer-readable storage medium having program instructions stored thereon, characterized in that, When the program instructions are executed by the processor, they implement the method described in any one of claims 1 to 6.
