A method for calculating spatiotemporal adjoint

By expanding the spatiotemporal domain of the main number trajectory and filtering candidate target features, combined with z-score transformation and logistic regression algorithms, the spatiotemporal problems caused by the difference in the number of trajectories and the uneven distribution of base stations are solved, thus improving computational efficiency and accuracy.

CN118843078BActive Publication Date: 2026-06-30CHENGDU HELIO INNOVATION TECH CO LTD

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
CHENGDU HELIO INNOVATION TECH CO LTD
Filing Date
2024-06-25
Publication Date
2026-06-30

AI Technical Summary

Technical Problem

Existing technologies for calculating spatiotemporal trajectory accompaniment suffer from several problems, including large discrepancies in the number of trajectories leading to accompaniment failure, uneven distribution of base stations resulting in incomparable distances, high computational load leading to low efficiency, and a lack of scientific rigor in feature weight settings.

Method used

By expanding the spatiotemporal domain of the main number trajectory, candidate target trajectories are screened, the feature values ​​of the candidate targets are calculated and z-score transformation is used, and the accompanying probability is calculated by combining the logistic regression algorithm, which reduces the amount of computation and improves the accuracy.

Benefits of technology

It effectively solves the problem of failure caused by the difference in the number of trajectories, reduces the incomparability of distances caused by uneven distribution of base stations, improves computational efficiency and enhances the accuracy of the accompanying calculation.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118843078B_ABST
    Figure CN118843078B_ABST
Patent Text Reader

Abstract

This invention relates to the field of trajectory accompaniment technology and discloses a method for calculating spatiotemporal accompaniment, comprising the following steps: extracting the main trajectory of the primary number within a specified time period, denoted as m_traj1; expanding the spatiotemporal domain of the main trajectory, denoted as m_traj2 after expansion; initial screening of target trajectories, denoted as f_traj after initial screening, and calculating the characteristics of the candidate target trajectories; performing trajectory collision and calculating the collision velocity difference and collision distance; statistically calculating the collision characteristics between each candidate target and the primary number; calculating the z-score of each feature value of the candidate target; calculating the weighted average of the features of each candidate target, the larger the weighted average, the higher the accompaniment probability. This method for calculating spatiotemporal accompaniment, through the initial screening process of candidate target trajectories, extracts the inherent features of the candidate target trajectories, combines the collision features between the candidate target and the source trajectory with the inherent features of the candidate target trajectories, and achieves spatiotemporal trajectory accompaniment when the number of trajectories differs significantly, avoiding the problem of trajectory collision failure when the number of trajectories differs significantly.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the field of trajectory accompaniment technology, specifically a method for calculating spatiotemporal accompaniment. Background Technology

[0002] Trajectory accompaniment, also known as trajectory accompaniment, is the calculation of other numbers (accompanying numbers) that accompany a given number (the primary number) and a given time range. The higher the overlap between the trajectory of the accompanying number and the trajectory of the primary number, the higher the probability of them being accompanied. In the calculation of accompaniment for multiple trajectories, the numbers may be external numbers that can directly identify the subject of the trajectory, such as mobile phone numbers, ID card numbers, or license plate numbers. They may also be internal numbers that distinguish the subject, such as ID cards or mobile phone IMSI codes. The primary number and accompanying number may be of the same type (e.g., using the primary mobile phone number to calculate the accompanying mobile phone number) or of different types (e.g., using the mobile phone number to calculate the accompanying person when providing mobile phone signaling and personnel trajectories for the same time period, or using the person's ID card number to calculate the accompanying mobile phone number). The former is generally called single-dimensional accompaniment, and the latter is called multi-dimensional accompaniment.

[0003] With the widespread adoption of 4G and 5G mobile communications, the number of mobile communication users and base stations has increased significantly. By the end of 2023, the total number of mobile communication base stations nationwide reached 11.62 million, of which 3.377 million were 5G base stations, accounting for 29.1% of the total. Statistics show that the coverage range of base stations in urban core areas is approximately 50-500 meters. Using signaling data including data from the base station to which the mobile phone is attached, the movement trajectory of the mobile phone and its owner can be described relatively accurately. Signaling data is a record generated by mobile devices during user calls, text messages, and internet browsing, recording the time, user behavior, and the geographical location and mobile cell of the connected base station. On the other hand, with the rapid advancement of the Skynet project and the rapid development of visual computing technology, images and video data captured by cameras, along with visual computing technology, can now quickly reconstruct the movement trajectories of people and vehicles. With the fusion and convergence of signaling data and visual computing data, the fusion calculation based on mobile phone signaling, personnel trajectories, and vehicle trajectories for single-dimensional and multi-dimensional tracking has moved from theory to practical demand.

[0004] Currently, existing technologies for spatiotemporal trajectory tracking using mobile phone signaling, personnel trajectory, and vehicle trajectory data face the following technical obstacles:

[0005] 1) Significant differences in the number of trajectories: The number of personnel and vehicle trajectories within the same time and space range differs greatly from the number of mobile phone signaling data. The number of mobile phone signaling data within the same time and space range also varies significantly between the primary and secondary SIM cards of the same mobile phone and between different operators.

[0006] 2) The uneven distribution of base stations among different operators and in different regions leads to uneven signaling trajectories in different regions;

[0007] 3) Missing trajectory points for people and vehicles: Due to the collection rate and recognition rate, even if people and vehicles appear near the collection point, their trajectory data may be missing.

[0008] Currently, there are two main technical solutions for spatiotemporal trajectory tracking using signaling data and visual computing data:

[0009] 1. Trajectory collision-based methods

