Ship abnormal behavior identification method, computer equipment and storage medium

By constructing a global shipping route model and using geometric parameters to determine ship deviations, the problems of high computational load and low real-time performance in existing technologies have been solved, enabling efficient and accurate identification of abnormal behavior of ships at sea.

CN121963535APending Publication Date: 2026-05-01CETC OCEAN INFORMATION CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
CETC OCEAN INFORMATION CO LTD
Filing Date
2025-12-25
Publication Date
2026-05-01

AI Technical Summary

Technical Problem

Existing ship monitoring technologies suffer from high computational demands, low real-time performance, and low efficiency and accuracy in identifying abnormal behavior of ships at sea. In particular, when there are a large number of ships within the monitoring range, it is difficult to effectively process massive amounts of AIS data.

Method used

By constructing a global shipping route model, the degree of ship deviation is determined using preprocessed route information and simple geometric parameters. This includes determining the shortest vertical distance and heading angle from the current trajectory point to the candidate route, accumulating the number of abnormal driving trajectory points, and drawing deviation routes to identify abnormal behavior.

Benefits of technology

It enables rapid assessment of ship status, improves the real-time performance and efficiency of identification, reduces computational load, lowers the false alarm rate, and can more accurately identify ships sailing normally and abnormally, thus improving the efficiency and accuracy of identifying abnormal ships at sea.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN121963535A_ABST
    Figure CN121963535A_ABST
Patent Text Reader

Abstract

The invention discloses a ship abnormal behavior identification method, computer equipment and a storage medium, and relates to the technical field of marine ship supervision, and the method comprises the steps: determining a candidate route containing a current track point of a target ship according to a global ship channel model; if the shortest vertical distance from the current track point to the candidate route is higher than a distance threshold value, and / or the included angle between the course of the current track point and the route direction of the candidate route is higher than an angle threshold value, determining that the current track point is an abnormal driving track point; and continuously acquiring a new current track point of the target ship and repeatedly executing the process until abnormal driving track points meeting a number threshold value are determined, determining a deviation route drawn by all the abnormal driving track points, identifying abnormal behaviors, and generating and issuing an abnormal behavior identification result of the target ship. According to the invention, the abnormal sailing ship can be analyzed more accurately, the identification efficiency and accuracy of the marine abnormal ship are improved, and a supervision department is helped to improve the overall efficiency of marine supervision.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This disclosure generally relates to the field of maritime vessel monitoring technology, and in particular to a method for identifying abnormal vessel behavior, computer equipment, and storage medium. Background Technology

[0002] With the rapid development of the global maritime economy, the number of ships at sea has increased significantly, highlighting the growing importance of ship supervision. Effective ship supervision technologies are crucial for ensuring maritime safety, maintaining maritime order, and protecting the marine environment. Furthermore, in the process of maritime ship supervision, the early identification of abnormal ship behavior is particularly important for regulatory authorities to conduct administrative enforcement and rescue operations.

[0003] However, relevant ship abnormal behavior identification technologies usually require data analysis of the Automatic Identification System (AIS) data of each ship within the monitoring range, which has problems such as large computational load and low real-time performance. In addition, although deep learning technology can be used for ship abnormal behavior analysis, when there are a large number of ships within the monitoring range, it is necessary to process massive amounts of AIS data, resulting in low efficiency and low accuracy in abnormal behavior identification. Summary of the Invention

[0004] In view of the above-mentioned defects or deficiencies in the existing technology, it is desirable to provide a method, computer equipment and storage medium for identifying abnormal ship behavior. Through a global shipping route model, it can effectively identify ships sailing normally and those sailing abnormally, and then conduct more accurate analysis of ships sailing abnormally. It has low computational load and high real-time performance, thereby improving the efficiency and accuracy of identifying abnormal ships at sea and helping regulatory authorities improve the overall effectiveness of marine supervision.

[0005] Firstly, this application provides a method for identifying abnormal ship behavior. The method includes: Based on a pre-built global shipping route model, candidate routes containing the current trajectory points of the target vessel are determined. The global shipping route model includes all commonly used routes fitted by analyzing AIS data of ships at sea worldwide. Determine the shortest vertical distance from the current trajectory point to the candidate route, and the angle between the heading of the current trajectory point and the route direction of the candidate route; If the shortest vertical distance is higher than the distance threshold and / or the included angle is higher than the angle threshold, then the current trajectory point is determined to be an abnormal driving trajectory point; The process continues to acquire new current trajectory points of the target vessel and repeats the above process until the cumulative number of abnormal driving trajectory points meets the number threshold. Then, the trajectory lines drawn by the multiple abnormal driving trajectory points that meet the number threshold are determined as deviations from the route. The deviations from the route are used to indicate that the target vessel is not on each of the commonly used routes. Based on the deviation from the course, the abnormal behavior of the target vessel is identified, and the abnormal behavior identification results of the target vessel are generated and published.

[0006] In conjunction with the first aspect, in one possible implementation, the global shipping route model is constructed, including: The original AIS dataset of ships at sea worldwide is subjected to time synchronization, spatial alignment and outlier removal to obtain the target AIS dataset; For each target AIS data in the target AIS dataset, the ship trajectory sequence corresponding to the target AIS data is segmented, and then the discrete trajectory point set of each trajectory sequence segment is hierarchically clustered. Then, the cluster with the longest life cycle is selected from the hierarchical clustering tree and noise is reduced to obtain multiple target stable clusters of ships corresponding to the target AIS data. Project the multiple target stable clusters of all the target AIS data onto the map, and merge, deduplicate and smooth the target stable clusters that are spatially overlapping or parallel to obtain the global shipping route model that includes all the commonly used routes.

[0007] In conjunction with the first aspect, in one possible implementation, the hierarchical clustering of the discrete trajectory point set for each trajectory sequence segment includes: For each trajectory sequence segment obtained by segmenting the target AIS data corresponding to the ship trajectory sequence, the spherical distance between every two adjacent discrete trajectory points in the discrete trajectory point set of the trajectory sequence segment is determined, and the minimum spanning tree algorithm is used to perform hierarchical clustering on multiple spherical distances; the discrete trajectory point set is formed by sampling trajectory points of the trajectory sequence segment at preset time intervals.

[0008] In conjunction with the first aspect, in one possible implementation, the step of identifying the abnormal behavior of the target vessel based on the deviation from the course, and generating and publishing the abnormal behavior identification result of the target vessel, includes: Feature extraction is performed on the deviation from the course to obtain the target vessel's average speed, speed standard deviation, rate of change of course, and trajectory curvature, as well as the first distance to the nearest port and the second distance to the nearest restricted area; The average speed, the speed standard deviation, the heading change rate, the trajectory curvature, the first distance, and the second distance are all input into a pre-trained abnormal behavior recognition model to identify abnormal behavior, and the abnormal behavior recognition result output by the abnormal behavior recognition model is obtained.

[0009] In conjunction with the first aspect, in one possible implementation, the method further includes: Obtain a training sample set; each training sample in the training sample set includes a sample vessel not on each of the commonly used routes, as well as the sample vessel's sample average speed, sample speed standard deviation, sample heading change rate, sample first distance to the nearest port of the sample, and sample second distance to the nearest restricted area of ​​the sample; The deep learning-based anomaly detection model is trained using the training sample set, a preset clustering loss function, and a preset meteorological disturbance regularization term to obtain the abnormal behavior recognition model.

[0010] In conjunction with the first aspect, in one possible implementation, the method further includes: If the instantaneous speed of the target vessel exceeds a first speed threshold, it is determined that the target vessel is speeding; the first speed threshold is the sum of the average speed and the speed standard deviation of a first preset multiple. If the instantaneous speed of the target vessel is lower than the second speed threshold, it is determined that the target vessel is exhibiting low-speed behavior; the second speed threshold is the result of subtracting the average speed from the speed standard deviation which is a second preset multiple. If the rate of change of course exceeds the rate of change threshold, then the target vessel is determined to have a sudden change in direction. If the trajectory curvature exceeds the curvature threshold, it is determined that the target vessel exhibits abnormal trajectory behavior. If either the first distance or the second distance is less than a preset safe distance threshold, then it is determined that the target vessel is approaching a restricted area. If the target vessel stays in the preset non-port area for more than a time threshold and its speed is lower than a speed threshold, then it is determined that the target vessel has anchored. If the distance between the target vessel and another vessel remains below a distance threshold for a preset period of time, it is determined that the target vessel is engaging in transshipment activities.

[0011] In conjunction with the first aspect, in one possible implementation, the method further includes: When the abnormal behavior recognition result output by the abnormal behavior recognition model is the target abnormal probability, a target abnormal behavior with a target risk level corresponding to the target abnormal probability is generated and published according to the pre-set mapping relationship between abnormal probability, abnormal behavior and risk level.

[0012] In conjunction with the first aspect, in one possible implementation, determining the shortest vertical distance from the current trajectory point to the candidate route includes: The centerline of the candidate route is cut to obtain multiple line segments; Determine the vertical distance from the current trajectory point to each of the line segments, and determine the shortest vertical distance from a plurality of the vertical distances.

[0013] Secondly, this application also provides a computer device. The computer device includes a memory and a processor, the memory storing a computer program, and the processor executing the computer program to implement the ship abnormal behavior identification method described in the first aspect.

[0014] Thirdly, this application also provides a computer-readable storage medium. This computer-readable storage medium stores a computer program thereon, which, when executed by a processor, implements the ship abnormal behavior identification method described in the first aspect.

[0015] This application provides a method, computer device, and storage medium for identifying abnormal ship behavior. The method first pre-constructs a global shipping route model, preprocessing and storing complex route information to avoid repetitive analysis of massive amounts of raw AIS data during real-time identification. Secondly, it quantifies the ship's deviation in a lightweight manner by determining two geometric parameters: the shortest vertical distance from the current trajectory point to the candidate route and the angle between the heading and the route direction. This simple geometric parameter-based judgment method has low computational cost, high real-time performance, and high computational efficiency, enabling rapid assessment of the ship's state. This approach improves the real-time performance and efficiency of identification. Furthermore, by continuously acquiring new trajectory points and accumulating the number of abnormal navigation trajectory points until a threshold is met before determining a deviation from the course, this mechanism effectively avoids false alarms caused by instantaneous data fluctuations or brief deviations, thus improving the accuracy of abnormal behavior identification. In addition, by plotting multiple abnormal navigation trajectory points as deviations from the course and identifying abnormal behavior based on these deviations, this more macroscopic and interpretable basis for abnormal behavior identification not only allows regulatory personnel to more intuitively understand the abnormal state of vessels and take corresponding actions, but also makes the visualization of deviations and the behavior identification based on them more practically valuable. Thus, by pre-constructing a global shipping channel model, simplifying geometric parameter calculations, implementing a cumulative judgment mechanism, and combining macroscopic identification and synergistic effects based on deviations from the course, this approach effectively solves the problems of high computational load, low real-time performance, low efficiency, and low accuracy faced by existing technologies in identifying abnormal vessel behavior. It can effectively identify vessels navigating normally and those navigating abnormally, thereby enabling more precise analysis of vessels navigating abnormally and significantly improving the efficiency and accuracy of identifying abnormal vessels at sea. Attached Figure Description

