Crossing water area ship encounter characteristic value extraction method based on AIS data

CN117392881BActive Publication Date: 2026-09-25SHANGHAI MARITIME UNIVERSITY
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202311322718.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-10-12
Publication Date
2026-09-25
Estimated Expiration
2043-10-12

AI Technical Summary

Technical Problem

[0004]但现有技术中,由于难以确定出交叉水域内船舶会遇局面特征值,导致无法准确获知交叉水域内船舶的紧迫程度,不利于推进船舶完全自主航行研究

Benefits of technology

[0048]一、本发明提出一种基于AIS数据的交叉水域船舶会遇特征值提取方法,首先选定研究区域并创建航道坐标系;之后获取AIS数据并清洗数据;进行船舶经纬度坐标转换并建立坐标系;数据插值处理;计算周围目标船与选定本船之间的方位角;由方位角筛选本船周围目标船舶的MMSI;确认每个方位内最近目标船舶与本船所形成的局面;绘制本船周围目标船舶的Space-Time图以及Course-Time图;分析图示转折点并收集转折点数据、找到船舶间间距阈值区间;通过阈值区间分析该区域船舶紧迫程度。由此实现通过分析利用大量AIS数据,以提取出数据中具有价值的各种动、静态信息,能够在某一区域历史AIS数据中挖掘出各种船舶行为的风险度,进而整体分析选定区域的风险度,从而为船舶安全航行、密集区域内船舶管理提供了新的依据,对降低船舶碰撞风险具有强有力的实践意义。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117392881B_ABST
    Figure CN117392881B_ABST
Patent Text Reader

Abstract

The application relates to a kind of crossing water area ship encounter characteristic value extraction methods based on AIS data, comprising: selecting research area and creating channel coordinate system;AIS data is obtained and cleaned;The latitude and longitude coordinates of ship are converted, and the relative position coordinate system of ship is established;After cleaning, AIS data is interpolated, and the azimuth between the target ship around the ship and the ship is calculated;The MMSI of the target ship around the ship is screened out from the azimuth;The situation formed by the nearest target ship in each direction and the ship is determined;The Space-Time diagram and Course-Time diagram of the target ship around the ship are drawn, and the turning point data is obtained from the diagram to determine the ship distance threshold interval;The urgency of the selected area is obtained by threshold interval analysis.Compared with the prior art, the application excavates the risk degree of various ship behaviors from AIS data, and analyzes the risk degree of the selected area as a whole, which can provide data support for ship safety navigation and ship management in dense areas, and has important significance for reducing ship collision risk.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of intelligent ship technology, and in particular to a method for extracting the feature values ​​of ship encounters in cross-waterways based on AIS data. Background Technology

[0002] With the increasing number of ships at sea and the growing complexity of traffic, the probability of ship safety accidents is also rising. Furthermore, as ships become increasingly intelligent, intelligent navigation is a crucial component in achieving this intelligence, but research results have not yet yielded significant progress, and ships are still unable to achieve fully autonomous navigation.

[0003] Crossing waters have always been a key and challenging area for autonomous navigation of ships. In order to ensure the safety of ship navigation, it is necessary to know the urgency of ships in crossing waters in advance, so as to facilitate early intervention in ship traffic in complex waters, prevent safety accidents, and provide convenience for maritime safety management.

[0004] However, in the existing technology, it is difficult to determine the characteristic values ​​of the situation that ships will encounter in the intersecting waters, which makes it impossible to accurately know the urgency of ships in the intersecting waters, which is not conducive to promoting the research on fully autonomous navigation of ships. Summary of the Invention

[0005] The purpose of this invention is to overcome the shortcomings of the existing technology and provide a method for extracting the feature values ​​of ship encounters in cross waters based on AIS data. This method can extract the risk level of various ship behaviors from AIS data and then analyze the overall risk level of cross waters.

[0006] The objective of this invention can be achieved through the following technical solution: a method for extracting feature values ​​of vessel encounters in intersecting waters based on AIS data, comprising the following steps:

[0007] S1. Select the study area and create a waterway coordinate system;

[0008] S2. Acquire AIS (Automatic Identification System) data and clean the data;

[0009] S3. Convert the ship's latitude and longitude coordinates and establish a relative position coordinate system for the ship;

[0010] S4. Perform interpolation on the cleaned AIS data, and then calculate the azimuth between the surrounding target ships and the selected ship.

[0011] S5. Filter out the MMSI (Maritime Mobile Service Identifier) ​​of target vessels around this vessel based on the azimuth angle;

[0012] S6. Determine the situation between the nearest target vessel and the ship in each bearing;

[0013] S7. Draw a Space-Time diagram and a Course-Time diagram of the target vessels around this vessel;

[0014] S8. Draw the turning points in the figure according to step S7, and obtain the turning point data to determine the threshold range of the distance between ships.

[0015] S9. The urgency level of ships in the selected area is obtained through threshold interval analysis.

[0016] Furthermore, the specific process of step S1 is as follows:

[0017] The study area was selected from waters where three types of vessel behavior—head-on encounter, overtaking, and crossing—existed simultaneously.

