A method and device for evaluating traffic congestion

By clustering ship trajectory information, the problem of high data processing complexity and inability to accurately reflect the busy ship traffic in the prior art is solved, and higher data processing efficiency and more accurate assessment of busy traffic are achieved.

CN118865745BActive Publication Date: 2025-03-25TRANSPORT PLANNING & RES INST MINIST OF TRANSPORT
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202410870084.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-06-28
Publication Date
2025-03-25
Estimated Expiration
2044-06-28

AI Technical Summary

Technical Problem

When the prior art deals with the busyness of ship traffic, the data processing is complex and cannot accurately reflect the busyness of ship traffic.

Method used

By acquiring ship identification data, clustering trajectory information, the data processing complexity is reduced, and the accuracy reflecting busy ship traffic is improved. The specific steps include obtaining ship identification data, generating a first trajectory set, performing clustering to obtain the second trajectory set, calculating the area, calculating the busy index, and outputting water traffic reference data.

Benefits of technology

By clustering trajectory information, the complexity of data processing is reduced, the accuracy reflecting busy ship traffic is improved, and maritime traffic can be more effectively evaluated and managed.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118865745B_ABST
    Figure CN118865745B_ABST
Patent Text Reader

Abstract

The embodiment of the present invention discloses a method and device for evaluating the degree of traffic congestion. By acquiring ship identification data, a first trajectory set is acquired according to the ship identification data, the first trajectory set is clustered to acquire at least one second trajectory set, a first region area is acquired according to the first trajectory set through a ship domain model, a second region area corresponding to each second trajectory set is acquired, a congestion index is acquired according to the first region area and the second region area, and water traffic reference data is acquired and output according to the congestion index. Thus, by clustering trajectory information, the complexity of data processing can be reduced, and the accuracy of reflecting the congestion of ship traffic can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention relates to the field of shipping data processing, and in particular to a method and device for evaluating traffic congestion. Background Art

[0002] As shipping accounts for an increasing proportion of the logistics system, the demand for safety in maritime transportation continues to grow. For this reason, the International Maritime Organization proposed the installation of an AIS system (Automatic Identification System). AIS data includes dynamic and static information of ships, which can well describe the operating status of ships. In busy shipping ports, ships come from all directions and follow different routes. These routes are not only affected by hydrological conditions and navigation rules, but also by their own characteristics such as ship type, size, and loading status. At present, the data reflecting the busy ship traffic mainly includes obtaining the number of ships passing through a certain water area within a statistical unit time; simulating the ship's driving process and analyzing the water traffic situation by establishing a ship driving model or a water traffic simulation model; using a geographic information system to perform spatial analysis on the ship's driving trajectory and calculate the ship density and distribution range. These methods often have the problem of high processing complexity and cannot accurately reflect the busy ship traffic situation. Summary of the invention

[0003] In view of this, an embodiment of the present invention provides a method and device for evaluating traffic congestion, which can reduce the complexity of data processing and improve the accuracy of reflecting the traffic congestion of ships by clustering trajectory information.

[0004] In a first aspect, an embodiment of the present invention provides a method for evaluating traffic congestion, the method comprising:

[0005] Obtaining ship identification data, the ship identification data including an identification code, a timestamp and location information;

[0006] Acquire a first track set according to the ship identification data, the first track set including a plurality of first tracks, the first tracks being acquired by sorting the position information in the order of timestamps according to the identification code;

[0007] Clustering the first trajectory set to obtain at least one second trajectory set, where the second trajectory set includes a plurality of second trajectories, and the second trajectories are first trajectories screened from the first trajectory set by clustering;

[0008] Acquire a first region area according to the first trajectory set by using a ship domain model, where the first region area is the sum of areas corresponding to each first trajectory in the first trajectory set;

[0009] Acquire the second area corresponding to each of the second trajectory sets;

[0010] Acquire a busy index according to the area of ​​the first region and the area of ​​the second region;

[0011] The water traffic reference data is acquired and outputted according to the busy index.

[0012] In some embodiments, acquiring a first trajectory set according to the ship identification data comprises:

[0013] The drift data, sparse data and noise data in the ship identification data are processed to obtain a first trajectory set.

[0014] In some embodiments, clustering the first trajectory set to obtain a second trajectory set includes:

[0015] Acquire multiple initial cluster centers in the first trajectory set, each of the initial cluster centers is a first trajectory in the first trajectory set, and a distance between each of the initial cluster centers is greater than or equal to a preset threshold;

[0016] Calculating the spatial similarity distance between each of the initial cluster centers and the remaining first trajectories;

[0017] Allocating the remaining first trajectories to the clusters represented by the initial cluster centers according to the spatial similarity distance to obtain a set of candidate trajectories;

[0018] The cluster centers in each of the candidate trajectory sets process the candidate trajectory sets to obtain the second trajectory set based on the final cluster centers.

[0019] In some embodiments, the spatial similarity distance is obtained by the following formula:

[0020]

[0021] in,

[0022]

[0023]

[0024] Among them, C i is the cluster center of the i-th candidate trajectory set, X l is the first trajectory, is the first maximum distance, is the second largest distance, d i,j is the Euclidean distance between the i-th trajectory point on one trajectory and the j-th trajectory point on another trajectory, k is the number of candidate trajectory sets, and n lis the first trajectory X l The number of trajectory points, d(X l , C i ) is the first trajectory X l With cluster center C i The spatial similarity distance between them.

[0025] In some embodiments, clustering the first trajectory set to obtain at least one second trajectory set is implemented as follows:

[0026] class(X l )=arg(min(d(X l ,C i )))

[0027] Among them, d(X l , C i ) is the first trajectory X l With cluster center C i The spatial similarity distance between them, min(d(X l , C i )) is the first trajectory X l The minimum value of the spatial similarity distance between the corresponding cluster center, i = 1, ..., k, X l is the first trajectory, C i is the cluster center of the i-th candidate trajectory set, class(X l ) is the first trajectory X l The set of candidate trajectories.

[0028] In some embodiments, the adjusting of the cluster centers in each of the candidate trajectory sets is implemented by the following formula:

[0029]