[0016] Other features, objects, and advantages of this application will become more apparent from the following detailed description of non-limiting embodiments with reference to the accompanying drawings: Figure 1 This is one of the flowcharts illustrating a method for identifying abnormal ship behavior in one embodiment; Figure 2 This is a second flowchart illustrating a method for identifying abnormal ship behavior in one embodiment; Figure 3 This is the third flowchart of a method for identifying abnormal ship behavior in one embodiment; Figure 4 This is the fourth flowchart of a method for identifying abnormal ship behavior in one embodiment; Figure 5 This is the fifth flowchart of a method for identifying abnormal ship behavior in one embodiment; Figure 6 This is a flowchart of the abnormal ship behavior identification method in one embodiment, number six. Figure 7 This is a structural block diagram of a ship abnormal behavior recognition device in one embodiment; Figure 8 This is an internal structural diagram of a computer device in one embodiment. Detailed Implementation

[0017] The present application will now be described in further detail with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are for illustrative purposes only and are not intended to limit the invention. Furthermore, it should be noted that, for ease of description, only the parts relevant to the invention are shown in the accompanying drawings.

[0018] It should be noted that, unless otherwise specified, the embodiments and features described in this application can be combined with each other. The present application will now be described in detail with reference to the accompanying drawings and embodiments. Furthermore, the term "and / or" in this document is merely a description of the relationship between related objects, indicating that three relationships can exist. For example, A and / or B can represent: A existing alone, A and B existing simultaneously, or B existing alone. The terms "first" and "second," etc., in the specification and claims of the embodiments of this application are used to distinguish different objects, not to describe a specific order of objects.

[0019] With the rapid development of the global maritime economy, the number of ships at sea has increased significantly, highlighting the growing importance of ship supervision. Effective ship supervision technologies are crucial for ensuring maritime safety, maintaining maritime order, and protecting the marine environment. Existing ship supervision methods mainly include radar, AIS, and optoelectronic equipment. Furthermore, in the process of maritime ship supervision, the pre-identification of abnormal ship behavior is particularly important for regulatory authorities to conduct administrative enforcement and rescue operations.

[0020] In related technologies for identifying abnormal ship behavior, it is usually necessary to analyze the AIS data of each ship within the monitoring range, which has problems such as large computational load and low real-time performance. In addition, although existing artificial intelligence (AI) based technologies can use deep learning technology to analyze abnormal ship behavior, when there are a large number of ships within the monitoring range, they need to process massive amounts of AIS data, resulting in low efficiency and low accuracy in identifying abnormal behavior.

[0021] Technologies such as radar, AIS, and optoelectronic equipment have played an important role in improving the accuracy of ship surveillance, but they also have obvious limitations.

[0022] Limitation 1: Combined use of radar, AIS, and optoelectronic equipment: While the combined use of radar, AIS, and optoelectronic equipment can provide high-precision ship position and dynamic information, its coverage is limited. Radar's effective coverage is typically limited to coastal areas or specific waterways; AIS data coverage is also limited by signal transmission distance; and optoelectronic equipment is greatly affected by weather and lighting conditions, making it impossible to operate in all weather conditions. Therefore, the application of these methods in the vast ocean is limited, and they cannot achieve anomaly detection of ships in a wider range of sea areas.

[0023] Limitation 2: AIS Data-Based Analysis Solutions: Currently, maritime vessel monitoring technologies based on AIS data are widely used. While AIS data provides real-time information such as vessel position, speed, and heading, the sheer volume of maritime targets and AIS data presents challenges to the accuracy and efficiency of existing algorithms. Existing technologies often require substantial computational resources to process large-scale AIS data, and real-time processing and response are difficult, resulting in low analysis efficiency and an inability to promptly detect abnormal behavior.

[0024] Therefore, it can be understood that existing technologies have the following main drawbacks in maritime vessel supervision: 1. Limited Coverage: Existing technologies have limited coverage for maritime surveillance, making it difficult to detect abnormal vessel conditions over large areas. The effective coverage of radar and optoelectronic equipment is typically limited to coastal areas or specific waterways, while the coverage of AIS data is also limited by signal transmission distance. Therefore, the application of these methods in the vast ocean is restricted, making it impossible to detect abnormal vessel conditions in a wider range of sea areas.

[0025] 2. High computational load in data analysis: Monitoring in the mid-to-far seas mainly relies on AIS data. Existing technologies suffer from high computational load in data analysis, high resource consumption, and inaccurate analysis. With numerous targets at sea, the large amount of AIS data requires existing algorithms to consume significant computational resources, making real-time processing and response difficult, resulting in low analysis efficiency and an inability to detect abnormal behavior in a timely manner.

[0026] To address the aforementioned technical problems, this application proposes a novel approach to regulating abnormal behavior of maritime targets. By analyzing AIS data of vessels worldwide, commonly used routes of these vessels are fitted, and a global vessel navigation model is generated. Based on this global vessel navigation model, vessels navigating normally and those navigating abnormally can be effectively identified, allowing for more precise analysis of vessels navigating abnormally. This improves the efficiency and accuracy of identifying abnormal vessels at sea, helping regulatory authorities enhance the overall effectiveness of maritime supervision. In other words, the objectives of this application include the following: (1) Expanding coverage: By analyzing AIS data of ships at sea worldwide, commonly used routes of ships are fitted and relevant models are generated. This method can effectively cover a wide range of ocean areas, ensuring that the behavior of ships in more sea areas can be effectively monitored.

[0027] (2) Reduce data computation and resource consumption: By fitting the commonly used route model, a large number of ships sailing normally can be filtered out, thereby reducing the amount of data computation and resource consumption. Ships on commonly used routes are identified as ships sailing normally, and no further data analysis is required, which significantly improves the efficiency and response speed of the system.

[0028] The following is combined Figures 1 to 8 This application describes a method, computer equipment, and storage medium for identifying abnormal ship behavior. The executing entity of the method can be a computer device or server capable of communication transmission with a trajectory data source (such as AIS) of any ship in the target sea area. This computer device can be a personal computer (PC), portable device, laptop, smartphone, tablet, portable wearable device, or other electronic device. The server can be a single server or a server cluster composed of multiple servers. This application does not specifically limit the form of the computer equipment or server. Furthermore, the method can also be applied to a ship abnormal behavior identification device installed in the computer equipment or server. This device can be implemented through software, hardware, or a combination of both. The following description uses a computer device as an example to illustrate the method's execution entity.

[0029] To facilitate understanding of the ship abnormal behavior identification method provided in this application, the following examples will provide a detailed description of the method. It is understood that these examples can be combined with each other, and similar concepts or processes may not be repeated in some embodiments.

[0030] Reference Figure 1 This is a flowchart illustrating the ship abnormal behavior identification method provided in the embodiments of this application, as shown below. Figure 1 As shown, the method for identifying abnormal ship behavior includes the following steps 101 to 105.

[0031] Step 101: Based on the pre-built global shipping route model, determine the candidate routes containing the current trajectory points of the target vessel. The global shipping route model includes all commonly used routes fitted by analyzing AIS data of ships at sea worldwide.

[0032] The target vessel can be understood as any vessel in the sea area to be measured that needs to be identified for abnormal behavior; and the trajectory data of the target vessel will be continuously monitored and analyzed.

[0033] The current trajectory point can be understood as the geographical location information of the target ship at a certain moment, which may include data such as longitude, latitude, timestamp, speed and heading.

[0034] Candidate routes can be understood as commonly used routes selected from the global shipping channel model based on the current trajectory points of the target vessel, and which may be related to the target vessel's travel path; for example, candidate routes may be commonly used routes that may contain the current trajectory points.

[0035] AIS data can be understood as a system that automatically broadcasts information such as a ship's identity, location, speed, and course; this data forms the basis for building global shipping route models and monitoring ship trajectories in real time.

[0036] Frequently used routes can be understood as navigation paths that ships generally follow at sea, exhibiting high frequency and regularity. All frequently used routes are typically determined after long-term data accumulation and analysis.

[0037] Specifically, based on a pre-built global shipping route model, candidate routes containing the current trajectory points of the target vessel are determined. This global shipping route model includes all commonly used routes fitted by analyzing AIS data of vessels worldwide. In one implementation, this global shipping route model can be drawn by human experts based on historical nautical charts and experience covering the entire globe, or it can be achieved by performing simple density clustering on historical AIS data of vessels worldwide, identifying high-density areas as commonly used routes. This approach avoids processing massive amounts of global AIS data in real time, thus reducing the computational burden and providing a rapid reference benchmark for subsequent anomaly behavior assessment.

[0038] For each commonly used shipping route obtained through fitting, metadata such as the geographical range, average width, lifespan, and electric speed range of each route can be acquired. Then, each commonly used shipping route and its metadata can be modeled to obtain a global shipping channel model. For the geographical dataset containing each commonly used shipping route and its metadata, an R-tree or GeoHash algorithm can be used to generate a spatial index structure for the geographical dataset. Therefore, the global shipping channel model can also be stored as this spatial index structure for easy and quick location and querying later.

[0039] In this way, for the current trajectory point of the target vessel, spatial indexing technology can be used to quickly locate candidate routes that may contain the current trajectory point from the global shipping route model with spatial index structure.

[0040] Step 102: Determine the shortest vertical distance from the current trajectory point to the candidate route, and the angle between the heading of the current trajectory point and the route direction of the candidate route.

[0041] The shortest vertical distance can be understood as the shortest geometric distance from the current trajectory point to the candidate route (or its centerline) and is perpendicular to the candidate route; this shortest vertical clustering can be used to quantify the degree to which the target ship's position deviates from the candidate route.

[0042] The heading of the current trajectory point can be understood as the actual direction the target ship is traveling.

[0043] The direction of a candidate route can be understood as the direction of navigation represented by the candidate route near the current trajectory point, and it can be used to quantify the degree of deviation between the ship's navigation direction and the standard route direction.

[0044] Specifically, the shortest vertical distance from the current trajectory point to the candidate route, and the angle between the current trajectory point's heading and the candidate route's direction, are determined. In one implementation, the candidate route can be simplified to a straight line segment, and then the vertical distance from the current trajectory point to that segment can be calculated. Simultaneously, the current trajectory point's heading can be directly obtained from the target vessel's AIS data, and the candidate route's direction can be determined based on the start and end points of the simplified straight line segment. For example, when the target vessel's current trajectory point is near a candidate route, the geometric shortest distance from the current trajectory point to that candidate route can be calculated, along with the angle between the target vessel's current heading and the candidate route's direction. The calculation of these two geometric parameters is relatively simple and can quickly quantify the degree to which the vessel deviates from the standard route in both position and direction.

