A vehicle trajectory processing method and device, electronic equipment and storage medium

By dividing the target jurisdiction into grid points and converting trajectory data into trajectory grid point data, the slow response and downtime issues of distributed databases when retrieving vehicle trajectories are solved, achieving fast and efficient trajectory data retrieval and improved regulatory efficiency.

CN115481170BActive Publication Date: 2026-02-06DIGITAL GUANGDONG NETWORK CONSTR CO LTD
View PDF 3 Cites 0 Cited by

Patent Information

Application Number
CN202211129719.6
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2022-09-16
Publication Date
2026-02-06
Estimated Expiration
2042-09-16

AI Technical Summary

Technical Problem

Existing distributed databases suffer from slow response times or even crashes when retrieving key vehicle trajectory data, especially under high concurrency conditions, which affects regulatory efficiency.

Method used

By dividing the target area into grid points, the trajectory data is converted into trajectory grid point data, and the data is processed to determine whether the vehicle trajectory overlaps with the target area.

Benefits of technology

It enables rapid and efficient retrieval of vehicle trajectory data to determine whether a vehicle has entered a target area, saving storage and processing time and improving regulatory efficiency.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN115481170B_ABST
    Figure CN115481170B_ABST
Patent Text Reader

Abstract

The application discloses a vehicle trajectory processing method and device, electronic equipment and a storage medium, and relates to the technical field of computers. The method comprises the following steps: acquiring trajectory data of a vehicle in a target jurisdiction; performing grid division on the target jurisdiction to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid data based on the grid jurisdiction; performing data processing on the trajectory grid data and grid data of a target region in the target jurisdiction to obtain a processing result; and determining whether the trajectory data of the vehicle overlaps with the target region based on the processing result. The technical scheme provided by the application can save the time for storing and processing the response trajectory data, and can quickly and efficiently search whether the trajectory data of the vehicle has entered the target region.
Need to check novelty before this filing date? Find Prior Art

Description

TECHNICAL FIELD

[0001] The present application relates to the technical field of computers, and in particular to a vehicle trajectory processing method and device, electronic equipment and a storage medium. BACKGROUND

[0002] The transportation department leads the free installation of intelligent video monitoring systems on "two passengers, one dangerous and one heavy cargo" key vehicles, and 24-hour real-time monitoring of the driving behavior of drivers and the running trajectory (vehicle speed, travel data) of vehicles. At present, the storage of these data by the supervision platform is distributed 32 shards of distributed database (Tencent Distributed SQL, TDSQL), each shard 1T, and the data can be stored into TDSQL with difficulty.

[0003] However, when supervising "two passengers, one dangerous and one heavy cargo" key vehicles in the jurisdiction, the distributed TDSQL is under great pressure when searching through license plates (about 8,000 records for each license plate) to check whether the vehicles entering the jurisdiction have passed or stayed in the restricted activity area, and the TDSQL often responds overtime or even crashes, affecting the efficiency of staff investigation and supervision. Therefore, how to quickly and efficiently search whether the trajectory data of the vehicle has entered the restricted activity area has become a problem to be solved. SUMMARY

[0004] The present application provides a vehicle trajectory processing method and device, electronic equipment and a storage medium, which can save storage and processing response trajectory data time, and quickly and efficiently search whether the trajectory data of the vehicle has entered the target area.

[0005] In a first aspect, the present application provides a vehicle trajectory processing method, which comprises:

[0006] Obtaining trajectory data of a vehicle in a target jurisdiction;

[0007] Dividing the target jurisdiction into grid points to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid point data based on the grid jurisdiction;

[0008] Data processing the trajectory grid point data and the grid point data of a target area in the target jurisdiction to obtain a processing result;

[0009] Determining whether the trajectory data of the vehicle overlaps with the target area based on the processing result.

[0010] The embodiment of the present application provides a vehicle trajectory processing method, comprising: obtaining trajectory data of a vehicle in a target jurisdiction; performing grid division on the target jurisdiction to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid point data based on the grid jurisdiction; performing data processing on the trajectory grid point data and grid point data of a target region in the target jurisdiction to obtain a processing result; and determining whether the trajectory data of the vehicle overlaps with the target region based on the processing result. The trajectory data is converted into trajectory grid point data by performing grid division on the target jurisdiction, so that the storage and processing time of the trajectory data can be saved; and the trajectory grid point data and the grid point data of the target region are processed, so that it can be determined whether the trajectory data of the vehicle overlaps with the target region, and the trajectory data of the vehicle can be quickly and efficiently searched.

[0011] Further, the data processing on the trajectory grid point data and the grid point data of the target region in the target jurisdiction to obtain a processing result comprises:

[0012] determining a starting index number of a starting grid point of the trajectory data and an ending index number of an ending grid point of the trajectory data based on the trajectory grid point data;

[0013] determining whether the starting grid point and the ending grid point are in the target region based on the grid point data of the target region, the starting index number and the ending index number, so as to obtain the processing result.

[0014] Further, the determination of whether the starting grid point and the ending grid point are in the target region based on the grid point data of the target region, the starting index number and the ending index number, so as to obtain the processing result, comprises:

[0015] calculating the trajectory grid point data corresponding to the starting index number based on the grid point data of the target region to obtain a calculation result;

[0016] if the calculation result is a first preset value, it is determined that the processing result is that the starting grid point is not in the target region;

[0017] if the calculation result is a second preset value, it is determined that the processing result is that the starting grid point is in the target region;

[0018] correspondingly, the trajectory grid point data corresponding to the ending index number is calculated based on the grid point data of the target region to obtain a calculation result;

[0019] if the calculation result is the first preset value, it is determined that the processing result is that the ending grid point is not in the target region;

[0020] If the calculation result is the second preset value, it is determined that the processing result is that the end grid point is in the target area.

[0021] Further, the determination of whether the trajectory data of the vehicle overlaps with the target area based on the processing result comprises:

[0022] If the processing result is that the start grid point and the end grid point are not in the target area, it is determined that the trajectory data does not overlap with the target area.

[0023] Further, the trajectory data comprises a plurality of trajectory line segments, each trajectory line segment corresponding to a grid; the determination of whether the trajectory data of the vehicle overlaps with the target area based on the processing result comprises:

[0024] If the processing result is that the start grid point and / or the end grid point is in the target area, it is determined that the trajectory data and the target area are in a target grid, and it is determined whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target area;

[0025] If not tangent or not intersecting, it is determined that the trajectory data does not overlap with the target area.

[0026] If tangent or intersecting, the target grid is divided into a plurality of sub-grids, the plurality of sub-grids are taken as new target grids, and the operation of determining whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target area is repeatedly performed until the resolution of the sub-grid reaches a preset requirement, and it is determined that the trajectory data overlaps with the target area.

[0027] Further, the grid jurisdiction comprises a plurality of grids, and the conversion of the trajectory data into trajectory grid point data based on the grid jurisdiction comprises:

[0028] determining a first grid corresponding to the trajectory data;

[0029] clustering trajectory line segments in the same grid to obtain a centroid trajectory point, thereby obtaining a centroid trajectory point of the first grid;

[0030] determining the trajectory grid point data of the vehicle based on the centroid trajectory point of the first grid.

[0031] Further, the obtaining of the trajectory data of the vehicle in the target jurisdiction comprises:

[0032] encoding the driving data of the vehicle to obtain an encoding result;

[0033] The coding result is clustered according to a jurisdiction type to obtain trajectory data of the vehicle in a target jurisdiction.

[0034] In a second aspect, the present application provides a vehicle trajectory processing apparatus, which comprises:

[0035] a trajectory data acquisition module configured to acquire trajectory data of a vehicle in a target jurisdiction;

[0036] a trajectory data conversion module configured to divide the target jurisdiction into grid jurisdictions, and convert the trajectory data into trajectory grid data based on the grid jurisdictions;

[0037] a first data processing module configured to perform data processing on the trajectory grid data and grid data of a target region in the target jurisdiction to obtain a processing result;

[0038] a second data processing module configured to determine whether the trajectory data of the vehicle overlaps with the target region based on the processing result.

[0039] In a third aspect, the present application provides an electronic device, which comprises:

[0040] at least one processor; and

[0041] a memory communicatively connected to the at least one processor; wherein

[0042] the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the vehicle trajectory processing method according to any of the embodiments of the present application.

[0043] In a fourth aspect, the present application provides a computer readable storage medium, which stores computer instructions for enabling a processor to execute the vehicle trajectory processing method according to any of the embodiments of the present application.

[0044] It should be noted that the above computer instructions can be stored on the computer readable storage medium in whole or in part. The computer readable storage medium can be packaged together with the processor of the vehicle trajectory processing apparatus, or can be packaged separately from the processor of the vehicle trajectory processing apparatus, and the present application does not limit the same.

[0045] The second aspect, the third aspect and the fourth aspect of the present application can refer to the detailed description of the first aspect, and the beneficial effects of the second aspect, the third aspect and the fourth aspect can refer to the beneficial effect analysis of the first aspect, which will not be repeated here.

[0046] It should be understood that the content described in this part is not intended to identify key or important features of the embodiments of the present application, nor to limit the scope of the present application. Other features of the present application will become apparent from the following description.

[0047] It can be understood that, before using the technical solutions disclosed in the embodiments of the present application, the type of personal information involved in the present application, the use range and the use scene should be informed to the user and the authorization of the user should be obtained according to relevant laws and regulations. BRIEF DESCRIPTION OF DRAWINGS

[0048] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings needed in the embodiment description will be briefly introduced as follows. Obviously, the drawings in the following description are only some embodiments of the present application, and other drawings can be obtained by those skilled in the art without creative labor on the basis of these drawings.

[0049] Figure 1 The first flowchart of a vehicle trajectory processing method provided by the embodiments of the present application is shown in the figure.

[0050] Figure 2 The second flowchart of a vehicle trajectory processing method provided by the embodiments of the present application is shown in the figure.

[0051] Figure 3 The structure diagram of a vehicle trajectory processing device provided by the embodiments of the present application is shown in the figure.