[0030] Among them, C f is the final cluster center, n i is the number of second trajectories in the i-th class, d(X l,i ,X k,i ) is the distance between the lth second trajectory and the kth second trajectory in the i-th class, For the range from 1 to n i The minimum distance in .

[0031] In some embodiments, the area of ​​the first region is obtained by the following formula:

[0032]

[0033] Among them, S t is the area of ​​the first region, S iis the area of ​​the i-th first trajectory in the first trajectory set, and m is the number of first trajectories in the first trajectory set.

[0034] In some embodiments, the area of ​​the second region is obtained by the following formula:

[0035]

[0036] Among them, S h is the area of ​​the second region, t is the number of the second trajectory set, L i is the length of the i-th second trajectory set, W i is the average width of the i-th second trajectory set.

[0037] In some embodiments, the busy index is a ratio of an area of ​​the second region to an area of ​​the first region.

[0038] In a second aspect, an embodiment of the present invention provides a device for evaluating traffic congestion level, the device comprising:

[0039] A preparation module, used to obtain ship identification data, wherein the ship identification data includes an identification code, a timestamp and location information;

[0040] A trajectory extraction module, used for acquiring a first trajectory set according to the ship identification data, wherein the first trajectory set includes a plurality of first trajectories, and the first trajectories are acquired by sorting the position information according to the identification code in the order of timestamps;

[0041] a clustering module, configured to cluster the first trajectory set to obtain at least one second trajectory set, wherein the second trajectory set includes a plurality of second trajectories, and the second trajectory is a first trajectory screened from the first trajectory set through clustering;

[0042] A first area acquisition module, configured to acquire the area of ​​a first region according to the first trajectory set by using a ship domain model, wherein the area of ​​the first region is the sum of the areas corresponding to each first trajectory in the first trajectory set;

[0043] A second area acquisition module, used to acquire the second region area corresponding to each of the second trajectory sets;

[0044] A busy index acquisition module, used to acquire a busy index according to the area of ​​the first region and the area of ​​the second region;

[0045] The water area traffic reference number output module is used to obtain and output the water area traffic reference data according to the busy index.

[0046] The technical solution of the embodiment of the present invention is to obtain ship identification data; obtain a first trajectory set according to the ship identification data; cluster the first trajectory set to obtain at least one second trajectory set; obtain a first area according to the first trajectory set through a ship domain model; obtain the second area corresponding to each second trajectory set; obtain a busy index according to the first area and the second area; obtain and output water traffic reference data according to the busy index. Therefore, by clustering trajectory information, the complexity of data processing can be reduced and the accuracy of reflecting the busy situation of ship traffic can be improved. BRIEF DESCRIPTION OF THE DRAWINGS

[0047] The above and other objects, features and advantages of the present invention will become more apparent through the following description of the embodiments of the present invention with reference to the accompanying drawings, in which:

[0048] Figure 1 is a schematic diagram of a system for evaluating traffic congestion level according to an embodiment of the present invention;

[0049] Figure 2 is a flow chart of a method for evaluating traffic congestion level according to an embodiment of the present invention;

[0050] Figure 3 is a flow chart of clustering a first trajectory set according to an embodiment of the present invention;

[0051] Figure 4 is a schematic diagram of calculating spatial similarity distance according to an embodiment of the present invention;

[0052] Figure 5 is a schematic diagram of adjusting cluster centers according to an embodiment of the present invention;

[0053] Figure 6 is a schematic diagram of a Fujii model according to an embodiment of the present invention;

[0054] Figure 7 is a schematic diagram of a traffic congestion degree evaluation device according to an embodiment of the present invention;

[0055] Figure 8 is a schematic diagram of an electronic device according to an embodiment of the present invention. DETAILED DESCRIPTION

[0056] The present application is described below based on embodiments, but the present application is not limited to these embodiments. In the detailed description of the present application below, some specific details are described in detail. It is possible for those skilled in the art to fully understand the present application without the description of these details. In order to avoid confusing the essence of the present application, known methods, processes, flows, components and circuits are not described in detail.

[0057] In addition, persons of ordinary skill in the art will appreciate that the drawings provided herein are for illustration purposes and are not necessarily drawn to scale.

[0058] Unless the context clearly requires otherwise, the words "include", "comprising" and similar words throughout the application should be interpreted as including rather than exclusive or exhaustive; that is, the meaning is "including but not limited to".

[0059] In the description of this application, it should be understood that the terms "first", "second", etc. are only used for descriptive purposes and cannot be understood as indicating or implying relative importance. In addition, in the description of this application, unless otherwise specified, the meaning of "plurality" is two or more.

[0060] Figure 1 Schematic diagram of a traffic congestion evaluation system according to an embodiment of the present invention. Figure 1 In the illustrated embodiment, the traffic congestion evaluation system includes a client 11, a server 12 and a shipborne device 13, and the server 12 can be connected to the shipborne device 13 by satellite communication, wireless communication, etc. Among them, the shipborne device 13 is used to obtain the ship identification data of the ship, and send the ship identification data to the server 12, and the shipborne device includes an AIS system (Automatic Identification System). The server 12 is used to obtain the ship identification data sent by the shipborne device 13, and obtain a first trajectory set according to the ship identification data, cluster the first trajectory set to obtain at least one second trajectory set, obtain the first area according to the first trajectory set through the ship domain model, obtain the second area corresponding to each second trajectory set, obtain the busy index according to the first area and the second area, obtain the water traffic reference data according to the busy index, and send the water traffic reference data to the client 11 for output display.

[0061] The client 11 may be implemented via a mobile phone, tablet computer, laptop computer, desktop computer or other dedicated data processing terminal.

[0062] The server 12 may be an independent server or a server cluster composed of multiple servers.

[0063] Figure 2 It is a flow chart of the method for evaluating the traffic congestion level according to an embodiment of the present invention. Figure 2 The traffic congestion evaluation method shown is applicable to a server, and the specific implementation method includes the following steps:

[0064] Step S100: Acquire ship identification data, where the ship identification data includes an identification code, a timestamp and location information.