[0045] Step 103: If the shortest vertical distance is higher than the distance threshold and / or the included angle is higher than the angle threshold, then the current trajectory point is determined to be an abnormal driving trajectory point.

[0046] Specifically, the shortest vertical distance from the current trajectory point to the candidate route is compared with a distance threshold, and the angle between the current trajectory point's heading and the candidate route's direction is compared with an angle threshold. If the shortest vertical distance is less than the distance threshold and the angle is less than the angle threshold, the match is considered successful, and the current trajectory point is identified as a normal navigation trajectory point. Conversely, if the shortest vertical distance is greater than the distance threshold and / or the angle is greater than the angle threshold, the match is considered unsuccessful, and the current trajectory point is identified as an abnormal navigation trajectory point.

[0047] For example, let the current trajectory point be denoted as p, the centerline of the candidate route be denoted as R, and the shortest vertical distance from the current trajectory point to the candidate route be denoted as... The heading of the current trajectory point Route direction relative to candidate routes The included angle between them is denoted as The distance threshold is denoted as (e.g., 1 nautical mile), and the angle threshold is denoted as (e.g., 30°), then the above matching process can be achieved by equation (1).

[0048] (1) In equation (1), This indicates that when the match is successful (True), the current trajectory point p is on the centerline R of the candidate route; or when the match fails (False), the current trajectory point p is not on the centerline R of the candidate route.

[0049] Step 104: Continuously acquire new current trajectory points of the target vessel and repeat the above process until the cumulative number of abnormal driving trajectory points meets the number threshold; then, determine the trajectory lines drawn by multiple abnormal driving trajectory points that meet the number threshold as deviations from the route. The deviations from the route are used to indicate that the target vessel is not on each common route.

[0050] Specifically, the process continuously acquires new current trajectory points of the target vessel and repeats steps 101 to 103 until the cumulative number of abnormal trajectory points meets a threshold. The trajectory lines drawn from multiple abnormal trajectory points that meet the threshold are then identified as deviations from the designated route. These deviation routes characterize the target vessel's absence from every commonly used route. In one implementation, a time window can be set. Within this window, if the cumulative number of consecutive or discontinuous abnormal trajectory points reaches a preset threshold (e.g., 5 abnormal trajectory points appear within 10 minutes), the vessel is considered to be exhibiting continuous deviation behavior. Subsequently, the geographical locations of these marked abnormal trajectory points are connected to form a deviation route. This cumulative judgment method effectively avoids misjudgments caused by instantaneous disturbances or data errors, ensuring the identified deviation behavior has a certain degree of persistence and reliability.

[0051] Alternatively, in another implementation, a sliding window can be set. The size of the sliding window can be the same as the number of trajectory points matched in each batch. That is, when the sliding window is N, N current trajectory points are matched consecutively each time, and each time it is checked whether each current trajectory point is an abnormal driving trajectory point. In this way, when N consecutive trajectory points fail to match, that is, when N consecutive current trajectory points are all judged as abnormal driving trajectory points, it is determined that the deviation from the route has been identified. This improves the efficiency of determining deviation from the route.

[0052] Step 105: Identify the abnormal behavior of the target vessel based on deviation from the course, and generate and publish the abnormal behavior identification results of the target vessel.

[0053] Specifically, the system identifies abnormal behavior of target vessels based on deviations from their routes, generating and disseminating the identification results. In one implementation, simple pattern matching can be performed on the identified deviation routes. For example, if the deviation route shows a trend of moving away from all commonly used routes, it can be identified as a route deviation; if the deviation route exhibits an irregular circling or meandering pattern within a certain area, it can be identified as circling behavior. The identification result of the target vessel's abnormal behavior can be a simple text description, such as "Vessel A has exhibited route deviation behavior," and this can be disseminated to relevant regulatory authorities through pre-defined communication channels. This identification method, based on the overall characteristics of route deviations, can judge the macroscopic abnormal behavior of target vessels and provide timely early warning information to regulatory terminals.

[0054] The ship abnormal behavior identification method provided in this application firstly pre-constructs a global ship navigation model to preprocess and store complex route information, thereby avoiding repeated analysis of massive amounts of raw AIS data during real-time identification. Secondly, it quantifies the degree of ship deviation in a lightweight manner by determining two geometric parameters: the shortest vertical distance from the current trajectory point to the candidate route and the angle between the heading and the route direction. This judgment method based on simple geometric parameters has low computational load, high real-time performance, and high computational efficiency, enabling rapid assessment of the ship's state and thus improving the real-time performance and efficiency of identification. Furthermore, it continuously acquires new trajectory points and accumulates the number of abnormal driving trajectory points until a threshold is met before determining a deviation from the route. This mechanism effectively avoids false alarms caused by instantaneous data fluctuations or brief deviations, improving the accuracy of abnormal behavior identification. In addition, by plotting multiple abnormal driving trajectory points as a deviation from the route and identifying abnormal behavior based on this deviation, this more macroscopic and interpretable basis for abnormal behavior identification not only allows regulatory personnel to more intuitively understand the abnormal state of the ship and take corresponding actions, but also makes the visualization of the deviation from the route and the behavior identification based on it more practical. In this way, by pre-constructing a global shipping channel model, simplifying geometric parameter calculations, implementing a cumulative judgment mechanism, and using macroscopic identification and synergistic effects based on deviations from the shipping route, the problem of large computational load, low real-time performance, low efficiency, and low accuracy faced by the identification of abnormal ship behavior in existing technologies is effectively solved. It can effectively identify ships sailing normally and those sailing abnormally, and then conduct more accurate analysis of ships sailing abnormally, thereby significantly improving the efficiency and accuracy of identifying abnormal ships at sea.

[0055] Based on the above Figure 1 In one example embodiment of the method shown, the global shipping lane model mentioned in step 101 is specifically constructed through the following process: Figure 2 Steps 201 to 203 shown are implemented.

[0056] Step 201: Perform time synchronization, spatial alignment and outlier removal on the original AIS dataset of ships at sea worldwide to obtain the target AIS dataset.

[0057] Step 202: For each target AIS data in the target AIS dataset, the ship trajectory sequence corresponding to the target AIS data is segmented, and then the discrete trajectory point set of each trajectory sequence segment is hierarchically clustered. Then, the cluster with the longest life cycle is selected from the hierarchical clustering tree and noise is reduced to obtain multiple target stable clusters of ships corresponding to the target AIS data.

[0058] Step 203: Project the multiple target stable clusters of all target AIS data onto the map, and merge, deduplicate and smooth the target stable clusters that overlap or are parallel in space to obtain a global shipping channel model that includes all commonly used routes.

[0059] The original AIS dataset includes multiple original AIS data sets, each containing the corresponding vessel's Maritime Mobile Service Identity (MMSI), longitude, latitude, speed, heading, and other trajectory information.

[0060] Specifically, data preprocessing for the original AIS dataset can include, but is not limited to, time synchronization, spatial alignment, and outlier removal. Time synchronization can be understood as aligning the timestamps of all the original AIS data to a time step of 1 second. Spatial alignment can be understood as converting the synchronized timestamps of the AIS data into coordinate systems to ensure data consistency. Outlier removal can be understood as removing outliers with flight speeds exceeding 50 knots or latitude and longitude exceeding 1°. This completes the data preprocessing of all the original AIS data, resulting in the preprocessed target AIS dataset.

[0061] For each target AIS data point in the target AIS dataset, each point is first segmented by trajectory and arranged chronologically to obtain the target trajectory sequence of the corresponding ship (i.e., the ship trajectory sequence corresponding to the target AIS data). Then, a density-based hierarchical clustering algorithm (HDBSCAN) is used to cluster the trajectory points of all target trajectory sequences. Three parameters are set: minimum clustering parameter (e.g., min_cluster_size = 50), minimum number of neighbors required for core points (e.g., min_samples = 10), and distance threshold (denoted as cluster_selection_epsilon and used to control the cluster boundaries). At this point, the HDBSCAN algorithm is used to construct a hierarchical clustering tree, and multiple stable target clusters corresponding to each ship for each target AIS data point are extracted from each hierarchical clustering tree. Here, stable clusters can be extracted by setting a stability threshold to extract target stable clusters with sufficient lifecycles from each level of the clustering tree. Then, noise point filtering is performed, marking points that do not belong to any target stable cluster as noise and filtering them, thus obtaining multiple target stable clusters for each ship corresponding to each target AIS data in the target AIS dataset.