[0010] Trajectory collision refers to the spatiotemporal overlap between the target trajectory and the primary number trajectory. Specifically, within a specified time and space range, both the primary number and the candidate target appear within that range. The time range 't' can be set via parameters; target trajectories appearing within the source trajectory's time point T ± t are considered to have spatiotemporal overlap. The spatial range parameter 'p' represents the area within a circle with radius 'p' centered on the primary number's trajectory point P; these areas are considered to have spatial overlap. Distance calculations with large datasets are very resource-intensive. To reduce computational load, spatial overlap is typically approximated using geographic grids such as Geohash. The geographic grid precision 'P' is determined based on parameter 'p' and the error range of each precision geographic grid. G The target trajectory appears at point P of the source trajectory. G The geographic grid of precision and the computable space within its neighborhood are considered to be spatially overlapping.

[0011] When the primary or accompanying number is a mobile phone, the number of mobile phones attached to the same base station at the same time is large, and the number of candidate numbers participating in trajectory collisions for a single trajectory point is even larger. Generally, there are thousands of candidate numbers participating in collisions for a single trajectory point, and in extreme cases, there can be tens of thousands. Simply relying on the number of collisions and the proportion cannot effectively filter out the accompanying numbers. At this time, it is necessary to use feature engineering to establish the overall feature value of each candidate target accompanying the entire trajectory, such as: number of collisions, number of collision points, accompanying time, accompanying distance, etc., calculate the normalized value of each feature, and then calculate the weighted average of multiple feature values. The larger the weighted average value, the higher the probability of the candidate target and the primary number accompanying each other.

[0012] 2. Trajectory Similarity-Based Methods

[0013] This method compares the trajectory of the primary number with the trajectory of the candidate target, and calculates the similarity between the trajectory of the primary number and the trajectory of the candidate target. Candidate targets with trajectory similarity exceeding a certain threshold can be regarded as having a spatiotemporal trajectory. The higher the trajectory similarity, the greater the probability of the primary number and the candidate target. The calculation method of trajectory similarity varies depending on the algorithm.

[0014] In practical applications, to reduce the computational burden of trajectory similarity calculation, trajectory collision is used for initial screening of candidate targets. Only targets with a collision count or ratio higher than each value are included in the candidate target set. Depending on the selection scheme, the shortcomings of existing technical solutions are described as follows:

[0015] 1. Limitations of trajectory collision-based methods

[0016] This method uses feature engineering and only considers the features related to trajectory collision, without considering the features of the candidate target itself. For example, for secondary SIM phone numbers with fewer trajectory points or phone numbers from operators with fewer base stations, there are fewer signaling trajectory points, so the number of collision trajectory points will naturally be less than that of phones with more trajectory points.

[0017] On the other hand, existing distance calculation methods have two problems when considering the distance characteristics of the main number and the individual trajectory points of the accompanying target:

[0018] a) Directly calculate the geographical distance between the primary number and the collision trajectory point of the accompanying target. When the accompanying number is a mobile phone, due to the uneven distribution and different densities of base stations in different operators and regions, this distance is not comparable. What is comparable is the distance between the candidate target and the nearest base station of the same operator. When the accompanying number is not a mobile phone and the primary number is a mobile phone, the comparable distance is the distance between the candidate target and the nearest base station of the primary number of the same operator.

[0019] b) Directly calculating geographical distance involves a huge amount of computation and the algorithm is extremely inefficient. If we consider the calculation of the nearest base station of the same operator for each trajectory point, the amount of computation will increase exponentially.

[0020] Secondly, the weighting parameters for each feature weighting calculation are mostly set through empirical values, lacking theoretical support; 2. Deficiencies of trajectory similarity-based methods

[0021] First, due to the large difference in the number of trajectory points between the primary number and the candidate target, the traditional quantitative indicators for calculating trajectory similarity need to be adjusted accordingly.

[0022] Secondly, similar to the shortcomings of method 1, when the primary number or the accompanying number is a mobile phone, the distance in the trajectory similarity calculation needs to take into account the distance of the nearest base station;

[0023] Finally, the lack of key trajectory points such as inflection points in candidate targets such as personnel and vehicles will lead to a large difference between the trajectory reconstructed from the trajectory data and the actual trajectory, ultimately resulting in the trajectory similarity calculation results not matching reality and spatiotemporal errors.

[0024] Therefore, a method for calculating spatiotemporal adjoints is needed to improve the following technical problems existing in the above-mentioned prior art:

[0025] 1. When using the trajectory collision method to calculate the spatiotemporal accompaniment, the trajectory characteristics of the candidate target itself are not considered, which leads to the failure of the accompaniment when the number of trajectories of the main number and the target number differs greatly;

[0026] 2. When signaling trajectories are involved in trajectory collisions, directly calculating the distance between the primary number trajectory point and the target trajectory point at the time of the collision is not comparable;

[0027] 3. When calculating the distance to the nearest base station of the operator, directly calculating the distance involves a large amount of computation, resulting in low computational efficiency;

[0028] 4. Setting feature weight parameters based on empirical values ​​cannot guarantee the rationality and scientific validity of the settings. Summary of the Invention

[0029] (a) Technical problems to be solved

[0030] To address the shortcomings of existing technologies, this invention provides a method for calculating spatiotemporal accompaniment, which has the advantages of preventing accompaniment failure due to a large difference in the number of trajectories of the primary number and the target number, and improving computational efficiency. It solves the problem of spatiotemporal accompaniment failure when the number of trajectories of the primary number and the target number differs significantly and the base station distribution in the signaling data is uneven.

[0031] (II) Technical Solution

[0032] To achieve the aforementioned goals of preventing significant discrepancies in the number of trajectories between the primary and target numbers that could lead to accompanying failures and to improve computational efficiency, this invention provides the following technical solution: A method for calculating spatiotemporal trajectories, comprising the following steps:

[0033] S1. Extract the main trajectory of the main number within a specified time period, denoted as m_traj1. The main trajectory consists of a series of trajectory points.

[0034] S2. Expand the spatiotemporal domain of the main trajectory. The expanded trajectory is denoted as m_traj2. The temporal expansion method is to extend the start and end times of each trajectory point outward by time t. The spatial expansion method is to expand the geographic grid of the trajectory point to the geographic grid of the trajectory point and its 8-neighborhood, ensuring that trajectories that overlap within the specified spatiotemporal range can complete the collision.