[0065] In this embodiment, the shipborne equipment containing the AIS system is installed on the ship, and ensures that it is correctly connected to the navigation system and power system of the ship. The client can receive ship identification data from each ship through satellite communication, wireless communication, etc. The ship identification data includes the identification code, timestamp and location information of each ship. The identification code is used to characterize a unique ship. The location information is the location information obtained by the shipborne equipment through the positioning function, which can be longitude and latitude. The positioning function of the shipborne equipment can be realized by the positioning function of the ship automatic identification system, the global positioning system and the global navigation satellite system. The server can receive the ship identification data sent by the shipborne equipment through the above-mentioned wireless communication method.

[0066] Step S200: acquiring a first trajectory set according to the ship identification data, wherein the first trajectory set includes a plurality of first trajectories, and the first trajectories are acquired by sorting the position information in the order of the timestamp according to the identification code.

[0067] In this embodiment, the server obtains the first trajectory according to the identification code, timestamp and location information in the obtained ship identification data. Specifically, the server determines the identity of the ship according to the identification code, and sorts and connects the location information in the order of the timestamp, thereby generating the first trajectory of the ship. According to the above method, the first trajectory of other ships in the research waters can be obtained, and the first trajectory set is determined according to the obtained first trajectory. The first trajectory set represents the trajectory information of all ships in the research waters.

[0068] Furthermore, in order to improve the accuracy of the data, the data may be cleaned when the first trajectory set is obtained. Specifically, the drift data, sparse data and noise data in the ship identification data may be processed to obtain the first trajectory set.

[0069] In this embodiment, the server performs data cleaning on the acquired ship identification data. Since the ship identification data may contain drift data, sparse data and noise data, the server needs to process the drift data, sparse data and noise data, wherein the drift data refers to some abnormal data points that deviate far from most route tracks due to positioning errors, the sparse data refers to data with a large distance between two adjacent track points due to missing information, and the noise data refers to abnormal data with different ships but the same identification code.

[0070] Specifically, in response to the server identifying that there are abnormal data points in the ship identification data that deviate far from most route trajectories, the server will fill in this point by fitting according to the distance between the two points before and after the abnormal data point. For abnormal data points that cannot be fitted, the server will remove the data point; in response to the server identifying that there are data in the ship identification data that the distance between two adjacent trajectory points is too large, the server will remove the data point; in response to the server identifying that there are identification codes in the ship identification data that are the same but the ship information corresponding to the identification codes is different, such as different ship names, call signs, IMO numbers (International Maritime Organization Numbers), etc., the server will remove the data point.

[0071] The first trajectory set includes all first trajectories obtained according to the ship identification data or the first trajectories after cleaning.

[0072] Step S300: clustering the first trajectory set to obtain at least one second trajectory set, where the second trajectory set includes a plurality of second trajectories, and the second trajectory is a first trajectory screened from the first trajectory set by clustering.

[0073] In this embodiment, the server randomly selects multiple initial cluster centers in the first trajectory set by using the K-means algorithm, and then assigns the first trajectory to the corresponding class according to the distance from the trajectory sequence to the initial cluster center. Finally, the center of each cluster is adjusted by minimizing the sum of the distances between samples within the class, thereby obtaining the second trajectory set.

[0074] Among them, the K-means algorithm is an unsupervised learning algorithm for dividing the points in a data set into K clusters. It clusters the data based on the centroid and tries to make the points within the cluster as close to the centroid as possible, while making the centroids between different clusters as far apart as possible. Specifically, K initial centroids are selected, which can be random selection or using some heuristic method. For each point in the data set, the distance between it and the K centroids is calculated. Each point is assigned to the cluster where the nearest centroid is located. For each cluster, the mean of all points in the cluster is calculated, and the mean is set as the new centroid. Repeat the assignment of clusters and the calculation of new centroids until a certain stopping condition is reached, such as reaching a preset maximum number of iterations, or the position of the centroid no longer changes significantly. The final cluster and centroid are the output of the K-means algorithm.

[0075] Figure 3 This is a flow chart of clustering a first trajectory set according to an embodiment of the present invention. Figure 3 The clustering of the first trajectory set shown specifically includes the following steps:

[0076] Step S310: obtaining a plurality of initial cluster centers in the first trajectory set, each of the initial cluster centers being a first trajectory in the first trajectory set, and a distance between each of the initial cluster centers being greater than or equal to a preset threshold.

[0077] In this embodiment, the server randomly selects multiple initial cluster centers in the first trajectory set, and the distance between each initial cluster center is greater than or equal to a preset threshold. For example, assuming that two initial cluster centers are selected as an example, the first trajectory set contains a total of L first trajectories. The server randomly selects a trajectory X1 in the first trajectory set as the first type of initial cluster center C1, and selects a first trajectory X2 from the remaining L-1 first trajectories as the center C2 of the second type of initial cluster center, and sets a threshold Q at the same time, so that the distance between the initial cluster center C1 and satisfies d(C1, C2)≥Q. The threshold is set to ensure that the two cluster centers are dispersed in the data space, which is helpful for the subsequent clustering process, wherein the optimal Q value needs to be determined through experiments or cross-validation. If Q is set too small, the cluster centers may be too close; if Q is set too large, the cluster centers may be too dispersed and fail to capture the natural grouping in the data.

[0078] The distance between the initial cluster centers is the spatial similarity distance between the trajectories, which can be specifically calculated by referring to the method in the following step S320.

[0079] Step S320: Calculate the spatial similarity distance between each of the initial cluster centers and the remaining first trajectories.

[0080] The spatial similarity distance is obtained by the following formula:

[0081]

[0082] in,

[0083]

[0084] Among them, C i is the cluster center of the i-th candidate trajectory set, X l is the lth first trajectory in the first trajectory set excluding the selected initial cluster center, is the first trajectory X l With the initial cluster center C i The maximum Euclidean distance between is the initial cluster center C i With the first trajectory X l The maximum Euclidean distance between D i,j is the lth first trajectory X in the first trajectory setl The i-th trajectory point on the i-th initial cluster center C i The Euclidean distance between the j-th trajectory points on D i,j is the i-th initial cluster center C in the first trajectory set i The i-th trajectory point on the l-th first trajectory X l The Euclidean distance between the jth trajectory points on the l is the first trajectory X l The number of trajectory points, wherein the k value can be preset or automatically determined according to a preset criterion during clustering.

