An underwater bionic three-dimensional electric field positioning method based on a fold-out prediction evaluation model
The underwater biomimetic three-dimensional electric field positioning method based on the outward prediction and evaluation model solves the problems of large three-dimensional positioning error and small detection range in the existing technology. By adopting regional and dual-region fault-tolerant mechanisms, it achieves high-precision three-dimensional positioning of small targets and adapts to the electric field changes in complex underwater environments.
Patent Information
- Application Number
- CN202611528220.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2026-09-30
- Publication Date
- 2026-11-03
AI Technical Summary
Existing active electric field positioning technology suffers from large positioning errors and small detection range in 3D applications. Furthermore, there is a contradiction between the positioning range and resolution of fixed devices, making it difficult to achieve efficient 3D positioning of small targets in complex underwater environments.
An underwater biomimetic three-dimensional electric field localization method based on an out-of-flight prediction and evaluation model is adopted. By dividing the localization area into regions and training coarse and fine localization algorithms, combined with an OOF evaluation model and multi-model ensemble learning, a regional localization and dual-region fault-tolerant mechanism is used to simulate the active electric field detection mechanism of electric eels, construct an underwater quasi-static electric field, and combine a modified electric field physical model to calculate the three-dimensional position.
It achieves high-precision three-dimensional positioning of small targets in complex underwater environments, adapts to electrode polarization, water conductivity drift and noise interference, reduces the number of electrodes and computational overhead, and improves the accuracy and efficiency of positioning.
Smart Images

