Unmanned ship turning control parameter learning method and device
By combining BP neural networks and improved genetic algorithms, the problems of time-consuming, labor-intensive, and safety hazards in unmanned surface vessel (USV) turning control methods have been solved, achieving efficient and accurate optimization of turning control parameters to adapt to complex marine environments.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- YICHANG TESTING TECHNIQUE RESEARCH INSTITUTE
- Filing Date
- 2025-12-31
- Publication Date
- 2026-05-15
AI Technical Summary
Traditional unmanned surface vessel (USV) turning control methods rely on manual adjustments, which are time-consuming and labor-intensive, making them difficult to adapt to complex marine environments. Furthermore, they struggle to balance turning trajectory tracking accuracy, response speed, and attitude stability, posing safety risks.
A BP neural network model is constructed and combined with an improved genetic algorithm. Through the comprehensive performance index of turning time, trajectory error and roll angle safety penalty term, the turning control parameters of the unmanned surface vessel are automatically learned and optimized. The Adam optimizer and early stop mechanism are used to accelerate training, and the Dropout layer is configured to reduce the risk of overfitting.
It achieves efficient, accurate, and safe automatic learning of unmanned surface vessel turning control parameters, takes into account the adaptability to different turning scenarios, improves the model's generalization ability and training efficiency, and avoids the performance imbalance caused by the optimization of a single performance index in traditional methods.
Smart Images