[0085] In this embodiment, the server may select all initial cluster centers in the first trajectory set according to the cluster number k, and then calculate the spatial similarity distance between the initial cluster centers and the remaining first trajectories to achieve preliminary clustering in the first trajectory set.

[0086] Specifically, the maximum Euclidean distance between the trajectory points on the first trajectory and the trajectory points of the initial cluster center, and the maximum Euclidean distance between the trajectory points of the initial cluster center and the trajectory points of the first trajectory are first determined, and the minimum value is selected as the spatial similarity distance between the initial cluster center and the first trajectory, wherein the Euclidean distance is used to measure the straight-line distance between two points or two points in a multidimensional space. For example, the i-th initial cluster center C in the first trajectory set is i The i-th trajectory point (x1, y1) on the l-th first trajectory X l The Euclidean distance between the j-th trajectory points on (x2, y2) can be obtained by the following format:

[0087] d = sqrt((x1-x2) 2 +(y1-y2) 2 )

[0088] Among them, (x1, y1) is the initial cluster center C i The longitude and latitude of the i-th trajectory point on the first trajectory X is (x2, y2). l The longitude and latitude of the jth trajectory point on , and d is the Euclidean distance between (x1, y1) and (x2, y2).

[0089] Figure 4 Schematic diagram of calculating spatial similarity distance in an embodiment of the present invention. Figure 4 As shown, an initial cluster center C1 and a first trajectory X1 are taken as an example for explanation. The first trajectory X1 includes i trajectory points x i , where i=4, the initial cluster center C1 includes j trajectory points cj , where j = 5. First, calculate the Euclidean distance d from point x1 on the first trajectory X1 to point c1 on the initial cluster center C1 1,1 , from point x1 on the first trajectory X1 to the initial cluster center C i The Euclidean distance d of c2 on 1,2 , the Euclidean distance d from point x1 on the first trajectory X1 to c3 on the initial cluster center C1 1,3 , the Euclidean distance d from point x1 on the first trajectory X1 to c4 on the initial cluster center C1 1,4 , the Euclidean distance d from point x1 on the first trajectory X1 to c5 on the initial cluster center C1 1,5 , assuming that in d 1,1 d 1,2 d 1,3 d 1,4 and d 1,5 Select the minimum value d 1,5 ; Get the Euclidean distance d from point x2 on the first trajectory X1 to c1 on the initial cluster center C1 2,1 , the Euclidean distance d from point x2 on the first trajectory X1 to point c2 on the initial cluster center C1 2,2 , the Euclidean distance d from point x2 on the first trajectory X1 to c3 on the initial cluster center C1 2,3 , the Euclidean distance d from point x2 on the first trajectory X1 to c4 on the initial cluster center C1 2,4 , the Euclidean distance d from point x2 on the first trajectory X1 to c5 on the initial cluster center C1 2,5 , assuming that in d 2,1 d 2,2 d 2,3 d 2,4 and d 2,5 Select the minimum value d 2,3 According to the above method, the minimum Euclidean distance between the third trajectory point x3 on the first trajectory X1 and the jth trajectory point on the initial cluster center C1 can be obtained as d 3,1 , the minimum Euclidean distance between the 4th trajectory point x4 on the first trajectory X1 and the jth trajectory point on the initial cluster center C1 is d 4,3 , and in the d 1,5 d 2,3 d 3,1 and d 4,3 Select the maximum value as the Euclidean distance D between the first trajectory X1 and the initial cluster center C1 X1C1 .

[0090] According to the above method, the Euclidean distance between the initial cluster center C1 and the first trajectory X1 can be obtained. The initial cluster center C1 includes i trajectory points c i, where i=5, the first trajectory X1 includes j trajectory points x j , where j = 4. Get the Euclidean distance d from the trajectory point c1 on the initial cluster center C1 to the trajectory point x1 on the first trajectory X1 1,1 , the Euclidean distance d from the trajectory point c1 on the initial cluster center C1 to the trajectory point x2 on the first trajectory X1 1,2 , the Euclidean distance d from the trajectory point c1 on the initial cluster center C1 to the trajectory point x3 on the first trajectory X1 1,3 , the Euclidean distance d from the trajectory point c1 on the initial cluster center C1 to the trajectory point x4 on the first trajectory X1 1,4 , assuming that in d 1,1 d 1,2 d 1,3 and d 1,4 Select the minimum value d 1,3 ; The Euclidean distance d from the trajectory point c2 on the initial cluster center C1 to the trajectory point x1 on the first trajectory X1 2,1 , the Euclidean distance d from the trajectory point c2 on the initial cluster center C1 to the trajectory point x2 on the first trajectory X1 2,2 , the Euclidean distance d from the trajectory point c2 on the initial cluster center C1 to the trajectory point x3 on the first trajectory X1 2,3 , the Euclidean distance d from the trajectory point c2 on the initial cluster center C1 to the trajectory point x4 on the first trajectory X1 2,4 , assuming d 2,1 d 2,2 d 2,3 and d 2,4 Select the minimum value d 2,1 ; Based on the same method, obtain the third trajectory point c3 on the initial cluster center C1 to the trajectory point x on the first trajectory X1 j The minimum Euclidean distance d 3,2 , the fourth trajectory point c4 on the initial cluster center C1 to the trajectory point x on the first trajectory X1 j The minimum Euclidean distance d 4,2 , the fifth trajectory point c5 on the initial cluster center C1 to the trajectory point x on the first trajectory X1 j The minimum Euclidean distance d 5,4 , and in the d 1,3 d 2,1 d 3,2 d 4,2 and d 5,4 Select the maximum value as the Euclidean distance between the initial cluster center C1 and the first trajectory X1

[0091] Finally, according to the Euclidean distance between the first trajectory X1 and the initial cluster center C1 And the Euclidean distance between the initial cluster center C1 and the first trajectory X1 The maximum value is selected as the spatial similarity distance between the initial cluster center and the first trajectory.