[0035] S3. Initial screening of target trajectories: The initial screened target trajectories are denoted as f_traj. Candidate target trajectories are then selected based on the time and spatial range of m_traj2, and their features are calculated. The geographic grid precision used for the initial screening of trajectories is the same as that used for the source trajectories, P. G same;

[0036] S4. Perform trajectory collision between the trajectory in f_traj and the trajectory in m_traj2. If a trajectory point in f_traj is within the extended spacetime range of a trajectory point in m_traj2, it can be considered as satisfying the trajectory collision condition. Calculate the collision velocity difference and collision distance.

[0037] S5. Statistically analyze and calculate the collision characteristics between each candidate target and the main number;

[0038] S6. Calculate the z-score of each feature value of the candidate target;

[0039] S7. Calculate the weighted average of the features of each candidate target. The larger the weighted average, the higher the probability.

[0040] Preferably, the candidate target trajectory features mentioned in step S3 include, but are not limited to, the number of trajectories, the number of trajectory points, and the trajectory time for each candidate target. The method for calculating the candidate target trajectory features is as follows:

[0041] Set the number of trajectories to traj_count, which is calculated as the number of trajectories that meet the initial screening criteria for the candidate target.

[0042] Set the number of trajectory points to pos_count, which is calculated as the number of duplicate P values ​​of the trajectory that meets the initial screening criteria for the candidate target. G Number of geographic grids with high precision;

[0043] The trajectory time is set to total_time, which is calculated as the sum of the dwell times of the trajectories that meet the initial screening conditions for the candidate target.

[0044] Preferably, the calculation method for the collision speed difference and collision distance in step S4 is as follows:

[0045] The collision velocity difference is set as loc_speed_diff, which is calculated as the velocity difference between the source and the candidate target in each source trajectory time interval at the time of the collision:

[0046] L1. Calculate the geographical distance between the source collision trajectory point and the next hop trajectory point, divide it by the dwell time of the source collision trajectory point, and that is the source velocity;

[0047] L2. Calculate the distance between the first and last collision trajectory points of the candidate target under the source trajectory point, divide it by the dwell time of the target trajectory participating in the collision of the source trajectory, and that is the collision velocity of the candidate target at the source trajectory point;

[0048] L3. Calculate the absolute value of the speed difference between the two speeds, loc_speed_diff.

[0049] The collision distance is set to loc_geo_dist, which is calculated as the distance between the source trajectory point and the candidate target trajectory point when a collision occurs, using the geographical distance between the two points.

[0050] Preferably, the collision features mentioned in step 5 include, but are not limited to, the number of collisions, the number of collision points, the total time, the time span, the spatial span, the average collision velocity difference, and the average collision distance. The feature calculation method for each candidate target is as follows:

[0051] The number of collisions is set as acc_count, which is calculated as the number of collisions in the collision record between the candidate target and the main number, based on the source trajectory. If multiple candidate target trajectories collide with the same source trajectory, it is counted as 1 time.

[0052] Set the number of collision points to acc_pos_count, which is calculated by counting the number of duplicate source trajectory points P in the collision records between the candidate target and the main number. G The number of geographic grids with high precision, if multiple candidate target trajectories have the same P G If the source trajectory points of the precision geographic grid collide, it is counted as 1 point.

[0053] The total time of accompaniment is set as acc_total_time, which is calculated as the sum of the overlap time between the source trajectory and the candidate target trajectory in the collision record between the candidate target and the main number.

[0054] The accompanying time span is set as acc_time_span, which is calculated as the time of the last collision record + the overlap time of the last collision record - the time of the first collision record in the collision records between the candidate target and the main number.

[0055] The accompanying space span is set as acc_space_span, which is calculated as the diagonal distance between the inscribed rectangle of the source trajectory and the target trajectory in the collision record between the candidate target and the main number.

[0056] The average collision speed difference is set as acc_speed_diff, which is calculated as the average of all collision speed differences in the collision records between the candidate target and the main number.

[0057] The average collision distance is set as acc_geo_dist, which is calculated as the average of all collision distances in the collision records between the candidate target and the main number.

[0058] Preferably, the weighted average of the candidate target features in step S7 is calculated using the following formula:

[0059] acc_score=(w1*z_acc_count*(acc_count / traj_count)+w2*z_acc_pos_count*(acc_pos_count / pos_count)+w3*z_acc_total_ time*(acc_total_time / total_time)+w4*z_acc_time_span+w5*z_acc_space_span-w6*acc_speed_diff-w7*acc_geo_dist) / Σwi

[0060] Preferably, in the collision distance calculation process described in step S4, when there are multiple sensing devices available for the candidate target within the spatial error range of the source trajectory point, the geographical distance between the available sensing device closest to the source trajectory point and the trajectory point of the candidate target is used as the collision distance.

[0061] Preferably, when calculating the distance between the location of the nearest available sensing device to the source trajectory point and the location of the trajectory point of the candidate target, the relative distance is estimated using the geographic grid values ​​of the sensing device, the source trajectory point, and the target trajectory point.

[0062] Preferably, in step S7, instead of using the weighted average method of empirical values, the associated probability is directly calculated using the Logistic Regression algorithm, where the formula for calculating the associated probability is as follows:

[0063]

[0064] Preferably, candidate target filtering is performed by setting algorithm hyperparameters based on collision features. The collision features include pos_count, acc_pos_count, acc_speed_diff, and acc_space_span, and the algorithm hyperparameters include min_pos_count, min_acc_pos_count, max_acc_speed_diff, and min_acc_space_span.

[0065] (III) Beneficial Effects

[0066] Compared with the prior art, the present invention provides a method for calculating spatiotemporal adjoint, which has the following beneficial effects:

[0067] 1. This method for calculating spatiotemporal accompaniment extracts the trajectory features of candidate targets through an initial screening process. It combines the collision features between the candidate target and the source trajectory with the inherent features of the candidate target trajectory to achieve spatiotemporal trajectory accompaniment when the number of trajectories differs significantly, thus avoiding the problem of trajectory collision failure when the number of trajectories differs significantly.

[0068] 2. This method of calculating spatiotemporal accompaniment, when there are multiple available sensing devices for candidate targets within the spatial error range of the source trajectory point, uses the geographical distance between the available sensing device closest to the source trajectory point and the trajectory point of the candidate target as the collision distance, instead of the geographical distance between the source trajectory point and the target trajectory point. This can avoid the problem of incomparable distances caused by uneven regional distribution of sensing devices.

[0069] 3. This method for calculating spatiotemporal accompaniment estimates the relative distances between sensing devices, source trajectory points, and target trajectory points using geographic grid values, thereby reducing computational load and improving algorithm efficiency.

[0070] 4. This method for calculating spatiotemporal companions obtains feature information for each candidate companion by calculating the characteristics of the candidate spatiotemporal companions, including the number of trajectories, the number of trajectory points, the trajectory time, the number of collisions, the number of collision points, the total companion time, the companion time span, the companion spatial span, the average collision velocity difference, and the average collision distance. It then uses a logistic regression algorithm to calculate the companion probability and quantitatively evaluate the candidate companion targets. By adjusting hyperparameter settings, the amount of data and computation in the correlation operations is reduced, effectively avoiding the influence of interfering data and increasing the accuracy of the companion calculation. Attached Figure Description

[0071] Figure 1 This is a schematic diagram illustrating the Geohash accuracy of the present invention;

[0072] Figure 2 This is a schematic diagram of the WS107M mesh of the present invention. Detailed Implementation

[0073] The technical solutions of the present invention will be clearly and completely described below with reference to the embodiments and accompanying drawings. Obviously, the described embodiments are only some embodiments of the present invention, and not all embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of the present invention.

[0074] A method for calculating spatiotemporal adjoint includes the following steps:

[0075] S1. Extract the main trajectory of the main number within a specified time period, denoted as m_traj1. The main trajectory consists of a series of trajectory points.

[0076] S2. Expand the spatiotemporal domain of the main trajectory. The expanded trajectory is denoted as m_traj2. The temporal expansion method is to extend the start and end times of each trajectory point outward by time t. The spatial expansion method is to expand the geographic grid of the trajectory point to the geographic grid of the trajectory point and its 8-neighborhood, ensuring that trajectories that overlap within the specified spatiotemporal range can complete the collision.

[0077] S3. Initial screening of target trajectories: The initial screened target trajectories are denoted as f_traj. Candidate target trajectories are then selected based on the time and spatial range of m_traj2, and their features are calculated. The geographic grid precision used for the initial screening of trajectories is the same as that used for the source trajectories, P. G same;

[0078] S4. Perform trajectory collision between the trajectory in f_traj and the trajectory in m_traj2. If a trajectory point in f_traj is within the extended spacetime range of a trajectory point in m_traj2, it can be considered as satisfying the trajectory collision condition. Calculate the collision velocity difference and collision distance.

[0079] S5. Statistically analyze and calculate the collision characteristics between each candidate target and the main number;

[0080] S6. Calculate the z-score of each feature value of the candidate target. The calculation formula is z-score=(x-μ) / σ, where x is the feature value, which represents the actual value of the candidate target on this feature, μ is the feature mean, which represents the mean of all candidate targets on this feature, and σ is the feature standard deviation, which represents the standard deviation of all candidate targets on this feature.

[0081] S7. Calculate the weighted average of the features of each candidate target. The larger the weighted average, the higher the probability.

[0082] The information on the main number's tracking points is shown in the table below:

[0083]

[0084]

[0085] Set the spatial range of trajectory collision to P, and the geographic grid precision to P. G Among them, the geographic grid accuracy P G The spatial range P of trajectory collision and the error range of the geographic grid are determined. Taking spatiotemporal trajectory accompaniment involving mobile phones as an example, the coverage diameter of most 4G base stations is currently within 2KM, and the spatial range P is taken as 1km. Considering that the actual distance between the edge of the geographic grid and the neighboring area is very small, when using geohash as the geographic grid, the geographic grid accuracy P is determined by referring to the geohash accuracy table. G A value of 6 indicates a 6-bit precision geohash and its neighborhood as a rectangle. Even with this, the error range is slightly greater than 1 km. Therefore, the geographic grid and its neighborhood are only an approximation of the spatial range. To improve the accuracy of this approximation, Google S2, with its finer grid precision, can be used. The precision of geohash is shown in the attached figure. Figure 1 As shown.

[0086] As attached Figure 2 As shown by the arrow in the ws107m grid, the distance between the edge of the Geohash grid and the neighboring grid is lower than the distance between other locations in the same grid. Therefore, when using Geohash to expand the spatial domain, it is necessary to expand the domain to the geographic grid of the current trajectory point and its neighborhood.

[0087] During the above implementation process, the geographic grid accuracy P of geohash G Values ​​can be calculated in real time or in advance, or high-precision values ​​can be calculated first and then truncated to the required precision when extracting data. In actual raw trajectory data, there may be trajectories with missing data, multiple continuous trajectories at the same location, drifting trajectories, ping-pong switching trajectories, etc. The detection and processing of these abnormal data can be handled uniformly before entering the adjoint calculation.

[0088] Set the start time of the collision between the overlapping trajectories in the spatiotemporal range in step S2 to Ti. M1 -t (i = 1, 2, 3...n), the trajectory collision end time is set to Ti. M1 +Di M1 +t(i = 1, 2, 3…n), with the grid and neighborhood set to Geohashi. M1 and its neighborhood (i = 1, 2, 3…n),