[0062] For example, hierarchical clustering is performed on the discrete trajectory point set of each trajectory sequence segment. The discrete trajectory point set refers to a series of representative trajectory points extracted from the trajectory sequence segment according to certain rules (e.g., sampling at fixed time intervals, sampling at fixed distance intervals, key point extraction, etc.). Hierarchical clustering is a clustering algorithm that organizes data points by constructing a clustering tree. It can be agglomerated (gradually merging from a single point) or divisive (gradually splitting from a large cluster). In addition to methods based on spherical distance and minimum spanning tree algorithms, other distance metrics (such as Euclidean distance, dynamic time warping (DTW) distance) and linkage criteria (such as single linkage, full linkage, average linkage, Ward's method) can also be used for clustering.

[0063] The process involves selecting the clusters with the longest lifespan from the hierarchical clustering tree and then applying noise reduction. The clusters with the longest lifespan refer to those that have remained the most stable and longest-lasting clusters during the clustering process. This can be assessed by analyzing the structure of the clustering tree, such as through tree depth, changes in the number of points within each cluster, or by evaluating cluster stability based on specific metrics. Noise reduction can be understood as removing trajectory points considered noise or outliers from the selected clusters. This can be achieved using density-based noise reduction algorithms (such as DBSCAN), distance-based noise reduction, or statistical methods.

[0064] Considering that noise or excessively short trajectory sequence segments will be eliminated, each trajectory sequence segment may not necessarily generate a stable cluster, and multiple trajectory sequence segments often fall into the same cluster; furthermore, the number of target stable clusters for each target AIS data point for a ship may be the same or different.

[0065] Therefore, it can be understood that when the total number of ships participating in the fitting is P (e.g., P=10000 ships), and the target trajectory sequence of each ship is divided into M (e.g., M takes the value of 3) trajectory sequence segments, the total number of target stable clusters of all target AIS data corresponding to each ship after processing by the HDBSCAN algorithm is P×M (e.g., 30000) is ≤ P×M (e.g., the original cluster 5000≤30000).

[0066] At this point, the edges / points of all stable clusters worldwide are projected onto the map, that is, multiple target stable clusters of ships corresponding to each target AIS data in the target AIS dataset are projected onto the map, and spatially overlapping or parallel target stable clusters are merged, fused and smoothed to generate multiple commonly used routes. Then, metadata is assigned to each commonly used route, namely the geographical range, average width, typical speed range and life cycle of each route.

[0067] For example, for all target stable clusters projected onto the map, if target stable cluster A and target stable cluster B overlap or are parallel in space, a common route a is generated accordingly. In this case, the geographical range of the common route a can be defined as its start-end rectangle plus a buffer zone. That is, it is formed by the maximum and minimum latitude and longitude of the coordinate points in cluster Q after merging target stable clusters A and B, resulting in a rectangular area. The buffer zone is obtained by expanding the four sides of the rectangular area by 2n miles with the center point as the center point. The average width of the common route a can be defined as the 95th percentile distance from the point within the cluster to the center line. That is, the distance from all points in cluster Q to the center point is calculated, and the 95th percentile distance value after sorting all distances from largest to smallest is selected as the average width. The lifespan of the common route a can be defined as the time span of the cluster's appearance, used to measure the duration of the common route a in the observation data. Its lifespan metadata includes the start time and the end time.

[0068] When the final generated number of frequently used routes is M, M is much smaller than the original number of clusters, which can be the total number of target stable clusters. Each frequently used route corresponds to a metadata set. During subsequent matching, only the spatial distance between the current trajectory point and the M frequently used routes needs to be determined, eliminating the need to return to the individual ship level, thus significantly improving the efficiency and accuracy of identifying abnormal ships at sea. Moreover, when target stable cluster A and target stable cluster B are each an original cluster and are parallel to each other, they can be grouped into one cluster and their center lines calculated. This results in the final number of frequently used routes being less than the original number of clusters.

[0069] The ship abnormal behavior identification method provided in this application significantly improves data quality by performing time synchronization, spatial alignment, and outlier removal on the original AIS dataset, providing a reliable foundation for subsequent analysis. Trajectory sequence segmentation and hierarchical clustering, combined with cluster selection covering the longest lifecycle and noise reduction processing, enable accurate identification of stable and representative navigation patterns from complex ship trajectories, effectively filtering out short-term fluctuations and abnormal behaviors. Furthermore, by performing map projection, merging, deduplication, and smoothing on the target stable clusters of all ships, a highly accurate, concise, and practical global ship navigation model is constructed. This model not only clearly represents commonly used routes globally but also provides a precise reference benchmark for subsequent ship abnormal behavior identification. Compared to relying solely on the original AIS data for judgment, the global ship navigation model constructed in this solution can more accurately determine candidate routes. This makes the calculation of the shortest vertical distance and heading angle more precise when determining whether a current trajectory point is an abnormal navigation point, significantly improving the accuracy and reliability of abnormal behavior identification, reducing the false alarm rate, and providing more efficient and accurate technical support for maritime ship supervision.

[0070] Based on the above Figure 2 In one example embodiment of the method shown, step 202 involves hierarchical clustering of the discrete trajectory point set for each trajectory sequence segment. The specific process in this embodiment can be implemented through the following steps.

[0071] For each trajectory sequence segment obtained by segmenting the ship trajectory sequence corresponding to the target AIS data, the spherical distance between each two adjacent discrete trajectory points in the discrete trajectory point set of the trajectory sequence segment is determined, and the minimum spanning tree algorithm is used to perform hierarchical clustering of multiple spherical distances; the discrete trajectory point set is formed by sampling trajectory points of the trajectory sequence segment according to a preset time interval.

[0072] The determination of the spherical distance between every two adjacent discrete trajectory points in the discrete trajectory point set of the trajectory sequence segment aims to accurately measure the actual distance between two points on the Earth's surface, avoiding errors caused by the Earth's curvature when processing geographic coordinate data using traditional Euclidean distance. This spherical distance can be calculated in several ways. For example, the Haversine formula can be used, which calculates the great circle distance based on latitude and longitude coordinates and is applicable to distance calculations between any two points. Alternatively, the Vincenty formula can be used, which further considers the Earth's oblateness based on the Haversine formula, providing even higher accuracy. Another example is the great circle distance formula, which calculates the distance between two points along the great circle arc using the principles of spherical trigonometry.

[0073] The minimum spanning tree algorithm is used for hierarchical clustering of multiple spherical distances to efficiently and accurately identify the intrinsic connections between trajectory points, thereby forming representative clusters. The minimum spanning tree algorithm connects all vertices with the minimum total edge weight, which in clustering means finding the "tightest" connection structure. This algorithm can be implemented in various ways. For example, Prim's algorithm can be used, starting from a starting point and progressively adding the shortest edges to expand the tree until all points are connected. Another example is Kruskal's algorithm, which sorts all edges by weight and then sequentially selects edges that do not form cycles until all points are connected. Furthermore, Boruvka's algorithm can be used, which, through parallel processing, finds the shortest external edge for each connected component in each iteration, thus accelerating the construction of the minimum spanning tree.

[0074] Discrete trajectory point sets can be understood as samples taken from each trajectory sequence segment at preset time intervals. The aim is to effectively reduce data volume and optimize the computational burden of subsequent processing while preserving key features of the ship's trajectory. The preset time interval can be adjusted according to actual needs and data characteristics. For example, a fixed time interval sampling can be used, such as sampling one trajectory point every 5 minutes, to obtain uniformly distributed trajectory point data. Alternatively, dynamic time interval sampling can be used, adaptively adjusting the sampling interval based on parameters such as ship speed and heading change rate. For instance, the sampling frequency can be increased when ship speed or heading changes significantly to capture finer trajectory changes. Furthermore, event-based sampling can be employed, such as sampling when the ship performs critical actions like turning, anchoring, or accelerating, to ensure complete recording of important event points.

[0075] Specifically, a global shipping route model is constructed by segmenting ship trajectory sequences and refining the discrete trajectory point set of each segment. First, the ship trajectory sequence is segmented to accommodate the characteristics of different navigation stages. Then, trajectory points are sampled from each segment at preset time intervals to form a discrete trajectory point set, effectively reducing data processing complexity while ensuring the integrity of trajectory features. Based on this, the spherical distance between each adjacent pair of trajectory points in the discrete trajectory point set is accurately calculated, fully considering the influence of the Earth's curvature on distance measurement and ensuring the accuracy of distance calculation. Subsequently, the minimum spanning tree algorithm is used to perform hierarchical clustering of these spherical distances. This algorithm can efficiently identify the inherent connections between trajectory points, forming stable and representative target stable clusters. These target stable clusters are the foundation for constructing the global shipping route model, and their accuracy and efficiency directly affect the reliability of subsequent abnormal behavior identification. Through the above technical means, this embodiment can more accurately and efficiently identify commonly used ship routes when constructing a global shipping route model, providing more reliable basic data for subsequent abnormal behavior identification.

[0076] For example, after segmenting the ship trajectory sequence corresponding to any target AIS data, the spherical distance between each two adjacent discrete trajectory points in the discrete trajectory point set of one trajectory sequence segment can be calculated by equation (2).

[0077] (2) In equation (2), This represents the spherical distance between two adjacent discrete trajectory points. This represents the Earth's average radius. This represents the latitude difference between two adjacent discrete trajectory points. It represents the difference in longitude between two adjacent discrete trajectory points.

[0078] The ship abnormal behavior identification method provided in this application significantly improves the accuracy of distance measurement by introducing spherical distance calculation, avoiding the errors of traditional Euclidean distance in the geographic coordinate system. Simultaneously, the use of the minimum spanning tree algorithm for hierarchical clustering not only reduces computational complexity and improves clustering efficiency but also ensures the stability and reliability of the clustering results. Furthermore, by sampling trajectory points at preset time intervals, key trajectory features are preserved while reasonably reducing the amount of data processing, further optimizing the model building process. These improvements work synergistically to make the construction of the global ship navigation model more efficient, accurate, and stable, thus providing a more solid and reliable foundation for subsequent ship abnormal behavior identification. This significantly improves the real-time performance and accuracy of abnormal behavior identification, effectively solving the problems of low computational efficiency and insufficient clustering accuracy in traditional hierarchical clustering methods when processing massive amounts of trajectory points.

[0079] Based on the above Figure 1 In one example embodiment of the method shown, step 105 involves identifying abnormal behavior of the target vessel based on deviation from its course, generating and publishing the abnormal behavior identification results of the target vessel. The specific process in this embodiment can be achieved through… Figure 3 Steps 301 and 302 shown are implemented.

[0080] Step 301: Extract features from the deviation from the course to obtain the target vessel's average speed, speed standard deviation, rate of change of course, and trajectory curvature, as well as the first distance to the nearest port and the second distance to the nearest restricted area.

[0081] Step 302: Input the average speed, speed standard deviation, heading change rate, trajectory curvature, first distance and second distance into the pre-trained abnormal behavior recognition model to perform abnormal behavior recognition, and obtain the abnormal behavior recognition results output by the abnormal behavior recognition model.

[0082] Feature extraction of deviations from the course can be understood as identifying and extracting representative information that reflects the essential attributes of ship behavior from deviations from the course. Its role is to transform complex trajectory data into structured and quantifiable behavioral indicators, thereby reducing the complexity of subsequent processing and highlighting key information related to abnormal behavior identification.

[0083] Average speed can be understood as the overall speed level of the target vessel during the period of deviation from the course. It can reflect the overall speed of the target vessel in the abnormal section and is the basis for judging whether there is speeding or low-speed behavior.

[0084] Speed ​​standard deviation can be understood as the degree of fluctuation in the speed of a target vessel during deviation from its course. It is used to measure the speed stability of the target vessel. A large speed standard deviation may indicate that the target vessel is accelerating, decelerating, or frequently changing speed, which may be a signal of abnormal behavior.

[0085] The rate of change of course can be understood as the rate at which the course of a target vessel changes over time while deviating from its course. It can reflect the frequency of the target vessel's turning or whether there are sudden changes in direction, such as sharp turns or irregular navigation.

[0086] Track curvature can be understood as the degree of curvature of the target vessel's path during deviation from its course. It is used to describe the smoothness of the target vessel's trajectory. High track curvature may indicate that the target vessel has made a sharp turn or irregular maneuver.

[0087] The first distance between the target vessel and the nearest port can be understood as the shortest distance between any point on the route and its nearest port. It is used to assess whether the target vessel is abnormally close to or far from the port, which may involve illegal docking, illegal trade, or deviation from the planned route into an undesignated area.

[0088] The second distance between the target vessel and the nearest restricted area can be understood as the shortest distance between any point on the route and its nearest restricted area. It is used to assess whether the target vessel is approaching or entering restricted waters, such as military restricted areas, ecological protection areas, or waterway control areas, which is usually a serious abnormal behavior.

[0089] A pre-trained abnormal behavior recognition model can be understood as a deep learning model that has been learned and optimized using a large amount of historical ship behavior data. Its function is to automatically determine whether the current behavior of a target ship is abnormal based on five input ship behavior features (i.e., average speed, speed standard deviation, rate of change of course, trajectory curvature, first distance, and second distance). This model can be built based on various machine learning algorithms. For example, traditional machine learning algorithms such as Support Vector Machines (SVM), decision trees, and random forests can be used to make judgments by learning the feature distributions of normal and abnormal behavior patterns. Alternatively, deep learning algorithms such as Long Short-Term Memory Networks (LSTM), Convolutional Neural Networks (CNN), or Deep Subspace Clustering Networks (DSC-Net) can be used. These models can learn deeper patterns from complex and multidimensional ship behavior features, thereby improving the accuracy and robustness of abnormal behavior recognition.

[0090] For example, an anomaly detection model obtained by training a DSC-Net model is used to detect anomalies in ship trajectory data. Specifically, five ship behavior features of the target ship (mean speed, speed standard deviation, rate of change of heading, trajectory curvature, first distance, and second distance) are used as input to the anomaly detection model. A multi-layer neural network automatically learns anomaly patterns in the trajectory and outputs anomaly probability scores, thus obtaining the anomaly behavior identification results for the target ship. These ship behavior features provide a multi-dimensional representation of ship motion, enhancing the model's ability to identify complex anomalies.

[0091] The average speed, speed standard deviation, rate of change of course, and trajectory curvature of the target vessel, as well as the first distance to the nearest port and the second distance to the nearest restricted area, can be calculated using equations (3) to (8).

[0092] (3) (4) (5) κ= |Δθ| / L(6) (7) (8) In equations (3) to (8), N represents the average speed, and N-1 represents the total number of deviations from the course. Indicates the first i The ground speed of the segment deviating from the trajectory; This represents the average speed over the time interval between the starting time of the first deviation segment and the ending time of the (N-1)th deviation segment. Indicates the standard deviation of velocity; This represents the rate of change of heading, and its angle difference is taken as a short arc from 0 to 180°; Indicates the first i The headings within each deviation segment can be obtained via AIS messages; Δθ represents the short arc difference between the headings of two adjacent deviation segments, L represents the deviation route containing N-1 deviation segments, and κ represents the trajectory curvature. Indicates the first i One deviation from the trajectory segment, Indicates the first distance. Indicates the second distance. Indicates the port area. Indicates the area of ​​the no-navigation zone.

[0093] The ship abnormal behavior identification method provided in this application extracts multi-dimensional features from deviations from the course, including average speed, speed standard deviation, rate of change of heading, trajectory curvature, and distance from key geographical areas. This transforms abstract trajectory data into specific, quantifiable behavioral indicators, thereby comprehensively capturing subtle changes and potential risks in ship behavior. The extraction of these features allows for a deeper analysis of ship behavior, moving beyond surface-level analysis to consider its kinematic characteristics and geographical location, significantly enriching the criteria for identifying abnormal behavior. Furthermore, inputting these rich behavioral features into a pre-trained abnormal behavior identification model enables a high degree of automation and intelligence in the identification process. This model can comprehensively analyze multi-dimensional features and learn complex abnormal patterns, overcoming the subjectivity and limitations of manual rule-based judgments and significantly improving the accuracy and robustness of abnormal behavior identification. This identification method, based on feature engineering and machine learning, not only processes data efficiently and reduces computational resource consumption, but also identifies various types of abnormal behavior, such as speeding, low speed, sharp turns, abnormal trajectories, or approaching restricted areas. This provides ship regulatory authorities with more refined and timely early warning information, effectively improving the efficiency and effectiveness of maritime safety supervision. It also effectively solves the problem of low efficiency and insufficient accuracy in identifying abnormal behavior caused by traditional methods that rely solely on deviations from the course without a specific identification mechanism.

[0094] Based on the above Figure 3 In one example embodiment of the method shown, the abnormal behavior recognition model used in step 302 is specifically trained through [method name missing]. Figure 4 Steps 401 and 402 shown are implemented.

[0095] Step 401: Obtain the training sample set; Each training sample in the training sample set includes a sample vessel that is not on every common route, as well as the sample vessel's sample average speed, sample speed standard deviation, sample heading change rate, sample first distance to the nearest port, and sample second distance to the nearest restricted area.

[0096] Step 402: Train the deep learning-based anomaly detection model based on the training sample set, the preset clustering loss function, and the preset meteorological disturbance regularization term to obtain the anomaly behavior recognition model.

[0097] Specifically, obtaining a training sample set provides learning data for the abnormal behavior recognition model, enabling it to identify ship behaviors significantly different from normal patterns. This training sample set can be obtained from historical Automatic Identification System (AIS) data, for example, by identifying known instances of abnormal behavior through manual annotation or semi-supervised learning methods and using them as positive samples; simultaneously, a portion of data can be randomly sampled from normal navigation data as negative samples. Another method is to utilize simulators to generate ship trajectory data with specific abnormal patterns to supplement the scarce anomaly types in real data. Each training sample in the training sample set includes sample ships not on every commonly used route. This feature emphasizes the selection strategy of training samples, focusing on ship data that deviates from commonly used routes. Its purpose is to enable the model to learn the characteristics of abnormal behavior more effectively, avoiding interference from a large amount of data on normal routes, thereby improving the sensitivity and accuracy of identifying abnormal behavior. These sample ships can be selected by analyzing their historical trajectories and comparing them with commonly used routes in the global shipping channel model, identifying ships that have deviated from commonly used routes for extended periods or multiple times. Alternatively, vessels operating in non-navigation areas can be directly identified as sample vessels through expert experience or pre-set rules.

[0098] The sample mean speed, sample speed standard deviation, sample heading change rate, sample first distance, and sample second distance of the sample vessels can all be calculated using equations (3) to (8), which are used to describe the characteristics of the sample vessel's behavior and its relationship with the environment. The sample mean speed and sample speed standard deviation reflect the motion state and stability of the corresponding sample vessel; the sample heading change rate characterizes the smoothness or abruptness of the corresponding sample vessel's heading; the sample first distance to the nearest port and the sample second distance to the nearest restricted area provide contextual information about the geographical location of the corresponding sample vessel, which helps to determine the compliance or risk of its behavior.

[0099] During the model training phase, the deep learning-based anomaly detection model is trained using the training sample set, a pre-defined clustering loss function, and a pre-defined meteorological disturbance regularization term. The pre-defined clustering loss function guides the deep learning model to effectively separate normal and abnormal samples in the feature space, ensuring that similar samples cluster together and dissimilar samples move apart. This helps the model learn the intrinsic structure of abnormal behavior. For example, contrastive loss can be used, which optimizes feature representation by bringing similar samples closer together and distancing dissimilar samples further apart; or triplet loss can be used, which learns discriminative features through the relative distances between anchor samples, positive samples, and negative samples.

[0100] The purpose of pre-setting a weather disturbance regularization term is to enhance the model's robustness to changes in actual weather conditions, preventing the model from misclassifying normal navigational fluctuations caused by natural factors such as wind, waves, and ocean currents as abnormal behavior. This helps improve the model's generalization ability. For example, simulated weather noise can be added to the input data during training, forcing the model to learn features that are insensitive to this noise; alternatively, a penalty term based on weather data can be introduced to increase the loss when the model exhibits overfitting under specific weather conditions.

[0101] Deep learning-based anomaly detection models are models capable of automatically learning features and identifying anomalous patterns from complex data. Their role is to leverage the powerful representational capabilities of deep neural networks to extract high-level abstract features from ship behavior characteristics, thereby more accurately identifying potential anomalous behavior. For example, an autoencoder can be used to detect anomalies by learning compressed representations and reconstructions of data, since anomalous data is often difficult to reconstruct effectively; alternatively, a generative adversarial network (GAN) can be used for anomaly detection, learning the distribution of normal data through adversarial training between the generator and discriminator, thus identifying anomalous data that deviates from this distribution. After training, an anomaly behavior recognition model is obtained, capable of performing anomaly behavior recognition tasks.

[0102] The ship abnormal behavior identification method provided in this application, through an innovatively constructed training sample set, particularly focusing on sample ships not on commonly used routes, and extracting multi-dimensional behavioral features, enables the abnormal behavior identification model to learn abnormal patterns more accurately, avoiding interference from normal navigation data. Furthermore, the introduction of a preset clustering loss function and a preset weather disturbance regularization term further optimizes the model's discriminative ability and robustness to environmental changes, significantly improving the model's generalization performance and identification accuracy in complex marine environments. Finally, by combining the mapping relationship between abnormal probability, abnormal behavior, and risk level, the model's output results are more interpretable and practical, facilitating rapid understanding and action by regulatory authorities. This comprehensive training and output mechanism makes the judgment of abnormal behavior based on deviation from the route more reliable and efficient, thereby improving the intelligent level of maritime ship supervision and effectively ensuring maritime safety.

[0103] Based on the above Figure 1 In one example embodiment, the method shown, besides obtaining the abnormal behavior recognition results of the target ship by sampling a pre-trained abnormal behavior recognition model, can also perform abnormal ship behavior recognition through a pre-set rule engine. Based on this, after extracting five ship behavior features in step 301, it can also be further refined through... Figure 5 Steps 501 to 507 shown complete the identification of abnormal behavior.

[0104] Step 501: If the instantaneous speed of the target vessel exceeds the first speed threshold, it is determined that the target vessel is speeding; the first speed threshold is the sum of the average speed and the speed standard deviation of the first preset multiple.

[0105] Step 502: If the instantaneous speed of the target vessel is lower than the second speed threshold, it is determined that the target vessel is exhibiting low-speed behavior; the second speed threshold is the result of subtracting the average speed from the speed standard deviation of the second preset multiple.

[0106] Step 503: If the rate of change of course exceeds the rate of change threshold, it is determined that the target vessel has a sudden change in direction.

[0107] Step 504: If the trajectory curvature exceeds the curvature threshold, it is determined that the target vessel has abnormal trajectory behavior.

[0108] Step 505: If the first distance or the second distance is less than the preset safe distance threshold, it is determined that the target vessel is approaching a restricted area.

[0109] Step 506: If the target vessel stays in the preset non-port area for more than the time threshold and its speed is lower than the speed threshold, then it is determined that the target vessel has anchored.

[0110] Step 507: If the distance between the target vessel and another vessel remains below the distance threshold within a preset time period, it is determined that the target vessel is engaged in transshipment.

[0111] It should be noted that step 502 is executed when the instantaneous speed of the target vessel does not exceed the first speed threshold; step 503 is executed when the instantaneous speed of the target vessel exceeds the second speed threshold; step 504 is executed when the rate of change of course does not exceed the rate of change threshold; step 505 is executed when the trajectory curvature does not exceed the curvature threshold; step 506 is executed when both the first and second distances exceed the preset safe distance thresholds; and step 507 is executed when the target vessel's dwell time in the preset non-port area does not exceed the time threshold and / or its speed exceeds the speed threshold. Alternatively, multiple extracted vessel behavior characteristics can be used simultaneously to determine whether the vessel is speeding, slowing down, experiencing sudden changes in direction, exhibiting abnormal trajectories, approaching restricted areas, anchoring, or transshipment. The execution order of steps 501 to 507 is not specifically limited here.

[0112] The first speed threshold and the second speed threshold are used to dynamically determine whether the speed of the target vessel is abnormal. The first speed threshold is used to identify speeding behavior, and it is calculated as the sum of the average speed of the target vessel and the standard deviation of the average speed of a first preset multiple. The second speed threshold is used to identify low-speed behavior, and it is calculated as the difference between the average speed of the target vessel and the standard deviation of the average speed of a second preset multiple. This statistical method can dynamically adjust the thresholds according to the historical behavior of the target vessel or the average behavior of its environment, rather than using fixed absolute values, thereby improving the adaptability and accuracy of anomaly identification.

[0113] The first and second preset multipliers are configurable parameters used to adjust the sensitivity of the speed threshold. For example, the first preset multiplier can be set to 2, meaning that when the instantaneous speed exceeds the average speed plus 2 standard deviations, it is considered speeding. The second preset multiplier can also be set to 2, meaning that when the instantaneous speed is lower than the average speed minus 2 standard deviations, it is considered slow. By adjusting these preset multipliers, the strictness of the identification can be flexibly controlled according to the actual application scenario and the tolerance for abnormal behavior.

[0114] The rate of change threshold is a preset value used to determine whether the rate of change of course has reached an abnormal level. When the rate of change of course exceeds this threshold, the target vessel is considered to have experienced a sudden change in direction. This rate of change threshold can be set empirically or derived through historical data analysis based on the normal turning capabilities of different types of vessels, the navigation environment (such as narrow waterways or open seas), and the definition of abrupt change behavior.

[0115] The curvature threshold is a preset value used to determine whether the trajectory curvature has reached an abnormal level; when the trajectory curvature exceeds this threshold, the trajectory of the target vessel is considered abnormal. This curvature threshold can be set according to the type of the target vessel, the characteristics of the navigation area, and the definition of trajectory abnormality.

[0116] A preset safe distance threshold is a configurable distance value used to define the safe range for a vessel approaching a port or restricted area. When either a first distance or a second distance is less than this preset safe distance threshold, the target vessel is considered to be approaching a restricted area. This preset safe distance threshold can be set according to the specific regulations of the port or restricted area, the size and maneuverability of the vessel, and safety management requirements.

[0117] Another vessel can understand other vessels not sailing near the target vessel, and their positions and navigation information can also be obtained through AIS data.

[0118] The preset duration is a time parameter used to determine the duration of close contact between ships. For example, it can be set to 1 hour or longer.

[0119] The distance threshold (used for transshipment) is a distance parameter used to define whether two vessels are in close proximity. For example, it can be set to 500 meters.

[0120] Speeding, low-speeding, sudden change of direction, abnormal trajectory, approach to restricted areas, and transshipment are the specific abnormal behavior types identified in this scheme. Each behavior corresponds to a specific navigation state or operating mode, which may indicate that the vessel is in violation of regulations, in danger, or experiencing unexpected situations.

[0121] Specifically, by combining expert knowledge, judgment rules for different types of abnormal behavior can be pre-set. In this way, the specific abnormal behavior of the target vessel can be identified based on the extracted vessel behavior characteristics.

[0122] For example, if the instantaneous speed of the target vessel exceeds its average speed plus twice the speed standard deviation, that is... If so, it is judged as speeding; For average speed, For the speed standard deviation, This refers to instantaneous velocity.

[0123] If the instantaneous speed of the target vessel is lower than its average speed minus twice the speed standard deviation, that is... If so, it is judged as low speed.

[0124] If the rate of change of the target vessel's course exceeds the rate of change threshold (e.g., 30° / minute), that is... If so, it is determined to be a sudden change in direction; This represents the rate of change of heading.

[0125] If the curvature of the target vessel's trajectory exceeds a curvature threshold (e.g., 0.1 radians / meter), that is... If so, it is determined to be an abnormal trajectory, indicating that the target vessel may be engaging in detour or evasive maneuvers; Let be the trajectory curvature.

[0126] If the target vessel's first distance from the nearest port or its second distance from the restricted area is less than a preset safety distance threshold (e.g., 500 meters), that is... If so, it is determined that the area is approaching an abnormal restricted zone; It can be either the first distance or the second distance.

[0127] If the target vessel stays in the preset non-port area (i.e., the distance between the target vessel and the nearest port is greater than the preset port radius, such as 1000 meters) for more than a preset time threshold (e.g., 1 hour) and its speed is close to 0, that is... If so, it is determined to be an anchor break-in; For the duration of stay, The distance between the target vessel and the nearest port.

[0128] If the distance between two vessels (i.e., the target vessel and another vessel) remains below a distance threshold (e.g., 300 meters) for a preset time period (e.g., 1 hour), that is... If so, it is deemed an overstatement; The distance between the target vessel and another vessel. This is the preset duration.

[0129] The ship abnormal behavior identification method provided in this application introduces a series of targeted abnormal behavior judgment rules, which can directly and quickly identify various specific abnormal behaviors such as speeding, low speeding, sudden changes in direction, abnormal trajectory, approaching restricted areas, anchoring, and transshipment. This rule-driven detection method avoids the complexity and delay of model inference, significantly improving the real-time performance of abnormal behavior identification. Simultaneously, because the threshold setting considers the ship's own dynamic characteristics (such as average speed and speed standard deviation), the identification results are more accurate and robust, reducing false alarms and missed alarms. Especially after the target ship deviates from its usual route, it can provide more detailed and targeted abnormal behavior analysis, providing timely and accurate early warning information to regulatory authorities, thereby better ensuring maritime navigation safety and order.

[0130] Based on the above Figure 3 In one example embodiment of the method shown, considering that the abnormal behavior identification result output by the abnormal behavior identification model is usually an abnormality probability score, a mapping mechanism that maps probability to specific abnormal behaviors and specific risk levels can be pre-constructed. This makes the abnormality identification result more intuitive and operable, improving regulatory efficiency and decision-making accuracy. Based on this, the embodiments of this application can also provide an abnormality probability mapping process, which can be implemented through the following steps in this embodiment.

[0131] When the abnormal behavior recognition model outputs an abnormal behavior recognition result that is the target abnormal probability, the target abnormal behavior with the target risk level corresponding to the target abnormal probability is generated and published based on the pre-set mapping relationship between abnormal probability, abnormal behavior and risk level.

[0132] Specifically, when the abnormal behavior recognition model outputs the abnormal behavior recognition result as the target abnormal probability, the target abnormal probability is usually a value between 0 and 1, used to quantify the possibility of abnormal ship behavior.

[0133] To transform this abstract target anomaly probability into understandable and actionable information, this embodiment introduces a pre-defined mapping relationship between anomaly probability, abnormal behavior, and risk level. This mapping relationship is a predefined set of rules or a lookup table that associates a specific anomaly probability range with a specific type of abnormal behavior (e.g., deviation from the flight path, slow driving, approaching a restricted area) and the corresponding risk level (e.g., low risk, medium risk, high risk, emergency risk). This mapping relationship can be set based on expert experience, historical data analysis, or regulatory provisions. For example, it can be set that when the anomaly probability is below a certain threshold, it is judged as normal behavior; when the anomaly probability is between two thresholds, it is judged as a specific type of abnormal behavior and assigned a medium risk level; when the anomaly probability is above a certain higher threshold, it is judged as a more serious abnormal behavior and assigned a high risk or emergency risk level.

[0134] Based on the aforementioned mapping relationship, it is possible to generate and publish target abnormal behaviors corresponding to target risk levels with target abnormal probabilities. This means that once the abnormal behavior identification model outputs a target abnormal probability, it will immediately query the preset mapping relationship to determine the specific abnormal behavior type and risk level corresponding to that target abnormal probability, and push this specific abnormal behavior type and risk level to the regulatory terminal in a structured form in real time to help regulatory authorities take rapid measures. For example, an alarm message containing information such as ship identification, abnormal behavior type, risk level, occurrence time, and geographical location can be generated and published to relevant regulatory personnel or automated systems through a visual interface, email, SMS, or other communication methods.

[0135] The ship abnormal behavior identification method provided in this application transforms the abstract target abnormal probability output by the abnormal behavior identification model into specific target risk levels and target abnormal behaviors through a pre-set mapping relationship, thereby making the identification results more interpretable and operable. This transformation mechanism ensures that even if the model outputs continuous probability values, regulatory personnel can quickly understand their meaning and take corresponding actions based on the clear risk level and behavior type. This not only improves the efficiency of abnormal behavior identification and enhances the accuracy and timeliness of regulatory decisions, but also effectively solves the problem of the lack of intuitive interpretation and operability when the abnormal probability output by the abnormal behavior identification model is displayed. This makes the abnormal identification results clearer and more standardized, greatly improving the regulatory authorities' understanding and response capabilities to ship abnormal behavior, optimizing the decision-making process, reducing the risk of misjudgment and omission, and improving the overall efficiency and accuracy of maritime supervision, thereby better safeguarding maritime safety and order.

[0136] Based on the above Figure 1In one example embodiment of the method shown, step 102 involves determining the shortest vertical distance from the current trajectory point to the candidate route. The specific process of this step in this embodiment can be achieved through… Figure 6 Steps 601 and 602 shown are implemented.

[0137] Step 601: Cut the centerline of the candidate route to obtain multiple line segments.

[0138] Step 602: Determine the vertical distance from the current trajectory point to each line segment, and determine the shortest vertical distance from multiple vertical distances.

[0139] Specifically, the centerline of the candidate route is cut to obtain multiple line segments. The aim is to decompose a potentially complex and lengthy candidate route into multiple easily manageable geometric units. This cutting can be achieved based on various strategies. For example, according to a preset length threshold, a point can be selected on the centerline at fixed intervals as a cutting point, and the route portion between adjacent cutting points can be defined as a line segment. Alternatively, the cutting can be based on the curvature change characteristics of the candidate route, cutting at locations where the curvature changes significantly (such as inflection points) to ensure that each line segment is approximately a straight line within a local range.

[0140] After dividing the candidate flight path into multiple line segments, it is necessary to determine the perpendicular distances from the current trajectory point to each of these line segments. This step is fundamental to calculating the shortest perpendicular distance, and its purpose is to quantify the proximity of the current trajectory point to each line segment in the candidate flight path. For each line segment, a standard geometric algorithm can be used to calculate the perpendicular distance from the current trajectory point to each line segment. For example, under two-dimensional plane projection, the perpendicular distance from the current trajectory point to the line containing the line segment can be calculated, and it can be further determined whether the perpendicular projection point falls inside the line segment. If the projection point is inside the line segment, then the perpendicular distance is the desired value; if the projection point is outside the line segment, then the distance is the closer distance between the current trajectory point and the two endpoints of the line segment. In practical applications, considering the curvature of the Earth, a local plane approximation or a more accurate geodesic distance calculation method can be used. Finally, the shortest vertical distance is determined from multiple vertical distances. After calculating the vertical distance from the current trajectory point to each line segment, these vertical distances are compared, and the minimum distance is selected. This minimum distance is determined as the shortest vertical distance from the current trajectory point to the entire candidate route. This process can be achieved by iterating through all the calculation results and comparing them, or by dynamically updating the minimum value during the calculation process, thus efficiently obtaining the final result.

[0141] For example, the current trajectory point is denoted as point p, and point p contains information such as latitude, longitude, speed, and azimuth. The centerline of the candidate route is denoted as centerline R, and it is divided into m-1 line segments. In this way, the shortest vertical distance from the current trajectory point to the candidate route can be determined by equation (9). .

[0142] (9) In equation (9), This represents the starting point of the j-th segment in the centerline R. This represents the endpoint of the j-th segment in the centerline R.

[0143] The ship abnormal behavior identification method provided in this application decomposes complex candidate routes into multiple simple line segments, thereby transforming the distance calculation problem from a point to a complex route into the distance calculation problem from a point to multiple line segments. This decomposition strategy significantly reduces the complexity of a single distance calculation. By calculating the perpendicular distance from the current trajectory point to each line segment separately and selecting the minimum value, the actual shortest perpendicular distance from the current trajectory point to the candidate route can be obtained efficiently and accurately. This method, combined with basic ship abnormal behavior identification methods, enables the rapid and real-time acquisition of key distance parameters when determining whether the current trajectory point is an abnormal navigation trajectory point. This improves the response speed and computational efficiency of the entire abnormal behavior identification process, allowing the ship abnormal behavior identification process to respond more quickly to changes in ship position and promptly detect potential abnormal navigation trajectory points. This enhances the overall accuracy and timeliness of abnormal behavior identification, providing more efficient technical support for maritime supervision and effectively solving the problems of high computational load and low efficiency in traditional methods that directly calculate the shortest perpendicular distance from a point to a complex route.

[0144] Therefore, this application analyzes AIS data globally to fit commonly used shipping routes and generate a global shipping lane model. Based on this model, it can quickly identify normally navigating vessels and those exhibiting abnormal behavior, and perform more precise analysis of abnormal vessels. This significantly improves the efficiency and accuracy of identifying abnormal vessels at sea, optimizes resource utilization, and provides law enforcement agencies with an efficient and accurate solution for maritime vessel supervision. Specifically, this application mainly proposes an efficient screening mechanism and a precise method for analyzing abnormal behavior.

[0145] Efficient screening mechanism: By fitting the global shipping route model, a large number of ships on normal routes can be quickly screened out, thereby significantly reducing the amount of data calculation and resource consumption; this mechanism enables the system to concentrate resources on further analyzing ships that are not on commonly used routes, improving the overall efficiency and response speed of the system.

[0146] Precise Anomaly Behavior Analysis Methods: For vessels not on frequently used routes, further anomaly behavior analysis is conducted. Deep learning-based anomaly detection models (such as DSC-Net), combined with weather disturbance regularization terms and clustering loss functions, are employed to more accurately identify and address anomalous vessel behavior. This method not only improves the accuracy of anomaly behavior identification but also reduces false alarms and false negatives, providing regulatory authorities with more reliable decision support.

[0147] In summary, this application has the following significant advantages: 1) Significantly improve regulatory efficiency: By fitting the global shipping route model, a large number of ships on normal navigation can be quickly filtered out, thereby significantly reducing the amount of data calculation and resource consumption. This allows the system to concentrate resources on more accurate analysis of ships that are not on commonly used routes, improving the overall efficiency and response speed of the system, reducing false alarms and missed alarms, and improving regulatory efficiency.