[0018] Then, a reference point for the waterway is selected, and a three-dimensional coordinate system is established for the waterway based on the reference point and the time series, with the waterway direction as the Y-axis, the perpendicularity to the waterway direction as the X-axis, and the time series as the Z-axis.

[0019] Furthermore, the data cleaning process in step S2 includes: removing duplicate data; filtering out data with less than 9 MMSI bits; and clearing ship data with fewer than 5 trajectory points.

[0020] Further, the specific process of step S3 is as follows: convert the latitude and longitude coordinates of the selected area into X and Y values, set the distance along the waterway as the Y value and the distance perpendicular to the waterway as the X value, establish a three-dimensional coordinate system with the waterway plane as the X-axis and Y-axis and the time series as the Z-axis, and use this coordinate system to reflect the relative position coordinates between ships.

[0021] Furthermore, the specific process of interpolating the cleaned AIS data in step S4 is as follows:

[0022] Cartesian coordinates, ship speed, and ship turning angle are extracted from the cleaned AIS data. The extracted data is then spatiotemporally synchronized to a set time scale. Cubic spline interpolation is used to interpolate the time series with the extracted data.

[0023] Furthermore, the specific process of calculating the azimuth angle between the surrounding target ships and the selected ship in step S4 is as follows: with the ship as the origin of the rectangular coordinate system, and with due east as 0°, a rectangular coordinate system is established in a counterclockwise direction;

[0024] Using the set R value as the radius, a circular area of ​​the ship is defined, and the ship's AIS data points within this circular area are filtered.

[0025] Iterate through all interpolated AIS data points except for the ship itself. If the x-value of a surrounding AIS data point is greater than the x-value of the ship itself, and its y-value is also greater than the y-value of the ship itself, then the AIS data point is determined to be in the first quadrant. If the x-value of a surrounding AIS data point is less than the x-value of the ship itself, and its y-value is greater than the y-value of the ship itself, then the AIS data point is determined to be in the second quadrant. And so on, calibrating which quadrant of the ship each AIS data point is located in.

[0026] Substitute the rectangular coordinates of the target ship and the target ship into the following formula to calculate the angle between the two ships. The final bearing of the target ship can then be determined by using the angle and quadrant sign:

[0027]

[0028] Where θ is the turning angle, X0 is the distance between the vessel and the reference point in the direction perpendicular to the channel, and X i Y0 is the distance between the target vessel and the reference point in the direction perpendicular to the channel, and Y0 is the distance between the current vessel and the reference point in the direction along the channel. i The distance between the target vessel and the reference point along the course.

[0029] Furthermore, the specific process of step S5 is as follows: based on the circular area selected with the ship as the center, the circular area is further divided into a sector of a set size;

[0030] Then, the data within each sector is traversed to calculate the Hausdorff distance between each ship and the ship within that sector:

[0031] H(Q,O)=max(h(Q,O),h(O,Q))

[0032] h(Q,O)=max(q∈Q)min(o∈O)‖qo‖

[0033] h(O,Q)=max(o∈O)min(q∈Q)‖qo‖

[0034]

[0035] Where Q = [q1, q2, q3, q4] is the coordinate set of the current ship, O = [o1, o2, o3, o4] is the coordinate set of the target ship, and q i (i = 1, 2, 3, 4) are the coordinates of the boundary points of this ship, o i(i = 1, 2, 3, 4) are the coordinates of the boundary points of the target ship, D is the Euclidean distance, H(Q, O) is the Hausdorff distance between the two ships, h(Q, O) is the minimum and maximum value of the distance from each point of the current ship set to each point of the target ship set, and ||qo|| is the Euclidean distance between the current ship and the target ship.

[0036] Identify the vessel with the shortest Hausdorff distance from your own vessel within each sector area and save its MMSI number, thereby obtaining the MMSI of multiple target vessels.

[0037] Furthermore, the specific process of step S6 is as follows:

[0038] First, establish a coordinate system with the ship as the origin and the ship's direction of travel as 0°, in a clockwise direction;

[0039] Calculate the deflection angles of the ship and the nearest vessel within the bearing. Use the deflection angles to correct the target vessel's heading angle in the Cartesian coordinate system. Based on the corrected angles, further correct the heading angles by setting the ship's sailing direction to 0°, so that the coordinate system can be dynamically established as the ship sails. At the same time, change the bearing angles of surrounding vessels. By comparing the coordinate system established by the ship with the bearing angles of the target vessel in the current coordinate system, determine the situation formed by the target vessel and the ship. Finally, save the data, including: the ship's MMSI, the target vessel's MMSI, the distance between the two vessels, and the situation between the two vessels.

[0040] Further, the specific process of step S7 is as follows: based on the MMSI of the ship and the MMSI of the nearest surrounding ship saved in step S6, extract data to calculate the Euclidean distance between the two ships at each time, and draw a Space-Time graph with the distance interval as the vertical axis and the time series as the horizontal axis.

[0041] Then, plot a Course-Time diagram with the heading angle of the target ship at each moment as the vertical axis and the time series as the horizontal axis.