[0089] The collision information of trajectories with overlapping spatiotemporal ranges is shown in the table below:

[0090]

[0091] In step S3, candidate target trajectories are filtered based on time and spatial ranges, and the characteristics of the candidate target trajectories are calculated. The spatiotemporal range filtering formula is expressed as follows:

[0092] (candidate trajectory geographic grid IN Merge(grid and neighborhood)) AND (candidate trajectory start time ∈ [min(collision start time), max(collision end time)] OR candidate trajectory start time + candidate trajectory dwell time ∈ [min(collision start time), max(collision end time)]);

[0093] The trajectory information of the candidate targets after initial screening is shown in the table below:

[0094]

[0095] The candidate target trajectory features include, but are not limited to, the number of trajectories, the number of trajectory points, and the trajectory time for each candidate target. The calculation method for the candidate target trajectory features is as follows:

[0096] Set the number of trajectories to traj_count, which is calculated as the number of trajectories that meet the initial screening criteria for the candidate target.

[0097] Set the number of trajectory points to pos_count, which is calculated as the number of duplicate P values ​​of the trajectory that meets the initial screening criteria for the candidate target. G Number of geographic grids with high precision;

[0098] The trajectory time is set to total_time, which is calculated as the sum of the dwell times of the trajectories that meet the initial screening conditions for the candidate target.

[0099] In step S4, the trajectory in f_traj is compared with the trajectory in m_traj2. The spatiotemporal range filtering formula is expressed as follows:

[0100] (candidate trajectory point geographic grid IN source trajectory point grid and neighborhood) AND (candidate trajectory point start time ∈ [source trajectory point collision start time, source trajectory point collision end time] OR (candidate trajectory point start time + candidate trajectory point dwell time) ∈ [source trajectory point collision start time, source trajectory point collision end time]);

[0101] The collision results are shown in the table below:

[0102]

[0103]

[0104] The methods for calculating the collision speed difference and collision distance are as follows:

[0105] The collision velocity difference is set as loc_speed_diff, which is calculated as the velocity difference between the source and the candidate target in each source trajectory time interval at the time of the collision:

[0106] L1. Calculate the distance between the source collision trajectory point and the next jump trajectory point (calculated by latitude and longitude), divide it by the dwell time of the source collision trajectory point, and that is the source velocity;

[0107] L2. Calculate the distance between the first and last collision trajectory points of the candidate target under the source trajectory point, divide it by the dwell time of the target trajectory participating in the collision of the source trajectory, and that is the collision velocity of the candidate target at the source trajectory point;

[0108] L3. Calculate the absolute value of the speed difference between the two speeds, loc_speed_diff.

[0109] The collision distance is set to loc_geo_dist, which is calculated as the distance between the source trajectory point and the candidate target trajectory point when a collision occurs, using the geographical distance between the two points.

[0110] The collision features in step 5 include, but are not limited to, the number of collisions, the number of collision points, the total time, the time span, the spatial span, the average collision velocity difference, and the average collision distance. The feature calculation method for each candidate target is as follows:

[0111] The number of collisions is set as acc_count, which is calculated as the number of collisions in the collision record between the candidate target and the main number, based on the source trajectory. If multiple candidate target trajectory points collide with the same source trajectory point, it is counted as 1 time.

[0112] Set the number of collision points to acc_pos_count, which is calculated by counting the number of duplicate source trajectory points P in the collision records between the candidate target and the main number. G Precision geographic grid number, if multiple candidate target trajectory points are the same as P G If the source trajectory points of the precision geographic grid collide, it is counted as 1 point.

[0113] The total time of accompaniment is set as acc_total_time, which is calculated as the sum of the overlap time between the source trajectory and the candidate target trajectory in the collision record between the candidate target and the main number.

[0114] The accompanying time span is set as acc_time_span, which is calculated as the time of the last collision record + the overlap time of the last collision record - the time of the first collision record in the collision records between the candidate target and the main number.

[0115] The accompanying space span is set as acc_space_span, which is calculated as the diagonal distance between the inscribed rectangle of the source trajectory and the target trajectory in the collision record between the candidate target and the main number.

[0116] The average collision speed difference is set as acc_speed_diff, which is calculated as the average of all collision speed differences in the collision records between the candidate target and the main number.

[0117] The average collision distance is set as acc_geo_dist, which is calculated as the average of all collision distances in the collision records between the candidate target and the main number.

[0118] Using the source trajectory collision points as the basis for the number of collisions and the number of collision points is to reduce the impact caused by the difference in the number of trajectories and the number of collision points of candidate targets.

[0119] In step S6, when performing z-score transformation on each feature, let's take the calculation of z_score for the adjoint number as an example:

[0120] z_acc_count=(acc_count-avg(acc_count)) / std(acc_count)

[0121] The reason for performing z-score transformation is to convert each feature into a dimensionless sequence with a mean of 0 and a variance of 1. This avoids the situation where features with larger values ​​suppress features with smaller values ​​when there is a large difference in the numerical values ​​of different features, and ensures that each feature can play a role.

[0122] The formula for calculating the weighted average of candidate target features in step S7 is as follows:

[0123] acc_score=(w1*z_acc_count*(acc_count / traj_count)+w2*z_acc_pos_count*(acc_pos_count / pos_count)+w3*z_acc_total_ time*(acc_total_time / total_time)+w4*z_acc_time_span+w5*z_acc_space_span-w6*acc_speed_diff-w7*acc_geo_dist) / Σwi

[0124] The formula is explained in the table below:

[0125]

[0126] The weight parameters w1 to w7 are estimated empirically based on existing positive samples. Candidate targets are sorted in reverse order according to acc_score, and the higher the score, the greater the probability.

[0127] Preferably, in the collision distance calculation process in step S4, when there are multiple sensing devices available for the candidate target within the spatial error range of the source trajectory point, the geographical distance between the available sensing device closest to the source trajectory point and the trajectory point of the candidate target is used as the collision distance.