[0148] 2) Improved accuracy of abnormal behavior identification: This application employs a deep learning-based anomaly detection model (such as DSC-Net), combined with a weather disturbance regularization term and a clustering loss function, which can more accurately identify and process abnormal ship behavior. This method not only improves the accuracy of abnormal behavior identification but also reduces false alarms and false negatives, providing regulatory authorities with more reliable decision support.

[0149] 3) Enhanced system real-time performance and dynamic adaptability: This application optimizes the processing flow, achieving a second-level response time and ensuring the shortest possible time from data acquisition to alarm issuance. Through a streaming dual-buffered architecture, combined with GPU batch processing and CPU real-time noise reduction, the system can process data and issue alarms in real time, helping regulatory authorities to take timely measures to ensure maritime safety.

[0150] 4) Reduced system resource consumption: Through an efficient route screening mechanism, this application significantly reduces the amount of data that needs to be processed and reduces system resource consumption. This enables the system to process more data with limited computing resources and improves the system's scalability.

[0151] It should be noted that although the operations of the method of this application are described in a specific order in the accompanying drawings, this does not require or imply that these operations must be performed in that specific order, or that all the operations shown must be performed to achieve the desired result. On the contrary, the steps depicted in the flowchart can be performed in a different order. Additionally or alternatively, certain steps may be omitted, multiple steps may be combined into one step, and / or one step may be broken down into multiple steps.