Figure CN123028615A_ABST
Abstract
Description
Technical Field
[0001] This invention belongs to the field of underwater positioning technology, and more specifically, it relates to an underwater biomimetic three-dimensional electric field positioning method based on an external prediction and evaluation model. Background Technology
[0002] For small unmanned underwater vehicles and drifting foreign objects that are small in scale and have variable motion states, single sensing methods are prone to blind spots in near-range early warning. Underwater vision is affected by scattering in water, and turbid water significantly compresses the imaging distance; sonar, within the limited space of the shoreline, suffers from reverberation, multipath propagation, and near-field obstruction, which reduce its ability to resolve small targets. Electric eels can generate electric discharge through their electroreceptors, and then receive the disturbance of the electric field generated by the environment through electroreceptors distributed on their body surface. Essentially, this involves using the transmitting electrode to establish a known background field, and using the receiving electrode to collect the potential or current changes caused by the target, and then using a model or data mapping to invert the target's position. This process does not require the detected object to actively emit sound or light, and conductors and insulators will change the local field distribution due to differences in boundary conditions, making it suitable for near-field target detection.
[0003] Currently, active electric field localization technology for weakly electric fish such as electric eels has become a popular research trend, but there are still many shortcomings at this stage. First, the scenarios are mostly small pools and two-dimensional planes. Changes in target depth, free water surface, pool walls or seabed boundaries will cause different electric field distributions than infinite medium models, and the three-dimensional localization results still lack sufficient cross-scenario verification. Second, there is a contradiction between the localization range and resolution of the fixed devices used: reducing the electrode spacing can enhance the local spatial resolution, but it is difficult to expand the coverage area; increasing the array scale will increase the channel, synchronization and wiring costs. Third, most algorithms are verified under ideal model or relatively sufficient data conditions, and cannot achieve effective localization when faced with environmental factors such as electrode polarization, dielectric conductivity drift, target material changes and single sampling noise. Summary of the Invention
[0004] This invention addresses the technical problems existing in the prior art by providing an underwater biomimetic three-dimensional electric field localization method based on an external prediction and evaluation model.
[0005] To solve the above-mentioned technical problems, the present invention provides the following technical solution: An underwater biomimetic three-dimensional electric field localization method based on an out-of-fold prediction and evaluation model includes the following steps: The algorithm is trained based on the training data. The localization area is divided into 3×3 partitions and the algorithm is trained separately based on the OOF evaluation model to determine the coarse localization area of the object. The most suitable precise localization algorithm for each of the nine coarse localization areas is trained based on the OOF evaluation model. The system receives real-time data from sensors and converts one-dimensional data into a two-dimensional array. A coarse positioning algorithm is used to determine the top-1 region where the disturbing object is most likely. Based on the local sensor data received in the top-1 region, a precise positioning algorithm is used to determine the object's location. Determine whether dual-region localization is enabled. If enabled, determine if the object may exist in a second region (top-2) adjacent to top-1 and perform precise localization. Combine the weights of the two precise localizations to predict the object's position. Otherwise, check if the object is located within the top-1 region in the first precise localization and output the object's position.
[0006] Preferably, it includes two stages: data training and actual prediction, and includes the following steps: During the data training phase, the device positioning area is first divided into a 3×3 coarse positioning area in the horizontal direction. When positioning, the coarse positioning area of the object is determined first, and then the actual position of the object is determined. When performing coarse positioning, the corresponding perturbation data is used in the x and y directions to predict the probability of the object in the three possible regions. Then, the probability of the nine regions is obtained by cross-pollination, and the region with the highest probability is selected as the top-1 coarse positioning region. The OOF evaluation model is used to comprehensively weight the localization results of different candidate algorithms. The dataset is divided into 9:1 multiple times with different random seeds to perform OOF out-of-place prediction, evaluate each model, solve the non-negative fusion weights, and integrate to obtain the directional probability output. The dataset is divided into 9 coarse regions, each region is modeled independently, and regression models are trained separately for the x, y, and z coordinate axes. Only receiving electrodes around the coarse localization regions are selected to construct local features. Multiple regressors are candidate for each coordinate axis, a boundary tolerance mechanism is set, and a dual-region mechanism is used to handle coarse localization misjudgments at the boundaries. In the actual prediction stage, data verification is first performed to check the integrity of the excitation voltage data of the voltage channel xy and check for any outliers. The rationality of the signal is verified, and it is determined whether the target is within the detection range. Then, the joint probability of the nine regions is output for coarse localization to obtain the top-1. Local features are generated, and single-region fine localization is performed. It is determined whether the dual-region mechanism is triggered. If it is triggered, the top-1 and top-2 results are fused. Finally, boundary fault tolerance verification is performed to complete the three-dimensional localization.
[0007] Preferably, the underwater biomimetic three-dimensional electric field includes several square electrode arrays, each square electrode array including a transmitting electrode group and a receiving electrode group; the transmitting electrode group includes multiple annular columnar structures, each transmitting electrode including several annular graphite electrodes equivalent to graphite columns; the receiving electrode group includes circular receiving electrodes, the receiving electrodes are arranged in a 4×4 matrix except for the four corners, and include a two-layer structure. In operation, a 50V sinusoidal voltage is applied to two transmitting electrodes, and a sinusoidal voltage with equal amplitude and a phase difference of 180 degrees is applied to the other two transmitting electrodes to form a horizontal electric field along the x-axis, which serves as the x-direction excitation, and a set of disturbance data is collected. Then, the excitation combination is changed to form a horizontal electric field along the y-axis, which serves as the y-direction excitation, and another set of disturbance data is obtained.
[0008] Preferably, the candidate algorithms include Extra Trees, Random Forest, HistGradientBoosting, and GradientBoosting. The localization results of the four candidate algorithms are evaluated using an Out-of-Flight (OOF) prediction model, which is a weighted average of the results. The training data was divided into a training set and a test set in a 9:1 ratio using a random seed. The training set was used to train the four algorithms, and the test set was used to evaluate the training effect. This process was repeated 4 times to obtain a total of 5 training data sets. Based on the OOF results, the classification accuracy, log loss, and Brier score of the four candidate models were obtained; among them, the classification accuracy was used to evaluate whether the region with the highest probability is the true location of the object. The formula for logarithmic loss is:
[0009] In the formula, p i To predict the probability of the actual location of an object for the model; The Brier score evaluates the difference between the overall three-class probability result output by the model and the true answer. Based on three types of information, non-negative fusion weights of four candidate localization algorithms are calculated with the goal of minimizing log loss. The output results of the four algorithms are combined to determine the region where the object is located in one direction. Three probabilities are obtained in both the x and y directions. After cross-multiplication, a joint probability of nine regions can be formed. The region with the highest joint probability is the coarse localization region top-1.
[0010] Preferably, after completing the coarse localization training, the training set data is divided into 9 parts according to the coarse localization region, and a set of three-dimensional precise localization models is trained separately for each region. The three-dimensional precise localization models are trained separately in the x, y, and z directions of each region. During precise positioning, based on the coarse positioning area, nearby receiving electrodes are used. For each receiving electrode, excitation data in the x and y directions are read simultaneously to generate absolute voltage values, normalized voltage, xy excitation voltage difference, upper and lower electrode differences, and local features of the region boundary and region center information. The local model gives its relative coordinates with respect to the top-1 center of the coarse positioning area, and finally converts it into absolute coordinates. The x, y, and z directions of each region are evaluated using Out-of-Flight (OOF) to compare six models: Ridge, KNN, RBF-SVR, Extra Trees Regression, Random Forest Regression, and Gradient Boosting Regression. The candidate models were used to calculate the mean absolute error (MAE) in nine regions using K-fold OOF predictions. In the balanced configuration, the two candidate models with the smallest mean absolute error in each direction are selected, and the local fusion weights are obtained by normalizing the error by the inverse:
[0011] In the formula, oh k The final fusion weights for model k are 1, and the sum of all model weights is 1. E k Let the mean absolute error (MAE) of model k within the region be the OOF (Out-of-Flight) error. e For parameters with values greater than 0, this prevents division by zero when the error is 0; After integration in the three directions, the local offset is added to the region center to obtain the original three-dimensional fine positioning coordinates of the region.
[0012] Preferably, after obtaining the precise positioning result, it is necessary to verify whether it is within the range of the coarse positioning area top-1. If it is, the precise positioning result is output; otherwise, "the center coordinates of the coarse positioning area top-1 are accurate with the z-axis" is output. When the disturbing object is located at the boundary between two regions, the boundary tolerance is automatically calculated using the OOF error of the training set. The final output results include: if the coordinates are within the region, they are output directly; if the coordinates are only slightly outside the region, within the allowable range of the boundary tolerance, the results are adjusted to the coarse positioning boundary; if the coordinates are significantly outside the boundary tolerance, it is considered that there is a conflict between coarse and fine positioning, the fine positioning result is not accepted, and "the center coordinates of the top-1 region of the coarse positioning region are accurate with the z-axis" is used as the output result.
[0013] Preferably, the dual-region mechanism includes: After coarsely determining the top-1 region where the object is most likely to exist, the second most likely region (top-2) adjacent to region top-1 is also determined. Precise localization is then performed within region top-2. The final localization result is a weighted average of the precise localization results for regions top-1 and top-2, based on the coarse localization probability and the region's historical reliability. The weighting formula is as follows:
[0014]
[0015] In the formula, pi For the first i Joint probability of coarse localization for each region; e i For the first i The OOF 3D history error of the local fine localization model of each region, in cm; s i This represents the score before the region's integration. oh i The final fusion weights after normalization; α It is a probability weighting index; β For regional reliability index; Select specific values for probability weight index, reliability index, upper limit of primary and secondary probability difference, lower limit of second candidate probability, and maximum allowable difference between the predicted coordinates of the two regions to form several candidate strategies. Use the candidate strategies to train each dual-region training sample to determine the final strategy.
[0016] Preferably, the conditions for activating the dual-zone mechanism include: First, the coarse localization output is the joint probability of 9 regions, of which the region with the highest probability is the main region, which is the top-1 region. The conditions for determining the second candidate region, top-2, are: sharing a boundary with the top-1 region; only adjacent regions on the top, bottom, left, and right are allowed, diagonal regions are not allowed, and cross-regions are not allowed; and a local fine localization model that has been successfully trained is required. Secondly, all conditions for evaluating the OOF model must be met, including: ensuring that there are no fewer than 20 valid boundary samples after deduplication during training; strictly reducing the average 3D error; strictly reducing the root mean square error (RMSE); not increasing the P95 error; passing the Bootstrap confidence test; and showing improvement with at least 4 random seeds.
[0017] Preferably, in the actual prediction stage, the data format is first checked and the existence of the target is determined. The collected data includes channel voltages under X-direction excitation and channel voltages under Y-direction excitation. Model checks include: whether the channel order is correct; whether there are null values; whether there are infinite values; and whether the data belongs to low confidence. At the same time, the one-dimensional data is converted into a two-dimensional matrix, and the data is verified to be normal through zero-point characteristics. After confirming that the collected data meets the requirements, it is determined whether the target object exists in the region. After confirming that the object exists within the positioning range, the joint probability of nine regions is obtained using the trained coarse positioning algorithm, with the region with the highest probability being designated as the top-1 region. Based on the top-1 region, local features are generated using signals collected by nearby receiving electrodes, and the xyz axis positions are predicted. Determine whether the current sample uses a dual-region mechanism; if the top-1 single-region localization is ultimately used, then the top-1 region boundary is used to perform boundary tolerance; if the dual-region mechanism is used for localization, then the joint rectangular boundary formed by two adjacent regions is used; after determining the boundary tolerance, verify the consistency of the prediction results. If the positioning result is within the coarse positioning area, it is output directly; if the positioning result slightly exceeds the boundary, it is automatically adjusted to the boundary; if the positioning result seriously exceeds the boundary, the signal is re-acquired and the above steps are repeated. If it still seriously exceeds the boundary after more than n times, the "coarse positioning center, z-axis positioning result" is output.
[0018] Preferably, the positioning model is trained before use. During training, information is repeatedly collected at the same location, and based on the collected airfield data, airfield calibration coefficients can be obtained, thereby determining the equivalent electrode potential intensity. S U ; The background potential with finite spacing when there is no target is:
[0019] In the formula, r 1 represents the distance from the target location to the positive electrode. r 2 represents the distance from the target location to the negative electrode; Based on the finite-pitch electrode model, the potential change before and after the presence of the disturbing object is analyzed, and the corrected potential perturbation formula is obtained:
[0020] In the formula, s i and s w These represent the electrical conductivity of the disturbing organism and seawater, respectively. a To the radius of the disturbed object, r The distance from the disturbing object to the receiving electrode. E c To correct the electric field strength at the disturbed object, i It is the angle between the direction of the electric field intensity and the direction from the disturbing object to the receiving electrode.
[0021] Compared with the prior art, the present invention has the following beneficial effects: This invention proposes an underwater biomimetic 3D electric field localization method based on an out-of-field prediction and evaluation model. This method solves the technical problems of large positioning errors and small detection range in existing active electric field localization technologies for 3D applications, and can be widely applied in the field of underwater localization technology. Based on theoretical formulas, this invention derives that target objects are often located at the positive and negative boundaries of disturbed electric potentials. Then, it designs the device structure and, based on the device structure, partitions the algorithm to map the algorithm results onto the physical structure. Furthermore, this invention mimics the active electric field detection mechanism of electric eels, using transmitting electrodes to construct an underwater quasi-static electric field. The target object disturbs the original electric field, and receiving electrodes collect the potential disturbance signal. Combined with a modified electric field physical model and out-of-field prediction (OOF) multi-model ensemble learning, it employs a two-level (coarse and fine) localization system with a dual-region fault-tolerant mechanism to achieve 3D position calculation for small underwater targets. It is adaptable to real-world interferences such as electrode polarization, water conductivity drift, and noise, reducing the number of electrodes and computational overhead. Attached Figure Description
[0022] To more clearly illustrate the technical solutions in the embodiments of this application, the drawings used in the description of the embodiments or the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0023] Figure 1 This is a schematic diagram of the overall process of the positioning method proposed in one embodiment of the present invention; Figure 2 This is a flowchart illustrating the coarse-fine collaborative algorithm for the evaluation model proposed in one embodiment of the present invention. Figure 3 This is a schematic diagram of the structure of a square electrode array proposed in one embodiment of the present invention; Figure 4 This is a top view of the square electrode array layout according to one embodiment of the present invention; Figure 5 This is a schematic diagram of a biomimetic three-dimensional electric field positioning device constructed from a square electrode array, according to one embodiment of the present invention. Figure 6 This is a comparison of the potential perturbation between the modified formula proposed in one embodiment of the present invention and the original formula and simulation results; Figure 7 This is a simulation diagram illustrating the positioning error between the positioning result and the actual position given by the algorithm model proposed in one embodiment of the present invention. Detailed Implementation
[0024] To make the technical problems, technical solutions, and beneficial effects to be solved by this application clearer, the following detailed description is provided in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative and are not intended to limit the scope of this application.
[0025] Example 1 Please see Figure 1 This invention provides an underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model, comprising the following steps: The algorithm is trained based on the training data. The localization area is divided into 3×3 partitions and the algorithm is trained separately based on the OOF evaluation model to determine the coarse localization area of the object. The most suitable precise localization algorithm for each of the nine coarse localization areas is trained based on the OOF evaluation model. The system receives real-time data from sensors and converts one-dimensional data into a two-dimensional array. A coarse positioning algorithm is used to determine the top-1 region where the disturbing object is most likely. Based on the local sensor data received in the top-1 region, a precise positioning algorithm is used to determine the object's location. Determine whether dual-region localization is enabled. If enabled, determine if the object may exist in a second region (top-2) adjacent to top-1 and perform precise localization. Combine the weights of the two precise localizations to predict the object's position. Otherwise, check if the object is located within the top-1 region in the first precise localization and output the object's position.
[0026] This invention proposes an underwater biomimetic 3D electric field localization method based on an out-of-flight prediction and evaluation model. This method solves the technical problems of large localization errors and small detection range in existing active electric field localization technologies for 3D applications, and can be widely applied in the field of underwater localization technology. This invention mimics the active electric field detection mechanism of the electric eel, using a transmitting electrode to construct an underwater quasi-static electric field. The target object will disturb the original electric field, and the receiving electrode collects the potential disturbance signal. Combined with a modified electric field physical model and out-of-flight prediction (OOF) multi-model integrated learning, it employs a two-level coarse-fine localization system with a dual-region fault-tolerant mechanism to achieve 3D position calculation for small underwater targets. It can adapt to real-world interferences such as electrode polarization, water conductivity drift, and noise, reducing the number of electrodes and computational overhead.
[0027] Example 2 Based on Example 1, this example proposes an underwater biomimetic three-dimensional electric field positioning method based on an external prediction and evaluation model to solve the technical problems of small positioning range, large computing power requirement and serious positioning error in the three-dimensional application of existing active electric field positioning technology.
[0028] The electric localization of electric eels is often considered as an electric dipole model, and the relevant formula is as follows:
[0029] In the formula, f The magnitude of the electric potential at the target location. e The relative permittivity of the surrounding water body is represented by , which is the dipole moment of the electric dipole. r is the distance from the center of the electric dipole to the target, and is the vector from the center of the electric dipole to the target.
[0030] Based on the electric dipole model, the potential change before and after the presence of the disturbed object is analyzed, and the theoretical formula for potential perturbation is obtained:
[0031] In the formula, f The potential difference at the receiving electrode depends on whether the object is present or not. s i and s w These represent the electrical conductivity of the disturbing organism and seawater, respectively. E 0 represents the magnitude of the electric field strength at the location of the disturbed object. a To the radius of the disturbed object, r The distance from the disturbing object to the receiving electrode. i This is the angle between the direction of the electric field intensity and the direction from the disturbing object to the receiving electrode.
[0032] From the above formula, we can see that the disturbing object and the receiving electrode have the following relationship: The electrical conductivity of both the disturbing object and seawater is constant. When the conductivity of the disturbing object is greater than that of seawater, the part of the formula related to conductivity is positive, and vice versa. The radius of the disturbing object, the distance from the disturbing object to the receiving electrode, and the magnitude of the electric field strength at the disturbing object only affect the magnitude of the disturbance potential, and are independent of the disturbance potential itself.
[0033] Assuming the electric field is horizontal and the conductivity of the disturbing object is greater than that of seawater, when the disturbing object is in front of and above the receiving electrode, cos i The value is negative, and the disturbance potential is negative at this time; when the disturbing object is above and behind the receiving electrode, cos i When the value is positive, the disturbance potential is positive; when the disturbing object is directly above the receiving electrode, cos i When the value is 0, the disturbance potential is also 0. This discovery is called the zero-crossing positioning method. Based on this, by using a row of receiving electrodes, the position of an object in one dimension can be determined. The higher the electrode density, the higher the positioning accuracy.
[0034] Meanwhile, the radius of the disturbing object and the part of the formula related to conductivity generally remain unchanged. Therefore, the magnitude of the absolute value of the disturbance potential depends on the magnitude of the electric field strength at the disturbing object, the distance from the disturbing object to the receiving electrode, and the cosine of the angle between the direction of the electric field strength and the direction from the disturbing object to the receiving electrode. i These three factors work together to determine the distance. When the disturbing object moves away from the receiving electrode, the distance *r* between the disturbing object and the receiving electrode increases. i Approaching 90°, cos i The absolute value of the voltage decreases, which in turn causes the perturbation potential to decrease. Based on this, by using a row of receiving electrodes, the position of the object on a two-dimensional plane can be determined.
[0035] Furthermore, an n×n receiving electrode matrix can determine the two-dimensional position of an object by the location of the zero point of the perturbation potential, and then determine the distance between the perturbed object and the receiving electrode matrix by the magnitude of the perturbation potential of the receiving electrodes to complete the three-dimensional positioning. Only by using a large number of electrodes can this effect be achieved, and this formula is only a theoretical model and deviates from practical applications. For example, the distance between the positive and negative electrodes of an electric eel is not negligible compared to its electro-positioning range, and in reality, it cannot be considered as an electric dipole model.
[0036] This embodiment modifies the above formula and proposes a potential perturbation model under finite electrode spacing. This model treats the positive and negative poles of the electric eel as electric dipoles, considering them as two electrodes. Furthermore, since the actual device uses constant voltage excitation, and the mathematical electrodes cannot be directly subjected to finite potential boundaries, this embodiment uses an empty field calibration coefficient. C U Excitation voltage U 0 is mapped to the equivalent electrode potential intensity. S U Based on this, the background potential at a finite distance without a target is derived as follows:
[0037] In the formula, r 1 represents the distance from the target location to the positive electrode. r 2 represents the distance from the target location to the negative electrode.
[0038] Based on the finite-pitch electrode model, the potential change before and after the presence of the disturbing object is analyzed, and the corrected potential perturbation formula is obtained:
[0039] In the formula, s i and s w These represent the electrical conductivity of the disturbing organism and seawater, respectively. a To the radius of the disturbed object, r The distance from the disturbing object to the receiving electrode. E c To correct the electric field strength at the disturbed object, i It is the angle between the direction of the electric field intensity and the direction from the disturbing object to the receiving electrode.
[0040] Furthermore, the finite electrode spacing correction used in this embodiment does not change the response structure of the original theoretical model; instead, it replaces the ideal electric dipole field in the original model with a precise background field with finite spacing. When the electrode spacing is sufficiently small relative to the detection distance, the corrected model automatically degenerates into the original model. Therefore, the previously derived relationship between the disturbing object and the receiving electrode remains applicable.
[0041] Considering that the volume of the disturbing object may cause errors in two-dimensional horizontal positioning, this embodiment only uses this method for coarse positioning, which can not only reduce the number of electrodes used and save costs, but also reduce the computational load of the algorithm and save computing power.
[0042] Furthermore, such as Figure 3-Figure 5 As shown, the underwater biomimetic three-dimensional electric field used in the positioning device provided in this embodiment includes several square electrode arrays. The square electrode arrays include a transmitting electrode group and a receiving electrode group. The transmitting electrode group includes multiple annular columnar structures. The transmitting electrode includes several annular graphite electrodes equivalent to graphite columns. The receiving electrode group includes circular receiving electrodes. The receiving electrodes are arranged in a 4×4 matrix except for the four corners and include a two-layer structure.
[0043] Specifically, this implementation uses four ring-shaped columnar structures as transmitting electrodes and a circular structure as receiving electrodes, with an overall square shape and dimensions of 1.5×1.5×0.8m. The transmitting electrode section uses ten ring-shaped graphite electrodes equivalent to graphite columns, saving materials while achieving the same effect as graphite columns; the receiving electrode uses a 4×4 matrix except for the four corners, divided into upper and lower layers.
[0044] In operation, a 50V sinusoidal voltage is first applied to two transmitting electrodes, while another two transmitting electrodes are applied with sinusoidal voltages of equal amplitude and a 180-degree phase difference, forming a horizontal electric field along the x-axis as the x-direction excitation, and a set of disturbance data is collected. Then, the excitation combination is changed to form a horizontal electric field along the y-axis as the y-direction excitation, obtaining another set of disturbance data. This method simulates the movement of an electric eel to obtain more information. An approximate horizontal electric field is achieved within the square structure, i.e., the positioning range, to meet the prerequisites of the zero-crossing positioning method.
[0045] like Figure 1 , Figure 2 As shown, the underwater biomimetic three-dimensional electric field localization method based on the out-of-fold prediction and evaluation model proposed in this embodiment mainly includes two stages: data training and actual prediction. The localization method includes the following steps: During the data training phase, the device positioning area is first divided into a 3×3 coarse positioning area in the horizontal direction. During positioning, the coarse positioning area of the object is determined first, and then the actual position of the object is determined.
[0046] When performing coarse localization, the object is not located directly in the nine regions. Instead, the corresponding perturbation data is used in the x and y directions to predict the probability of the object in three possible regions. Then, the probability of the nine regions is obtained by cross-pollination. The region with the highest probability is the top-1 coarse localization region, and the region with the highest probability is the region where the object is located.
[0047] In this embodiment, four candidate localization algorithms—Extra Trees, RandomForest, HistGradientBoosting, and GradientBoosting—are used in both horizontal directions. The localization results of these four candidate algorithms are evaluated using an Out-of-Fold (OOF) model that comprehensively weights the results. Specific methods include: The training data is divided into training and test sets in a 9:1 ratio using random seeds. The training set is used to train the four algorithms, and the test set is used to evaluate the training effect, serving as a single training dataset. This process is repeated four times, resulting in five training datasets. Five random seeds are used across the five training iterations, but these seeds are not completely random; rather, they distribute the training data relatively evenly to ensure sufficient training data for each position. Simultaneously, these five training iterations are conducted simultaneously without interference, maintaining independence. This training method ensures that each test set dataset is unseen by the trained model, making the training results more objective and fair, and preventing the use of the same data for training and testing from leading to overly optimistic final test results.
[0048] Based on the OOF results, the classification accuracy, log loss, and Brier score of the four candidate models were obtained. Among them, the classification accuracy is used to evaluate whether the region with the highest probability is the actual location of the object. The higher the value, the better, but it cannot answer the specific probability value of the region with the highest probability.
[0049] Log loss is used to check whether the model assigns a sufficiently high probability to the true location of an object. If it is wrong, it indicates that the model is overconfident and will penalize this overconfidence. The formula is as follows; a smaller value is better.
[0050] The formula for logarithmic loss is:
[0051] In the formula, p i This determines the probability that the object is actually located in the model.
[0052] The Brier score evaluates the difference between the model's output of the overall three-class classification probability result and the true answer; the smaller the value, the better. For example, if the object is located in the middle region, the true label can be written as (0,1,0). If the model outputs (0.1,0.8,0.1), the difference between it and the true label is the squared difference of two vectors, which is 0.06. The Brier score is calculated by averaging over all OOF samples.
[0053] Based on these three types of information, the non-negative fusion weights of the four candidate localization algorithms are calculated with the goal of minimizing logarithmic loss. The output results of the four algorithms are combined to determine the region where the object is located in one direction.
[0054] Then, three probabilities can be obtained in both the x and y directions. After cross-multiplication, a joint probability of nine regions can be formed, among which the region with the largest joint probability is the coarse localization region top-1.
[0055] In this embodiment, after completing the coarse localization training, the training set data is divided into nine parts according to the coarse localization region, and a separate three-dimensional precise localization model is trained for each region. Because the localization range is large, the electric field intensity and electric field line distribution are different in the nine coarse localization regions, and their most suitable algorithms are not necessarily the same. By training each of the nine regions separately, the most suitable localization model for each region can be obtained to achieve better localization results. Moreover, the three-dimensional precise localization model is not a single model, but a separate model is trained in each region in the x, y, and z directions, because the information features in each direction are also different.
[0056] During precise localization, not all receiving electrodes are used. Instead, only nearby receiving electrodes are used based on the coarse localization area, which improves the algorithm's efficiency. For each receiving electrode, excitation data in both the x and y directions are read simultaneously, generating local features such as absolute voltage value, normalized voltage, xy excitation voltage difference, difference between upper and lower electrodes, and information on region boundaries and center. These features allow the precise localization model to focus on learning the electric field changes near the target.
[0057] The local model does not directly predict the absolute coordinates of the disturbing object. Instead, it provides its relative coordinates with respect to the top-1 center of the coarse localization region, and then converts them into absolute coordinates. This approach reduces the range of coordinates that the local model needs to learn, making it easier for the algorithm to run in each region.
[0058] In this embodiment, the x, y, and z directions of each region are evaluated using Out-of-Flight (OOF) model comparison with six models: Ridge, KNN, RBF-SVR, Extra Trees Regression, Random Forest Regression, and Gradient Boosting Regression. The candidate models are used to calculate the Mean Absolute Error (MAE) in nine regions using K-fold OOF prediction. Under the balanced configuration, the two candidate models with the smallest MAE in each direction are selected, and the local fusion weights are obtained by normalizing the error by the inverse.
[0059] In the formula, oh k The final fusion weights for model k are 1, and the sum of all model weights is 1. E k Let the mean absolute error (MAE) of model k within the region be the OOF (Out-of-Flight) error. e For very small parameters with values greater than 0, this prevents division by zero when the error is 0.
[0060] This formula allows models with smaller errors to receive higher weights.
[0061] After integration in the three directions, the local offset is added to the region center to obtain the original three-dimensional fine positioning coordinates of the region.
[0062] Regionalized modeling allows for the selection of different models for different locations. For example, when the local mapping of a region is close to linear, Ridge may achieve a smaller OOF error; when the sample data shows obvious patterns, KNN or RBF-SVR may be more suitable; and when there are complex nonlinearities and channel interactions, tree models can provide stronger fitting capabilities. The final model selection is entirely determined by the OOF error of the dataset for each region and each coordinate axis, without requiring all regions to use the same regressor.
[0063] After obtaining the precise localization result, it is necessary to verify whether it is within the top-1 range of the coarse localization region. The limitation of the coarse localization region range is used to prevent errors in the precise localization result. If it is, the precise localization result is output; otherwise, "the center coordinates of the top-1 coarse localization region are precise with the z-axis" is output. However, when the disturbing object is at the boundary between two regions, the local precise localization result based on the coarse localization region may sometimes exceed the coarse localization region. However, if "the center coordinates of the top-1 coarse localization region are precise with the z-axis" is used as the output result, it will lead to excessive error. In this case, the boundary tolerance is automatically calculated using the OOF error of the training set.
[0064] The calculation is based on taking the error at 95% of the maximum error in the x and y directions as the boundary tolerance, ensuring it is within 2-10cm. The final output includes three cases: if the coordinates are within the area, output directly; if the coordinates only slightly exceed the boundary tolerance, adjust the result to the coarse positioning boundary; if the coordinates significantly exceed the boundary tolerance, it is considered that there is a conflict between coarse and fine positioning, the fine positioning result is not accepted, and the "coarse positioning area top-1 center coordinates and z-axis accurate" is used as the output result.
[0065] Furthermore, considering the interference of the actual use environment, the influence of the size of the disturbing object itself, and the difference between the formula and the actual application, the coarse positioning result may be misjudged. Therefore, this embodiment adopts a dual-region mechanism to deal with this.
[0066] Analysis of coarse positioning misjudgments revealed two categories: one where the data itself is abnormal, requiring re-collection; and the other where the data is normal, but the disturbing object is near the region boundary, leading to coarse positioning placing the object in region A. Precise positioning is then performed using receiving electrodes near region A, even though the disturbing object is actually located in region B, which is adjacent to region A. Therefore, using an incorrect coarse positioning region for precise positioning increases the error.
[0067] For coarse-level location errors occurring under normal data conditions, a dual-region mechanism is used for correction. The dual-region mechanism includes: After coarsely determining the top-1 region where the object is most likely to exist, the second most likely region (top-2) adjacent to region top-1 is also determined. Precise localization is then performed within region top-2. The final localization result is a weighted average of the precise localization results for regions top-1 and top-2, based on the coarse localization probability and the region's historical reliability. The weighting formula is as follows:
[0068]
[0069] In the formula, p i For the first i Joint probability of coarse localization for each region; e i For the first i The OOF 3D history error of the local fine localization model of each region, in cm; s i This represents the score before the region's integration. oh i The final fusion weights after normalization; α It is a probability weighting index; β This is the regional reliability index.
[0070] Select specific values for probability weight index, reliability index, upper limit of primary and secondary probability difference, lower limit of second candidate probability, and maximum allowable difference between the predicted coordinates of the two regions to form several candidate strategies. Use the candidate strategies to train each dual-region training sample to determine the final strategy.
[0071] Specifically, the probability weighting index α is set to 0.5, 1.0, and 2.0, and the reliability index β is set to 0, 0.5, and 1.0; the upper limit of the primary and secondary probability difference is set to 0.05, 0.10, 0.15, 0.20, and 0.30; the lower limit of the second candidate probability is set to 0.10, 0.15, 0.20, and 0.25; and the maximum allowable difference between the predicted coordinates of the two regions is set to 5, 10, 15, 20, and 30 cm, resulting in 900 candidate strategies. Each candidate strategy is used to train on each dual-region training sample, and the best-performing candidate strategy is selected as the final strategy. By using two adjacent regions for precise localization, the error caused by coarse localization misjudgment is reduced.
[0072] The dual-region mechanism is conditional and is not used on all suspected boundary samples. It can only be activated if certain conditions are met, thus avoiding errors caused by blindly activating the dual-region mechanism.
[0073] The conditions for activating the dual-zone mechanism include: First, the coarse localization outputs the joint probability of nine regions, with the region having the highest probability being the primary region, designated as the top-1 region. The second candidate region (top-2) is not simply selected from the nine regions with the second highest probability; it must also meet certain conditions: it must share a boundary with the top-1 region; it can only be adjacent to the region in the top, bottom, left, or right directions, not diagonally opposite or across regions; and the region must possess a successfully trained local fine localization model. For example, the central region's legal adjacent regions are only the four directions: top, bottom, left, and right. If a region has a high probability but is diagonally adjacent to the central region, it cannot be considered a dual-region candidate. Instead, the region with the highest joint probability among all legally adjacent regions must be selected as the second candidate.
[0074] Secondly, the dual-region mechanism requires all conditions of the OOF evaluation model to be met. These include: First, ensure that there are at least 20 valid boundary samples after deduplication during training. This prevents the dual-region mechanism from performing well only on a very few accidental samples and being mistakenly activated. When a target may be located at the boundary of two coarse localization regions, the coarse localization model will usually show a higher probability in the top-1 region but also a relatively high probability in adjacent regions, with the probabilities of the two regions being relatively close. This sample is called a boundary sample. However, not all samples with similar probabilities can be used to train the dual-region mechanism. The sample must also meet the following conditions: the second candidate region must be adjacent to the top-1 region vertically or horizontally, and diagonal regions are not allowed; both regions must have usable local fine localization models; the predicted coordinates of the two regions must be finite effective values; the probability difference between the primary and secondary regions cannot exceed a set upper limit; the top-2 probability of the second candidate region cannot be lower than a set lower limit; and the difference in coordinates given by the two local models cannot be too large. Only after all these conditions are met can the sample be called a valid boundary sample.
[0075] The current program uses five random seeds for OOF training. The same sample may appear repeatedly in the OOF records of multiple random seeds. To avoid errors caused by such repetition, it is necessary to deduplicate the effective boundary samples. After deduplication, the number of effective boundary samples should be at least 20. By setting a minimum protection threshold, the entire dual-region mechanism cannot be activated based on just a few accidental samples. The limited number of boundary samples after deduplication is mainly to prevent large errors caused by duplicate records and excessive evidence due to insufficient samples.
[0076] Second, the average 3D error must be strictly reduced. The average error reflects the overall impact of the two-region mechanism on all OOF samples. Samples that did not trigger the two-region mechanism still use the top-1 results. This comparison is between the impact of partially using the two-region mechanism versus not using it at all on the overall model, rather than comparing only a few favorable samples.
[0077] Third, the Root Mean Square Error (RMSE) must be strictly reduced. Because it is more sensitive to larger errors, RMSE is used to check if the algorithm has introduced a small number of very serious localization errors. Even if the average error decreases, it should not be enabled if the dual-region approach introduces a small number of particularly large errors. This is because dual-region weighting may improve many ordinary boundary samples, but it may also introduce a small number of new serious errors.
[0078] Fourth, the P95 error must not increase. P95 refers to the 95th percentile of the error. This condition is used to protect against tail errors, preventing the worst-performing samples from becoming even worse while the two-region approach reduces the average error. Therefore, P95 is allowed to remain unchanged, but it is not allowed to increase.
[0079] 5. The Bootstrap confidence test must pass. It is mainly used to determine whether the decrease in two-region error is a truly stable improvement or merely a random occurrence due to a small number of samples. The procedure is as follows: Calculate both the top-1 single-region error and the two-region error for the same sample simultaneously, and define the error difference:
[0080] The two-region mechanism is more accurate when the error difference is less than 0; it is worse when the error difference is greater than 0; and both methods perform the same when the error difference is equal to 0. This sample is then replaced, and sampling with replacement is performed 2000 times, resulting in 2000 error differences. These are then sorted from smallest to largest to obtain a 95% confidence interval. If the entire interval is less than 0, it indicates that the two-region mechanism performs better across a large number of different resampling combinations. Therefore, the model requires that the 95% confidence interval be less than 0.
[0081] VI. Improvement Required for at Least 4 Random Seeds. The program calculates the average error under 5 random seeds, requiring improvement to be achieved for at least 80% of the random seeds. Therefore, the two-region mechanism cannot be effective only under a single random partition, but needs to maintain improvement across at least 4 different partitions.
[0082] All six conditions above must be met simultaneously; if any one is not met, the entire dual-region mechanism will automatically shut down. The purpose of designing the dual-region mechanism is to reduce errors caused by coarse positioning errors. If used when coarse positioning is correct, its positioning error is often greater than the positioning error of the top-1 of a single region.
[0083] Furthermore, in the final stage of training, the model utilizes OOF records to analyze the characteristics typically found in samples with large localization errors. These characteristics include lower probabilities of coarse localization regions and significant differences in predictions between two adjacent local models. The model then automatically assigns a low-confidence threshold. When encountering similar data, it will indicate that the data is low-confidence and prompt resampling.
[0084] In this embodiment, during the actual prediction stage, the data format is first checked and the existence of the target is determined.
[0085] Specifically, the collected data includes 24 voltage channels under X-direction excitation and 24 voltage channels under Y-direction excitation, totaling 48 voltage channels. Model checks include: whether the 48 channels are in the correct order; whether there are null values; whether there are infinite values; and whether the data belongs to low confidence levels. Simultaneously, the one-dimensional data is converted into a two-dimensional matrix, and the zero-point characteristic is used to verify the data's normality; each row or column of data has at most one zero point. After confirming that the collected data meets the requirements, it is determined whether the target object exists in the region. The principle is: when a target exists in a certain region, the perturbation potential change of the receiving electrodes near that region is the largest. Based on this, the magnitude of the perturbation signal of the 24 receiving electrodes is checked. If the perturbation signals of these electrodes are all less than the lower limit of the perturbation signal, the above process is repeated n times (usually 3 times). If it is still less than the lower limit of the perturbation signal, the object is considered to be outside the positioning range. Otherwise, it is considered to be within the positioning range.
[0086] After confirming that the object exists within the positioning range, the joint probability of nine regions is obtained using the trained coarse positioning algorithm, with the region with the highest probability being designated as the top-1 region. Based on the top-1 region, local features are generated using signals collected by nearby receiving electrodes, and the xyz axis positions are predicted.
[0087] Determine whether the current sample uses the dual-region mechanism. Even if the dual-region mechanism is enabled during training, the current sample still needs to meet the following conditions: the probability difference between the top-1 and second regions is sufficiently small; the probability of the second region is not lower than the lower limit; both regions can generate valid coordinates; and the difference between the predicted coordinates of the two regions cannot be too large. If the conditions are met, calculate the weights using the formula and finally output the dual-region coordinates; otherwise, continue to use the top-1 single-region localization.
[0088] Furthermore, if top-1 single-region localization is ultimately used, then boundary tolerance is performed using the top-1 region boundary. If a dual-region mechanism is used for localization, then the joint rectangular boundary formed by two adjacent regions is used; this ensures that the dual-region fusion result is reasonably incorporated into the second region, preventing it from being incorrectly clipped back to the first region. After determining the boundary tolerance, the consistency of the prediction results is verified. The final result may fall into three categories: If the positioning result is within the coarse positioning area, it is output directly; if the positioning result slightly exceeds the boundary, it is automatically adjusted to the boundary; if the positioning result seriously exceeds the boundary, the signal is re-acquired and the above steps are repeated. If it still seriously exceeds the boundary after more than n times, the "coarse positioning center, z-axis positioning result" is output.
[0089] Example 3 Furthermore, based on the above embodiments, this embodiment provides an underwater biomimetic three-dimensional electric field positioning method based on an outward prediction and evaluation model. By reducing computational complexity through coarse-fine coordination, improving positioning accuracy through regional training of the model, and reducing positioning error through a dual-region correction mechanism, a high-precision and high-efficiency three-dimensional positioning method for a large range of underwater targets is achieved.
[0090] like Figure 1 The diagram shows the overall process of the underwater biomimetic three-dimensional electric field localization method. The localization model needs to be trained before use. When the sensor collects information, it repeatedly collects information from the same location to eliminate interference from accidental factors. Simultaneously, based on the collected empty field data, the empty field calibration coefficient can be obtained, thereby determining the equivalent electrode potential intensity. S U The sensor data given by the formula can be obtained. Combining the actual data with the theoretical data, the potential used for final training can be eliminated, thus eliminating interference from complex environments and the influence of the experimental setup itself.
[0091] like Figure 2 The diagram shows the logical flowchart of the coarse-fine collaborative algorithm based on the out-of-flight prediction and evaluation model. During model execution, the data collected by the sensors is first processed to determine if it meets the requirements. In complex marine environments, the data collected by the sensors is affected by factors such as waves. Therefore, the model gives the sensors multiple opportunities; if the data is determined to be unacceptable or the disturbing objects are absent, resampling is performed.
[0092] like Figure 3-Figure 5 As shown, this is a schematic diagram of the underwater biomimetic three-dimensional electric field positioning device based on the outward prediction and evaluation model disclosed in this embodiment. The positioning device uses four ring-shaped cylindrical structures as transmitting electrodes and a circular structure as receiving electrodes. The overall shape is square, with dimensions of 1.5×1.5×0.8m. Let the coordinates of the four cylindrical transmitting electrodes be (-75, -75), (-75, 75), (75, -75), (75, 75), and the coordinates of the receiving electrodes be (-75, -25), (-75, 25), (-25, -75), (-25, -25), (-25, 25), (-25, 75), (25, -75), (25, -25), (25, 25), (25, 75), (75, -25), (75, 25).
[0093] Furthermore, the transmitting electrode section uses ten annular graphite electrodes, equivalent to a 0.81m graphite column, which saves materials while achieving the same effect; the receiving electrode uses a 4×4 matrix except for the four corners, divided into upper and lower layers, with a total of 24 electrodes, and z-axis coordinates of -40.5m and 40.5m respectively.
[0094] In operation, a 50V sinusoidal voltage is first applied to the transmitting electrodes at (-75, -75) and (-75, 75), and a positive voltage with a phase difference of 180 degrees is applied to (75, -75) and (75, 75), forming a horizontal electric field along the x-axis, called x-direction excitation, and a set of disturbance data is collected. Then, a 50V sinusoidal voltage is applied to the transmitting electrodes at (-75, 75) and (75, 75), and a sinusoidal voltage with a phase difference of 180 degrees is applied to (-75, -75) and (75, -75), forming a horizontal electric field along the y-axis, called y-direction excitation, and another set of disturbance data is obtained.
[0095] The above is considered as a single unit structure. By horizontally assembling this array, the device can expand its horizontal positioning range. Adjacent sides share a set of receiving and transmitting electrodes. The same array assembly is used vertically, ultimately achieving a positioning range of 1.5a × 1.5b × 0.8dm, where a, b, and d are rational numbers. Each unit structure is numbered. During positioning, each unit first checks for the presence of an object within its respective positioning range. If an object is found, it uses the center of its positioning area as the local coordinate origin for positioning, and finally, the absolute coordinates are determined by combining the unit structure number.
[0096] Furthermore, Figure 6 To compare the potential perturbation of the corrected formula with that of the original formula under ideal conditions, eight representative receiving points were selected for comparison. M0 significantly overestimated the perturbation amplitude in the main channels; for example, the predicted values for channels 1 and 2 reached ±280.33 μV, while the experimental results under ideal conditions were ±150.00 μV. After using a finite-electrode spacing accurate background field, the corresponding result for M1 decreased to ±147.67 μV, very close to the experimental data. At this location, the relative errors of M0 and M1 were 90.35% and 6.00%, respectively, directly demonstrating the reliability of the potential calculated by the finite-electrode spacing correction formula.
[0097] Figure 7 The system represents the positioning error between the positioning result given by the algorithm model and the actual position. The system outputs a root mean square error (RMSE) of 3D space of 3.243 cm and an average 3D error of 2.561 cm. The actual positioning error of the system in 3D space remains within 10 cm. This result fully demonstrates that the method in this embodiment has excellent positioning accuracy.
[0098] This invention discloses an underwater biomimetic three-dimensional electric field localization method based on an out-of-flight (OOF) prediction and evaluation model. The method includes training an algorithm based on training data; dividing the localization area into 3×3 partitions and training the algorithm separately based on the OOF evaluation model to determine the coarse localization area of the object; training the most suitable precise localization algorithm for each of the nine coarse localization areas based on the OOF evaluation model; receiving real-time data from sensors and converting the one-dimensional data into a two-dimensional array; using the coarse localization algorithm to determine the most likely region (top-1) of the disturbing object; using the locally received sensor data in the top-1 region to determine the object's position using a precise localization algorithm; determining whether dual-region localization is enabled; if enabled, determining the second likely region (top-2) of the object that is adjacent to the top-1 region and performing precise localization; combining the weights of the two precise localizations to predict the object's position; otherwise, verifying whether the first precise localization is within the top-1 region and outputting the object's position.
[0099] This invention solves the technical problems of large positioning errors and small detection range in existing active electric field positioning technologies for three-dimensional applications, and can be widely applied in the field of underwater positioning technology. Based on theoretical formulas, this invention derives that target objects are often located at the positive and negative boundaries of disturbed electric potentials. Then, it designs the device structure and, based on the device structure, partitions the algorithm to map the algorithm results onto the physical structure. Furthermore, this invention mimics the active electric field detection mechanism of electric eels, using transmitting electrodes to construct an underwater quasi-static electric field. The target object disturbs the original electric field, and receiving electrodes collect the potential disturbance signal. Combined with a modified electric field physical model and ensemble learning of multiple models including out-of-field (OOF) prediction, it employs a two-level (coarse and fine) positioning system with regional fault tolerance to achieve three-dimensional position calculation for small underwater targets. It is adaptable to real-world interferences such as electrode polarization, water conductivity drift, and noise, reducing the number of electrodes and computational overhead.
[0100] In the description of this invention, it should be understood that terms such as “length”, “width”, “upper”, “lower”, “front”, “rear”, “left”, “right”, “vertical”, “horizontal”, “top”, “bottom”, “inner”, and “outer” indicate the orientation or positional relationship based on the orientation or positional relationship shown in the accompanying drawings. They are only for the convenience of describing this application and simplifying the description, and are not intended to indicate or imply that the device or element referred to must have a specific orientation, or be constructed and operated in a specific orientation. Therefore, they should not be construed as limitations on this application.
[0101] Furthermore, the terms "first" and "second" are used for descriptive purposes only and should not be construed as indicating or implying relative importance or implicitly specifying the number of technical features indicated. Thus, a feature defined as "first" or "second" may explicitly or implicitly include one or more of that feature. In the description of this application, "multiple" means two or more, unless otherwise explicitly specified.
[0102] The above description is merely a preferred embodiment of this application and is not intended to limit this application. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this application should be included within the protection scope of this application.
Claims
1. An underwater biomimetic three-dimensional electric field localization method based on an out-of-fold prediction and evaluation model, characterized in that, Includes the following steps: The algorithm is trained based on the training data. The localization area is divided into 3×3 partitions and the algorithm is trained separately based on the OOF evaluation model to determine the coarse localization area of the object. The most suitable precise localization algorithm for each of the nine coarse localization areas is trained based on the OOF evaluation model. The system receives real-time data from sensors and converts one-dimensional data into a two-dimensional array. A coarse positioning algorithm is used to determine the top-1 region where the disturbing object is most likely. Based on the local sensor data received in the top-1 region, a precise positioning algorithm is used to determine the object's location. Determine whether dual-region localization is enabled. If enabled, determine if the object may exist in a second region (top-2) adjacent to top-1 and perform precise localization. Combine the weights of the two precise localizations to predict the object's position. Otherwise, check if the object is located within the top-1 region in the first precise localization and output the object's position.
2. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 1, characterized in that, It includes two phases: data training and actual prediction, and includes the following steps: During the data training phase, the device positioning area is first divided into a 3×3 coarse positioning area in the horizontal direction. When positioning, the coarse positioning area of the object is determined first, and then the actual position of the object is determined. When performing coarse positioning, the corresponding perturbation data is used in the x and y directions to predict the probability of the object in the three possible regions. Then, the probability of the nine regions is obtained by cross-pollination, and the region with the highest probability is selected as the top-1 coarse positioning region. The OOF evaluation model is used to comprehensively weight the localization results of different candidate algorithms. The dataset is divided into 9:1 multiple times with different random seeds to perform OOF out-of-place prediction, evaluate each model, solve the non-negative fusion weights, and integrate to obtain the directional probability output. The dataset is divided into 9 coarse regions, each region is modeled independently, and regression models are trained separately for the x, y, and z coordinate axes. Only receiving electrodes around the coarse localization regions are selected to construct local features. Multiple regressors are candidate for each coordinate axis, a boundary tolerance mechanism is set, and a dual-region mechanism is used to handle coarse localization misjudgments at the boundaries. In the actual prediction stage, data verification is first performed to check the integrity of the excitation voltage data of the voltage channel xy and check for any outliers. The rationality of the signal is verified, and it is determined whether the target is within the detection range. Then, the joint probability of the nine regions is output for coarse localization to obtain the top-1. Local features are generated, and single-region fine localization is performed. It is determined whether the dual-region mechanism is triggered. If it is triggered, the top-1 and top-2 results are fused. Finally, boundary fault tolerance verification is performed to complete the three-dimensional localization.
3. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2, characterized in that, The underwater biomimetic three-dimensional electric field includes several square electrode arrays, which include a transmitting electrode group and a receiving electrode group; the transmitting electrode group includes multiple annular columnar structures, and the transmitting electrode includes several annular graphite electrodes equivalent to graphite columns; the receiving electrode group includes circular receiving electrodes, which are arranged in a 4×4 matrix except for the four corners, and include a two-layer structure. In operation, a 50V sinusoidal voltage is applied to two transmitting electrodes, and a sinusoidal voltage with equal amplitude and a phase difference of 180 degrees is applied to the other two transmitting electrodes to form a horizontal electric field along the x-axis, which serves as the x-direction excitation, and a set of disturbance data is collected. Then, the excitation combination is changed to form a horizontal electric field along the y-axis, which serves as the y-direction excitation, and another set of disturbance data is obtained.
4. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2, characterized in that, Candidate algorithms include Extra Trees, Random Forest, HistGradientBoosting, and GradientBoosting. The localization results of the four candidate algorithms are evaluated using an Out-of-Flight (OOF) prediction model, which is a weighted average of the results. The training data was divided into a training set and a test set in a 9:1 ratio using a random seed. The training set was used to train the four algorithms, and the test set was used to evaluate the training effect. This process was repeated 4 times to obtain a total of 5 training data sets. Based on the OOF results, the classification accuracy, log loss, and Brier score of the four candidate models were obtained; among them, the classification accuracy was used to evaluate whether the region with the highest probability is the true location of the object. The formula for logarithmic loss is: In the formula, p i To predict the probability of the actual location of an object for the model; The Brier score evaluates the difference between the overall three-class probability result output by the model and the true answer. Based on three types of information, non-negative fusion weights of four candidate localization algorithms are calculated with the goal of minimizing log loss. The output results of the four algorithms are combined to determine the region where the object is located in one direction. Three probabilities are obtained in both the x and y directions. After cross-multiplication, a joint probability of nine regions can be formed. The region with the highest joint probability is the coarse localization region top-1.
5. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2, characterized in that, After completing the coarse localization training, the training set data is divided into 9 parts according to the coarse localization region. A set of three-dimensional precise localization models is trained separately for each region in the x, y, and z directions. During precise positioning, based on the coarse positioning area, nearby receiving electrodes are used. For each receiving electrode, excitation data in the x and y directions are read simultaneously to generate absolute voltage values, normalized voltage, xy excitation voltage difference, upper and lower electrode differences, and local features of the region boundary and region center information. The local model gives its relative coordinates with respect to the top-1 center of the coarse positioning area, and finally converts it into absolute coordinates. The x, y, and z directions of each region are evaluated using Out-of-Flight (OOF) to compare six models: Ridge, KNN, RBF-SVR, ExtraTrees Regression, Random Forest Regression, and Gradient Boosting Regression. The candidate models were used to calculate the mean absolute error (MAE) in nine regions using K-fold OOF predictions. In the balanced configuration, the two candidate models with the smallest mean absolute error in each direction are selected, and the local fusion weights are obtained by normalizing the error by the inverse: In the formula, ω k The final fusion weights for model k are 1, and the sum of all model weights is 1. E k Let the mean absolute error (MAE) of model k within the region be the OOF (Out-of-Flight) error. ε For parameters with values greater than 0, this prevents division by zero when the error is 0; After integration in each of the three directions, the local offset is added to the region center to obtain the original three-dimensional fine positioning coordinates of the region.
6. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2 or 5, characterized in that, After obtaining the precise positioning result, it is necessary to verify whether it is within the range of the coarse positioning area top-1. If it is, output the precise positioning result; otherwise, output "the center coordinates of the coarse positioning area top-1 are precise with the z-axis". When the disturbing object is located at the boundary between two regions, the boundary tolerance is automatically calculated using the OOF error of the training set. The final output results include: if the coordinates are within the region, they are output directly; if the coordinates are only slightly outside the region, within the allowable range of the boundary tolerance, the results are adjusted to the coarse positioning boundary; if the coordinates are significantly outside the boundary tolerance, it is considered that there is a conflict between coarse and fine positioning, the fine positioning results are not accepted, and "the center coordinates of the top-1 region of the coarse positioning area are accurate with the z-axis" is used as the output result.
7. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2, characterized in that, The dual-region mechanism includes: After coarsely determining the top-1 region where the object is most likely to exist, the second most likely region (top-2) adjacent to region top-1 is also determined. Precise localization is then performed within region top-2. The final localization result is a weighted average of the precise localization results for regions top-1 and top-2, based on the coarse localization probability and the region's historical reliability. The weighting formula is as follows: In the formula, p i For the first i Joint probability of coarse localization for each region; e i For the first i The OOF 3D history error of the local fine localization model of each region, in cm; s i This represents the score before the region's integration. ω i The final fusion weights after normalization; α It is a probability weighting index; β For regional reliability index; Select specific values for probability weight index, reliability index, upper limit of primary and secondary probability difference, lower limit of second candidate probability, and maximum allowable difference between the predicted coordinates of the two regions to form several candidate strategies. Use the candidate strategies to train each dual-region training sample to determine the final strategy.
8. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 7, characterized in that, The conditions for activating the dual-region mechanism include: First, the coarse localization output is the joint probability of 9 regions, of which the region with the highest probability is the main region, which is the top-1 region. The conditions for determining the second candidate region, top-2, are: sharing a boundary with the top-1 region; only adjacent regions on the top, bottom, left, and right are allowed, diagonal regions are not allowed, and cross-regions are not allowed; and a local fine localization model that has been successfully trained is required. Secondly, all conditions for evaluating the OOF model must be met, including: ensuring that there are no fewer than 20 valid boundary samples after deduplication during training; strictly reducing the average 3D error; strictly reducing the root mean square error (RMSE); not increasing the P95 error; passing the Bootstrap confidence test; and showing improvement with at least 4 random seeds.
9. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 2, characterized in that, In the actual prediction phase, the data format is first checked and the existence of the target is determined. The collected data includes channel voltages under X-direction excitation and channel voltages under Y-direction excitation. Model checks include: whether the channel order is correct; whether there are null values; whether there are infinite values; and whether the data belongs to low confidence. At the same time, the one-dimensional data is converted into a two-dimensional matrix, and the data is verified to be normal through zero-point characteristics. After confirming that the collected data meets the requirements, it is determined whether the target object exists in the region. After confirming that the object exists within the positioning range, the joint probability of nine regions is obtained using the trained coarse positioning algorithm, with the region with the highest probability being designated as the top-1 region. Based on the top-1 region, local features are generated using signals collected by nearby receiving electrodes, and the xyz axis positions are predicted. Determine whether the current sample uses a dual-region mechanism; if the top-1 single-region localization is ultimately used, then the top-1 region boundary is used to perform boundary tolerance; if the dual-region mechanism is used for localization, then the joint rectangular boundary formed by two adjacent regions is used; after determining the boundary tolerance, verify the consistency of the prediction results. If the positioning result is within the coarse positioning area, it is output directly; if the positioning result slightly exceeds the boundary, it is automatically adjusted to the boundary; if the positioning result seriously exceeds the boundary, the signal is re-acquired and the above steps are repeated. If it still seriously exceeds the boundary after more than n times, the "coarse positioning center, z-axis positioning result" is output.
10. The underwater biomimetic three-dimensional electric field localization method based on an outward prediction and evaluation model according to claim 1 or 2, characterized in that, Before use, the localization model is trained. During training, information is repeatedly collected at the same location, and based on the collected airfield data, airfield calibration coefficients can be obtained, thereby determining the equivalent electrode potential intensity. S U ; The background potential with finite spacing when there is no target is: In the formula, r 1 represents the distance from the target location to the positive electrode. r 2 represents the distance from the target location to the negative electrode; Based on the finite-pitch electrode model, the potential change before and after the presence of the disturbing object is analyzed, and the corrected potential perturbation formula is obtained: In the formula, σ i and σ w These represent the electrical conductivity of the disturbing organism and seawater, respectively. a To the radius of the disturbed object, r The distance from the disturbing object to the receiving electrode. E c To correct the electric field strength at the disturbed object, θ It is the angle between the direction of the electric field intensity and the direction from the disturbing object to the receiving electrode.