[0052] Figure 4 The block diagram of an electronic device for implementing a vehicle trajectory processing method according to the embodiments of the present application is shown in the figure. DETAILED DESCRIPTION

[0053] In order to make the purpose, technical solutions and advantages of the embodiments of the present application more clear, the technical solutions in the embodiments of the present application will be described clearly and completely in combination with the drawings in the embodiments of the present application. Obviously, the described embodiments are only some of the embodiments of the present application, not all the embodiments. Based on the embodiments in the present application, all other embodiments obtained by those skilled in the art without creative labor should be within the scope of protection of the present application.

[0054] It should be noted that the terms "first", "second", "target", and "original" and the like in the description and claims of the present application and the above-mentioned drawings are used to distinguish similar objects, and do not necessarily have to be used to describe a specific order or sequence. It should be understood that the data thus used can be interchanged under appropriate circumstances, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein. In addition, the terms "include", "have" and any variations thereof are intended to cover non-exclusive inclusion, for example, a process, method, system, product or device that includes a series of steps or units does not have to be limited to those steps or units clearly listed, but can include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0055] Figure 1 A first flowchart of a vehicle trajectory processing method provided by an embodiment of the present application, the embodiment can be applied to determining whether a vehicle enters a target area based on trajectory data of the vehicle. The target area can be a restricted activity area or a movable area. The vehicle trajectory processing method provided by the embodiment can be executed by a vehicle trajectory processing device provided by the embodiment, which can be implemented in software and / or hardware and integrated in an electronic device that executes the method.

[0056] Referring to Figure 1 The method of the embodiment includes but is not limited to the following steps:

[0057] S110, obtaining trajectory data of a vehicle in a target jurisdiction.

[0058] The target jurisdiction can be a province, city or region, which refers to the jurisdiction where the target area is located. The target area is the area currently determined whether the vehicle enters, that is, the target jurisdiction contains the target area. The trajectory data is the data of the vehicle driving in the same jurisdiction.

[0059] In the embodiment of the present application, the method of obtaining vehicle trajectory data can be to collect driving data of the vehicle by a positioning device, and then classify according to the jurisdiction type to select the trajectory data of the target jurisdiction. The positioning device can be a global positioning system (GPS), Galileo satellite navigation system, Russian GLONASS system or Beidou satellite navigation system, which is not limited in the present application.

[0060] The method of acquiring vehicle trajectory data can also acquire trajectory data of a vehicle in a target jurisdiction from a certain transportation supervision platform. It is necessary to introduce the method of storing trajectory data to a certain transportation supervision platform. Specifically, GPS data of each vehicle connected to the supervision platform is collected every interval of a preset time length (such as five seconds), and then stored in the TDSQL of the supervision platform as a trajectory data of each vehicle in the same jurisdiction (such as Tianhe District, Baiyun District, Yuexiu District). For example, the GPS data of a vehicle in Tianhe District is a trajectory data.

[0061] Preferably, acquiring trajectory data of a vehicle in a target jurisdiction from a certain transportation supervision platform can also include: using a Geography Hash (GeoHash) algorithm to encode the driving data (GPS data) cached in the message middleware to obtain an encoding result; clustering the encoding result according to the jurisdiction type, taking the GPS data in the target jurisdiction after clustering as a trajectory data, and obtaining the trajectory data of the vehicle in the target jurisdiction. Optionally, the trajectory data is a binary bit encoding corresponding to the trajectory data of the vehicle in the target jurisdiction, and each small grid point in the jurisdiction corresponds to a binary bit, such as 1011000000010010100101001. It should be noted that when the acquired trajectory data is a binary bit encoding, the step S120 is included in this step.

[0062] S120, dividing the target jurisdiction into grid points to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid point data based on the grid jurisdiction.

[0063] The grid jurisdiction refers to the jurisdiction after the grid points are divided, and the grid jurisdiction includes a plurality of grids. The trajectory grid point data is a binary bit encoding corresponding to the trajectory data of the vehicle in the target jurisdiction, and each binary number in the binary bit encoding represents a grid.

[0064] In the embodiments of the present application, the starting longitude and latitude and the ending longitude and latitude of the target jurisdiction are acquired, and the target jurisdiction is divided into grid points based on the starting longitude and latitude and the ending longitude and latitude under the GPS global coordinate system (World Geodetic System 1984, WGS84) according to a preset resolution, which is normalized to a plurality of equally divided grids, thereby obtaining the grid jurisdiction. The preset resolution can be 0.01°*0.01°.

[0065] Further, the trajectory data is converted into trajectory grid data based on the grid jurisdiction, including: determining a network passed by the trajectory data as a first grid; clustering (or interpolating) trajectory line segments located in the same grid to obtain a centroid trajectory point, thereby obtaining the centroid trajectory point of the first grid; and determining the trajectory grid data of the vehicle according to the centroid trajectory point of the first grid, specifically: performing two-dimensional tensor coding on the centroid trajectory point, the GPS data of the vehicle in a jurisdiction (such as Tianhe District) is coded by bit (1 bit is 8 bits), the binary code of the first grid can be 1, and the binary code of the remaining grids can be 0, and the trajectory grid data of the vehicle is obtained by sequentially traversing all grids in the grid jurisdiction. Optionally, the clustering algorithm can be a density-based clustering method with noise (Density-Based Spatial Clustering of Applications with Noise, DBSCAN).

