Inland ship route optimization method based on AIS data
Through the combination of MPDP, OPTICS and NSGA-II algorithms, the ship routes in AIS data are optimized, the problems of redundancy and error data are solved, and the planning efficiency and accuracy of inland routes are significantly improved.
Patent Information
- Application Number
- CN202411161868.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-08-23
- Publication Date
- 2024-11-26
AI Technical Summary
The ship navigation data generated by the AIS system contains a large amount of redundant and error information due to equipment and environmental factors, which is difficult to effectively store and analyze, affecting the accuracy and efficiency of route planning.
The MPDP algorithm is used to compress the AIS data trajectory, and the OPTICS algorithm is used to extract meaningful waypoints, and cluster connectivity is judged through the A* algorithm. Finally, the path optimization is used to form an optimized route.
It effectively reduces the path length and congestion, improves the efficiency of route planning, optimizes the path length by 1.74% and the congestion by 17.31%, providing scientific basis for shipping management and optimization.
Smart Images

Figure CN119026777A_ABST
Abstract
Description
Technical Field
[0001] The invention belongs to the technical field of inland river ship route planning, and in particular relates to an inland river ship route optimization method based on AIS (Automatic Identification System, ship automatic identification system) data. Background Art
[0002] In recent years, the computational science of ship routes has become a frontier hot issue in the field of marine intelligence. Its core research content includes inputting the coordinates of the starting point, the coordinates of the end point and related parameters, and exploring and determining the "optimal" route through efficient intelligent optimization algorithms. This process not only requires the algorithm to have excellent computational efficiency and accuracy, but also takes into account the safety, economy and environmental sustainability of the route, and promotes the shipping industry to develop in a more intelligent and refined direction. The research on inland waterway route planning can be roughly divided into global route planning and local route planning. Global route planning covers a large range and ignores specific river information. By constructing an inland navigable network between ports, the path planning algorithm is used to plan the ports and waterways passed after inputting the starting point and the end point. The scope of local path planning is smaller, and it usually relies on electronic charts to consider obstacles and other non-navigable factors, and plans the route on the grid map through the path planning algorithm.
[0003] The AIS system is an automatic tracking system that provides identification and positioning services for ships by exchanging data with shore stations, nearby ships, satellites and other communication facilities. Although the AIS system was originally designed for radar identification and vessel traffic services (VTS), researchers are now able to collect and store AIS data generated in a specific water area over a certain period of time. These data have become an important source of big data for analyzing the navigation behavior of ships in that water area, providing a valuable resource for shipping management and optimization. However, the AIS system was originally designed to assist in the communication of vessel traffic services, so its use has brought many challenges to scientific research. One of the most representative issues is how to store and analyze these data. The AIS system transmits information every 2 to 12 seconds when the ship is moving, and every 6 minutes in semi-static and static states. In other words, the update frequency of AIS data is sometimes higher than the frequency of changes in the speed, position and heading of the ship during navigation. AIS data is affected by many factors during transmission and may contain invalid or erroneous information. The main factors include equipment problems, such as failures caused by long-term operation or lack of maintenance of signal sending and receiving equipment; environmental factors, such as poor signal communication caused by obstructions, bad weather or congested waterways; and data fusion problems, that is, format mismatches or parsing errors that may occur during the fusion process of data collected by different monitoring devices. Therefore, the original AIS data contains a lot of redundant information, which is not conducive to subsequent research and calculations. Summary of the invention
[0004] The purpose of the embodiment of the present invention is to provide an inland river vessel route optimization method based on AIS data, aiming to solve the problems raised in the above background technology.
[0005] The embodiment of the present invention is implemented as follows: a method for optimizing inland river vessel routes based on AIS data, comprising the following steps:
[0006] Step 1: AIS data preprocessing;
[0007] Step 2: Apply MPDP (Multi-Objective Peak Douglas-Peucker) algorithm to compress AIS data trajectory;
[0008] Step 3: Apply the OPTICS (Ordering Points To Identify the Clustering Structure) algorithm to the compressed data to extract meaningful waypoints;
[0009] Step 4: After obtaining the clustering results, use the A* algorithm to determine the connectivity of the clusters, retain the connected clusters, and use the NSGA-II (Non-dominated Sorting Genetic Algorithms II) algorithm for path optimization.
[0010] An embodiment of the present invention provides an inland ship route optimization method based on AIS data. First, the AIS data of ships in inland waters is obtained, and the MPDP algorithm is applied to compress the track data. Subsequently, the OPTICS algorithm is used to perform cluster analysis on the compressed waypoints. For the clustering results, the A* algorithm is used to judge the connectivity between clusters, and finally NSGA-II is used to select appropriate waypoints in the connected clusters. The optimization objectives include path length and route congestion to form an optimized complete route. Simulation experiments were carried out based on ship data in the waters near Shuangshan Island. The experimental results show that compared with the three classic routes in the original route, this method optimizes the path length by 1.74% and the congestion by 17.31%, effectively improving the planning efficiency of inland ship routes and providing a scientific basis and technical support for inland shipping. BRIEF DESCRIPTION OF THE DRAWINGS
[0011] Figure 1 A flowchart of a method for optimizing inland river vessel routes based on AIS data provided by an embodiment of the present invention;
[0012] Figure 2 Schematic diagram of trajectory compression of the traditional DP (Douglas-Peucker) algorithm;
[0013] Figure 3 It is the pseudo code of DP algorithm;
[0014] Figure 4 This is part of the pseudo code for the MPDP algorithm;
[0015] Figure 5 This is another part of the pseudo code for the MPDP algorithm;
[0016] Figure 6 Pseudo code for the OPTICS algorithm;
[0017] Figure 7 Process diagram of path optimization for NSGA-II algorithm;
[0018] Figure 8 For inland waterway maps using the grid method;
[0019] Fig. 9 is the processed AIS data;
[0020] Fig.10 is the pre-processed AIS trajectory;
[0021] Fig.11 Compression results for DP and MPDP trajectories;
[0022] Fig.12 is the change of critical distance;
[0023] Fig.13 To compress the heading angle and speed comparison;
[0024] Fig.14 This is the compression effect using the DP algorithm;
[0025] Fig.15 This is the compression effect of using the MPDP algorithm;
[0026] Fig.16 The reachable distance diagram obtained by the OPTICS algorithm (a is the reachable distance distribution of each point; b is the cluster classified according to the threshold of 27, where red is the noise point; c is the classified result);
[0027] Fig.17 This is the clustering result of DBSCAN algorithm in the waters near Shuangshan Island;
[0028] Fig.18 This is the clustering result of OPTICS algorithm in the waters near Shuangshan Island;
[0029] Fig.19 To optimize the Pareto solution distribution of routes;
[0030] Fig. 20The optimized route and Pareto frontier route obtained using the NSGA-II algorithm;
[0031] Fig.21 It is the original AIS track chart;
[0032] Fig. 22 The optimized route. DETAILED DESCRIPTION
[0033] In order to make the purpose, technical solution and advantages of the present invention more clearly understood, the present invention is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present invention and are not intended to limit the present invention.
[0034] The specific implementation of the present invention is described in detail below in conjunction with specific embodiments.
[0035] like Figure 1 As shown, a method for optimizing inland river vessel routes based on AIS data is provided in one embodiment of the present invention, comprising the following steps:
[0036] Step 1: AIS data preprocessing:
[0037] First, obtain the raw AIS data stream from the AIS device or base station. This data is usually transmitted in NMEA (NationalMarine Electronics Association) format and contains information such as the ship's position, speed, and heading. Remove possible duplicate data, invalid data, or erroneous data. This includes detecting and repairing missing values, outliers, and inconsistent data in the data.
[0038] Step 2: AIS data trajectory compression:
[0039] After acquiring the AIS data, the MPDP algorithm is used to compress the AIS trajectory data, effectively reducing redundancy and improving processing efficiency for subsequent clustering.
[0040] 2.1 Classical DP Algorithm
[0041] DP algorithm is one of the most widely used compression algorithms. The main task of this algorithm is to extract the original trajectory point set OS = {P1, ...P i ,...P N} to extract the key trajectory point set KS = {K1,...K j ,...K M}. The DP algorithm compression steps are as follows:
[0042] First, set the compression threshold ε (ε>0), add the starting point and end point of the original trajectory point set OS to the key trajectory point KS. Then divide OS into M-1 subsets, and set two adjacent points K j To K j+1 The corresponding OS subset is OS_Sub j , with K j To K j+1 The line segment between is the baseline and OS_Sub is calculated. j The distance set DS from each point to the baseline. Finally, record the maximum value d in DS max Corresponding index Index, if d max ≥ε, then OS_Sub j [Index] Add the key track point set KS and repeat the above process until the compression is completed. The algorithm compression process is as follows: Figure 2 As shown, the pseudo code is as follows Figure 3 shown.
[0043] 2.2MPDP Algorithm
[0044] The traditional DP algorithm only selects the farthest point as the split point for each layer of compression, decomposes the route chain and continues to compress. However, the farthest point is not the point with the largest turning degree, which is not ideal for the winding inland waterway. Therefore, a multi-peak retention strategy is used to find the maximum point in the distance set DS to form an extreme point set ES. The points in ES are compared with the threshold ε one by one. If it is greater than ε, it is stored in the set KS. This method can reduce the number of compression layers, thereby reducing the number of traversals.
[0045] In order to prevent too many track points from being retained, a peak number threshold Th_n is set. When the number of extreme point sets ES is greater than Th_n, the peaks are obtained again for the points in ES, and the threshold Th_n maximum value points with the largest changes in the extreme point set ES are retained. In the early stage of the compression process, there are many peaks in the distance set DS. In the later stage of the compression process, due to the decomposition into small segments, the maximum value in DS is consistent with the maximum value point. Therefore, the compression layer threshold Th_l is set. When the compression layer is less than Th_l, multiple track points are retained, otherwise only one track point is retained.
[0046] In addition, during the navigation process of the ship, the change of the ship speed has a certain impact on the restoration of the ship track, but the DP algorithm does not take this into account. Therefore, the MPDP algorithm uses a fitness function instead of the distance from the point to the baseline. The fitness function includes the distance from the point to the straight line, the heading change rate, and the speed change rate, as shown in the following formula:
[0047] fitness=α×d+β×η+γ×ν (1)
[0048] α+β+γ=1 (2)
[0049] Where d, η and ν are the normalized straight line distance, heading change rate and speed change rate, respectively, and α, β and γ are the corresponding coefficients.
[0050] In addition, MPDP has an obstacle detection mechanism: when it is detected that the line connecting two points KS(i) and KS(i+1) in KS passes through an obstacle, the original trajectory will be compressed again with KS(i) and KS(i+1) as endpoints, retaining the key nodes until the restored trajectory successfully passes the obstacle.
[0051] Finally, when the ship is in a round trip motion, the coordinates of the track points at different times will overlap. At this time, when the DP algorithm is compressed, the baseline length is infinitely close to 0, and the point-to-baseline distance solution is invalid. Therefore, a position overlap judgment mechanism is added: when the coordinates of two points are the same, the point-to-straight-line distance calculation is changed to the point-to-point distance calculation, as shown in the following formula, which ensures the correctness of the algorithm without changing the algorithm principle.
[0052]
[0053] In the formula, x extrem With y extrem is the horizontal and vertical coordinates of the extreme point, x base With y base are the horizontal and vertical coordinates of the two coincident base points. The pseudo code of the MPDP algorithm is as follows Figure 4 and Figure 5 shown.
[0054] Step 3: Apply the OPTICS algorithm to the compressed data to extract meaningful waypoints, thereby improving the accuracy of subsequent path planning. The pseudo code of the OPTICS algorithm is as follows: Figure 6 As shown, the operation steps are as follows:
[0055] The following key concepts are involved:
[0056] Neighborhood distance (ε OPTICS ): In the OPTICS algorithm, it is used to define the radius of the neighborhood range of a data point. All data points within this radius are considered to be members of the neighborhood of the point, and are therefore used to evaluate the local density characteristics of the point.
[0057] Core distance (Core_Distance): Core distance refers to the minimum radius distance of a data point that contains at least MinPts points in its neighborhood distance range. If the number of points in the neighborhood distance is less than MinPts, the core distance is undefined;
[0058] Reachable distance (RD): Reachable distance refers to the distance from a data point to its nearest core point, or the larger value of the core distance of the core point and the Euclidean distance between two points, as shown in Formula 4. It is used to measure the density accessibility of points in the clustering structure.
[0059] RD(q,p)=max(Core_Distance(p),Euclidean_Distance(q,p)) (4)
[0060] Step 1: First, initialize an empty ordered list to store the processed data points, and then initialize an empty priority queue to store the candidate points and their reachable distances;
[0061] Step 2: Select an unprocessed point p from the data set and calculate its core distance Core_Distance and reachable distance RD;
[0062] Step 3: Calculate the core distance of the selected point p;
[0063] Step 4: Mark point p as processed and add it to the ordered list, calculate the reachable distance RD of all unprocessed points in the neighborhood of p, and add these points and their reachable distance RD to the priority queue;
[0064] Step 5: Select the point q with the minimum reachable distance from the priority queue. If q has not been processed, calculate its core distance Core_Distance and reachable distance RD. Then mark point q as processed and add it to the ordered list. Update the reachable distances of all unprocessed points in the q domain again and add these points and their reachable distances to the priority queue. Repeat the above steps until all points in the dataset have been visited.
[0065] Step 4: After obtaining the clustering results, use the A* algorithm to determine the connectivity of the clusters, retain the connected clusters, and use the NSGA-II algorithm to perform path optimization. Figure 7 As shown. The optimization objectives include: shortest distance and lowest congestion, and the fitness function is shown as follows:
[0066]
[0067] In formula (5), N is the number of waypoints in the path, (x i ,y i ) is the coordinate of the i-th point in the path. In formula (6), t i is the timestamp of the i-th point in the path, C(t i ) is the timestamp t i The number of points in the lower cluster.
[0068] As a preferred embodiment of the present invention, in order to verify the effectiveness and feasibility of the algorithm, the section of the Yangtze River near Shuangshan Island (120.32878E~120.70191E; 31.98000N~32.09305N) was used as the experimental background, and the newly proposed route optimization algorithm was used for experiments, and three typical tracks in the original AIS track were selected for comparison. The algorithm was implemented and run on the following configuration computer (Windows 64bit with twelve cores (Intel(R)Core(TM)i7-12700F@2.10GHz) and 16GB of RAM) using MATLAB R2022a.
[0069] Step 1: AIS data preprocessing
[0070] In the process of processing AIS data, it is necessary to calculate the distance from a point to a straight line. However, the original AIS data ship coordinate information is established based on the geographic coordinate system. It is relatively complicated to directly calculate the distance between two points on the sphere and the distance from a point to a straight line. In order to facilitate data calculation, the trajectory points are Converted to Mercator projection coordinates P′(x,y), the conversion process is as follows:
[0071] x Merca =r0×λ(7)
[0072] y Merca =r0×q iso (8)
[0073]
[0074] where λ and Respectively represent the latitude and longitude of the track point, x Merca and Merca Respectively represent the horizontal and vertical coordinates of the track point; represents the standard latitude in the Mercator projection; l represents the major radius of the earth ellipsoid; e represents the first eccentricity of the earth ellipsoid; r0 represents the radius of the circle parallel to the standard latitude; q iso Indicates isometric latitude.
[0075] The grid method is used for modeling. The map is divided into grids of the same size according to the ground resolution, and the information is converted into binary information according to the environmental characteristics in the grid. The calculation formula for the ground resolution is:
[0076]
[0077] Where Level is the zoom level; is the latitude; R0 is the equatorial radius, and the value is R0 = 6378140 (m); the electronic chart with zoom level Level = 13 is selected, and the resolution is 19.1093 (m). The electronic chart and the map after raster binarization are as follows Figure 8 shown.
[0078] AIS data is affected by many factors during transmission and may contain invalid or erroneous information. The main factors include equipment problems, such as failures caused by long-term operation or lack of maintenance of signal sending and receiving equipment; environmental factors, such as poor signal communication caused by obstructions, bad weather or congested waterways. Therefore, before continuing to the next step of processing, it is necessary to clean up unreasonable data according to the reasonable data range of each field. Data preprocessing consists of the following parts:
[0079] (1) First, obtain the original AIS data stream from the AIS device or base station. This data is usually transmitted in NMEA format and contains information such as the ship's position, speed, and heading;
[0080] (2) Parse the cleaned data and convert the NMEA formatted data into structured data that can be analyzed and processed. This step usually involves segmenting the data into different fields and parsing out key information such as the ship’s MMSI (Maritime Mobile Service Identity), location, timestamp, etc. Fig. 9 As shown;
[0081] (3) Data filtering: Filter the parsed data as needed to select data from specific time periods, specific areas or specific types of ships. This helps reduce the amount of data and improve the efficiency of subsequent analysis;
[0082] (4) Data cleaning: Clean the data to remove possible duplicate data, invalid data, or erroneous data. This includes detecting and repairing missing values, outliers, and inconsistent data in the data.
[0083] Errors are divided into the following categories: (1) The length of the MMSI is not 9 digits or is unreasonable; (2) The longitude is less than 0° or greater than 180°, and the latitude is less than 0° or greater than 90°; (3) The ship's heading or speed exceeds the reasonable range (for example, the heading is greater than 360° or the speed is less than 0kn). In addition, incomplete tracks with less than 20 track points will also be eliminated. Here, the 5-hour AIS data in the waters of Shuangshan Island in the Yangtze River system is preprocessed, which contains 656 navigation tracks and a total of 145,359 track points. The final AIS data is as follows: Fig.10 shown.
[0084] Step 2: MPDP trajectory compression algorithm experiment
[0085] The compression ratio R will be usedc , length loss rate R l , Synchronous Euclidean distance D SE , average speed deviation R v The average deviation from the heading R θ Five performance indicators are used to measure the compression effect. The definitions of each indicator are as follows:
[0086] Definition 1: Compression ratio R c , the ratio of the number of trajectory points discarded during compression to the number of original trajectory points is as follows:
[0087]
[0088] Among them, n c is the number of omitted track points for each ship, and N is the total number of original track points for each ship.
[0089] Definition 2: Length loss rate R l , the ratio of the difference between the original trajectory length and the waypoint recovery length after compression to the original trajectory length is as shown in the following formula:
[0090]
[0091] represents the distance between two adjacent points of the original trajectory, and M represents the number of trajectory points retained after compression for each ship. is the distance between two adjacent points of the compression trajectory.
[0092] Definition 3: Synchronous Euclidean distance D SE , let P i =(x i ,y i ,t i ) is a point in the original trajectory, K j =(x j ,y j ,t j ) and K j+1 =(x j+1 ,y j+1 ,t j+1 ) is the compression trajectory in the order of time at P j (t j ≤t i ≤t j+1 ) before and after. Let P i ′=(x′ i ,y′ i ,t i ) is the restored track point, expressed as follows:
[0093]
[0094] Set distance The recovery point P i ′ and the original point P i The distance between them. Synchronous Euclidean distance D SE It is the average distance between the original trajectory and the restored trajectory, which is often used to reflect the compression effect and is expressed as follows:
[0095]
[0096] Definition 4: Average speed deviation R v , used to reflect the restored track point P i ′ and the original track point P i The average speed difference between the two ships is expressed as follows:
[0097]
[0098] Among them, v i Indicates that the ship travels to the track point P i The velocity at v' i Indicates that the ship travels to the restoration trajectory point P' i The speed at v j Indicates that the ship travels to the key trajectory point K j The speed at which the
[0099] Definition 5: Average heading deviation R θ The route recovery rate is used to reflect the recovery point P i ′ and the original point P i The average speed difference between the two ships is as follows:
[0100]
[0101] Among them, θ i Indicates that the ship travels to the track point P i The heading angle at θ′ i Indicates that the ship travels to the restoration trajectory point P i ′. (x′ i ,y′ i ) and (x′ j+1 ,y′ j+1 ) represent the restored trajectory points P i ′ and P′ i+1 The coordinates of the location.
[0102] In order to verify the effectiveness of the algorithm, a track in the waters near Shuangshan Island in the Yangtze River system was selected for a compression comparison experiment between the MPDP algorithm and the DP algorithm. The algorithm parameter settings are shown in Table 1 below:
[0103] Table 1 Algorithm parameter settings
[0104]
[0105] The DP and MPDP trajectory compression results are as follows Fig.11 As shown in the figure, the critical distance changes as Fig.12 As shown in the figure, the compression heading angle and speed are compared. Fig.13 The compression trajectory results are shown in Table 2 below:
[0106] Table 2 Compressed trajectory results
[0107]
[0108] The MPDP algorithm reduces the compression rate by 5.27% compared to the DP algorithm. Fig.12 It can be seen that the MPDP algorithm retains 7 more track points than the DP algorithm, and the length loss rate R l Reduced by 0.04%, an improvement of 26.67% year-on-year. Synchronous Euclidean distance D SE It was reduced by 82.6876m, an improvement of 50.16% year-on-year. The average heading deviation R θ It has been reduced by 0.0104, an improvement of 23.53% year-on-year. v Reduced by 0.0886kn, optimized by about 10.86%.
[0109] The above experimental results show that there are only slight differences between the MPDP algorithm and the DP algorithm in terms of compression rate and length loss rate, and the retained track points have a good average heading deviation R θ There is a small improvement in performance, but the synchronization of Euclidean distance D SE and the average speed deviation R v In both aspects, the optimization effect of the MPDP algorithm is significantly improved, and the addition of an obstacle detection mechanism fully ensures the connectivity of the route.
[0110] Next, the DP and MPDP algorithms were used to perform compression experiments on the 5-hour AIS in the waters near Shuangshan Island. The experimental results are as follows: Fig.14 and 15 shown.
[0111] The average compression ratio R using the MPDP algorithm c The average length loss rate R l The average synchronous Euclidean distance D SE Reduced by 11.5922m, approximately 25.70% optimization. Average heading deviation R θ Reduced by 0.0133 rad, about 11.73% optimization. Average speed deviation R v The reduction is 0.059 kn, which is about 25.13% of the optimization. The experimental results are shown in Table 3:
[0112] Table 3 Compression index of Shuangshan Island ship trajectories
[0113]
[0114] Step 3: Track point clustering experiment based on OPTICS algorithm
[0115] After obtaining the key track points, the DBSCAN algorithm and the OPTICS algorithm were used to cluster the water area data. The DBSCAN algorithm compressed 46 clusters, and the OPTICS algorithm obtained 111 clusters. The reachable distance diagram obtained by the OPTICS algorithm is shown in the figure below. Fig.16 As shown in a.
[0116] After obtaining the reachable distance graph, it is easy to understand the density and structure of the data set. The low-value area (valley) in the reachable distance graph indicates the dense area of data points. The larger the horizontal axis range of the low-value area, the larger the cluster and the more points in the cluster. The high-value area (peak) indicates the sparsity. The higher the peak value, the sparser the area. In this paper, the neighborhood distance threshold is set to 27, and we get Fig.16 b Experimental results, where red is the noise point whose reachable distance is greater than the threshold. The final classification results are as follows Fig.16 c, where different colors represent different clusters. The final clustering result of AIS data in the waters near Shuangshan Island in the Yangtze River system is as follows: Fig.17 and 18 shown.
[0117] from Fig.18 It can be observed that compared with Fig.17 In the clustering results of the DBSCAN algorithm, the clusters obtained by the OPTICS algorithm are more numerous and detailed, including some key waypoint clusters, such as the tributaries of the waterway in the lower left corner, while the DBSCAN algorithm loses this information, which will be detrimental to the subsequent judgment and optimization of path connectivity.
[0118] Step 4: Route planning experiment based on A* algorithm and NSGA-II algorithm
[0119] Using the shortest flight distance and minimum congestion as optimization objectives, the A* algorithm and NSGA-II algorithm are used to search and optimize the route of the waypoint clusters after OPTICS algorithm clustering. First, the A* algorithm is used to determine the connectivity between each waypoint cluster, and then the NSGA-II algorithm is used to select the optimal waypoint in the connected waypoint cluster. The solution distribution is as follows: Fig.19 shown.
[0120] Fig. 20 a is the experimental result obtained after the last iteration of NSGA-II, Fig. 20b is the path corresponding to the Pareto frontier solution. To verify the feasibility of the algorithm, three typical tracks were selected from the historical AIS data of the Yangtze River system. The real route information was input, as shown in Table 4, and compared with the optimized route. Fig.21 and 22 The experimental results are shown.
[0121] Table 4 Original data of route planning experiment
[0122]
[0123] The route planning experiment results are shown in Table 5. Fig. 20 It can be seen that the Pareto front solution does not include the route along the Northern Sea Route, because the route is not only long but also crowded. Here, the solution that is not on the non-dominated front is selected for comparison with the original track. It can be seen that the optimized route saves many unnecessary turning points, the total route length is reduced by 2.564km, an optimization of 1.74%, and the congestion is reduced by 0.2448, an optimization of 17.31%.
[0124] Table 5 Route planning experimental results
[0125]
[0126] In summary, this method combines the MPDP compression algorithm, OPTICS clustering algorithm, A* algorithm and NSGA-II multi-objective optimization algorithm. Through the route planning experiment in the waters near Shuangshan Island in the Yangtze River system, it is verified that this method significantly improves the efficiency of path planning, reduces the path length and route congestion. Specifically, the MPDP algorithm effectively compresses the AIS trajectory data compared with the DP algorithm, optimizes the length loss rate by 26.67%, optimizes the synchronous Euclidean distance by 50.16%, optimizes the average heading deviation and the average speed deviation by 23.53% and 10.86% respectively, and improves the data processing efficiency; the OPTICS algorithm accurately identifies waypoint clusters in an uneven density environment, especially the key waypoint clusters ignored by the DBSCAN algorithm, which is crucial for subsequent path optimization; the A* algorithm ensures the connectivity between clusters; the NSGA-II algorithm provides the optimal route under multi-objective optimization. The innovation of this method lies in the organic combination of these four algorithms to form a comprehensive inland ship route optimization method. This combination not only makes full use of the advantages of each algorithm, but also overcomes the limitations of a single algorithm in path planning. For example, the MPDP algorithm improves data compression and processing efficiency, the OPTICS algorithm can accurately cluster in an environment with uneven density, the A* algorithm ensures the connectivity of the path, and the NSGA-II algorithm provides the optimal solution under multi-objective optimization. It is this combination that makes this method significantly improve the efficiency and accuracy of multi-objective path planning.
[0127] The experimental results show that the path lengths of the three typical routes are optimized by 3.25%, 1.67%, and 0.24% respectively, the total path length optimization rate of the three typical routes is 1.74%, and the congestion is optimized by 17.31%. These results show the potential and effect of this method in practical applications, and provide a scientific path planning basis and technical support for inland waterway shipping.
[0128] The above description is only a preferred embodiment of the present invention and is not intended to limit the present invention. Any modifications, equivalent substitutions and improvements made within the spirit and principles of the present invention should be included in the protection scope of the present invention.
Claims
1. A method for optimizing inland river ship routes based on AIS data, characterized in that: The following steps are involved: Step 1: AIS data preprocessing: First, the original AIS data stream is obtained from the AIS device or base station, and duplicate data, invalid data or erroneous data is removed; Step 2: AIS data trajectory compression: After obtaining the AIS data, the MPDP algorithm is used to compress the AIS trajectory data; Step 3: Apply the OPTICS algorithm to the compressed data to extract meaningful waypoints; Step 4: After obtaining the clustering results, use the A* algorithm to determine the connectivity of the clusters, retain the connected clusters, and use the NSGA-II algorithm to optimize the path; The optimization objectives include: shortest distance and lowest congestion. The fitness function is shown as follows: In formula (1), N path is the number of waypoints in the path, (x i ,y i ) is the coordinate of the i-th point in the path; in formula (2), t i is the timestamp of the i-th point in the path, C(t i ) is the timestamp t i The number of points in the lower cluster.
2. The inland river vessel route optimization method based on AIS data according to claim 1 is characterized in that: In step 1, data preprocessing includes the following steps: Step 1.1, first obtain the original AIS data stream from the AIS device or base station; this data is transmitted in NMEA format and contains the ship's position, speed, and heading information; Step 1.2, data cleaning: Clean the data to remove possible duplicate data, invalid data or erroneous data; specifically, detect and repair missing values, outliers and inconsistent data in the data; Step 1.3: Parse the cleaned data and convert the NMEA format data into structured data that can be analyzed and processed; Step 1.4, data filtering: Filter the parsed data to select ship data of a specific time period, specific area or specific type.
3. The inland river vessel route optimization method based on AIS data according to claim 2 is characterized in that: In step 2, a multi-peak retention strategy is used to find the maximum point in the distance set DS to form an extreme point set ES, and the points in ES are compared with the threshold ε one by one. If the value is greater than ε, it is stored in the set KS; In order to prevent retaining too many track points, a peak value threshold Th_n is set. When the number of extreme value points in the searched extreme value set ES is greater than Th_n, the peak value of the points in ES is calculated again, and the threshold Th_n maximum value points with the largest change in the extreme value point set ES are retained; In the early stage of the compression process, there are many peaks in the distance set DS. In the later stage of the compression process, due to the decomposition into small segments, the maximum value in DS coincides with the maximum value point. Therefore, the compression layer threshold Th_l is set. When the compression layer is less than Th_l, multiple track points are retained, otherwise only one track point is retained. In addition, the MPDP algorithm uses a fitness function instead of the distance from the point to the line. The fitness function includes the distance from the point to the line, the heading change rate, and the speed change rate, as shown in the following formula: fitness=α×d+β×η+γ×ν (3) α+β+γ=1(4) Where d, η and ν are the normalized distance from the point to the line, the heading change rate and the speed change rate, respectively, and α, β and γ are the corresponding coefficients; In addition, MPDP has an obstacle detection mechanism: when it is detected that the line connecting two points KS(i) and KS(i+1) in KS passes through an obstacle, the original trajectory will be compressed again with KS(i) and KS(i+1) as endpoints, and the key nodes will be retained until the restored trajectory successfully passes the obstacle; At the same time, MPDP also has a position coincidence judgment mechanism: when the coordinates of two points are the same, the calculation of the point-to-line distance is changed to the point-to-point distance calculation, as shown in the following formula, which ensures the correctness of the algorithm without changing the algorithm principle: In the formula, x extrem With y extrem is the horizontal and vertical coordinates of the extreme point, x base With y base are the horizontal and vertical coordinates of two coincident base points.
4. The inland river vessel route optimization method based on AIS data according to claim 3 is characterized in that: In step 3, the operation steps of the OPTICS algorithm are as follows: The following key concepts are involved: Neighborhood distance (ε OPTICS ): In the OPTICS algorithm, it is used to define the radius of the neighborhood range of a data point. All data points within this radius are considered to be members of the neighborhood of the point, and are therefore used to evaluate the local density characteristics of the point. Core distance (Core_Distance): Core distance refers to the minimum radius distance of a data point that contains at least MinPts points in its neighborhood distance range. If the number of points in the neighborhood distance is less than MinPts, the core distance is undefined; Reachable distance (RD): Reachable distance refers to the distance from a data point to its nearest core point, or the larger value of the core distance of the core point and the Euclidean distance between two points, as shown in Formula 6. It is used to measure the density reachability of points in the clustering structure. RD(q,p)=max(Core_Distance(p),Euclidean_Distance(q,p)) (6) Step 1: First, initialize an empty ordered list to store the processed data points, and then initialize an empty priority queue to store the candidate points and their reachable distances; Step 2: Select an unprocessed point p from the data set and calculate its core distance Core_Distance and reachable distance RD; Step 3: Calculate the core distance of the selected point p; Step 4: Mark point p as processed and add it to the ordered list, calculate the reachable distances RD of all unprocessed points in the neighborhood of p, and add these points and their reachable distances RD to the priority queue; Step 5: Select the point q with the minimum reachable distance from the priority queue. If q has not been processed, calculate its core distance Core_Distance and reachable distance RD. Then mark point q as processed and add it to the ordered list. Update the reachable distances of all unprocessed points in the area of point q again, and add these points and their reachable distances to the priority queue. Repeat the above steps until all points in the data set have been visited.
5. The inland river vessel route optimization method based on AIS data according to claim 2 is characterized in that: In step 1, the distance from the point to the straight line needs to be calculated during the processing of the AIS data. However, the original AIS data ship coordinate information is established based on the geographic coordinate system. In order to facilitate the calculation of the data, the track point Convert to Mercator projection coordinates P′(x,y), the conversion process is as follows: x Merca =r0×λ (7) and Merca =r0×q iso (8) where λ and Respectively represent the latitude and longitude of the track point, x Merca and Merca They represent the horizontal and vertical coordinates of the track point after Mercator projection conversion; represents the standard latitude in the Mercator projection; l represents the major radius of the earth ellipsoid; e represents the first eccentricity of the earth ellipsoid; r0 represents the radius of the circle parallel to the standard latitude; q iso Indicates isometric latitude; The grid method is used for modeling. The map is divided into grids of the same size according to the ground resolution, and the information is converted into binary information according to the environmental characteristics in the grid. The calculation formula of the ground resolution is: Where Level is the zoom level; is the latitude; R0 is the equatorial radius.
Citation Information
Cited By
Rapid simplification method for ship wandering AIS track
CN119829691A