[0152] In one embodiment, this application also provides a device for identifying abnormal ship behavior, such as... Figure 7As shown, the abnormal behavior identification device for ships includes: a candidate route determination unit 701, an abnormal behavior preliminary judgment unit 702, and an abnormal behavior identification unit 703.

[0153] The candidate route determination unit 701 is used to determine candidate routes containing the current trajectory points of the target vessel based on a pre-built global shipping route model. The global shipping route model includes all commonly used routes fitted by analyzing AIS data of ships at sea worldwide.

[0154] The abnormal behavior initial judgment unit 702 is used to determine the shortest vertical distance from the current trajectory point to the candidate route, and the angle between the heading of the current trajectory point and the route direction of the candidate route. If the shortest vertical distance is higher than the distance threshold and / or the angle is higher than the angle threshold, the current trajectory point is determined to be an abnormal driving trajectory point. The unit continuously acquires new current trajectory points of the target vessel and repeats the above process until the cumulative number of abnormal driving trajectory points meets the number threshold. The trajectory lines drawn by multiple abnormal driving trajectory points that meet the number threshold are then determined as deviations from the route. The deviations from the route are used to indicate that the target vessel is not on each commonly used route.

[0155] The abnormal behavior identification unit 703 is used to identify abnormal behavior of the target vessel based on deviation from the course, and to generate and publish the abnormal behavior identification results of the target vessel.