[0066] The advantage of such a setting is that the grid division of the jurisdiction can save storage and processing response time, and the clustering (or interpolation) of the trajectory line segments in the grid can speed up the calculation speed of the following step S130.

[0067] S130, performing data processing on the trajectory grid data and the grid data of the target region in the target jurisdiction to obtain a processing result.

[0068] The target region can be a polygonal region, and the target region is included in the target jurisdiction. The target region can be a restricted activity region or a movable region, which is not limited by the present application. The present application only determines whether the vehicle enters the target region. The grid data of the target region is also the binary bit encoding of the target region in the grid jurisdiction. The binary code of the grid corresponding to the target region can be 1, and the binary code of the remaining grids can be 0. The grid data of the target region is obtained by sequentially traversing all grids in the grid jurisdiction.

[0069] Further, the trajectory grid data and the grid data of the target region in the target jurisdiction are processed to obtain a processing result, including: first determining the starting index number of the starting grid of the trajectory data and the ending index number of the ending grid of the trajectory data based on the trajectory grid data, which can improve the operation speed and efficiency of the central processing unit (CPU); and then determining whether the starting grid and the ending grid are in the target region based on the grid data of the target region, the starting index number and the ending index number, thereby obtaining the processing result. This can greatly reduce the problem of sparse calculation and further improve the operation speed and reduce the CPU load.

[0070] Specifically, the starting grid point and the ending grid point are determined based on the grid point data of the target region, the starting index number and the ending index number, so as to obtain a processing result, including: calculating (such as performing a bitwise AND operation) the trajectory grid point data corresponding to the starting index number based on the grid point data of the target region to obtain a calculation result; if the calculation result is a first preset value, it is determined that the processing result is that the starting grid point is not in the target region; if the calculation result is a second preset value, it is determined that the processing result is that the starting grid point is in the target region; correspondingly, the trajectory grid point data corresponding to the ending index number is calculated (such as performing a bitwise AND operation) based on the grid point data of the target region to obtain a calculation result; if the calculation result is the first preset value, it is determined that the processing result is that the ending grid point is not in the target region; if the calculation result is the second preset value, it is determined that the processing result is that the ending grid point is in the target region. The first preset value is zero, and the second preset value is one.

[0071] In S140, it is determined whether the trajectory data of the vehicle overlaps with the target region based on the processing result.

[0072] In the embodiment of the present application, after the processing result is obtained by performing a bitwise AND operation on the trajectory grid point data and the grid point data of the target region in the above step S130, it is determined whether the trajectory data of the vehicle overlaps with the target region based on the processing result. Specifically, when the processing result is that the starting grid point and the ending grid point are not in the target region, it is determined that the trajectory data does not overlap with the target region, i.e., the vehicle does not enter the target region; if the processing result is that the starting grid point and / or the ending grid point is in the target region, it is determined that the trajectory data overlaps with the target region, i.e., the vehicle enters the target region, and then the relevant staff will manage the driver of the vehicle.

[0073] The technical scheme provided in the embodiment includes: obtaining trajectory data of a vehicle in a target jurisdiction; performing grid point division on the target jurisdiction to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid point data based on the grid jurisdiction; performing data processing on the trajectory grid point data and the grid point data of a target region in the target jurisdiction to obtain a processing result; and determining whether the trajectory data of the vehicle overlaps with the target region based on the processing result. The present application can save storage and processing time of the trajectory data by performing grid point division on the target jurisdiction and then converting the trajectory data into trajectory grid point data; and can quickly and efficiently search whether the trajectory data of the vehicle has entered the target region by performing a bitwise AND operation on the trajectory grid point data and the grid point data of the target region.

[0074] In one application scenario, the license plate number of a vehicle and the identification information of a target jurisdiction are input into a transportation supervision platform, and the trajectory data of the vehicle in the target jurisdiction is output. Then, the trajectory data is converted into trajectory grid point data based on the grid jurisdiction, such as 1011000000010010100101001. The trajectory grid point data is processed by performing a bitwise AND operation with the grid point data of the target region to obtain a processing result. Finally, when the processing result is that the start grid point and the end grid point are not in the target region, it is determined that the trajectory data does not overlap with the target region, that is, the vehicle does not enter the target region; if the processing result is that the start grid point and / or the end grid point is in the target region, it is determined that the trajectory data overlaps with the target region, that is, the vehicle enters the target region. If the vehicle has entered the target region, the relevant staff will manage the driver of the vehicle.

[0075] The vehicle trajectory processing method provided by the embodiment of the application is further described below, Figure 2 The second flowchart of the vehicle trajectory processing method provided by the embodiment of the application is shown in FIG. 2. The embodiment of the application is an optimization based on the above-mentioned embodiment, and the specific optimization is that the embodiment explains in detail the process of determining whether the trajectory data overlaps with the target region (i.e., step S140 of the above-mentioned embodiment). Figure 1