[0092] Step S330: Allocate the remaining first trajectories to the clusters represented by the initial cluster centers according to the spatial similarity distances to obtain a set of candidate trajectories.

[0093] The at least one candidate trajectory set is obtained by the following formula:

[0094] class(X l )=arg(min(d(X l ,C i )))

[0095] Among them, d(X l , C i ) is the lth first trajectory X in the first trajectory set except the selected initial cluster center l and the cluster center C of the i-th candidate trajectory set i The spatial similarity distance between them, i = 1, ..., k, X l is the first trajectory, C i is the cluster center min(d(X l , C i )) is the first trajectory X l The minimum value of the spatial similarity distance between the corresponding cluster center and the first trajectory X can be found according to the minimum value of the spatial similarity distance. l The initial cluster center with the smallest spatial similarity distance can be used to determine the first trajectory X l The candidate trajectory set of class(X l ) is the distance from the first trajectory X l The nearest candidate trajectory set, that is, to determine the first trajectory X l The set of candidate trajectories that belong to .

[0096] In this embodiment, the server determines the first trajectory X based on the spatial similarity distance between each initial cluster center and the remaining first trajectory. l Which initial cluster center C should be assigned to i In the corresponding candidate trajectory set. That is, after traversing all cluster centers C i , where i ranges from 1 to k, k is the number of initial cluster centers, and calculates the correlation between each initial cluster center and trajectory X l The spatial similarity distance d(X l , C iThen, the arg function will find the value of i that makes the distance the smallest. When this value of i is found, the trajectory X l It will be assigned to the candidate trajectory set corresponding to this i.

[0097] For example, assuming that the number of initial cluster centers k is 4, the spatial similarity distance between the first trajectory X1 and the initial cluster centers C1, C2, C3, and C4 is d 1,1 d 1,2 d 1,3 and d 1,4 , where the minimum spatial similarity distance is d 1,2 , which means that the first trajectory X1 belongs to the cluster represented by the initial cluster center C2. The spatial similarity distance between the first trajectory X2 and the initial cluster centers C1, C2, C3 and C4 is d 2,1 d 2,2 d 2,3 and d 2,4 , where the minimum spatial similarity distance is d 2,1 , which means that the first trajectory X2 belongs to the cluster represented by the initial cluster center C1. According to the above method, four candidate trajectory sets centered on the initial cluster center C1, the initial cluster center C2, the initial cluster center C3 and the initial cluster center C4 can be obtained respectively.

[0098] Step S340: Adjust the cluster centers in each of the candidate trajectory sets to process the candidate trajectory sets to obtain the second trajectory set.

[0099] The second trajectory set is obtained by the following formula:

[0100]

[0101] Among them, C f is the final cluster center determined after adjustment of the initial cluster center of the candidate trajectory set, n i is the number of second trajectories in the i-th class, d(X l,i ,X k,i ) is the spatial similarity distance between the lth second trajectory and the kth second trajectory in the i-th candidate trajectory set, To traverse the candidate trajectory set of the i-th category from 1 to n i Second trajectory, calculate each second trajectory X l,i With each second trajectory X k,i The sum of the spatial similarity distances between and select the minimum value. The final cluster center C can be determined based on the minimum value f .

[0102] In this embodiment, the server searches for a new cluster center in each candidate trajectory set based on the obtained candidate trajectory set that has been preliminarily clustered, so that the spatial similarity distance between the new cluster center and all other second trajectories in the candidate trajectory set is minimized.

[0103] Specifically, the server selects all n candidates from the i-th candidate trajectory set according to the above formula. i A second trajectory is selected from the second trajectories as a new cluster center. The selection criterion of this point is to minimize the sum of the distances to the new cluster center and all other second trajectories in the candidate trajectory set.

[0104] Figure 5 FIG. 1 is a schematic diagram of adjusting the cluster center according to an embodiment of the present invention. Figure 5 As shown, there are 4 second trajectories in the first category of candidate trajectory set. A second trajectory X is randomly selected from the first category of candidate trajectory set. 1,1 As the new cluster center in the first category of candidate trajectory set, and calculate the other second trajectories X in the first category of candidate trajectory set 2,1 , X 3,1 and X 4,1 To the second track X 1,1 The minimum distance d(X 1,1 ,X 2,1 ), d(X 1,1 ,X 3,1 ) and d(X 1,1 ,X 4,1 ), and obtain d(X 1,1 ,X 2,1 ), d(X 1,1 ,X 3,1 ) and d(X 1,1 ,X 4,1 ) and then select another second trajectory X 2,1 As the new cluster center in the first category of candidate trajectory set, and calculate the other second trajectories X in the first category of candidate trajectory set 1,1 , X 3,1 and X 4,1 To the second track X 2,1 The minimum distance d(X 2,1 ,X 1,1 ), d(X 2,1 ,X 3,1 ) and d(X 2,1 ,X 4,1 ), and obtain d(X 2,1 ,X 1,1 ), d(X 2,1 ,X 3,1 ) and d(X 2,1,X 4,1 ) and; select X 3,1 is the new cluster center in the first candidate trajectory set, and calculates the other second trajectories X in the first candidate trajectory set 1,1 , X 2,1 and X 4,1 To the second track X 2,1 The minimum distance d(X 3,1 ,X 1,1 ), d(X 3,1 ,X 2,1 ) and d(X 3,1 ,X 4,1 ), and obtain d(X 3,1 ,X 1,1 ), d(X 3,1 ,X 2,1 ) and d(X 3,1 ,X 4,1 ) and; select X 4,1 is the new cluster center in the first candidate trajectory set, and calculates the other second trajectories X in the first candidate trajectory set 1,1 , X 2,1 and X 3,1 To the second track X 4,1 The minimum distance d(X 4,1 ,X 1,1 ), d(X 4,1 ,X 2,1 ) and d(X 4,1 ,X 4,1 ), and obtain d(X 4,1 ,X 1,1 ), d(X 4,1 ,X 2,1 ) and d(X 4,1 ,X 4,1 ) and determine to select X 1,1 , X 2,1 , X 3,1 and X 4,1 As the new cluster center, the other second trajectories in the first category candidate trajectory set to the X 1,1 , X 2,1 , X 3,1 and X 4,1 The minimum value of the distance is obtained, and a new cluster center of the first type of candidate trajectory set is determined according to the minimum distance.

[0105] In this embodiment, steps S320 to S340 are repeated until the cluster centers do not change for two consecutive times, and the final cluster center and the membership relationship of other second trajectories are outputted according to the final cluster center, so as to determine the second trajectory set. At this time, the second trajectories in each second trajectory set belong to the same type of trajectory.

[0106] Step S400: obtaining a first region area according to the first trajectory set through a ship domain model, where the first region area is the sum of areas corresponding to each first trajectory in the first trajectory set.

[0107] The area of ​​the first region is obtained by the following formula:

[0108]

[0109] Among them, S t is the area of ​​the first region, S i is the area of ​​the i-th first trajectory in the first trajectory set, and m is the number of first trajectories in the first trajectory set.

[0110] In this embodiment, the server determines the domain area corresponding to each first trajectory in the first trajectory set based on the acquired first trajectory set, and adds the domain areas corresponding to all the first trajectories to obtain the first area area corresponding to the first trajectory set. The ship domain model may be a Fujii model, and the domain area corresponding to each first trajectory defines a domain or buffer zone for the first trajectory based on the Fujii model. This domain or buffer zone may be a strip area extending along the trajectory line, and for each trajectory point, the corresponding ship domain area is calculated. This can be achieved by multiplying the area calculation formula of the ellipse by the product of the major axis radius and the minor axis radius. Since the position of the ship is constantly changing during navigation, it is necessary to calculate the corresponding ship domain area for each trajectory point, and add them up to obtain the ship domain area area S corresponding to the first trajectory. i . Figure 6 Schematic diagram of the Fujii model of an embodiment of the present invention. Figure 6 As shown, when defining areas or buffer zones, the Fujii model has two modes: the ratio of the major axis radius to the minor axis radius is 8L*3.2L and the ratio of the major axis radius to the minor axis radius is 1.6L*6L, where L is the length of the ship. When selecting the calculation mode, the staff can determine the length of the major axis and minor axis in the Fujii model based on the length of the ship L and the characteristics of the navigation waters.

[0111] Step S500: Obtain the second region area corresponding to each of the second trajectory sets.

[0112] The area of ​​the second region is obtained by the following formula:

[0113]

[0114] Among them, S h is the area of ​​the second region, t is the number of the second trajectory set, L i is the length of the i-th second trajectory set, W i is the average width of the i-th second trajectory set.

[0115] In this embodiment, the server determines the domain area corresponding to each second trajectory set based on the acquired second trajectory set, that is, the channel domain area of ​​the same type of trajectory, and determines the area of ​​the clustered region based on the domain area corresponding to each second trajectory set. Specifically, each second trajectory set represents a channel, and all trajectory points are extracted from the selected second trajectory set. All trajectory points in the second trajectory set are traversed to calculate the actual distance between adjacent points. Since the ship sails on the surface of the earth, the great circle distance calculation method can be used to add up the distances between all adjacent points to obtain the total length L of the channel. i For the channel, the boundaries of the outermost ship tracks on both sides are taken as the width boundaries. After the width boundary of the channel is determined, the distance between the boundaries on both sides is calculated as the width of the channel. The channel has different widths at different positions. The width can be calculated at multiple key positions of the channel, and the width values ​​at multiple positions are averaged to obtain the average width W of the channel. i .

[0116] Step S600: Obtain a busy index according to the area of ​​the first region and the area of ​​the second region.

[0117] Further, in order to explain in more detail how to obtain the busy index, it can be obtained specifically according to the ratio of the area of ​​the second region to the area of ​​the first region.

[0118] In this embodiment, the server uses the ratio of the area of ​​the first region to the area of ​​the second region as the busyness index of the research waters.

[0119] Step S700: Obtain water area traffic reference data according to the busy index and output it.

[0120] In this embodiment, the server obtains water traffic reference data based on the acquired busy index, and sends the obtained water traffic reference data to the client for display. The water traffic reference data includes a traffic busy index change curve, changing trend data of water cargo transportation and economy, water safety risk data and research water traffic situation data.

[0121] Specifically, by observing in specific areas, such as the Yangtze River Estuary, the Pearl River Estuary, the Bay Area, the Yangtze River, the Pearl River, the Strait, the Qiongzhou Strait and the eastern coastal waters, a traffic busyness index change curve is drawn according to the busyness index, and the change curve is displayed on the client. By analyzing the change curve, the relationship between shipping and economic activity changes can be established to obtain water transport change trend data, which is convenient for timely analysis of the macro-change situation of transportation;

[0122] By tracking the changes in busy indexes in different port areas at different times, we analyze the changing trend data of water cargo transportation and economy, and display them through the client to provide decision support for transportation planning and construction;

[0123] Obtain water safety risk data based on the busyness index and display it through the client, so that enterprises can understand the transportation rules and reasonably formulate operation plans and management measures; and

[0124] The busy index is sent to a GIS (geographic information system) to obtain the water area traffic situation and display it on the client in the form of an image, providing an intuitive portrait of the traffic operation situation.

[0125] The embodiment of the present invention obtains ship identification data; obtains a first trajectory set according to the ship identification data; clusters the first trajectory set to obtain at least one second trajectory set; obtains a first region area according to the first trajectory set through a ship domain model; obtains a second region area corresponding to each second trajectory set; obtains a busy index according to the first region area and the second region area; obtains and outputs water traffic reference data according to the busy index. Thus, by clustering trajectory information, the complexity of data processing can be reduced, and the accuracy of reflecting the busy situation of ship traffic can be improved.

[0126] Figure 7 Schematic diagram of a traffic congestion evaluation device according to an embodiment of the present invention. Figure 7As shown, the traffic congestion evaluation device of the embodiment of the present invention includes a preparation module 81, which is used to obtain ship identification data, and the ship identification data includes an identification code, a timestamp and location information; a trajectory extraction module 82, which is used to obtain a first trajectory set according to the ship identification data, the first trajectory set includes multiple first trajectories, and the first trajectory is obtained by sorting the location information according to the identification code in the order of the timestamp; a clustering module 83, which is used to cluster the first trajectory set to obtain at least one second trajectory set, the second trajectory set includes multiple second trajectories, and the second trajectory is a first trajectory screened from the first trajectory set by clustering; a first area acquisition module 84, which is used to obtain a first area according to the first trajectory set through a ship domain model, and the first area is the sum of the areas corresponding to each first trajectory in the first trajectory set; a second area acquisition module 85, which is used to obtain the second area corresponding to each second trajectory set; a busy index acquisition module 86, which is used to obtain a busy index according to the first area and the second area; a water traffic reference number output module 87, which is used to obtain and output water traffic reference data according to the busy index.

[0127] In some embodiments, the trajectory extraction module 82 includes:

[0128] A cleaning module is used to process the drift data, sparse data and noise data in the ship identification data to obtain a first trajectory set.

[0129] In some embodiments, the clustering module 83 includes:

[0130] an initial cluster center selection module, used to obtain a plurality of initial cluster centers in the first trajectory set, each of the initial cluster centers being a first trajectory in the first trajectory set, and a distance between each of the initial cluster centers being greater than or equal to a preset threshold;

[0131] A spatial similarity acquisition module, used to calculate the spatial similarity distance between each of the initial cluster centers and the remaining first trajectories;

[0132] a candidate trajectory set acquisition module, configured to allocate the remaining first trajectories to the clusters represented by the initial cluster centers according to the spatial similarity distances, so as to obtain a candidate trajectory set;

[0133] The second trajectory set determination module is configured to adjust the cluster centers in each of the candidate trajectory sets to process the candidate trajectory sets to obtain the second trajectory set.

[0134] In some embodiments, the spatial similarity distance is obtained by the following formula:

[0135]

[0136] in,

[0137]

[0138] Among them, C i is the cluster center of the i-th candidate trajectory set, X l is the first trajectory, is the first maximum distance, is the second largest distance, d i,j is the Euclidean distance between the i-th trajectory point on one trajectory and the j-th trajectory point on another trajectory, k is the number of candidate trajectory sets, and n l is the first trajectory X l The number of trajectory points.

[0139] In some embodiments, the candidate trajectory set is obtained by the following formula:

[0140] class(X l )=arg(min(d(X l ,C i )))

[0141] Among them, d(X l , C i ) is the first trajectory X l With cluster center C i The spatial similarity distance between them, min(d(X l , C i )) is the first trajectory X l The minimum value of the spatial similarity distance between the corresponding cluster center, i = 1, ..., k, X l is the first trajectory, C i is the cluster center of the i-th candidate trajectory set, class(X l ) is the first trajectory X l The set of candidate trajectories.

[0142] In some embodiments, the adjusting of the cluster centers in each of the candidate trajectory sets is implemented by the following formula:

[0143]

[0144] Among them, C f is the final cluster center, n i is the number of first trajectories in the i-th class, d(X l,i ,X k,i ) is the distance between the lth second trajectory and the kth second trajectory in the i-th class, For the range from 1 to ni The minimum distance in .

[0145] In some embodiments, the area of ​​the first region is obtained by the following formula:

[0146]

[0147] Among them, S t is the area of ​​the first region, S i is the area of ​​the i-th first trajectory in the first trajectory set, and m is the number of first trajectories in the first trajectory set.

[0148] In some embodiments, the area of ​​the second region is obtained by the following formula:

[0149]

[0150] Among them, S h is the area of ​​the second region, t is the number of the second trajectory set, L i is the length of the i-th second trajectory set, W i is the average width of the i-th second trajectory set.

[0151] In some embodiments, the busy index is a ratio of an area of ​​the first region to an area of ​​the second region.

[0152] The embodiment of the present invention obtains ship identification data, obtains a first track set according to the ship identification data, clusters the first track set to obtain at least one second track set, obtains a first region area according to the first track set through a ship domain model, obtains a second region area corresponding to each second track set, obtains a busy index according to the first region area and the second region area, obtains water traffic reference data according to the busy index and outputs it. Therefore, by clustering track information, the complexity of data processing can be reduced and the accuracy of reflecting the busy situation of ship traffic can be improved.

[0153] Figure 8 Schematic diagram of an electronic device according to an embodiment of the present invention. Figure 8 As shown, Figure 8The electronic device shown is a general address query device, which includes a general computer hardware structure, which at least includes a processor 91 and a memory 92. The processor 91 and the memory 92 are connected via a bus 93. The memory 92 is suitable for storing instructions or programs executable by the processor 91. The processor 91 can be an independent microprocessor or a collection of one or more microprocessors. Thus, the processor 91 executes the instructions stored in the memory 92, thereby executing the method flow of the embodiment of the present invention as described above to realize the processing of data and the control of other devices. The bus 93 connects the above-mentioned multiple components together, and at the same time connects the above-mentioned components to the display controller 94 and the display device and the input / output (I / O) device 95. The input / output (I / O) device 95 can be a mouse, a keyboard, a modem, a network interface, a touch input device, a somatosensory input device, a printer, and other devices known in the art. Typically, the input / output device 95 is connected to the system via an input / output (I / O) controller 96.

[0154] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, devices (equipment) or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment or an embodiment combining software and hardware. Moreover, the present application may adopt a computer program product implemented on one or more computer-readable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) containing computer-usable program code.