[0156] Optionally, the candidate route determination unit 701 is specifically used to perform time synchronization, spatial alignment, and outlier removal on the original AIS dataset of ships at sea worldwide to obtain the target AIS dataset. For each target AIS data in the target AIS dataset, the ship trajectory sequence corresponding to the target AIS data is segmented, and then the discrete trajectory point set of each trajectory sequence segment is hierarchically clustered. Then, the cluster with the longest lifecycle is selected from the hierarchical clustering tree and denoised to obtain multiple target stable clusters of ships corresponding to the target AIS data. The multiple target stable clusters of all target AIS data are projected onto the map, and spatially overlapping or parallel target stable clusters are merged, deduplicated, and smoothed to obtain a global ship waterway model that includes all commonly used routes.

[0157] Optionally, the candidate route determination unit 701 is specifically used to determine the spherical distance between each two adjacent discrete trajectory points in the discrete trajectory point set of the trajectory sequence segment obtained after segmenting the ship trajectory sequence corresponding to the target AIS data, and to perform hierarchical clustering of multiple spherical distances using the minimum spanning tree algorithm; the discrete trajectory point set is formed after sampling trajectory points of the trajectory sequence segment according to a preset time interval.

[0158] Optionally, the abnormal behavior initial judgment unit 702 is specifically used to cut the centerline of the candidate route to obtain multiple line segments; determine the vertical distance from the current trajectory point to each line segment, and determine the shortest vertical distance from multiple vertical distances.

[0159] Optionally, the abnormal behavior recognition unit 703 is specifically used to extract features from deviations from the course, obtain the target vessel's average speed, speed standard deviation, rate of change of course, and trajectory curvature, as well as the first distance to the nearest port and the second distance to the nearest restricted area; input the average speed, speed standard deviation, rate of change of course, trajectory curvature, first distance, and second distance into a pre-trained abnormal behavior recognition model for abnormal behavior recognition, and obtain the abnormal behavior recognition results output by the abnormal behavior recognition model.

[0160] Optionally, the abnormal behavior recognition unit 703 is specifically used to acquire a training sample set; each training sample in the training sample set includes a sample vessel not on every common route, as well as the sample vessel's sample average speed, sample speed standard deviation, sample heading change rate, sample first distance to the nearest port, and sample second distance to the nearest restricted area; the deep learning-based anomaly detection model is trained based on the training sample set, a preset clustering loss function, and a preset weather disturbance regularization term to obtain the abnormal behavior recognition model.

[0161] Optionally, the abnormal behavior identification unit 703 is specifically used to determine that the target vessel is speeding if its instantaneous speed exceeds a first speed threshold; the first speed threshold is the sum of the average speed and the speed standard deviation of a first preset multiple; if the instantaneous speed of the target vessel is lower than a second speed threshold, it is determined that the target vessel is slowing down; the second speed threshold is the subtraction between the average speed and the speed standard deviation of a second preset multiple; if the rate of change of course exceeds a rate of change threshold, it is determined that the target vessel is changing direction abruptly; if the trajectory curvature exceeds a curvature threshold, it is determined that the target vessel is exhibiting abnormal trajectory behavior; if the first distance or the second distance is less than a preset safe distance threshold, it is determined that the target vessel is approaching a restricted area; if the target vessel stays in a preset non-port area for a period of time exceeding a time threshold and its speed is lower than a speed threshold, it is determined that the target vessel is anchoring; if the distance between the target vessel and another vessel remains below a distance threshold for a preset duration, it is determined that the target vessel is transshipping.

[0162] Optionally, the abnormal behavior identification unit 703 is specifically used to generate and publish a target abnormal behavior with a target risk level corresponding to the target abnormal probability, based on a pre-set mapping relationship between abnormal probability, abnormal behavior, and risk level, when the abnormal behavior identification result output by the abnormal behavior identification model is the target abnormal probability.

[0163] It should be understood that the units recorded in the ship abnormal behavior identification device are related to the reference. Figure 1 The steps in the described method correspond to each other. Therefore, the operations and features described above for the method are also applicable to the ship abnormal behavior identification device and the units contained therein, and will not be repeated here. The ship abnormal behavior identification device can be pre-implemented in a computer device's browser or other security applications, or it can be loaded into a computer device's browser or its security applications through download or other means. The corresponding units in the ship abnormal behavior identification device can cooperate with the units in the computer device to implement the solutions of the embodiments of this application.

[0164] The following is for reference. Figure 8 It shows a schematic diagram of the structure of a computer system 800 suitable for implementing computer devices or servers in the embodiments of this application.