[0076] Referring to Figure 2 , the method of the embodiment includes but is not limited to the following steps:

[0077] S210, if the processing result is that the start grid point and the end grid point are not in the target region, it is determined that the trajectory data does not overlap with the target region.

[0078] In the embodiment of the application, after the bitwise AND operation is performed on the trajectory grid point data and the grid point data of the target region to obtain the processing result, if the processing result is that the start grid point and the end grid point are not in the target region, it means that the processing does not pass through the target region, and the result is returned; otherwise, step S220 is entered.

[0079] S220, if the processing result is that the start grid point and / or the end grid point is in the target region, the target grid in which the trajectory data and the target region are located is determined, and it is determined whether the trajectory line segment in the target grid is tangent to or intersects the boundary of the target region.

[0080] The trajectory data includes a plurality of trajectory line segments, and each trajectory line segment corresponds to a grid.

[0081] ​In the embodiment of the present application, the network through which the trajectory data passes is determined first and taken as the first grid; then the target grid in which the target region is located in the same grid is determined in the first grid, and then it is determined whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target region. If not, step S230 is executed; if so, step S240 is executed.

[0082] The target region can be a polygon region, and steps S210-S220 only determine whether the polygon boundary and the trajectory line segment of the vehicle are in the same grid. Preferably, in order to speed up the positioning of whether the polygon of the target region is in the same grid, the grid can also be abstracted as a centroid grid point.

[0083] S230, if not tangent or not intersecting, it is determined that the trajectory data does not overlap with the target region.

[0084] In the embodiment of the present application, if not tangent or not intersecting, it indicates that the trajectory line segment of the vehicle in the target grid does not tangent to or intersect with the boundary of the target region in the target grid, and it is determined that the trajectory data does not overlap with the target region, that is, the vehicle does not enter the target region.

[0085] S240, if tangent or intersecting, the target grid is divided into a plurality of sub-grids, the plurality of sub-grids are taken as new target grids, the operation of determining whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target region is repeatedly executed until the resolution of the sub-grid reaches a preset requirement, and it is determined that the trajectory data overlaps with the target region.

[0086] In the embodiment of the present application, if tangent or intersecting, the target grid needs to be further divided into grid points, and it is determined whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target region at a more fine resolution. Optionally, the number of sub-grids can be dynamically configured according to the grid point size and the scene size, and preferably the target grid is divided into four sub-grids.

[0087] The grid point division of the grid jurisdiction in the step S120 is divided according to a specific resolution. In order to further accurately determine whether the grid inside is intersected or cut by the polygon and the trajectory line segment, the target grid needs to be further segmented as a parent grid. For example, if the segmentation is four sub-grids, and the resolution of the target grid is 1 km, the resolution of the grid after segmentation is 250 m. If the polygon boundary of the target area and the trajectory line segment are still tangent or intersected, the segmentation is continued to four sub-grids, and the resolution of the grid after the second segmentation is 250 / 4 m. The same is true until the current resolution is less than or equal to 10 m, and the segmentation is stopped. If the polygon boundary of the target area and the trajectory line segment are not tangent or intersected under the current resolution, it is determined that the trajectory data and the target area have no overlap. If the polygon boundary of the target area and the trajectory line segment are still tangent or intersected, it is determined that the trajectory data and the target area have overlap.

[0088] The technical scheme provided by the embodiment determines that the trajectory data and the target area have no overlap if the processing result is that the start grid point and the end grid point are not in the target area. The trajectory data and the target area are located in the same target grid if the processing result is that the start grid point and / or the end grid point are in the target area, and it is determined whether the trajectory line segment is tangent or intersected with the boundary of the target area in the target grid. If the trajectory line segment is not tangent or intersected with the boundary of the target area, it is determined that the trajectory data and the target area have no overlap. If the trajectory line segment is tangent or intersected with the boundary of the target area, the target grid is segmented into a plurality of sub-grids, the plurality of sub-grids are taken as new target grids, the operation of determining whether the trajectory line segment is tangent or intersected with the boundary of the target area in the target grid is repeatedly performed, and the resolution of the sub-grid reaches the preset requirement, and it is determined that the trajectory data and the target area have overlap. The application can save the storage and the processing time of the response trajectory data, and can quickly and efficiently search whether the trajectory data of the vehicle enters the target area.

[0089] Figure 3 The structure diagram of the vehicle trajectory processing device provided by the embodiment of the application is shown in FIG. 3. Figure 3 As shown in FIG. 3, the device 300 can include:

[0090] The trajectory data acquisition module 310 is configured to acquire the trajectory data of the vehicle in the target jurisdiction.

[0091] The trajectory data conversion module 320 is configured to divide the target jurisdiction into grid points to obtain a grid jurisdiction, and convert the trajectory data into trajectory grid point data based on the grid jurisdiction.

[0092] The first data processing module 330 is configured to perform data processing on the trajectory grid point data and the grid point data of the target area in the target jurisdiction to obtain a processing result.