[0155] The present application is described with reference to flowcharts of methods, apparatuses (devices) and computer program products according to embodiments of the present application. It should be understood that each process in the flowchart can be implemented by computer program instructions.

[0156] These computer program instructions may be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device that implements the process Figure 1 A function specified in a process or multiple processes.

[0157] These computer program instructions may also be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to produce a machine, so that the instructions executed by the processor of the computer or other programmable data processing device produce the instructions for implementing the process Figure 1 A device that specifies functions in a process or multiple processes.

[0158] Another embodiment of the present invention relates to a non-volatile storage medium for storing a computer-readable program, wherein the computer-readable program is used for a computer to execute part or all of the above method embodiments.

[0159] That is, those skilled in the art can understand that all or part of the steps in the above-mentioned embodiment method can be completed by specifying relevant hardware through a program, and the program is stored in a storage medium, including several instructions for a device (which can be a single-chip microcomputer, chip, etc.) or a processor (processor) to execute all or part of the steps of the method described in each embodiment of the present application. The aforementioned storage medium includes: U disk, mobile hard disk, read-only memory (ROM, Read-Only Memory), random access memory (RAM, Random Access Memory), disk or optical disk and other media that can store program codes.

[0160] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. For those skilled in the art, the present application may have various modifications and variations. Any modification, equivalent replacement, improvement, etc. made within the spirit and principle of the present application shall be included in the protection scope of the present application.