[0128] A typical scenario in this embodiment is to use signaling trajectory to calculate the accompanying number of the primary number. The position in the signaling trajectory is the location of the mobile phone attached to the base station at that time. The collision distance calculated in step S4 is actually the geographical distance between the primary number and the accompanying target attached to the base station at that time. Considering that the base station distribution is uneven and the density is different in different operators and different regions, the collision distance is not comparable. Under normal circumstances, the probability of the mobile phone attaching to the nearest base station of its own operator is relatively high, and the probability of attaching to a distant base station is relatively low. Therefore, the collision distance should be calculated as the distance between the candidate target trajectory point and the nearest base station of the same operator. The larger the distance, the smaller the probability of being attached.

[0129] The collision distance calculation method for this scenario is as follows:

[0130] a1. Initial screening of base stations: Based on the geographic location grid and neighborhood of the source trajectory points in m_traj2, select base stations in the base station table that are the same as the candidate target operators and whose geographic grid is within the grid and neighborhood of the source trajectory points. The basic information of the base station table is shown below, where the accuracy of the geographic grid is P, which is the same as the accuracy of the source trajectory geographic grid. G same;

[0131] Serial Number Base station number Operators longitude latitude Geographic Grid 1 J1 <![CDATA[O J1 ]]> <![CDATA[Lon1 J1 ]]> <![CDATA[Lat1 J1 ]]> <![CDATA[Geohash1 J1 ]]> 2 J1 <![CDATA[O J2 ]]> <![CDATA[Lon2 J2 ]]> <![CDATA[Lat2 J2 ]]> <![CDATA[Geohash2 J2 ]]> 3 J1 <![CDATA[O J3 ]]> <![CDATA[Lon3 J3 ]]> <![CDATA[Lat3 J3 ]]> <![CDATA[Geohash1 J3 ]]> 4 J1 <![CDATA[O J4 ]]> <![CDATA[Lon4 J4 ]]> <![CDATA[Lat4 J4 ]]> <![CDATA[Geohash2 J4 ]]> … … … … … …

[0132] The filtering formula is: (Base station operator = candidate target operator) AND (Base station geographic grid IN source trajectory point grid and neighborhood);

[0133] a2. Calculate the geographical distance between the filtered base station and the source trajectory point, compare the distances, and obtain the candidate target base station of the same operator that is closest to the source trajectory point;

[0134]

[0135] a3. Calculate the geographical distance between the candidate target trajectory point and the nearest base station in the previous step at the time of collision;

[0136] In practice, when the source trajectory points, operator list, and base station list can be obtained all at once, a1 and a2 can be merged. First, calculate the nearest base station of all source trajectory points and all operators at once. Then, based on the candidate target operators and source trajectory points in the collision records, extract the latitude and longitude of the nearest base station. Finally, calculate the geographical distance between the candidate target trajectory point and the nearest base station of the current operator. The nearest base station results are shown in the table below:

[0137] Serial Number Source trajectory point Operators Nearest base station number longitude latitude 1 Tr1 O1 J_Tr1_O1 Lon_Tr1_O1 Lat_Tr1_O1 2 Tr1 O2 J_Tr1_O2 Lon_Tr1_O2 Lat_Tr1_O2 3 Tr1 O3 J_Tr1_O3 Lon_Tr1_O3 Lat_Tr1_O3 4 Tr1 O4 J_Tr1_O4 Lon_Tr1_O4 Lat_Tr1_O4 1 Tr2 O1 J_Tr2_O1 Lon_Tr2_O1 Lat_Tr1_O1 2 Tr2 O2 J_Tr2_O2 Lon_Tr2_O2 Lat_Tr2_O2 3 Tr2 O3 J_Tr2_O3 Lon_Tr2_O3 Lat_Tr3_O3 4 Tr2 O4 J_Tr2_O4 Lon_Tr2_O4 Lat_Tr4_O4

[0138] Preferably, when calculating the distance between the location of the nearest available sensing device to the source trajectory point and the location of the candidate target trajectory point, the relative distance is estimated using the geographic grid values ​​of the sensing device, the source trajectory point, and the target trajectory point. Using this distance estimation method reduces computation and improves algorithm efficiency. Taking geohash as an example, the specific calculation method is as follows:

[0139] b1. P of the computational sensing device (taking a base station as an example), source trajectory points, and initial screening trajectory points G Geohash values ​​with +1 bit precision, including the mobile phone as an accompanying source or target, have a geohash precision P. G =6. In practice, the 7-bit precision geohash value of all trajectories and base stations can be calculated in advance, and then the 6-bit geohash precision value can be obtained by extracting the first 6 bits of the string.

[0140] b2. Calculate P after deduplication in the base station table. G +1 bit precision geohash value and its corresponding carrier list, representing the P of the source trajectory. G When the geohash value with +1 bit precision is equal to this value, the nearest base station of the operator in this list is represented by this geohash value;

[0141]

[0142]

[0143] b3. Calculate P after deduplication in the base station table. G Bit-precision geohash values ​​and their corresponding carrier lists represent the P of the source trajectory. G When the geohash value is equal to this value, the nearest base station of the operator in the list is represented by this geohash value;

[0144] Serial Number <![CDATA[P G [bit geohash value]]> Carrier list 1 <![CDATA[Geohash_P G _1]]> [O2, O3, O4] 2 <![CDATA[Geohash_P G _2]]> [O1, O4]

[0145] b4. In the collision log, based on the operator of the candidate target trajectory point, the source trajectory point P G +1 bit geohash value or P G The geohash value determines the geohash value of the nearest base station;

[0146] b5. Compare the geohash values ​​of the candidate target trajectory points with the geohash values ​​of the nearest base stations to calculate the relative distance. The calculation method is as follows:

[0147] 1) If P of two geohash values G +1 bit precision means that the candidate target trajectory point is in the same P-value as the nearest base station of this operator. G Within the +1 digit geohash range, using this as the baseline distance, the collision distance is counted as 1;