[0165] like Figure 8 As shown, the computer system 800 includes a central processing unit (CPU) 801, which can perform various appropriate actions and processes based on programs stored in read-only memory (ROM) 802 or programs loaded from storage section 808 into random access memory (RAM) 803. The RAM 803 also stores various programs and data required for the operation of the system 800. The CPU 801, ROM 802, and RAM 803 are interconnected via a bus 804. An input / output (I / O) interface 805 is also connected to the bus 804.

[0166] The following components are connected to I / O interface 805: an input section 806 including a keyboard, mouse, etc.; an output section 807 including a cathode ray tube (CRT), liquid crystal display (LCD), etc., and speakers, etc.; a storage section 808 including a hard disk, etc.; and a communication section 809 including a network interface card such as a LAN card, modem, etc. The communication section 809 performs communication processing via a network such as the Internet. A drive 810 is also connected to I / O interface 805 as needed. A removable medium 811, such as a disk, optical disk, magneto-optical disk, semiconductor memory, etc., is installed on drive 810 as needed so that computer programs read from it can be installed into storage section 808 as needed.

[0167] Specifically, according to embodiments of this application, the above references Figure 1 The described process can be implemented as a computer software program. For example, embodiments of this application include a computer program product comprising a computer program tangibly embodied on a machine-readable medium, the computer program containing instructions for performing... Figure 1The program code for the method. In such an embodiment, the computer program can be downloaded and installed from a network via the communication section 809, and / or installed from removable media 811.

[0168] It should be noted that the computer-readable medium shown in this application can be a computer-readable signal medium or a computer-readable storage medium, or any combination of the two. A computer-readable storage medium can be, for example,—but not limited to—an electrical, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any combination thereof. More specific examples of a computer-readable storage medium may include, but are not limited to: an electrical connection having one or more wires, a portable computer disk, a hard disk, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or flash memory), optical fiber, portable compact disk read-only memory (CD-ROM), optical storage device, magnetic storage device, or any suitable combination thereof. In this application, a computer-readable storage medium can be any tangible medium containing or storing a program that can be used by or in conjunction with an instruction execution system, apparatus, or device. In this application, a computer-readable signal medium can include a data signal propagated in baseband or as part of a carrier wave, carrying computer-readable program code. Such propagated data signals can take various forms, including but not limited to electromagnetic signals, optical signals, or any suitable combination thereof. Computer-readable signal media can also be any computer-readable medium other than computer-readable storage media, which can send, propagate, or transmit a program for use by or in connection with an instruction execution system, apparatus, or device. The program code contained on the computer-readable medium can be transmitted using any suitable medium, including but not limited to: wireless, wire, optical fiber, RF, etc., or any suitable combination thereof.

[0169] The flowcharts and block diagrams in the accompanying drawings illustrate the architecture, functionality, and operation of possible implementations of systems, methods, and computer program products according to various embodiments of this application. In this regard, each block in a flowchart or block diagram may represent a module, segment, or portion of code containing one or more executable instructions for implementing a specified logical function. It should also be noted that in some alternative implementations, the functions indicated in the blocks may occur in a different order than those indicated in the drawings. For example, two consecutively indicated blocks may actually be executed substantially in parallel, and they may sometimes be executed in reverse order, depending on the functions involved. It should also be noted that each block in the block diagrams and / or flowcharts, and combinations of blocks in the block diagrams and / or flowcharts, can be implemented using a dedicated hardware-based system that performs the specified function or operation, or using a combination of dedicated hardware and computer instructions.

[0170] The units or modules described in the embodiments of this application can be implemented in software or hardware. The described units or modules can also be located in a processor. The names of these units or modules do not, in certain circumstances, constitute a limitation on the unit or module itself.

[0171] On the other hand, this application also provides a computer-readable storage medium, which may be included in the computer device described in the above embodiments, or may exist independently and not assembled into the computer device. The aforementioned computer-readable storage medium stores one or more programs that, when used by one or more processors, execute the methods described in this application. For example, it may execute... Figure 1 The steps of the method shown are as follows.

[0172] This application provides a computer program product including instructions that, when executed, cause the method described in this application to be performed. For example, it can execute... Figure 1 The steps of the method shown are as follows.

[0173] Those skilled in the art will understand that all or part of the processes in the above embodiments can be implemented by a computer program instructing related hardware. The computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments described above. Any references to memory, databases, or other media used in the embodiments provided in this application can include at least one of non-volatile and volatile memory. Non-volatile memory can include read-only memory (ROM), magnetic tape, floppy disk, flash memory, optical memory, high-density embedded non-volatile memory, resistive random access memory (ReRAM), magnetic random access memory (MRAM), ferroelectric random access memory (FRAM), phase change memory (PCM), graphene memory, etc. Volatile memory can include random access memory (RAM) or external cache memory, etc. By way of illustration and not limitation, RAM can take many forms, such as Static Random Access Memory (SRAM) or Dynamic Random Access Memory (DRAM). The databases involved in the embodiments provided in this application may include at least one type of relational database and non-relational database. Non-relational databases may include, but are not limited to, blockchain-based distributed databases. The processors involved in the embodiments provided in this application may be general-purpose processors, central processing units, graphics processing units, digital signal processors, programmable logic devices, quantum computing-based data processing logic devices, etc., and are not limited to these.

[0174] The above description is merely a preferred embodiment of this application and an explanation of the technical principles employed. Those skilled in the art should understand that the scope of the invention involved in this application is not limited to technical solutions formed by specific combinations of the above-described technical features, but should also cover other technical solutions formed by arbitrary combinations of the above-described technical features or their equivalents without departing from the inventive concept. For example, technical solutions formed by substituting the above features with (but not limited to) technical features with similar functions disclosed in this application.

Claims

1. A method for identifying abnormal ship behavior, characterized in that, The method includes: Based on a pre-built global shipping route model, candidate routes containing the current trajectory points of the target vessel are determined. The global shipping route model includes all commonly used routes fitted by analyzing AIS data of ships at sea worldwide. Determine the shortest vertical distance from the current trajectory point to the candidate route, and the angle between the heading of the current trajectory point and the route direction of the candidate route; If the shortest vertical distance is higher than the distance threshold and / or the included angle is higher than the angle threshold, then the current trajectory point is determined to be an abnormal driving trajectory point; The process continues to acquire new current trajectory points of the target vessel and repeats the above process until the cumulative number of abnormal driving trajectory points meets the number threshold. Then, the trajectory lines drawn by the multiple abnormal driving trajectory points that meet the number threshold are determined as deviations from the route. The deviations from the route are used to indicate that the target vessel is not on each of the commonly used routes. Based on the deviation from the course, the abnormal behavior of the target vessel is identified, and the abnormal behavior identification results of the target vessel are generated and published.

2. The method according to claim 1, characterized in that, The global shipping route model is constructed by including: The original AIS dataset of ships at sea worldwide is subjected to time synchronization, spatial alignment and outlier removal to obtain the target AIS dataset; For each target AIS data in the target AIS dataset, the ship trajectory sequence corresponding to the target AIS data is segmented, and then the discrete trajectory point set of each trajectory sequence segment is hierarchically clustered. Then, the cluster with the longest life cycle is selected from the hierarchical clustering tree and noise is reduced to obtain multiple target stable clusters of ships corresponding to the target AIS data. Project the multiple target stable clusters of all the target AIS data onto the map, and merge, deduplicate and smooth the target stable clusters that are spatially overlapping or parallel to obtain the global shipping route model that includes all the commonly used routes.

3. The method according to claim 2, characterized in that, The hierarchical clustering of the discrete trajectory point set for each trajectory sequence segment includes: For each trajectory sequence segment obtained by segmenting the target AIS data corresponding to the ship trajectory sequence, the spherical distance between every two adjacent discrete trajectory points in the discrete trajectory point set of the trajectory sequence segment is determined, and the minimum spanning tree algorithm is used to perform hierarchical clustering on multiple spherical distances; the discrete trajectory point set is formed by sampling trajectory points of the trajectory sequence segment at preset time intervals.

4. The method according to claim 1, characterized in that, The step of identifying abnormal behavior of the target vessel based on the deviation from the course, and generating and publishing the abnormal behavior identification results of the target vessel, includes: Feature extraction is performed on the deviation from the course to obtain the target vessel's average speed, speed standard deviation, rate of change of course, and trajectory curvature, as well as the first distance to the nearest port and the second distance to the nearest restricted area; The average speed, the speed standard deviation, the heading change rate, the trajectory curvature, the first distance, and the second distance are all input into a pre-trained abnormal behavior recognition model to identify abnormal behavior, and the abnormal behavior recognition result output by the abnormal behavior recognition model is obtained.

5. The method according to claim 4, characterized in that, The method further includes: Obtain a training sample set; each training sample in the training sample set includes a sample vessel not on each of the commonly used routes, as well as the sample vessel's sample average speed, sample speed standard deviation, sample heading change rate, sample first distance to the nearest port of the sample, and sample second distance to the nearest restricted area of ​​the sample; The deep learning-based anomaly detection model is trained using the training sample set, a preset clustering loss function, and a preset meteorological disturbance regularization term to obtain the abnormal behavior recognition model.

6. The method according to claim 4, characterized in that, The method further includes: If the instantaneous speed of the target vessel exceeds a first speed threshold, it is determined that the target vessel is speeding; the first speed threshold is the sum of the average speed and the speed standard deviation of a first preset multiple. If the instantaneous speed of the target vessel is lower than the second speed threshold, it is determined that the target vessel is exhibiting low-speed behavior; the second speed threshold is the result of subtracting the average speed from the speed standard deviation which is a second preset multiple. If the rate of change of course exceeds the rate of change threshold, then the target vessel is determined to have a sudden change in direction. If the trajectory curvature exceeds the curvature threshold, it is determined that the target vessel exhibits abnormal trajectory behavior. If either the first distance or the second distance is less than a preset safe distance threshold, then it is determined that the target vessel is approaching a restricted area. If the target vessel stays in the preset non-port area for more than a time threshold and its speed is lower than a speed threshold, then it is determined that the target vessel has anchored. If the distance between the target vessel and another vessel remains below a distance threshold for a preset period of time, it is determined that the target vessel is engaging in transshipment activities.

7. The method according to claim 4, characterized in that, The method further includes: When the abnormal behavior recognition result output by the abnormal behavior recognition model is the target abnormal probability, a target abnormal behavior with a target risk level corresponding to the target abnormal probability is generated and published according to the pre-set mapping relationship between abnormal probability, abnormal behavior and risk level.

8. The method according to claim 1, characterized in that, Determining the shortest vertical distance from the current trajectory point to the candidate route includes: The centerline of the candidate route is cut to obtain multiple line segments; Determine the vertical distance from the current trajectory point to each of the line segments, and determine the shortest vertical distance from a plurality of the vertical distances.

9. A computer device, comprising a processor, a memory, and a computer program stored in the memory and executable on the processor, characterized in that, When the processor executes the computer program, it implements the ship abnormal behavior identification method according to any one of claims 1 to 8.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by the processor, it implements the ship abnormal behavior identification method according to any one of claims 1 to 8.