Claims

1. A method for evaluating traffic congestion, characterized in that: The method comprises: Obtaining ship identification data, the ship identification data including an identification code, a timestamp and location information; Acquire a first track set according to the ship identification data, the first track set including a plurality of first tracks, the first tracks being acquired by sorting the position information in the order of timestamps according to the identification code; Clustering the first trajectory set to obtain at least one second trajectory set, where the second trajectory set includes a plurality of second trajectories, and the second trajectories are first trajectories screened from the first trajectory set by clustering; Acquire a first region area according to the first trajectory set by using a ship domain model, where the first region area is the sum of areas corresponding to each first trajectory in the first trajectory set; Obtaining the second region area corresponding to each of the second trajectory sets; Acquire a busy index according to the area of ​​the first region and the area of ​​the second region, where the busy index is a ratio of the area of ​​the second region to the area of ​​the first region; Acquire water traffic reference data according to the busy index and output it; The area of ​​the first region is obtained by the following formula: Among them, S t is the area of ​​the first region, S i is the domain area of ​​the i-th first trajectory in the first trajectory set, and m is the number of first trajectories in the first trajectory set; The area of ​​the second region is obtained by the following formula: Among them, S h is the area of ​​the second region, t is the number of the second trajectory set, L i is the length of the i-th second trajectory set, W i is the average width of the i-th second trajectory set.