[0093] The second data processing module 340 is configured to determine whether the trajectory data of the vehicle overlaps with the target region based on the processing result.

[0094] Further, the first data processing module 330 can be specifically configured to determine a start index number of a start grid point of the trajectory data and an end index number of an end grid point of the trajectory data based on the grid point data of the trajectory; and determine whether the start grid point and the end grid point are in the target region based on the grid point data of the target region, the start index number and the end index number, so as to obtain the processing result.

[0095] Further, the first data processing module 330 can be specifically configured to: calculate the trajectory grid point data corresponding to the start index number based on the grid point data of the target region to obtain a calculation result; if the calculation result is a first preset value, determine that the processing result is that the start grid point is not in the target region; if the calculation result is a second preset value, determine that the processing result is that the start grid point is in the target region; and correspondingly, calculate the trajectory grid point data corresponding to the end index number based on the grid point data of the target region to obtain a calculation result; if the calculation result is the first preset value, determine that the processing result is that the end grid point is not in the target region; if the calculation result is the second preset value, determine that the processing result is that the end grid point is in the target region.

[0096] Further, the second data processing module 340 can be specifically configured to: if the processing result is that the start grid point and the end grid point are not in the target region, determine that the trajectory data does not overlap with the target region.

[0097] Optionally, the trajectory data includes a plurality of trajectory line segments, and each trajectory line segment corresponds to a grid.

[0098] Further, the first data processing module 330 can be specifically configured to: if the processing result is that the start grid point and / or the end grid point are in the target region, determine a target grid in which the trajectory data and the target region are located, and determine whether the trajectory line segment is tangent to or intersects with the boundary of the target region in the target grid; if not tangent or not intersect, determine that the trajectory data does not overlap with the target region; if tangent or intersect, divide the target grid into a plurality of sub-grids, take the plurality of sub-grids as new target grids, and repeatedly perform the operation of determining whether the trajectory line segment is tangent to or intersects with the boundary of the target region in the target grid until the resolution of the sub-grid reaches a preset requirement, and determine that the trajectory data overlaps with the target region.

[0099] Optionally, the grid jurisdiction includes a plurality of grids.

[0100] Further, the trajectory data conversion module 320 can be specifically configured to: determine a first grid corresponding to the trajectory data; cluster trajectory line segments located in the same grid to obtain a centroid trajectory point, thereby obtaining a centroid trajectory point of the first grid; and determine the trajectory grid point data of the vehicle based on the centroid trajectory point of the first grid.

[0101] Further, the trajectory data acquisition module 310 can be specifically configured to: encode the driving data of the vehicle to obtain an encoding result; and cluster the encoding result according to jurisdiction types to obtain the trajectory data of the vehicle in the target jurisdiction.

[0102] The vehicle trajectory processing apparatus provided in the embodiment can be applied to the vehicle trajectory processing method provided in any of the above embodiments, and has corresponding functions and advantages.

[0103] Figure 4 is a block diagram of an electronic device for implementing a vehicle trajectory processing method according to an embodiment of the present application. The electronic device 10 is intended to represent various forms of digital computers, such as laptops, desktops, tablets, personal digital assistants, servers, blade servers, mainframes, and other appropriate computers. The electronic device can also represent various forms of mobile devices, such as personal digital processors, cellular telephones, smart phones, wearable devices (such as headsets, glasses, watches, etc.), and other similar computing devices. The components shown here, their connections and relationships, and their functions, are meant to be examples only, and are not intended to limit the implementations of the present application described and / or claimed in this document.

[0104] As shown in Figure 4 The electronic device 10 includes at least one processor 11 and a memory, such as a read-only memory (ROM) 12, a random access memory (RAM) 13, etc., which are communicatively connected to the at least one processor 11. The memory stores a computer program that can be executed by the at least one processor. The processor 11 can perform various appropriate actions and processes according to the computer program stored in the read-only memory (ROM) 12 or loaded from the storage unit 18 into the random access memory (RAM) 13. In the RAM 13, various programs and data required for the operation of the electronic device 10 can also be stored. The processor 11, the ROM 12, and the RAM 13 are connected to each other through a bus 14. An input / output (I / O) interface 15 is also connected to the bus 14.

[0105] A plurality of components in the electronic device 10 are connected to the I / O interface 15, including: an input unit 16, such as a keyboard, a mouse, etc.; an output unit 17, such as various types of displays, speakers, etc.; a storage unit 18, such as a magnetic disk, an optical disk, etc.; and a communication unit 19, such as a network card, a modem, a wireless communication transceiver, etc. The communication unit 19 allows the electronic device 10 to exchange information / data with other devices through a computer network, such as the Internet, and / or various telecommunication networks.

[0106] The processor 11 can be various general and / or special purpose processing components with processing and computing capabilities. Some examples of the processor 11 include, but are not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various special-purpose artificial intelligence (AI) computing chips, various processors running machine learning model algorithms, a digital signal processor (DSP), and any appropriate processor, controller, microcontroller, etc. The processor 11 performs various methods and processes described above, such as the processing method of vehicle trajectories.