[0042] Furthermore, the specific process of step S8 is as follows:

[0043] Based on the Space-Time and Course-Time diagrams drawn in step S7, obtain the distances between the nearest ships in each direction and extract the turning angles and data where the turning angle changes exceed the preset threshold at the corresponding time.

[0044] The critical intervals between urgent situations and urgent dangers are selected from the nearest ship distances in all directions. The critical intervals between risk-free and urgent situations are calculated from the distance between the two ships at the moment when the change in the turning angle is the largest.

[0045] Further, the specific process of step S9 is as follows: based on the two critical intervals obtained in step S8, filter the number of all records of the saved data, filter the data under each situation, and filter the number of data records under the situations of no risk, urgent situation, urgent danger, and collision danger by the boundaries of the two critical intervals respectively.

[0046] By analyzing the ratio of ships in urgent situations under various circumstances, it is possible to determine which situation in the region carries a risk higher than a preset risk threshold, thereby making an overall assessment of the urgency level of ships.

[0047] Compared with the prior art, the present invention has the following advantages:

[0048] I. This invention proposes a method for extracting vessel encounter feature values ​​in intersecting waterways based on AIS data. First, a study area is selected and a channel coordinate system is created. Then, AIS data is acquired and cleaned. Vessel latitude and longitude coordinates are transformed and a coordinate system is established. Data interpolation is performed. The bearing angles between surrounding target vessels and the selected vessel are calculated. The MMSI of surrounding target vessels is filtered based on the bearing angles. The situation formed by the nearest target vessel and the selected vessel in each bearing is confirmed. Space-Time and Course-Time maps of surrounding target vessels are drawn. Turning points in the maps are analyzed and turning point data is collected to find the threshold intervals for vessel spacing. The urgency of vessels in the area is analyzed using these threshold intervals. This method utilizes a large amount of AIS data to extract valuable dynamic and static information, enabling the mining of risk levels for various vessel behaviors from historical AIS data in a specific area. This allows for a comprehensive analysis of the risk level in the selected area, providing new evidence for safe navigation and vessel management in densely populated areas, and has strong practical significance for reducing the risk of vessel collisions.

[0049] II. This invention uses massive amounts of AIS data to determine and filter vessel encounter patterns in complex traffic flow intersections, categorizing them into three scenarios: crossing, encountering, and overtaking. Based on these scenarios, the minimum distance threshold between vessels under each scenario is further selected as a threshold for subsequent urgency classification. Furthermore, the Hausdorff method is used to calculate the minimum distance between vessels, incorporating hull contour coordinates for more accurate distance determination. This not only defines the characteristic values ​​of intelligent vessel behavior in intersecting waters but also provides quantitative evaluation indicators for the navigational hazard level in intersecting waters, indirectly serving the evaluation of maritime traffic management regulations (routing system). Attached Figure Description

[0050] Figure 1 This is a schematic diagram of the method flow of the present invention;

[0051] Figure 2 A diagram showing the screening of vessels around this ship;

[0052] Figure 3 A schematic diagram for calculating the distance between two ships;

[0053] Figure 4 This is a schematic diagram illustrating the time-series distance between surrounding target vessels and the vessel itself in the embodiment.

[0054] Figure 5 This is a time-series chart of the ship's course (413264640) and the target ship (413303620) in the example.

[0055] Figure 6 This is a time-series chart of the ship's course (413264640) and the target ship (413224230) in the example.

[0056] Figure 7 This is a 3D view of the ship in various situations as shown in the example;

[0057] Figure 8 The diagram shows the movement of the cross-situation in the x and y directions (within the same time period) in the example.

[0058] Figure 9 The diagram shows the movement of the situation in the x and y directions (within the same time period) in the example.

[0059] Figure 10 The following is a diagram showing the movement of the chase situation in the x and y directions (within the same time period) in the example.

[0060] Figure 11 The diagram shows the movement of the dry cargo ship and the port supply ship in the x and y directions (encounter situation) in the example.

[0061] Figure 12 The diagram shows the movement of the container ship and the workboat in the x and y directions (overtaking situation) in the example.

[0062] Figure 13 The diagram shows the movement of the chemical tanker and the dry cargo ship in the x and y directions (intersection). Detailed Implementation

[0063] The present invention will now be described in detail with reference to the accompanying drawings and specific embodiments.

[0064] Example

[0065] like Figure 1 As shown, a method for extracting feature values ​​of vessel encounters in cross-waterways based on AIS data includes the following steps:

[0066] S1. Select the study area and create a waterway coordinate system;

[0067] S2. Obtain AIS data and clean the data;

[0068] S3. Convert the ship's latitude and longitude coordinates and establish a relative position coordinate system for the ship;

[0069] S4. Perform interpolation on the cleaned AIS data, and then calculate the azimuth between the surrounding target ships and the selected ship.

[0070] S5. Filter out the MMSI of target vessels around this ship based on the azimuth angle;

[0071] S6. Determine the situation between the nearest target vessel and the ship in each bearing;