2. The method according to claim 1, characterized in that The acquiring a first trajectory set according to the ship identification data comprises: The drift data, sparse data and noise data in the ship identification data are processed to obtain a first trajectory set.

3. The method according to claim 1, characterized in that The clustering the first trajectory set to obtain a second trajectory set comprises: Acquire multiple initial cluster centers in the first trajectory set, each of the initial cluster centers is a first trajectory in the first trajectory set, and a distance between each of the initial cluster centers is greater than or equal to a preset threshold; Calculating the spatial similarity distance between each of the initial cluster centers and the remaining first trajectories; Allocating the remaining first trajectories to the clusters represented by the initial cluster centers according to the spatial similarity distance to obtain a set of candidate trajectories; The cluster centers in each of the candidate trajectory sets are adjusted to process the candidate trajectory sets to obtain the second trajectory set.

4. The method according to claim 3, characterized in that The spatial similarity distance is obtained by the following formula: in, Among them, C i is the cluster center of the i-th candidate trajectory set, X l is the first trajectory, is the first maximum distance, is the second largest distance, d i,j is the Euclidean distance between the i-th trajectory point on one trajectory and the j-th trajectory point on another trajectory, k is the number of candidate trajectory sets, and n l is the first trajectory X l The number of trajectory points, d(X l , C i ) is the first trajectory X l With cluster center C i The spatial similarity distance between them.

5. The method according to claim 3, characterized in that: The candidate trajectory set is obtained by the following formula: class(X l )=arg(min(d(X l ,C i ))) Among them, d(X l , C i ) is the first trajectory X l With cluster center C i The spatial similarity distance between them, min(d(X l , C i )) is the first trajectory X l The minimum value of the spatial similarity distance between the corresponding cluster center, i = 1, ..., k, X l is the first trajectory, C i is the cluster center of the i-th candidate trajectory set, class(X l ) is the first trajectory X l The set of candidate trajectories.

6. The method according to claim 3, characterized in that The adjustment of the cluster centers in each of the candidate trajectory sets is achieved by the following formula: Among them, C f is the final cluster center, n i is the number of second trajectories in the i-th class, d(X l,i ,X k,i ) is the distance between the lth second trajectory and the kth second trajectory in the i-th class, For the range from 1 to n i The minimum distance in .

7. A traffic congestion evaluation device, characterized in that: The device comprises: A preparation module, used to obtain ship identification data, wherein the ship identification data includes an identification code, a timestamp and location information; A trajectory extraction module, used for acquiring a first trajectory set according to the ship identification data, wherein the first trajectory set includes a plurality of first trajectories, and the first trajectories are acquired by sorting the position information according to the identification code in the order of timestamps; a clustering module, configured to cluster the first trajectory set to obtain at least one second trajectory set, wherein the second trajectory set includes a plurality of second trajectories, and the second trajectory is a first trajectory screened from the first trajectory set through clustering; A first area acquisition module, configured to acquire the area of ​​a first region according to the first trajectory set by using a ship domain model, wherein the area of ​​the first region is the sum of the areas corresponding to each first trajectory in the first trajectory set; A second area acquisition module, used to acquire the second region area corresponding to each of the second trajectory sets; A busy index acquisition module, configured to acquire a busy index according to the area of ​​the first region and the area of ​​the second region, wherein the busy index is a ratio of the area of ​​the second region to the area of ​​the first region; A water area traffic reference number output module, used for obtaining and outputting water area traffic reference data according to the busy index; The area of ​​the first region is obtained by the following formula: Among them, S t is the area of ​​the first region, S i is the domain area of ​​the i-th first trajectory in the first trajectory set, and m is the number of first trajectories in the first trajectory set; The area of ​​the second region is obtained by the following formula: Among them, S h is the area of ​​the second region, t is the number of the second trajectory set, L i is the length of the i-th second trajectory set, W i is the average width of the i-th second trajectory set.

Citation Information

Patent Citations

  • AIS route segment clustering-based route planning method

    CN117073674A

  • Method for determining an optimal naval navigation routes from historical GNSS data of naval trajectories

    EP3739295A1