[0148] 2) Otherwise, if the two geohash values ​​P G The same bit precision indicates that the candidate target trajectory point is in the same P-value as the nearest base station of this operator. G Within the bit geohash range, the collision distance is denoted as dist1, where dist1 = (P G (bit geohash error range) / (P) G +1 bit geohash error range), P G When the error is 6, dist1 = (6-bit geohash error range) / (7-bit geohash error range), and the result is 8.

[0149] 3) Otherwise, if the candidate target trajectory point P G In table b3, the geohash and its operator indicate that the candidate target trajectory point is within the neighborhood of the source trajectory point, and the candidate target trajectory point is on the same P-value as the nearest base station of this operator. G Within the bit geohash range, the collision distance is measured as dist1;

[0150] 4) Otherwise, the collision distance is measured as dist2, where dist2 = (P G -1 bit geohash error range) / (P G +1 bit geohash error range); P G When = 6, dist2 = 5-bit geohash error range / 7-bit geohash error range, and the calculation result is 24.

[0151] The collision distance estimated by the above method is in P G The +1 bit precision geohash range is the baseline relative distance, which can be used as an approximate estimate of the actual geographic distance because the collision distance will be converted to a z-score during final processing.

[0152] Preferably, in step S7, instead of using the weighted average method of empirical values, the associated probability is directly calculated using the Logistic Regression algorithm, where the formula for calculating the associated probability is as follows:

[0153]

[0154] Features X1~X n The feature values ​​and their combinations obtained in steps S3 and S6 are used, specifically including: z_acc_count*(acc_count / traj_count), z_acc_pos_count*(acc_pos_count / pos_count), z_acc_total_time*(acc_total_time / total_time), z_acc_time_span, z_acc_space_span, z_acc_speed_diff, and z_acc_geo_dist;

[0155] The model was trained using previously acquired spatiotemporal positive samples to obtain model parameters θ0~θ n In actual calculation of the association, the feature values ​​of the candidate target and their combinations are used to calculate the association probability value of the candidate target. When the association probability value exceeds the specified threshold (e.g., 0.5), it can be regarded as a spatiotemporal association. The association probability threshold can be set as needed.

[0156] Preferably, candidate target filtering is performed by setting algorithm hyperparameters based on collision features. The collision features that can be set as hyperparameters include pos_count, acc_pos_count, acc_speed_diff, and acc_space_span, and the corresponding algorithm hyperparameters include min_pos_count, min_acc_pos_count, max_acc_speed_diff, and min_acc_space_span.

[0157] Filtering candidate targets by setting algorithm hyperparameters based on existing features can reduce the computational load and improve the efficiency of the algorithm. The specific applications of existing features and their hyperparameters are shown in the table below:

[0158]

[0159] The beneficial effects of this invention are: the method for calculating spatiotemporal accompaniment extracts the features of candidate target trajectories through the initial screening process of candidate target trajectories, combines the collision features between the candidate target and the source trajectory with the inherent features of the candidate target trajectory, and realizes spatiotemporal trajectory accompaniment when the number of trajectories differs greatly, thus avoiding the problem of trajectory collision failure when the number of trajectories differs greatly.

[0160] When there are multiple available sensing devices for candidate targets within the spatial error range of the source trajectory point, the geographical distance between the available sensing device closest to the source trajectory point and the trajectory point of the candidate target can be used as the collision distance to replace the geographical distance between the source trajectory point and the target trajectory point. This can avoid the problem of incomparable distances caused by uneven distribution of sensing devices.

[0161] By using the geographic grid values ​​of sensing devices, source trajectory points, and target trajectory points to estimate relative distances, the computational load is reduced and the algorithm efficiency is improved.

[0162] By calculating the spatiotemporal accompanying candidate target features, we obtain characteristic information for each candidate accompanying target, including the number of trajectories, the number of trajectory points, the trajectory time, the number of collisions, the number of collision points, the total accompanying time, the accompanying time span, the accompanying spatial span, the average collision velocity difference, and the average collision distance. We then use a logistic regression algorithm to calculate the accompanying probability and quantitatively evaluate the candidate accompanying targets. Through hyperparameter settings, we reduce the amount of data and computational load in correlation operations, effectively avoiding the influence of interfering data and increasing the accuracy of accompanying calculations.

[0163] Although embodiments of the invention have been shown and described, it will be understood by those skilled in the art that various changes, modifications, substitutions and alterations can be made to these embodiments without departing from the principles and spirit of the invention, the scope of which is defined by the appended claims and their equivalents.

Claims