[0072] S7. Draw a Space-Time diagram and a Course-Time diagram of the target vessels around this vessel;

[0073] S8. Draw the turning points in the figure according to step S7, and obtain the turning point data to determine the threshold range of the distance between ships.

[0074] S9. The urgency level of ships in the selected area is obtained through threshold interval analysis.

[0075] Applying the above scheme to practice, when selecting the research area and establishing the waterway coordinate system, we select waters where three types of vessel behaviors—encountering, overtaking, and crossing—exist simultaneously, select waterway reference points, and establish a plane rectangular coordinate system.

[0076] When acquiring and cleaning AIS data, the main task is to remove duplicate data with the same MMSI and time from the AIS data, and extract data with attribute names of MMSI, Course, Speed, Lon, Lat, Width, Length, and Shiptype from the AIS data and form them into a new data table.

[0077] When converting ship latitude and longitude coordinates and establishing a coordinate system, the latitude and longitude coordinates of the selected area are converted into X and Y values. The distance along the waterway is defined as the Y value, and the distance perpendicular to the waterway as the X value. A three-dimensional coordinate system is established using the waterway plane as the X and Y axes and the time series as the Z axis. This coordinate system reflects the relative positions of ships, making it easier to observe the situation between them.

[0078] When interpolating the filtered data, the corresponding X and Y values, ship speed, ship turning angle, etc. are taken from the converted latitude and longitude data. The above data is then spatiotemporally synchronized to a specified time scale, which is set to 30 seconds in this embodiment. Using a 30-second interpolation interval can ensure the integrity of the track data while reducing data redundancy.

[0079] The cubic spline interpolation formula is introduced below:

[0080] The boundary conditions are:

[0081] S″′(x0)=S″′(x1) and S″′(x n-1 )=S″′(x n (1)

[0082] Input interpolation point a1 = x0 < x1 < x2 < ... < x n =a2, and its corresponding function values ​​are y0, y1, y2, ..., y n The interpolation point x is to be found * .

[0083] z j =x j+1 -x j (j=1,2,…,n-1) (2)

[0084]

[0085]

[0086] Solve the system of equations using the chasing method:

[0087]

[0088] Output the expression for S(x) for each interval, and determine x. * Find the interval and calculate the interpolation y. * Preserve interpolation;

[0089] In the above formula, S(x) is a spline function, S″′(x0) is the third derivative of the spline function at point x0 (the same applies below), and x i (i = 0, 1, 2…n) represents the output data that needs interpolation (the X value of the ship in a Cartesian coordinate system), y i (i = 0, 1, 2…n) is x i The corresponding function value (the Y-value of the ship in a rectangular coordinate system), z j (j = 1, 2, ..., n-1) represents two adjacent x i Interval difference, M i =S″(x i ) represents an undetermined parameter, β i γ i a i μ i (i = 1, 2, ..., n) are the parameters for solving the equation.

[0090] When calculating the azimuth between the target ships in the vicinity and the ship itself, first establish a rectangular coordinate system with the ship itself as the origin of the coordinate system, with due east as 0°, and in a counterclockwise direction;

[0091] With a fixed radius R, a circular area centered on the ship is defined, and the ship's AIS data points within this circular area are filtered.

[0092] Traverse all interpolated AIS data points except for the ship itself: if the x-value of a surrounding AIS data point is greater than the x-value of the ship itself, and the y-value is also greater than the y-value of the ship itself, then the AIS data point is determined to be in the first quadrant.

[0093] If the x-value of a surrounding AIS data point is less than the x-value of this ship and the y-value is greater than the y-value of this ship, then the AIS data point is determined to be in the second quadrant.

[0094] Similarly, all AIS data points are calibrated to determine which quadrant of the ship they belong to.

[0095] Substitute the rectangular coordinates of the ship and the target ship into formula (6) to obtain the angle between the target ship and the ship. The final bearing of the target ship can be determined by the angle and quadrant sign. Let the rectangular coordinates of the ship be (X0, Y0), and the rectangular coordinates of the target ship be (X...). i Y i The azimuth angle is calculated using the tangent function.

[0096]

[0097] Where θ is the turning angle; X0 is the distance between the vessel and the reference point in the direction perpendicular to the channel; X i Y0 is the distance between the target vessel and the reference point in the direction perpendicular to the channel; Y0 is the distance between the current vessel and the reference point in the direction along ... target vessel and the reference point in the direction perpendicular to the channel; Y0 is the distance between the current vessel and the reference point in the i The distance between the target vessel and the reference point along the course.

[0098] When filtering the MMSI of surrounding vessels based on azimuth, the circular area centered on the vessel is first divided into a fan of a set size.

[0099] Then, traverse the data within each sector area and use formula (7) to calculate the Hausdorff distance between each ship in the area and the ship itself.

[0100] Finally, save the MMSI of the nearest ship.

[0101] Follow the steps above to iterate through the data within each sector area. Determine the ship data within several bearings around the selected ship, take a maximum threshold value, use the ship as the center and the threshold value as the radius to initially define the surrounding ships, scan the entire circular area at a fixed azimuth angle, calculate the Euclidean distance between the ships in each area and the selected ship, solve for the MMSI and save it, repeat the above process until the defined area has been scanned.

[0102] Let the coordinates of our ship be Q = [q1, q2, q3, q4], and the coordinates of the target ship be O = [o1, o2, o3, o4]. Calculate the distance between the two ships using the following formula. Where q i (i = 1, 2, 3, 4) are the coordinates of the boundary points of this ship, o i (i = 1, 2, 3, 4) are the coordinates of the boundary points of the target ship.

[0103] H(Q,O)=max(h(Q,O),h(O,Q)) (7)

[0104] h(Q,O)=max(q∈Q)min(o∈O)‖qo‖

[0105] h(O,Q)=max(o∈O)min(q∈Q)‖qo‖

[0106]

[0107] Where D is the Euclidean distance, H(Q,O) is the Hausdorff distance between the two ships (i.e., the distance between the two ships); h(Q,O) is the minimum and maximum distance from each point in the current ship set to each point in the target ship set; and ||qo|| is the Euclidean distance between the current ship and the target ship.

[0108] When confirming the situation between the nearest target vessel and the vessel in each bearing, first establish a coordinate system with the vessel's sailing direction as 0° and clockwise.

[0109] The deflection angle between the ship and the nearest ship in the bearing is calculated by formula (6). The direction angle of the target ship in the rectangular coordinate system is corrected by the deflection angle. Based on the correction angle, the direction angle is corrected again by setting the ship's sailing direction to 0°. This allows the coordinate system to be dynamically established as the ship sails. At the same time, the bearing angle values ​​of the surrounding ships are changed. The situation formed by the target ship and the target ship is determined by the coordinate system established by the ship and the bearing angle of the target ship in the current coordinate system. Finally, the data is saved. The data includes: the MMSI of the ship, the MMSI of the target ship, the distance between the two ships, and the situation between the two ships.

[0110] When drawing the Space-Time and Course-Time diagrams of target vessels around the ship, the distance between the ship and the selected target vessels at the same moment is first calculated. The Space-Time diagram of the ships is drawn with the time series as the horizontal axis and the distance between the ships at the same moment as the vertical axis. The Course-Time diagram is drawn with the time series as the horizontal axis and the course of the target vessels as the vertical axis.

[0111] The inflection points obtained from the plotted diagram are then analyzed to find the threshold range of the distance between ships. First, the location data of the closest distance between the ship and the target ship within a set time period is saved (including information such as time, speed, rectangular coordinate point, heading, and bow direction). The location data of the ship and different target ships at various times are saved in the same way. Then, the location data values ​​are analyzed to obtain the threshold range of the ship. The closest threshold range under various situations in this area is analyzed in the same way.

[0112] Finally, the urgency of ships in the area was analyzed using threshold intervals. The nearest coordinate points were collected and filtered according to different ship situations. The ship position data under different situations were then further filtered to find the closest distance between two ships, and this minimum value was taken as the critical point between a urgency situation and a collision risk (which is generally unlikely). The position data with the largest turning radius was saved, and the closest and farthest distances among the ship position data under different situations were filtered out. The (min, max) interval was taken as the avoidance timing interval; that is, if avoidance action is not taken in time, a urgency or collision risk situation will arise. If the distance is greater than the farthest distance, there is no risk, and the ship can navigate normally without collision avoidance. Based on the above method, four situations were defined: no risk, urgency situation, urgency risk, and collision risk.

[0113] This embodiment applies the above technical solution, and its main contents include:

[0114] I. Select the study area and establish a rectangular coordinate system. After selecting the area, establish a planar three-dimensional coordinate system for the waterway based on the waterway reference point and the time series, with the waterway direction as the Y-axis, the perpendicular to the waterway direction as the X-axis, and the time series as the Z-axis.

[0115] II. Data Cleaning and Ship Latitude / Longitude Coordinate Conversion. Remove duplicate data; filter out data with non-standard MMSI (less than 9 digits); remove ship data with fewer than 5 trajectory points. Specific filtering methods: Remove rows with the same MMSI and time, keeping only the first row; extract the MMSI column from the data and convert it to a string using the `str` method in pandas; use the `map` and `len` functions to calculate and save the MMSI length for each data point; finally, filter out data with an MMSI length of 9 or more; group the data by ship's MMSI number using the `groupby` method in pandas, and use the `count` method to calculate the number of data records (i.e., the number of trajectory points), removing data with fewer than 5 points.

[0116] Third, interpolate the filtered data. First, determine the base time and convert the international time format to seconds using Python. Then, divide the time into a list with 30-second intervals, extract the latitude, longitude, speed, turning angle, and Mercator-converted rectangular coordinates from the data. Substitute the required time series and the extracted data for interpolation into a cubic spline interpolation algorithm. The interpolated data are then merged into a table and saved.

[0117] It should be noted that since ships may make round trips within the selected time period, it is necessary to group the ships by day and then interpolate the data for each day separately. In other words, it is not possible to simply extract all the data under the same MMSI.

[0118] IV. Calculate the azimuth between the selected vessel and the ship itself. First, establish a rectangular coordinate system with the ship itself as the origin. Scan each row of data after filtering, and determine which quadrant of the coordinate system established with the ship itself is located by the rectangular coordinate system coordinates in the data row. Then, pass the coordinates to the angle calculation function to solve for the tangent value of the line connecting the target coordinates and the origin. Finally, combine the tangent value with the quadrant number to solve for the azimuth.

[0119] Let the rectangular coordinates of this ship be (X0, Y0), and the rectangular coordinates of the target ship be (X0, Y0). i Y i The azimuth angle is calculated using the tangent function.

[0120]

[0121] Where θ is the turning angle; X0 is the distance between the vessel and the reference point in the direction perpendicular to the channel; X i Y0 is the distance between the target vessel and the reference point in the direction perpendicular to the channel; Y0 is the distance between the current vessel and the reference point in the direction along ... target vessel and the reference point in the direction perpendicular to the channel; Y0 is the distance between the current vessel and the reference point in the i The distance between the target vessel and the reference point along the course.

[0122] V. For example Figure 2 As shown, the MMSIs of target vessels around the ship are filtered by azimuth angle. First, using the ship as the origin, a circular area with a fixed radius is selected. Next, the filtering range is determined, specifying the angle within a sector to sweep across the entire circular area. The Hausdorff distance from the ship within each sector to the origin is calculated. Finally, the ship with the shortest Hausdorff distance within each sector is calculated and its MMSI number is saved. This process is repeated for each sector scanned, saving one MMSI, until the entire area is scanned. All saved MMSI numbers from each sector are then matched with the ship's MMSI and saved for subsequent calculations.

[0123] Let the coordinates of our ship be Q = [q1, q2, q3, q4], and the coordinates of the target ship be O = [o1, o2, o3, o4]. Calculate the distance between the two ships using the following formula. Where q i (i = 1, 2, 3, 4) are the coordinates of the boundary points of this ship, o i (i = 1, 2, 3, 4) are the coordinates of the boundary points of the target ship.

[0124] H(Q,O)=max(h(Q,O),h(O,Q))

[0125] h(Q,O)=max(q∈Q)min(o∈O)‖oq‖

[0126] h(O,Q)=max(o∈O)min(q∈Q)‖qo‖

[0127]

[0128] Where D is the Euclidean distance (e.g., ... Figure 3 As shown in the figure, H(Q,O) is the Hausdorff distance between the two ships (i.e., the distance between the two ships); h(Q,O) is the minimum value of each point in the set of the ships and the maximum value of each point in the set of the target ships; ‖qo‖ is the Euclidean distance between the ship and the target ship.

[0129] In this embodiment, a coordinate system is established with the ship as the center, and the area around the ship is divided into 6 sectors by 60° each. The Hausdorff calculation method is used to select the ships closest to the ship in each of the six sectors, and the MMSI of the above ships is collected.

[0130] VI. Confirm the situation between the nearest target vessel and your own vessel in each bearing: First, establish a coordinate system from your own vessel, with your sailing direction as 0°, moving clockwise. Calculate the bearing angle of the target vessel in the nautical coordinate system by using the tangent of the rectangular coordinates of surrounding vessels relative to your own. Rotate the nautical coordinate system from your own sailing direction, simultaneously changing the bearing angles of the surrounding vessels (to determine the final bearing angle). The specific determination method is as follows:

[0131] This is a head-on situation involving vessels within 10° to the left or right of this vessel's course and with a course angle difference greater than 90°.

[0132] If a vessel is within 22.5° to the left or right of the opposite direction of its course, it is considered an overtaking situation, and the course angle difference is less than or equal to 90°.

[0133] If the distance difference in the y-direction between this vessel and the target vessel is simultaneously negative or positive, it indicates that the vessel is following the target vessel.

[0134] The rest are determined to be crossovers;

[0135] 7. Draw the Space-Time and Course-Time diagrams of target vessels around the ship. First, extract the relevant data from the MMSI of the ship and the MMSI of the nearest surrounding vessels saved in the previous step, calculate the interval (Euclidean distance) between the two vessels at various times, and then draw the Space-Time diagram with the distance interval as the vertical axis and the time series as the horizontal axis (e.g., ...). Figure 4 (As shown); plot a Course-Time diagram with the heading angle of the target ship at each moment as the vertical axis and the time series as the horizontal axis (as shown). Figure 5 and Figure 6 (As shown).

[0136] 8. Analyze the turning points shown in the diagram and collect data on these turning points to find the threshold range for ship spacing. First, the diagram from the previous step shows the closest ship spacing in each direction. We can also extract the corresponding turning angles at those times, as well as the data for times when the turning angle changes significantly. By collecting this data, we can filter out the critical range between urgent situations and urgent dangers from the closest ship spacing in each direction. We can then calculate the critical range between no risk and urgent situations based on the ship spacing corresponding to times when the turning angle changes excessively.

[0137] 9. Analyze the urgency of ships in the area using threshold intervals. Using the two critical intervals from the above steps, filter the number of all saved data records to identify data under each situation. The data records under the following conditions are filtered by the boundaries of the two critical intervals: no risk, urgent situation, imminent danger, and collision danger.

[0138] Finally, by analyzing the ratio of ships in urgent situations under various circumstances, we can determine which situation in the region carries a higher risk and thus make an overall assessment of the urgency of ships.

[0139] In this embodiment, the three-dimensional diagrams of various ship situations (encounter, overtaking, crossing) are as follows: Figure 7 As shown, the corresponding ship movements under each situation are illustrated in the diagram. Figures 8-10 As shown in Table 1, the statistics of the maximum and minimum spacing data for each situation are as follows:

[0140] Table 1

[0141] Encounter 69.83 2342.58 overtake 97.80 3195.50 cross 58.87 3531.15

[0142] Based on the minimum distance values ​​corresponding to different scenarios, the detailed ship information for each scenario in this embodiment is shown in Table 2, and the corresponding movement diagrams are as follows: Figures 11-13 As shown.

[0143] Table 2

[0144] Encounter Dry cargo ships - port supply ships 55 / 9-38 / 11 7.9 overtake Container ship - workboat 106 / 17-140 / 20 9.9 cross Chemical tanker - dry cargo ship 93 / 15-133 / 24 7.8

[0145] In summary, this scheme first selects the study area and creates a waterway coordinate system, then filters out and cleans the AIS data for a fixed area. Next, it performs a transformation of the ship's latitude and longitude coordinates and establishes a rectangular coordinate system. The transformed data is then subjected to cubic spline interpolation to obtain relatively complete track data. Finally, through interpolation, the azimuth angle between the selected ship and surrounding target ships is calculated. The azimuth angle calculation method is as follows: a rectangular coordinate system is established for the ship, with the ship's sailing direction at 90°. The specific azimuth angle of the ship is then obtained based on the quadrant number of the ship in the coordinate system and the arctangent function.

[0146] Next, filter the MMSI of target vessels around the ship based on the azimuth angle to confirm the situation between the nearest target vessel and the ship in each azimuth: vessels within 10° to the left and right of the ship's course and with a course angle difference greater than 90° are considered to be in a head-on situation; vessels within 45° to the left and right of the ship's course in the opposite direction are considered to be in an overtaking situation and with a course angle difference less than or equal to 90° are considered to be overtaking; if the distance difference between the ship and the target vessel in the y-direction at the same moment is both negative or positive, it is considered to be following; all others are considered to be crossing.

[0147] Then, Space-Time and Course-Time diagrams of target vessels around the ship are drawn, the turning points in the diagrams are analyzed and turning point data is collected, and further analysis and filtering are used to obtain the minimum distance critical value between different types of ships under different situations.

[0148] Finally, the ship features data will be collected and the entire process of ship navigation will be represented by a three-dimensional image. This will facilitate a better analysis of the ship's response when faced with extremely small distances between two ships in various situations. In other words, after extracting the ship features in the complex intersection of traffic flow, the ship navigation routes in the selected features will be visualized in three dimensions, which will make it easier to observe the navigation status between ships in various situations.

Claims

1. A method for extracting feature values ​​of vessel encounters in intersecting waters based on AIS data, characterized in that, Includes the following steps: S1. Select the study area and create a waterway coordinate system; S2. Obtain AIS data and clean the data; S3. Convert the ship's latitude and longitude coordinates and establish a relative position coordinate system for the ship; S4. Perform interpolation on the cleaned AIS data, and then calculate the azimuth between the surrounding target ships and the selected ship. S5. Filter out the MMSI of target vessels around this ship based on the azimuth angle; S6. Determine the situation between the nearest target vessel and the ship in each bearing; S7. Draw a Space-Time diagram and a Course-Time diagram of the target vessels around this vessel; S8. Draw the turning points in the figure according to step S7, and obtain the turning point data to determine the threshold range of the distance between ships. S9. The urgency level of ships in the selected area is obtained through threshold interval analysis; The specific process of step S1 is as follows: The study area was selected from waters where three types of vessel behavior—head-on encounter, overtaking, and crossing—existed simultaneously. Then, a reference point for the waterway is selected, and a three-dimensional coordinate system is established for the waterway based on the reference point and the time series, with the waterway direction as the Y-axis, the perpendicularity to the waterway direction as the X-axis, and the time series as the Z-axis. The specific process of step S3 is as follows: convert the latitude and longitude coordinates of the selected area into X and Y values, set the distance along the waterway as the Y value and the distance perpendicular to the waterway as the X value, establish a three-dimensional coordinate system with the waterway plane as the X-axis and Y-axis and the time series as the Z-axis, and use this coordinate system to reflect the relative position coordinates between ships. The specific process of interpolating the cleaned AIS data in step S4 is as follows: Rectangular coordinates, ship speed, and ship turning angle are extracted from the cleaned AIS data. The extracted data is then spatiotemporally synchronized to a set time scale. Cubic spline interpolation is used to interpolate the time series with the extracted data. The specific process of calculating the azimuth angle between the surrounding target ships and the selected ship in step S4 is as follows: with the ship as the origin of the rectangular coordinate system, and with due east as 0°, a rectangular coordinate system is established in the counterclockwise direction. Using the set R value as the radius, a circular area of ​​the ship is defined, and the ship's AIS data points within this circular area are filtered. Iterate through all interpolated AIS data points except for the ship itself. If the x-value of a surrounding AIS data point is greater than the x-value of the ship itself, and its y-value is also greater than the y-value of the ship itself, then the AIS data point is determined to be in the first quadrant. If the x-value of a surrounding AIS data point is less than the x-value of the ship itself, and its y-value is greater than the y-value of the ship itself, then the AIS data point is determined to be in the second quadrant. And so on, calibrating which quadrant of the ship each AIS data point is located in. Substitute the rectangular coordinates of the target ship and the target ship into the following formula to calculate the angle between the two ships. The final bearing of the target ship can then be determined by using the angle and quadrant sign: in, For steering angle, This is the distance between the vessel and the reference point in the direction perpendicular to the waterway. The distance between the target vessel and the reference point in the direction perpendicular to the waterway. This is the distance between the vessel and the reference point along the course. The distance between the target vessel and the reference point along the course; The specific process of step S5 is as follows: Based on the circular area selected with the ship as the center, the circular area is further divided into a sector of a set size. Then, the data within each sector is traversed to calculate the Hausdorff distance between each ship and the ship within that sector: in, This is the set of coordinates for this ship. For the set of coordinates of the target ship, These are the coordinates of the ship's boundary points. Let D be the coordinates of the boundary point of the target ship, and D be the Euclidean distance. The Hausdorff distance between the two ships. This is the minimum value from each point in the current ship set to each point in the target ship set, plus the maximum value. This is the Euclidean distance between the vessel and the target vessel. Identify the vessel with the shortest Hausdorff distance from your own vessel within each sector area and save its MMSI number, thereby obtaining the MMSI of multiple target vessels; The specific process of step S6 is as follows: First, establish a coordinate system with the ship as the origin and the ship's direction of travel as 0°, in a clockwise direction; Calculate the deflection angle between the ship and the nearest vessel within the bearing. Use the deflection angle to correct the target vessel's heading angle in the Cartesian coordinate system. Based on the corrected angle, further correct the heading angle by setting the ship's sailing direction to 0°, so that the coordinate system can be dynamically established as the ship sails. At the same time, change the bearing angle values ​​of surrounding vessels. By comparing the bearing angles of the target vessel in the current coordinate system with the coordinate system established by the ship, determine whether the situation formed by the target vessel and the ship is a head-on encounter, overtaking, following, or crossing. Finally, save the data, including: the ship's MMSI, the target vessel's MMSI, the distance between the two vessels, and the situation between the two vessels.

2. The method for extracting vessel encounter feature values ​​in cross-waterways based on AIS data according to claim 1, characterized in that, The data cleaning process in step S2 includes: removing duplicate data; filtering out data with less than 9 MMSI digits; and clearing ship data with fewer than 5 trajectory points.

3. The method for extracting vessel encounter feature values ​​in cross-waterways based on AIS data according to claim 1, characterized in that, The specific process of step S7 is as follows: Based on the MMSI of the ship and the MMSI of the nearest surrounding ship saved in step S6, extract the data to calculate the Euclidean distance between the two ships at each time, and draw a Space-Time graph with the distance interval as the vertical axis and the time series as the horizontal axis. Then, plot a Course-Time diagram with the heading angle of the target ship at each moment as the vertical axis and the time series as the horizontal axis.

4. The method for extracting vessel encounter feature values ​​in cross-waterways based on AIS data according to claim 3, characterized in that, The specific process of step S8 is as follows: Based on the Space-Time and Course-Time diagrams drawn in step S7, obtain the distances between the nearest ships in each direction and extract the turning angles and data where the turning angle changes exceed the preset threshold at the corresponding time. The critical intervals between urgent situations and urgent dangers are selected from the nearest ship distances in all directions. The critical intervals between risk-free and urgent situations are calculated from the distance between the two ships at the moment when the change in the turning angle is the largest.

5. The method for extracting vessel encounter feature values ​​in cross-waterways based on AIS data according to claim 4, characterized in that, The specific process of step S9 is as follows: Based on the two critical intervals obtained in step S8, filter the number of all records of the saved data, filter out the data under each situation, and filter the number of data records under the no-risk, urgent, urgent danger, and collision danger situations respectively by the boundary of the two critical intervals. By analyzing the ratio of ships in urgent situations under various circumstances, it is possible to determine which situation in the region carries a risk higher than a preset risk threshold, thereby making an overall assessment of the urgency level of ships.

Citation Information

Patent Citations

  • AIS-based ship collision avoidance decision method

    CN112820150A

  • Ship danger early warning system and method based on AIS

    CN114550501A

  • Multi-ship meeting scene detection method, system and platform based on AIS data

    CN114999231A