[0107] In some embodiments, the processing method of vehicle trajectories can be implemented as a computer program tangibly embodied in a computer readable storage medium, such as the storage unit 18. In some embodiments, part or all of the computer program can be loaded and / or installed onto the electronic device 10 via the ROM 12 and / or the communication unit 19. When the computer program is loaded onto the RAM 13 and executed by the processor 11, one or more steps of the processing method of vehicle trajectories described above can be performed. Alternatively, in other embodiments, the processor 11 can be configured to perform the processing method of vehicle trajectories by any other appropriate means, such as by means of firmware.

[0108] Various implementations of the systems and techniques described above can be realized in digital electronic circuitry, integrated circuitry, a field programmable gate array (FPGA), an application specific integrated circuit (ASIC), a system on a chip (SOC), a programmable logic device (PLD), a computer hardware, firmware, software, and / or combinations thereof. These various implementations can include implementation in one or more computer programs that are executable and / or interpretable on a programmable system including at least one programmable processor, which can be special or general purpose, coupled to receive data and instructions from, and to transmit data and instructions to, a storage system, at least one input device, and at least one output device.

[0109] Computer programs used to practice the methods of the application can be written in any combination of one or more programming languages. These computer programs can be implemented on general-purpose computers, special purpose computers, or other programmable data processing apparatus to produce the functions / acts specified in the flow diagrams and / or block diagrams. Computer programs can be applied to a data changed on the functioning of the computer or processing apparatus by transforming the programming language into a machine language.

[0110] In the context of the present application, a computer-readable storage medium can be a tangible medium that can contain or store computer programs for use by or in connection with an instruction execution system, apparatus, or device. Computer-readable storage media can include, but are not limited to, electronic, magnetic, optical, electromagnetic, infrared, or semiconductor systems, apparatus, or devices, or any suitable combination of the foregoing. Alternatively, a computer-readable storage medium can be a machine-readable signal medium. More specific examples of a machine-readable storage medium will include one or more lines of electrical connections, portable computer disks, hard disk drives, random access memory (RAM), read-only memory (ROM), erasable programmable read-only memory (EPROM or Flash memory), optical fibers, portable compact disc read-only memories (CD-ROMs), optical storage devices, magnetic storage devices, or any suitable combination of the foregoing.

[0111] To provide for interaction with a user, the systems and techniques described here can be implemented on an electronic device having a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to the user and a keyboard and a pointing device (e.g., a mouse or a trackball) by which the user can provide input to the electronic device. Other kinds of devices can be used to provide for interaction with a user as well; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user can be received in any form, including acoustic, speech, or tactile input.

[0112] The systems and techniques described herein can be implemented in a computing system that includes a back end component, e.g., as a data server, or that includes a middleware component, e.g., an application server, or that includes a front end component, e.g., a user computer having a graphical user interface or a Web browser through which a user can interact with an implementation of the systems and techniques described herein, or any combination of such back end, middleware, or front end components. The components of the system can be interconnected by any form or medium of digital data communication, e.g., a communication network. Examples of communication networks include a local area network (LAN), a wide area network (WAN), a blockchain network, and the Internet.

[0113] The computing system can include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other. A server can be a cloud server, also known as a cloud computing server or cloud host, which is a host product in the cloud computing service system, and solves the defects of large management difficulty and weak business scalability in traditional physical host and VPS service.

[0114] It should be understood that the various forms of flow shown above can be re-ordered, added to, or deleted from without departing from the scope of the present disclosure. For example, the steps recited in the present disclosure can be executed in parallel, executed in sequence, or executed in different orders, as long as the desired results of the technical solutions of the present disclosure can be achieved, and the present disclosure is not limited herein.

[0115] The specific implementation described above does not constitute a limitation on the scope of protection of the present application. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present application shall be included in the scope of protection of the present application.

Claims

1. A method of processing a vehicle trajectory, characterized by, The method comprises: acquiring trajectory data of a vehicle in a target jurisdiction, the target jurisdiction being a jurisdiction in which a target area is located, the trajectory data being data of the vehicle driving in the same jurisdiction; dividing the target jurisdiction into grid cells to obtain grid jurisdiction, and converting the trajectory data into trajectory grid data based on the grid jurisdiction, the trajectory grid data being binary bit encoding corresponding to the trajectory data of the vehicle in the target jurisdiction; performing data processing on the trajectory grid data and grid data of the target area in the target jurisdiction to obtain a processing result, the grid data of the target area being binary bit encoding corresponding to the target area in the grid jurisdiction; determining whether the trajectory data of the vehicle overlaps with the target area based on the processing result; wherein the data processing on the trajectory grid data and the grid data of the target area in the target jurisdiction to obtain the processing result comprises: determining a starting index number of a starting grid cell of the trajectory data and an ending index number of an ending grid cell of the trajectory data based on the trajectory grid data; determining whether the starting grid cell and the ending grid cell are in the target area based on the grid data of the target area, the starting index number and the ending index number, thereby obtaining the processing result; the trajectory data comprises a plurality of trajectory line segments, each trajectory line segment corresponding to a grid; the determination of whether the trajectory data of the vehicle overlaps with the target area based on the processing result comprises: if the processing result is that the starting grid cell and / or the ending grid cell is in the target area, determining that the trajectory data and the target area are located in a target grid of the same grid, and determining whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target area; if not tangent or intersecting, determining that the trajectory data does not overlap with the target area; if tangent or intersecting, dividing the target grid into a plurality of sub-grids, taking the plurality of sub-grids as new target grids, and repeatedly performing the operation of determining whether the trajectory line segment in the target grid is tangent to or intersects with the boundary of the target area until the resolution of the sub-grids reaches a preset requirement, and determining that the trajectory data overlaps with the target area.