1. A method for calculating spatiotemporal adjoints, characterized in that, Includes the following steps: S1. Extract the source trajectory of the main number within a specified time period, denoted as m_traj1. The source trajectory consists of a series of trajectory points. S2. Spatiotemporal expansion of the source trajectory, the expanded trajectory is denoted as m_traj2. The temporal expansion method is to expand the start and end times of each trajectory point outward by time t. The spatial expansion method is to expand the geographic grid of the trajectory point to the geographic grid of the trajectory point and its 8 neighbors, ensuring that trajectories that overlap within the specified spatiotemporal range can complete the collision. S3. Initial screening of target trajectories: The initial screened target trajectories are denoted as f_traj. Candidate target trajectories are then selected based on the time and spatial range of m_traj2, and their features are calculated. The geographic grid precision used for the initial screening of trajectories is the same as that used for the source trajectories, P. G same; S4. Perform trajectory collision between the trajectory in f_traj and the trajectory in m_traj2. If a trajectory point in f_traj is within the extended spacetime range of a trajectory point in m_traj2, it can be considered as satisfying the trajectory collision condition. Calculate the collision velocity difference and collision distance. S5. Statistically analyze and calculate the collision characteristics between each candidate target and the main number; S6. Calculate the z-score of each feature value of the candidate target; S7. Calculate the weighted average of the features of each candidate target. The larger the weighted average, the higher the probability. The candidate target trajectory features mentioned in step S3 include, but are not limited to, the number of trajectories, the number of trajectory points, and the trajectory time for each candidate target; the trajectory features of the candidate targets are calculated as follows: Set the number of trajectories to traj_count, which is calculated as the number of trajectories that meet the initial screening criteria for the candidate target. Set the number of trajectory points to pos_count, which is calculated as the geographic grid accuracy P of the deduplicated trajectory that meets the initial screening criteria for the candidate target. G The number of geographic grids; The trajectory time is set to total_time, which is calculated as the total dwell time of the trajectory that satisfies the initial screening conditions for the candidate target. The calculation methods for the collision speed difference and collision distance in step S4 are as follows: The collision velocity difference is set as loc_speed_diff, which is calculated as the velocity difference between the source trajectory point and the candidate target in each time interval of the source trajectory at the time of the collision. L1. Calculate the geographical distance between the source collision trajectory point and the next hop trajectory point, divide it by the dwell time of the source collision trajectory point, and that is the source velocity; L2. Calculate the distance between the first and last collision trajectory points of the candidate target under the source trajectory point, divide it by the dwell time of the target trajectory participating in the collision of this source trajectory, and that is the collision velocity of the candidate target at the source trajectory point; L3. Calculate the absolute value of the speed difference between the two speeds, loc_speed_diff; The collision distance is set to loc_geo_dist, which is calculated as the distance between the source trajectory point and the candidate target trajectory point when a collision occurs, based on the geographical distance between the two points. The collision features mentioned in step S5 include, but are not limited to, the number of collisions, the number of collision points, the total time, the time span, the spatial span, the average collision velocity difference, and the average collision distance. The feature calculation method for each candidate target is as follows: The number of collisions is set as acc_count, which is calculated as the number of collisions in the collision record between the candidate target and the main number, based on the source trajectory. If multiple candidate target trajectories collide with the same source trajectory, it is counted as 1 time. Set the number of collision points to acc_pos_count, which is calculated as the deduplicated geographic grid precision P in the collision records between the candidate target and the main number. G The number of geographic grids, if multiple candidate target trajectories are with the same geographic grid precision P G If a point on the source trajectory collides with another point, it is counted as one point. The total time of accompaniment is set as acc_total_time, which is calculated as the sum of the overlap time between the source trajectory and the candidate target trajectory in the collision record between the candidate target and the main number. The accompanying time span is set as acc_time_span, which is calculated as the time of the last collision record + the overlap time of the last collision record - the time of the first collision record in the collision records between the candidate target and the main number. The accompanying space span is set as acc_space_span, which is calculated as the diagonal distance between the inscribed rectangle of the source trajectory and the target trajectory in the collision record between the candidate target and the main number. The average collision speed difference is set as acc_speed_diff, which is calculated as the average of all collision speed differences in the collision records between the candidate target and the main number. The average collision distance is set as acc_geo_dist, which is calculated as the average of all collision distances in the collision records between the candidate target and the main number.

2. The method for calculating spatiotemporal adjoints according to claim 1, characterized in that, The method for calculating the weighted average of the candidate target features in step S7 is as follows: acc_score=(w1*z_acc_count*(acc_count / traj_count)+w2*z_acc_pos_count*(acc_pos_count / pos_count)+w3*z_acc_total_t ime*(acc_total_time / total_time)+w4*z_acc_time_span+w5*z_acc_space_span-w6*acc_speed_diff-w7*acc_geo_dist) / Σwi; Where acc_count is the number of collisions; z_acc_count is the standardized value of the number of collisions; traj_count is the number of candidate target trajectories; acc_pos_count is the number of collision points; z_acc_pos_count is the standardized value of the number of collision points; pos_count is the number of candidate target trajectory points; acc_total_time is the total collision time; z_acc_total_time is the normalized value of the total collision time; total_time represents the total time for the trajectory; acc_time_span is the accompanying time span; z_acc_time_span is the standardized value of the accompanying time span; acc_space_span is the accompanying space span; z_acc_space_span is the standardized value of the accompanying space span; acc_speed_diff is the mean of the collision speed differences; z_acc_speed_diff is the standardized value of the mean collision speed difference; acc_geo_dist is the average collision distance; z_acc_geo_dist is the standardized value of the average collision distance.

3. The method for calculating spatiotemporal adjoints according to claim 1, characterized in that, In the collision distance calculation process described in step S4, when there are multiple sensing devices available for the candidate target within the spatial error range of the source trajectory point, the geographical distance between the available sensing device closest to the source trajectory point and the trajectory point of the candidate target is used as the collision distance.

4. The method for calculating spatiotemporal adjoints according to claim 3, characterized in that, When calculating the distance between the location of the nearest available sensing device to the source trajectory point and the location of the trajectory point of the candidate target, the relative distance is estimated using the geographic grid values ​​of the sensing device, the source trajectory point, and the target trajectory point.

5. The method for calculating spatiotemporal adjoints according to claim 1, characterized in that, In step S7, instead of using the weighted average method of empirical values, the associated probability is directly calculated using the logistic regression algorithm.

6. The method for calculating spatiotemporal adjoints according to claim 1, characterized in that, Candidate targets are filtered by setting algorithm hyperparameters based on collision features. The collision features include pos_count, acc_pos_count, acc_speed_diff, and acc_space_span. The algorithm hyperparameters include min_pos_count, min_acc_pos_count, max_acc_speed_diff, and min_acc_space_span. Where pos_count is the number of trajectory points, acc_pos_count is the number of accompanying points, acc_speed_diff is the accompanying speed difference, and acc_space_span is the accompanying space span; min_pos_count is the minimum number of trajectory points, min_acc_pos_count is the minimum number of accompanying points, max_acc_speed_diff is the maximum accompanying speed difference, and min_acc_space_span is the minimum accompanying space span.