Figure CN122043922A_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of marine unmanned system control, and in particular to a method and apparatus for learning turning control parameters of an unmanned surface vessel. Background Technology
[0002] Unmanned surface vessels (USVs), as important unmanned platforms at sea, are playing an increasingly vital role in marine resource exploration, environmental monitoring, and national defense. Their autonomous navigation and precise control capabilities are crucial for achieving predetermined missions. During USV navigation, turning maneuvers are fundamental actions for changing course, avoiding obstacles, and executing specific routes; their control effectiveness directly impacts the USV's maneuverability, navigation efficiency, and mission success rate.
[0003] Traditional methods for adjusting turning control parameters mainly rely on the experience of control engineers or offline debugging based on simplified mathematical models. This approach has several drawbacks. First, manual debugging is cumbersome, time-consuming, and labor-intensive, and it's difficult to guarantee the global optimality of the parameters. Second, when unmanned surface vessels (USVs) turn in complex and ever-changing marine environments, their dynamic characteristics are significantly affected by environmental factors such as wind, waves, and currents, as well as the turning action itself (e.g., centrifugal force, attitude changes), making fixed parameters unsuitable for all turning conditions. Third, traditional methods often focus on single performance indicators such as turning trajectory tracking accuracy or response speed, paying insufficient attention to attitude stability during turns (e.g., roll angle), posing a potential safety hazard of capsizing due to excessive roll angles. This makes it difficult to meet the requirements of efficiency, accuracy, and safety for learning turning control parameters in complex marine environments. Summary of the Invention
[0004] The purpose of this invention is to provide a method and apparatus for learning turning control parameters of unmanned surface vessels (USVs). By constructing a comprehensive performance index including turning time, trajectory error, and roll angle safety penalties, a BP neural network model is built, and an improved genetic algorithm is employed to achieve efficient, accurate, and safe automatic learning and optimization of USV turning control parameters. The specific technical solution is as follows: A method for learning turning control parameters for unmanned surface vessels, including: Acquire sample data for the turning control of the unmanned surface vessel, including turning control parameters; A BP neural network model is constructed. A sample set is formed based on the sample data of UAV turning control and divided into a training set and a validation set. A comprehensive turning performance index is constructed based on the sample data of UAV turning control. The comprehensive turning performance index includes turning time, turning trajectory error, and safety penalty. The network architecture of the BP neural network model is built to establish the mapping relationship between turning control parameters and comprehensive turning performance index. At the same time, the legal value range of turning control parameters is used to characterize the turning control parameter space. The training strategy is configured for the BP neural network model based on the training set and the training is completed. The loss function of the model during the training process is monitored through the validation set until the training termination condition is met. An improved genetic algorithm is used, with the trained BP neural network model as a surrogate model for turning performance. Based on the surrogate model's prediction of the comprehensive turning performance index in the turning control parameter space, the optimal combination of turning control parameters that achieves the comprehensive turning performance index is searched in the turning control parameter space.
[0005] Furthermore, the network architecture for building a BP neural network model includes: The number of nodes in the input layer of the BP neural network model is set to match the number of turning control parameters to receive the turning control parameter vector; at least two hidden layers are set after the input layer, and each hidden layer uses the ReLU activation function; Dropout layers are configured after each hidden layer to reduce the risk of model overfitting; Set the output layer of the BP neural network model to have 1 node and use a linear activation function.
[0006] Furthermore, configuring training strategies for BP neural network models includes: The Adam optimizer is used as the training optimizer for the model, and an initial learning rate is set. A learning rate scheduling strategy is configured to automatically decay the learning rate when the validation set loss does not decrease within a preset number of rounds. An early stopping mechanism is enabled to monitor the validation set loss in real time and trigger training termination when the validation set loss does not improve for a preset number of consecutive rounds. The training loop is executed based on the training strategy. Iterative training is achieved through model computation, loss processing and weight updates. The validation set loss is evaluated simultaneously. Training is completed and the model parameters are saved after the validation set loss converges.
[0007] Furthermore, the comprehensive turning performance indicators include: The turning time, turning trajectory error, and safety penalty item of the unmanned surface vessel during the turning process are calculated separately. The safety penalty item is determined based on the relationship between the maximum roll angle and the safety threshold. Normalization is performed on turning time, turning trajectory error, and safety penalty items to eliminate differences in the dimensions and numerical ranges of different indicators; The normalized indicators are weighted and summed according to preset weights to obtain the comprehensive turning performance index. When the maximum roll angle exceeds the safety threshold, the safety penalty item increases with the increase of the exceedance of the safety threshold. When the maximum roll angle does not exceed the safety threshold, the safety penalty item is zero.
[0008] Further improvements to the genetic algorithm include: Population initialization: A hybrid initialization strategy is used to generate an initial population, which is then used for subsequent iterations to find the best population. Individual performance evaluation: Each combination of turning control parameters in the population is input into the trained BP neural network surrogate model to obtain the comprehensive turning performance index corresponding to each parameter combination, and this index is used as the individual fitness value; Genetic manipulation sequence: Based on fitness values, selection, crossover, and mutation operations are performed to generate a new generation of population; Termination Judgment: Determine whether the preset termination condition is met. If not, return to individual performance evaluation and continue iteration. If the condition is met, terminate the iteration.
[0009] Furthermore, hybrid initialization strategies include: Based on the unmanned surface vessel turning control sample data, determine the baseline parameter combination for turning control; An initial population is generated, which includes experienced individuals and random individuals. Experienced individuals are randomly generated within a preset range based on a combination of baseline parameters, while random individuals are uniformly and randomly generated within the turning control parameter space.
[0010] Furthermore, the execution of genetic manipulation sequences includes: Selection operation: Use a preset selection strategy to filter parent individuals; Crossover operation: Perform a preset crossover operation on the selected parent individual to generate a child individual; Mutation operation: Perform a preset mutation operation on the offspring individuals after crossover to adjust the combination of turning control parameters.
[0011] Furthermore, during population initialization, experienced individuals are generated within a preset range based on a combination of baseline parameters, and experienced individuals and random individuals are configured in a preset ratio in the initial population. In the genetic manipulation sequence, the selection operation adopts tournament selection and elite retention strategies, the crossover operation adopts simulated binary crossover strategy, and the mutation operation adopts polynomial mutation strategy; The preset termination conditions include at least one of the following: the number of iterations reaches the preset maximum number of iterations, the fitness value of the best individual does not improve significantly for multiple consecutive rounds, and the turning comprehensive performance index corresponding to the optimal parameter combination reaches the preset threshold.
[0012] Furthermore, it also includes verifying the combination of turning control parameters, including: High-fidelity simulation verification: Input the combination of turning control parameters into the unmanned surface vessel turning simulation platform to verify the turning performance indicators under different sea conditions and turning mission scenarios; Real-ship test verification: Under safe and controllable conditions, the combination of turning control parameters is deployed to the actual turning control system of the unmanned surface vessel, and a real-ship turning test is conducted for verification. Parameter deployment and application: The optimal combination of turning control parameters is used as the recommended parameters for the turning maneuver of the unmanned surface vessel, or as the initial parameters for the adaptive turning control system.
[0013] A device for learning turning control parameters of an unmanned surface vessel includes: The acquisition module is used to acquire sample data for the unmanned surface vessel's turning control, including turning control parameters. The module is used to build a BP neural network model. It forms a sample set based on the sample data of UAV turning control and divides it into a training set and a validation set. It constructs a comprehensive turning performance index based on the sample data of UAV turning control. The comprehensive turning performance index includes turning time, turning trajectory error, and safety penalty. It builds the network architecture of the BP neural network model to establish the mapping relationship between turning control parameters and comprehensive turning performance index. At the same time, it uses the legal value range of turning control parameters to characterize the turning control parameter space. The training module is used to configure the training strategy for the BP neural network model based on the training set and complete the training. It monitors the loss function of the model during the training process through the validation set until the training termination condition is met. An improved genetic algorithm module is used to employ an improved genetic algorithm, using the trained BP neural network model as a surrogate model for turning performance. Based on the surrogate model's prediction results of the comprehensive turning performance index within the turning control parameter space, the module searches for the optimal combination of turning control parameters that achieves the best comprehensive turning performance index within the turning control parameter space.
[0014] The unmanned surface vessel turning control parameter learning method and device of the present invention have the following advantages: 1. By integrating sample data acquisition, BP neural network model construction, model training, and improved genetic algorithm optimization, the trained BP neural network is used as a proxy model for turning performance, replacing the traditional time-consuming unmanned surface vessel (USV) turning simulation or actual ship test. This achieves accurate mapping between turning control parameters and comprehensive performance indicators. At the same time, the improved genetic algorithm efficiently searches for the optimal parameter combination in the parameter space, achieving efficient, accurate, safe, and automatic learning and optimization of USV turning control parameters. This balances parameter optimization efficiency with practicality for adapting to different turning scenarios.
[0015] 2. By matching the number of input layer nodes to the number of turning control parameters, the effective reception of parameter vectors is ensured; at least two hidden layers are paired with the ReLU activation function to improve the model's ability to fit the complex nonlinear relationship between parameters and comprehensive performance indicators; a Dropout layer is configured after each hidden layer to effectively reduce the risk of model overfitting; a single node in the output layer is paired with a linear activation function to ensure the accurate output of the predicted results of the turning comprehensive performance indicators, significantly enhancing the model's generalization ability and prediction accuracy, and providing high-precision performance surrogate model support for subsequent parameter optimization.
[0016] 3. By adopting the Adam optimizer, dynamic learning rate scheduling strategy, and early stopping mechanism, combined with standardized training loop iteration logic, the convergence speed of model weights is accelerated, and the problems of invalid training iterations and overfitting are avoided. At the same time, the stability of the training process is ensured by real-time monitoring of the validation set loss, which effectively improves the model training efficiency, reduces computing power and time costs, and finally obtains a stable and reliable turning performance proxy model.
[0017] 4. Turning time, turning trajectory error, and safety penalty based on maximum roll angle are incorporated into a unified optimization objective. Normalization eliminates differences in dimensions and numerical ranges between different indicators, and a weighted summation method is used to integrate the indicators. Furthermore, the safety penalty can quantify the safety risk of exceeding the roll angle limit. This approach achieves a multi-dimensional balance between the efficiency, accuracy, and safety of unmanned surface vessels (USVs) turning, while making the optimization objective more aligned with the needs of real-world application scenarios, avoiding the performance imbalance caused by optimizing a single indicator.
[0018] 5. The iterative optimization process of the genetic algorithm has been optimized, which effectively improves the global optimization capability of the algorithm, avoids the premature convergence problem that is prone to occur in traditional genetic algorithms, and ensures that the optimal parameter combination with comprehensive performance is efficiently selected in the turning control parameter space.
[0019] 6. Based on unmanned surface vessel (USV) turning sample data, a baseline parameter combination is determined to generate experienced individuals. Simultaneously, random individuals are generated within the parameter space. This ensures the initial population maintains both the quality of experienced individuals based on actual test samples and population diversity through random individuals. This avoids the optimization limitations caused by homogeneity in the initial population, lays a high-quality foundation for subsequent genetic algorithm iterations, and improves the probability and efficiency of finding the globally optimal turning control parameter combination. Attached Figure Description
[0020] Figure 1 This is an overall flowchart of the unmanned surface vessel turning control parameter learning method proposed in this application.
[0021] Figure 2 This is a flowchart of the construction and training of a BP neural network model in the method for learning turning control parameters of an unmanned surface vessel (USV) according to this application.
[0022] Figure 3 This is a flowchart of the improved genetic algorithm parameter optimization method used in the unmanned surface vessel turning control parameter learning method of this application. Detailed Implementation
[0023] The terminology used in this invention is for the purpose of describing particular embodiments only and is not intended to be limiting of the invention. The singular forms “a,” “the,” and “the” used in this invention and the appended claims are also intended to include the plural forms unless the context clearly indicates otherwise. It should also be understood that the term “and / or” as used herein refers to and includes any or all possible combinations of one or more of the associated listed items.
[0024] It should be understood that although the terms first, second, third, etc., may be used herein to describe various information, this information should not be limited to these terms. These terms are only used to distinguish information of the same type from one another. For example, without departing from the scope of the invention, first information may also be referred to as second information, and similarly, second information may also be referred to as first information. Depending on the context, the word "if," as used herein, can be interpreted as "when," "in response to a determination," or "when," or "in the event of a determination." like Figure 1 As shown, the unmanned surface vessel (USV) turning control parameter learning method provided by this invention proceeds sequentially from data input, model construction and training, and intelligent optimization. First, sample data containing turning control parameters is acquired as the foundation for subsequent steps. Then, a BP neural network model is constructed, generating a comprehensive turning performance index based on the sample data, including turning time, trajectory error, and safety penalty terms. Simultaneously, an adaptive network architecture is built to establish a mapping relationship between parameters and the comprehensive performance index, and the control parameter space is defined by the legal value range of the parameters. Subsequently, training strategies such as the Adam optimizer and learning rate scheduling are configured for the model to complete training, resulting in a usable turning performance proxy model. Finally, the parameter performance is quickly predicted based on this proxy model, and an improved genetic algorithm is used to search within the parameter space to ultimately obtain the optimal combination of turning control parameters that achieves the best comprehensive performance index, efficiently realizing automatic parameter optimization.
[0025] This method replaces traditional time-consuming simulations or ship trials with a BP neural network, and combines an improved genetic algorithm to achieve efficient optimization within the parameter space. At the same time, it incorporates safety penalty terms into the comprehensive performance index, which not only ensures the efficiency and accuracy of unmanned surface vessel (USV) turning parameter optimization, but also strengthens the safety constraints of the turning process. Finally, after simulation and ship verification, it is deployed to achieve intelligent, efficient and safe optimization of USV turning control parameters.
[0026] Specifically, the sample data for unmanned surface vessel (USV) turning control mainly comes from a high-fidelity USV turning simulation platform. This simulation should reproduce the real marine environment (wind, waves, currents) and USV dynamics model as much as possible, and simulate the standard turning maneuver process. It can also be supplemented and verified by combining some actual ship turning test data.
[0027] Furthermore, based on the basic performance of the unmanned surface vessel and experience in turning control, a reasonable range of values is set for the turning control parameters to be optimized. These turning control parameters include the proportional gain of the PID controller. Integral coefficient Differential coefficients and the speed coefficient used to adjust cornering characteristics. and turning distance coefficient For example, it can be set , , , , These parameters collectively determine the turning response, trajectory accuracy, and safety status of the unmanned surface vessel, and are the core objects of subsequent model building and parameter optimization.
[0028] Based on the determined turning control parameters, the input-output relationship is first defined, with the input being the turning control parameter vector. The output consists of performance metrics for the unmanned surface vessel after performing a specific turning maneuver, primarily including: Turning time T: The time required from the start of a turn to the completion of a turn at a specified angle.
[0029] Turning trajectory error E: measures the deviation between the actual navigation trajectory and the expected turning trajectory during a turn. Mean square error (MSE) or other distance metrics can be used.
[0030] Maximum roll angle Record the maximum absolute value of the unmanned surface vessel's roll angle during the entire turning process.
[0031] Subsequently, a sample set is constructed by generating a large number of samples through uniform sampling, Latin hypercube sampling, or sampling based on certain strategies within the parameter space. The sample pairs, namely the set of sample pairs of "turning control parameter vector - turning performance index", form a complete sample set. Then, the sample set is divided into a training set and a validation set according to the proportion. The training set is used to iteratively update the weights of the BP neural network, and the validation set is used to monitor changes in the loss function and trigger the early stopping mechanism to ensure the model's generalization ability.
[0032] After obtaining the corresponding unmanned surface vessel (USV) turning control sample data, it is necessary to construct a comprehensive turning performance index that can comprehensively evaluate the turning effect. This includes the following steps: First, calculate the turning time, turning trajectory error, and safety penalty related to the maximum roll angle of the USV under the corresponding parameters. Then, normalize these indicators to eliminate dimensional differences. Finally, sum the normalized indicators according to preset weights to obtain a comprehensive turning performance index that can simultaneously reflect turning efficiency, accuracy, and safety.
[0033] Specifically, the turning trajectory error is calculated using MSE to quantify the turning trajectory deviation, and the formula is as follows:
[0034] in, This represents the total number of sampling points for the turning trajectory. These are the coordinates of the actual trajectory points during the turning process. By defining the coordinates of the desired trajectory points during the turning process and quantifying the deviation between the actual trajectory and the desired trajectory through a clearly defined mean square error, the turning accuracy can be standardized and quantified for evaluation.
[0035] To ensure navigational safety during turns, a safety penalty is introduced based on the maximum roll angle during the turn. Set a safety threshold for the turning process. (For example, 15° or determined based on unmanned surface vessel stability calculations). The penalty term is defined as follows:
[0036] This penalty ensures that when the roll angle exceeds a safe threshold during a turn, the overall turning performance index will be reduced. This will significantly increase the efficiency of the unmanned surface vessel (USV), thereby suppressing parameter combinations that lead to unsafe conditions during the optimization process, ensuring navigation safety when the USV turns from a parameter perspective, and avoiding the risk of capsizing.
[0037] To eliminate the differences in dimensions and numerical ranges among different turning performance indicators, , and Perform normalization. The normalization formula is:
[0038] in, represent , and , and These are the minimum and maximum values of the indicator in the turning sample set, respectively.
[0039] Define the overall performance index for turning The formula is the weighted sum of the normalized turning performance indicators:
[0040] , , These are the weighting coefficients for turning time, turning error, and the yaw angle penalty during turning, respectively, satisfying... The weighting needs to be adjusted according to the specific turning task requirements and safety requirements. A sufficiently high value should be assigned to ensure safety during the turning process, in order to obtain a comprehensive turning performance index. This enables the improved genetic algorithm to efficiently search for the optimal parameter combination that balances turning efficiency, trajectory accuracy, and safety using a single metric.
[0041] like Figure 2 As shown, in order to establish a precise mapping relationship between turning control parameters and comprehensive turning performance indicators, a corresponding neural network structure framework is set up. First, the network topology is configured, using a multi-layer feedforward BP neural network, with the input layer set to 5 nodes, corresponding to the input turning control parameter vector. The output layer is set to one node, corresponding to the output of the overall turning performance index. This is to establish a precise input / output interface for mapping turning control parameters to comprehensive performance indicators, ensuring that parameter information is transmitted without omission, while also adapting to the output requirements of comprehensive performance indicators.
[0042] Next, hidden layer configuration is implemented: To enhance the network's ability to fit complex nonlinear relationships during cornering, a multi-hidden-layer structure is adopted. For example, in this example, the first hidden layer contains 8 neurons, and the second hidden layer contains 6 neurons. This can be flexibly adjusted based on the training results of actual cornering simulation data and the required network complexity. The configuration of multiple hidden layers allows the network to more deeply capture the profound correlation between the combination of cornering control parameters and cornering performance, thus improving its ability to fit complex cornering processes.
[0043] Next, a regularization technique is introduced, adding a Dropout (regularization) layer after each hidden layer. In this embodiment, the Dropout rate is set to 0.2 or 0.3. This technique reduces co-fitness between neurons by randomly setting the output of some neurons to zero during training, thereby effectively reducing the risk of model overfitting and significantly improving the model's generalization ability, allowing the network to stably output reliable performance metrics in different turning scenarios.
[0044] Finally, for the choice of activation function, the ReLU (Rectified Linear Unit) activation function is commonly used in hidden layers. The ReLU function is simple to compute and can effectively alleviate the gradient vanishing problem, thereby accelerating network training. The output layer uses a linear (or identity) activation function because the overall performance index of the output is... It is a continuous real value, and the linear activation function can be adapted to its numerical properties, thereby optimizing the training efficiency of the network and ensuring the matching degree between the output results and the indicator properties.
[0045] The above configuration enables the BP neural network to accurately fit the nonlinear mapping relationship between turning control parameters and turning comprehensive performance indicators, while taking into account both training efficiency and generalization ability, so as to obtain a reliable performance evaluation proxy model for subsequent improvement of genetic algorithms to optimize turning parameters of unmanned surface vessels.
[0046] Preferably, after completing the network architecture and parameter configuration of the BP neural network model, an appropriate training strategy should be adopted to optimize the model parameters and improve the fitting effect. The Adam (Adaptive Moment Estimation) optimizer is used for training, and an initial learning rate is set and a learning rate scheduling strategy is used. At the same time, an early stopping strategy is enabled to adapt to the structural characteristics of the current model, effectively avoid overfitting, accelerate training convergence, and enable the model to accurately fit the mapping relationship between turning control parameters and comprehensive performance indicators.
[0047] Specifically, the Adam optimizer combines the advantages of momentum and RMSprop algorithms, dynamically adjusting the learning rate of each parameter based on the first and second moment estimates of the gradient. Compared to traditional optimization algorithms, it has a faster convergence speed and better optimization performance. In this embodiment, its initial learning rate is set to 0.001 to provide a reasonable initial step size for model training. At the same time, the ReduceLROnPlateau learning rate scheduling strategy is adopted. When the turning performance loss function on the validation set does not decrease within 10 rounds, the learning rate is automatically decayed by 0.5. This strategy can help the model escape local optima and further accelerate the convergence process.
[0048] Furthermore, an EarlyStopping strategy is implemented to monitor the turning performance loss function value on the validation set in real time. If the validation loss does not improve for several consecutive rounds (e.g., 20 rounds), training is terminated early to effectively avoid the problem of overfitting the model to the turning training set. An appropriate batch size is selected; in this embodiment, 32 or 64 is chosen to ensure the accuracy of gradient estimation while balancing memory usage efficiency, avoiding memory overflow due to an excessively large batch or gradient oscillation caused by an excessively small batch. Finally, the turning sample dataset is divided into a training set and a validation set. The network weights are iteratively updated through the training set, while the model performance is continuously evaluated on the validation set, such as until the maximum number of training rounds is reached or the validation loss converges, to ensure that the model has a stable and accurate mapping ability.
[0049] The training loop is performed according to the training strategy. Forward propagation is performed sequentially to obtain the overall turning performance index predicted by the model, the loss between the predicted result and the sample true value is calculated, and backpropagation is performed based on the loss to update the model weights. After each training round, the validation set loss is evaluated to determine whether the validation set loss has converged. If the validation set loss has converged, the optimal parameters of the model are saved and the training is completed. If it has not converged, the training loop is returned to continue iterating.
[0050] like Figure 3 As shown, based on the trained BP neural network surrogate model, an improved genetic algorithm is initiated to optimize parameters. First, a hybrid initialization strategy is used to generate an initial population. Based on the unmanned surface vessel (USV) turning sample data, a baseline parameter combination is determined to generate experienced individuals to ensure the quality of the initial population. At the same time, random individuals are generated in the parameter space to maintain population diversity. Then, each turning control parameter combination in the population is input into the trained BP neural network surrogate model to quickly obtain the corresponding comprehensive turning performance index as the individual fitness value. Subsequently, based on the fitness value, a genetic operation sequence of selection, crossover, and mutation is executed sequentially to generate a new generation of population. Next, it is determined whether the preset termination condition is met. If not, the process returns to the performance evaluation stage for continuous iteration; if it is met, the iteration terminates. Finally, the turning control parameter combination with the optimal fitness value is selected from the final population as the optimal parameter combination for USV turning control. This achieves efficient and accurate search for the optimal parameter combination in the USV turning control parameter space, balancing optimization efficiency with parameter adaptability to different sea conditions and turning scenarios.
[0051] Specifically, population initialization first determines the parameter encoding method, using real-valued encoding to directly input the turning control parameters. The numerical value serves as the gene representation of the chromosome (individual). Real number encoding can represent parameters more accurately, avoiding the precision loss and decoding process of binary encoding. It is adapted to the characteristics of continuous turning control parameters and serves as the basis for the generation and genetic operations of subsequent population individuals.
[0052] Subsequently, population initialization is performed, using a hybrid initialization strategy to generate the initial population. First, an empirical seed is determined, which is a set of baseline turning control parameters based on experience or preliminary turning simulations. Then perform mixed initialization to generate the initial population. Population size in this embodiment Setting the population size to 100 or 150 ensures sufficient population diversity and avoids limiting the initial search area. Specifically, the population is divided into two parts: experienced individuals account for approximately 20%, based on baseline parameters. Randomly generated from nearby locations, the generation formula is as follows: ,in This indicates element-wise multiplication. The first vector is a random vector uniformly distributed within the interval [-0.1, 0.1]. This setting allows for the initial use of empirical information to guide the search for turning parameters, reducing ineffective optimization and significantly improving initial optimization efficiency. The remaining 80% of the vectors are random individuals, uniformly and randomly generated throughout the entire turning parameter search space, using the following formula: ,in The random vector is uniformly distributed within the interval [0,1]. This method can effectively maintain the diversity of the population and prevent the algorithm from getting stuck in local optima from the initial stage.
[0053] The aforementioned hybrid initialization strategy not only relies on empirical seeds to quickly lock in the approximate range of high-quality parameters, reducing the optimization cost of subsequent iterations, but also covers a wider search space through random individuals, providing sufficient parameter samples for global optimization. Ultimately, it provides a high-quality initial population foundation for improving the efficiency and accuracy of genetic algorithms.
[0054] After the initial population generation is complete, individual performance evaluation begins. Each combination of turning control parameters in the population is input into a trained BP neural network surrogate model. This model quickly outputs the comprehensive turning performance index corresponding to each parameter combination, and this index is directly used as the individual's fitness value. Specifically, turning performance evaluation is performed first for each individual in the population. This is fed as input to a trained BP neural network model, which then quickly outputs the predicted turning performance index for that individual. This approach leverages the precise parameter-performance mapping capability of the pre-trained BP model, shortening the performance evaluation time for individual models while ensuring the consistency and accuracy of the evaluation results. Fitness calculation is then performed: while the conventional iterative logic of genetic algorithms maximizes fitness, the core objective of this invention is to minimize the overall turning performance index. Therefore, individuals fitness Defined as , in It is a very small positive constant. This function achieves minimization on the one hand. To maximize the fit of the target, the genetic algorithm can directly serve the optimization needs of this invention. On the other hand... The introduction effectively avoided the situation The fact that the denominator is close to 0 prevents calculation errors caused by the denominator being zero, thus ensuring the numerical stability of the fitness calculation. Ultimately, the fitness value... The higher the value, the better the performance of the turning parameter combination. This quantification rule provides a clear and reliable standard for selecting high-quality individuals in subsequent genetic operations, ensuring that the algorithm can continuously iterate towards parameter combinations with better performance.
[0055] Furthermore, based on the obtained fitness values, a sequence of genetic operations consisting of selection, crossover, and mutation is sequentially executed to generate a new generation of population. The selection operation employs a tournament selection and elite retention strategy, where tournament selection randomly selects from the current population. Individuals (e.g.) =3), compare their fitness and select the individual with the highest fitness as the parent to enter the next generation. This method is not only simple and efficient in computation, but also can be adjusted. The value of can flexibly control selection pressure and adapt to the needs of different optimization stages; elite preservation, on the other hand, is used to generate the next generation of the population. Previously, the current generation population The one or a few individuals with the highest fitness (elite individuals) are directly copied to the next generation to effectively ensure that the optimal turning parameters found at the moment are not lost in subsequent iterations, thus guaranteeing the continuity of high-quality genetic information.
[0056] Next, a crossover operation is performed, using the Simulated Binary Crossover (SBX) operator specifically designed for real number encoding. This is applied to the two parent individuals selected through the selection operation. and SBX will generate two new offspring individuals. and It mimics the behavior of binary crossover, and the distance between the generated offspring and parents follows a specific probability distribution (usually a power function distribution). This characteristic helps to achieve a balance between global and local search, preventing the algorithm from being overly biased towards one search dimension; crossover probability It can be set to 0.9. A higher crossover probability can promote the recombination of turning parameters and the generation of new solutions, thereby enhancing the iterative vitality of the population.
[0057] Finally, mutation operations are performed, employing either polynomial mutation or adaptive mutation strategies: Polynomial mutation mutates each gene (turning control parameter) of an individual, adaptively adjusting the mutation length based on the gene's distance from the boundary or optimal solution, helping to maintain population diversity and avoid homogenization of parameter combinations; mutation probability... Can be set to ,in, Here, the number of decision variables is... =5, therefore It can also be dynamically adjusted according to the fitness variance of the population; adaptive mutation will dynamically adjust the mutation intensity according to the evolutionary state of the population (such as the degree of convergence), which can maintain the diversity of the population in the early stage of the search to cover a wider parameter space, and perform fine search in the later stage to approach the optimal solution, effectively avoiding the problem of premature convergence of the algorithm.
[0058] After the generation of the new generation population is completed, a termination judgment operation is performed. During the iterative execution phase, selection, crossover, and mutation operations are repeatedly performed to generate a new generation population. The system then uses a trained backpropagation (BP) neural network to evaluate the turning fitness of each individual in the population. This iterative process continuously filters and optimizes the parameter combinations within the population, gradually improving the overall performance of the population. Furthermore, thanks to the rapid evaluation capability of the BP neural network, fitness calculations can be efficiently completed in each iteration, avoiding the time-consuming problems of traditional real-ship or simulation evaluations and ensuring the efficiency of the iterative process.
[0059] The algorithm stops iterating when either of the following termination conditions is met: First, the maximum number of generations is reached, i.e., the number of generations g reaches a preset maximum value G (e.g., 200 generations). This condition effectively controls the computational resource consumption of the algorithm and avoids the redundant costs caused by unlimited iteration. Second, fitness convergence occurs, i.e., the fitness of the best individual in the population changes very little (e.g., less than 10) over several consecutive generations (e.g., 20 generations). -6 This judgment method can accurately identify the convergence state of the algorithm and terminate ineffective iterations that have no significant performance improvement in a timely manner; thirdly, the objective function value is met, that is, the optimal individual found corresponds to The value is lower than the preset turning performance threshold. This condition directly anchors the actual performance requirements of the unmanned surface vessel's turning, ensuring that the output parameter combination can meet the performance standards of engineering applications.
[0060] After the algorithm terminates, it returns to the fitness level found during the evolutionary process (i.e., the highest fitness level). The individual with the lowest value This individual parameter represents the optimal combination of turning control parameters. This output ensures that the final parameters are the best-performing combination throughout the entire evolution process, directly matching the parameter optimization requirements for unmanned surface vessel turning control.
[0061] After completing the parameter optimization of the improved genetic algorithm, the next step is to verify and deploy the learning results of the turning parameters to ensure the practicality and reliability of the optimal parameters.
[0062] First, simulation verification was conducted, and the optimized turning parameters were used for verification. The data was input into a high-fidelity turning simulation platform to verify its control effectiveness under different sea conditions and turning scenarios, and the turning performance indicators (time, error, roll angle) before and after optimization were compared. The high-fidelity simulation platform can cover complex and diverse operating scenarios at low cost and without risk, proactively identifying parameter adaptability issues under different environments. Furthermore, by comparing performance indicators, the improvement effect brought about by parameter optimization can be intuitively quantified, providing preliminary and effective support for subsequent real-ship applications.
[0063] Subsequently, a full-scale ship trial was conducted, and the parameters were determined under safe and controllable conditions. The simulation was deployed into the actual turning control system of the unmanned surface vessel (USV) to conduct small-scale real-ship turning tests. This was done to compensate for the differences between the simulation environment and the real marine environment, verify the effectiveness and safety of the parameters under actual working conditions, and avoid the problem of the simulation results being out of sync with the actual performance. At the same time, the small-scale test method ensured the safety of the testing process and accurately obtained parameter performance data under real-world scenarios.
[0064] Finally, the parameters were deployed and applied, and the optimal turning parameters were verified to be effective. It can be used as a recommended parameter for unmanned surface vessels (USVs) when performing turning maneuvers, directly improving the efficiency, accuracy, and safety of a single turning mission; it can also be used as the initial parameter for an adaptive turning control system, leveraging its superior basic performance to reduce the initial adjustment time of the adaptive system, achieve stable control effects more quickly, and ultimately improve the overall turning performance of USVs from a practical application perspective.
[0065] The present invention also provides an unmanned surface vessel turning control parameter learning device, which includes an acquisition module, a construction module, a training module, and an improved genetic algorithm module. It can be flexibly integrated into the electronic control unit (ECU) of the unmanned surface vessel or the industrial control equipment of the shore-based monitoring center. The overall functionality is achieved by relying on an embedded hardware platform and modular software logic.
[0066] Specifically, the acquisition module serves as the data input to the device, collecting and preprocessing sample data for the unmanned surface vessel's (USV) turning control. This data comprises key information during the USV's turning process, including turning control parameters such as the proportional gain of the PID controller. Integral coefficient Differential coefficients and the speed coefficient used to adjust cornering characteristics. and turning distance coefficient Simultaneously, the module collects corresponding measured performance indicators (turning time, deviation between actual and expected trajectory, maximum roll angle). If real ship data is insufficient, offline sample data generated by a high-fidelity simulation platform can be imported via Ethernet interface for supplementation. Subsequently, the acquisition module filters outliers from the collected raw data, removing invalid data such as excessive roll angles and trajectory coordinate jumps caused by sensor malfunctions. Finally, a standardized sample of "turning control parameter vector + corresponding measured performance indicators" is formed and stored in the sample database on the solid-state drive, providing a reliable data foundation for subsequent module construction.
[0067] The construction module receives the sample data output by the acquisition module for three purposes: First, to construct a comprehensive turning performance index. This involves extracting turning time, turning trajectory error, and maximum roll angle from the samples, with a preset roll angle safety threshold (e.g., 15°). If the maximum roll angle does not exceed the threshold, the safety penalty term is 0; if it exceeds the threshold, the penalty term increases with the increase in roll angle. The three indicators are then weighted and summed according to preset weights to obtain an index that comprehensively reflects turning efficiency, accuracy, and safety. Second, to build a BP neural network architecture. Based on the number of turning control parameters (e.g., 5 parameters), 5 input nodes are set, with at least two hidden layers (each using the ReLU activation function and paired with a Dropout layer to reduce overfitting), and one node outputting a linear activation function, clarifying the nonlinear mapping relationship between "turning control parameters and comprehensive performance index." Third, to characterize the turning control parameter space. Combining unmanned surface vessel engineering experience and safety requirements, the legal value range of each control parameter is determined, defining the search boundary for subsequent parameter optimization. Upon completion, the comprehensive performance index, network architecture, and parameter space file are simultaneously output to the training module.
[0068] The training module takes the network architecture and sample data provided by the construction module as input and focuses on the training and optimization of the BP neural network. During implementation, the training module first configures a targeted training strategy, employing the Adam optimizer and setting an initial learning rate (e.g., 0.001) to efficiently update weights. A dynamic learning rate scheduling mechanism is configured, automatically decaying the learning rate by 50% if the validation set loss does not decrease within 10 rounds. Simultaneously, an early stopping mechanism is enabled, terminating training if the validation loss does not improve after 20 consecutive rounds to avoid model overfitting. Subsequently, the sample data is divided into training and validation sets. Forward propagation is used to obtain the comprehensive performance index predicted by the model, and the mean squared error loss between the model predictions and the measured values is calculated. Then, backpropagation is used to iteratively update the model weights until the validation set loss converges. After training, the model's weights, biases, and other parameters are stored on a solid-state drive, forming a directly callable turning performance proxy model for use by the improved genetic algorithm module.
[0069] The improved genetic algorithm module is the core of parameter optimization. Its key lies in using a trained BP neural network as a surrogate model to replace traditional time-consuming real-ship or simulation evaluations. Specifically, the module first generates an initial population (e.g., size 100) based on the parameter space represented by the construction module using a hybrid initialization strategy. Some individuals are derived from high-quality parameters in the sample data to ensure the quality of the initial population; others are randomly generated within the parameter space to maintain population diversity. Next, each parameter combination in the population is input into the surrogate model to quickly obtain the corresponding comprehensive performance index as the individual's fitness value. Then, genetic operations are performed based on the fitness value, employing a tournament strategy to select parents, simulate binary crossover to generate offspring, and use polynomial mutation to adjust parameters, continuously iterating to generate a new generation of the population. When the number of iterations reaches a preset maximum, or when the fitness value of the optimal individual shows no significant improvement for several consecutive rounds, the iteration terminates, and the parameter combination that optimizes the comprehensive turning performance index is selected as the recommended parameters for the unmanned surface vessel's turning control.
[0070] The aforementioned modules form a complete working loop through a tight data flow: the acquisition module provides the data foundation, the construction module completes the indicator and architecture design, the training module outputs a usable surrogate model, the improved genetic algorithm module achieves parameter optimization, and finally, the optimal parameters are output to the unmanned surface vessel's turning control system. This modular and collaborative design not only ensures the independence and maintainability of each function but also ensures that parameter learning is efficient and accurate throughout the entire process from data input to optimized application, effectively meeting the automatic learning needs of unmanned surface vessels for turning control parameters in complex marine environments.
[0071] It should be noted that not all steps and units in the above process and system structure diagrams are mandatory; some steps or units can be omitted according to actual needs. The execution order of each step is not fixed and can be determined as needed. The device structure described in the above embodiments can be a physical structure or a logical structure; that is, some units may be implemented by the same physical entity, or some units may be implemented by multiple physical entities, or they may be jointly implemented by certain components in multiple independent devices.
[0072] In the above embodiments, the hardware units or modules can be implemented mechanically or electrically. For example, a hardware unit, module, or processor may include permanent dedicated circuitry or logic (such as a dedicated processor, FPGA, or ASIC) to perform the corresponding operation. The hardware unit or processor may also include programmable logic or circuitry (such as a general-purpose processor or other programmable processor), which can be temporarily configured by software to perform the corresponding operation. The specific implementation method (mechanical, dedicated permanent circuitry, or temporarily configured circuitry) can be determined based on cost and time considerations.
Claims
1. A method for learning turning control parameters of an unmanned surface vessel, characterized in that, include: Acquire sample data for the turning control of the unmanned surface vessel, the sample data including turning control parameters; A BP neural network model is constructed, and a sample set is formed based on the sample data of the unmanned surface vessel's turning control and divided into a training set and a validation set. The turning comprehensive performance index is constructed based on the sample data of the unmanned surface vessel's turning control, and the turning comprehensive performance index includes turning time, turning trajectory error, and safety penalty item. The network architecture of the BP neural network model is constructed to establish the mapping relationship between the turning control parameters and the comprehensive turning performance index; at the same time, the turning control parameter space is characterized by the legal value range of the turning control parameters. The training strategy is configured for the BP neural network model based on the training set and the training is completed. The loss function of the model during the training process is monitored through the validation set until the training termination condition is met. An improved genetic algorithm is used to take the trained BP neural network model as a surrogate model for turning performance. Based on the prediction results of the surrogate model for the comprehensive turning performance index in the turning control parameter space, the optimal combination of turning control parameters that makes the comprehensive turning performance index optimal is searched in the turning control parameter space.
2. The unmanned surface vessel turning control parameter learning method as described in claim 1, characterized in that, The network architecture for building the BP neural network model includes: The number of nodes in the input layer of the BP neural network model is set to match the number of turning control parameters to receive the turning control parameter vector; at least two hidden layers are set after the input layer, and each hidden layer uses the ReLU activation function; A Dropout layer is configured after each of the hidden layers to reduce the risk of model overfitting; The output layer of the BP neural network model is set to have 1 node, and a linear activation function is used.
3. The unmanned surface vessel turning control parameter learning method as described in claim 1, characterized in that, Configuring a training strategy for the BP neural network model includes: The Adam optimizer is used as the training optimizer for the model, and an initial learning rate is set. A learning rate scheduling strategy is configured to automatically decay the learning rate when the validation set loss does not decrease within a preset number of rounds. An early stopping mechanism is enabled to monitor the validation set loss in real time and trigger training termination when the validation set loss does not improve for a preset number of consecutive rounds. The training loop is executed based on the training strategy. Iterative training is achieved through model computation, loss processing and weight updates. The validation set loss is evaluated simultaneously. Training is completed and model parameters are saved after the validation set loss converges.
4. The unmanned surface vessel turning control parameter learning method as described in claim 1, characterized in that, The comprehensive turning performance index is constructed by including: The turning time, turning trajectory error, and safety penalty item of the unmanned surface vessel during the turning process are calculated respectively. The safety penalty item is determined based on the relationship between the maximum roll angle and the safety threshold. The turning time, turning trajectory error, and safety penalty item are normalized to eliminate differences in the dimensions and numerical ranges of different indicators. The normalized indicators are weighted and summed according to preset weights to obtain the comprehensive turning performance index. When the maximum roll angle exceeds the safety threshold, the safety penalty item increases as the magnitude of exceeding the safety threshold increases. When the maximum roll angle does not exceed the safety threshold, the safety penalty item is zero.
5. The unmanned surface vessel turning control parameter learning method as described in claim 1, characterized in that, The Improved genetic algorithms include: Population initialization: An initial population is generated using a hybrid initialization strategy, and this initial population is used for subsequent iterative optimization. Individual performance evaluation: Each combination of turning control parameters in the population is input into the trained BP neural network surrogate model to obtain the comprehensive turning performance index corresponding to each parameter combination, and this index is used as the individual fitness value; Genetic manipulation sequence: Based on fitness values, selection, crossover, and mutation operations are performed to generate a new generation of population; Termination Judgment: Determine whether the preset termination condition is met. If not, return to the individual performance evaluation and continue iterating. If the condition is met, terminate the iteration.
6. The unmanned surface vessel turning control parameter learning method as described in claim 5, characterized in that, The hybrid initialization strategy includes: Based on the unmanned surface vessel turning control sample data, determine the baseline parameter combination of the turning control parameters; The initial population is generated, which includes experienced individuals and random individuals. The experienced individuals are randomly generated within a preset range based on the combination of the benchmark parameters, and the random individuals are uniformly and randomly generated within the turning control parameter space.
7. The unmanned surface vessel turning control parameter learning method as described in claim 5, characterized in that, The execution of the genetic operation sequence includes: Selection operation: Use a preset selection strategy to filter parent individuals; Crossover operation: Perform a preset crossover operation on the selected parent individual to generate a child individual; Mutation operation: Perform a preset mutation operation on the offspring individuals after crossover to adjust the combination of turning control parameters.
8. The unmanned surface vessel turning control parameter learning method as described in claim 5, characterized in that, In the population initialization, experienced individuals are generated within a preset range based on a combination of benchmark parameters, and experienced individuals and random individuals are configured in a preset ratio in the initial population. In the genetic operation sequence, the selection operation adopts a tournament selection and elite retention strategy, the crossover operation adopts a simulated binary crossover strategy, and the mutation operation adopts a polynomial mutation strategy. The preset termination conditions include at least one of the following: the number of iterations reaches the preset maximum number of iterations, the fitness value of the optimal individual does not improve significantly for multiple consecutive rounds, and the turning comprehensive performance index corresponding to the optimal parameter combination reaches a preset threshold.
9. The method for learning turning control parameters of an unmanned surface vessel as described in any one of claims 1 to 8, characterized in that, It also includes verifying the combination of turning control parameters, the verification including: High-fidelity simulation verification: The combination of the turning control parameters is input into the unmanned surface vessel turning simulation platform to verify the turning performance indicators under different sea conditions and turning mission scenarios; Real-ship test verification: Under safe and controllable conditions, the combination of the turning control parameters is deployed to the actual turning control system of the unmanned surface vessel and a real-ship turning test is conducted for verification. Parameter deployment and application: The optimal combination of turning control parameters is used as recommended parameters for the turning maneuver of the unmanned surface vessel, or as the initial parameters for the adaptive turning control system.
10. A learning device for unmanned surface vessel turning control parameters, characterized in that, include: The acquisition module is used to acquire sample data for the turning control of the unmanned surface vessel, the sample data including turning control parameters; The module is used to build a BP neural network model, form a sample set based on the sample data of the unmanned surface vessel turning control and divide it into a training set and a validation set, and build the turning comprehensive performance index based on the sample data of the unmanned surface vessel turning control. The turning comprehensive performance index includes turning time, turning trajectory error and safety penalty item. The network architecture of the BP neural network model is constructed to establish the mapping relationship between the turning control parameters and the comprehensive turning performance index; at the same time, the turning control parameter space is characterized by the legal value range of the turning control parameters. The training module is used to configure the training strategy for the BP neural network model based on the training set and complete the training, and to monitor the loss function of the model during the training process through the validation set until the training termination condition is met. An improved genetic algorithm module is used to employ an improved genetic algorithm, using the trained BP neural network model as a surrogate model for turning performance. Based on the surrogate model's prediction results of the comprehensive turning performance index within the turning control parameter space, the module searches for the optimal combination of turning control parameters in the turning control parameter space to achieve the best comprehensive turning performance index.