2. The method of claim 1, wherein, the determination of whether the starting grid cell and the ending grid cell are in the target area based on the grid data of the target area, the starting index number and the ending index number, thereby obtaining the processing result, comprises: calculating the trajectory grid data corresponding to the starting index number based on the grid data of the target area to obtain a calculation result; if the calculation result is a first preset value, determining that the processing result is that the starting grid cell is not in the target area; if the calculation result is a second preset value, determining that the processing result is that the starting grid cell is in the target area; correspondingly, calculating the trajectory grid data corresponding to the ending index number based on the grid data of the target area to obtain a calculation result; if the calculation result is the first preset value, determining that the processing result is that the ending grid cell is not in the target area; If the calculation result is the second preset value, it is determined that the processing result is that the end grid point is in the target region.

3. The method of claim 1, wherein, The determination of whether the trajectory data of the vehicle overlaps with the target region based on the processing result comprises: If the processing result is that the start grid point and the end grid point are not in the target region, it is determined that the trajectory data does not overlap with the target region.

4. The method of claim 1, wherein, The grid jurisdiction comprises a plurality of grids, and the conversion of the trajectory data into trajectory grid point data based on the grid jurisdiction comprises: determining a first grid corresponding to the trajectory data; clustering trajectory line segments located in the same grid to obtain a centroid trajectory point, thereby obtaining a centroid trajectory point of the first grid; determining the trajectory grid point data of the vehicle based on the centroid trajectory point of the first grid.

5. The method of claim 1, wherein, The acquisition of the trajectory data of the vehicle in the target jurisdiction comprises: encoding the driving data of the vehicle to obtain an encoding result; clustering the encoding result according to the jurisdiction type to obtain the trajectory data of the vehicle in the target jurisdiction.

6. A processing device of a vehicle trajectory, characterized by, The device comprises: a trajectory data acquisition module for acquiring trajectory data of a vehicle in a target jurisdiction, the target jurisdiction being a jurisdiction in which a target region is located, and the trajectory data being data of the vehicle driving in the same jurisdiction; a trajectory data conversion module for dividing the target jurisdiction into grid points to obtain a grid jurisdiction, and converting the trajectory data into trajectory grid point data based on the grid jurisdiction, the trajectory grid point data being binary bit encoding corresponding to the trajectory data of the vehicle in the target jurisdiction; a first data processing module for performing data processing on the trajectory grid point data and grid point data of a target region in the target jurisdiction to obtain a processing result, the grid point data of the target region being binary bit encoding corresponding to the target region in the grid jurisdiction; a second data processing module for determining whether the trajectory data of the vehicle overlaps with the target region based on the processing result; The first data processing module is specifically configured to determine a start index number of a start grid point of the trajectory data and an end index number of an end grid point of the trajectory data based on the trajectory grid point data; determine whether the start grid point and the end grid point are in the target region based on the grid point data of the target region, the start index number and the end index number, thereby obtaining the processing result. The trajectory data includes a plurality of trajectory line segments, each trajectory line segment corresponding to a grid; the first data processing module is further configured to, if the processing result is that the start grid point and / or the end grid point is in the target region, determine a target grid in which the trajectory data and the target region are located in the same grid, and determine whether the trajectory line segment is tangent to or intersects with a boundary of the target region in the target grid; if not tangent or not intersect, determine that the trajectory data does not overlap with the target region; if tangent or intersect, divide the target grid into a plurality of sub-grids, take the plurality of sub-grids as new target grids, and repeatedly perform the operation of determining whether the trajectory line segment is tangent to or intersects with the boundary of the target region in the target grid until the resolution of the sub-grids reaches a preset requirement, and determine that the trajectory data overlaps with the target region.

7. An electronic device, comprising: The electronic device includes: at least one processor; and a memory connected to the at least one processor in communication; wherein the memory stores a computer program executable by the at least one processor, and the computer program is executed by the at least one processor to enable the at least one processor to execute the vehicle trajectory processing method of any one of claims 1 to 5.

8. A computer-readable storage medium, characterized in that, The computer readable storage medium stores computer instructions for causing the processor to execute the vehicle trajectory processing method of any one of claims 1 to 5 when executed.

Citation Information

Patent Citations

  • Lane detection method and device and computer readable storage medium

    CN113516105A

  • Vehicle track processing method and device, computer device and storage medium

    CN113990105A

  • Parking space management and control method, device and equipment and storage medium

    CN114581465A