Vehicle track generation method and device and electronic equipment
By identifying and screening stop points in the GPS positioning system, the problem of misjudgment by the GPS positioning system when the vehicle is parked is solved, the accuracy of the driving trajectory is improved, and the accuracy of the trajectory points is ensured.
Patent Information
- Application Number
- CN202311861527.9
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2023-12-29
- Publication Date
- 2024-10-18
AI Technical Summary
When the GPS positioning system is interfered by the external environment or the signal is weak, it is difficult to accurately collect the parking status of the vehicle, resulting in errors in driving trajectory confirmation and affecting the accuracy of the trajectory.
By identifying stationary trajectory points from the vehicle's driving data as stay points, filtering and deleting stay points that affect the confirmed trajectory, a more accurate driving trajectory is generated. The specific method includes determining the stay points based on the distance and time interval of the track points, filtering out the stay points that meet the preset conditions, and generating a driving trajectory based on the target track points.
It improves the accuracy of the driving trajectory, reduces misjudgments caused by drift of GPS position information, and ensures the accuracy of the vehicle's trajectory points when it is stationary or driving.
Smart Images

Figure CN118795505A_ABST
Abstract
Description
Technical Field
[0001] The present application belongs to the field of computers, and in particular to a vehicle trajectory generation method, device, and electronic device. Background Art
[0002] With the continuous development of Global Positioning System (GPS) technology, vehicle-mounted GPS technology has played a great role in applications such as vehicle tracking, itinerary planning, vehicle navigation, and vehicle dispatching.
[0003] In the prior art, the electronic equipment of the GPS positioning system collects the location information of the vehicle during driving and the collection time according to a preset frequency to confirm the driving track of the vehicle.
[0004] However, when there is interference in the external environment or the transmission signal is weak, there may be a certain error between the collected GPS location information and the actual location of the vehicle. That is, when the vehicle is parked, the collected GPS location information drifts, causing the GPS positioning system to misjudge that the vehicle is traveling at a low speed in an area, affecting the accuracy of the confirmed driving trajectory. Summary of the invention
[0005] The embodiments of the present application provide a vehicle trajectory generation method, device and electronic device, which achieve the purpose of improving the accuracy of confirming the driving trajectory.
[0006] In a first aspect, an embodiment of the present application provides a vehicle trajectory generation method, the method comprising:
[0007] Acquire driving data of the vehicle, wherein the driving data includes N trajectory points, where N is a positive integer;
[0008] Selecting at least one stop point that satisfies a preset track stop condition from the N track points of the driving data, wherein the preset track stop condition refers to a track point generated when the vehicle is in a stationary state;
[0009] At least one target trajectory point other than the at least one stop point is acquired from the N trajectory points, and a driving trajectory is generated according to data of the at least one target trajectory point.
[0010] It can be seen from the above embodiments that the present application improves the accuracy of the generated driving trajectory by identifying trajectory points that can confirm that the vehicle is in a stationary state as stop points and deleting the stop points that affect the confirmed trajectory during the journey.
[0011] In a possible implementation manner of the first aspect, the selecting at least one stop point that satisfies a preset track stop condition from the N track points of the driving data includes:
[0012] Obtaining the driving positions and driving times of N trajectory points from the driving data;
[0013] Determine at least one stop point set according to the driving positions and driving times of the N trajectory points, wherein each stop point set includes at least two stop points, and the distance between the first stop point and the last stop point in each stop point set is less than a preset distance, and the time interval between the first stop point and the last stop point is greater than a preset time period;
[0014] The trajectory points in each of the stop point sets are used as stop points.
[0015] It should be understood that when the location information uploaded by the positioning device drifts within a certain range, the accuracy of the calculated driving trajectory is improved by screening out the stop points based on the distance and time between the collection points and deleting the stop points that affect the confirmed trajectory during the trip.
[0016] In a possible implementation manner of the first aspect, after determining at least one set of stay points according to the driving positions and driving times of the N trajectory points, the method further includes:
[0017] For each set of stay points, if the last trajectory point P in the set of stay points n The position of the next trajectory point P n+1 The distance between them is greater than the preset driving distance, according to the driving time of the first trajectory point P1 in the set of stop points and P n+1 The driving time is determined by the driving time, and the driving time interval is determined according to P1 and P n+1 The predicted average driving speed is determined based on the distance between the two vehicles and the driving time interval, wherein n is a positive integer greater than 1 and less than or equal to N;
[0018] If the predicted average driving speed is greater than or equal to the preset driving speed, the trajectory point in the set of stop points is determined to be a driving trajectory point.
[0019] It should be understood that when a vehicle is traveling in a tunnel, the uploaded location information is always the location information at the beginning of the tunnel entry. When the vehicle exits the tunnel, new location information is uploaded, which will cause the location uploaded just before the vehicle exits the tunnel to be very far from the location uploaded just after the vehicle exits the tunnel. This does not conform to the vehicle's driving rules. Therefore, it is necessary to screen out the vehicle's driving trajectory in the tunnel to avoid excessive error between the calculated driving trajectory and the vehicle's actual driving range.
[0020] In a possible implementation manner of the first aspect, after selecting at least one stop point satisfying a preset track stop condition from the N track points of the driving data, the method further includes:
[0021] Obtaining the driving speeds of N trajectory points from the driving data;
[0022] For each stay point set, if the ratio of the number of trajectory points with a driving speed of zero in the stay point set to the number of all trajectory points included in the stay point set is greater than a first preset percentage, a new stay point set is generated according to the trajectory points with a driving speed of zero in the stay point set;
[0023] For each stay point set, if the ratio of the number of trajectory points in the stay point set whose driving speed is greater than zero to the number of all trajectory points included in the stay point set is greater than a second preset percentage, a new stay point set is generated based on all trajectory points except the 1st trajectory point to the Xth trajectory point and the Xth to last trajectory point, where X is a positive integer greater than 1 and less than or equal to N.
[0024] It should be understood that the trajectory points collected during the parking process may be mistakenly taken as stop points. Therefore, the parking journey of the vehicle is screened out from the stop point set according to the vehicle's driving speed, thereby improving the accuracy of the calculated driving trajectory.
[0025] In a possible implementation manner of the first aspect, after generating a driving trajectory according to the data of the at least one target trajectory point, the method further includes:
[0026] Determine the driving time interval between every two adjacent trajectory points, and use the driving time interval that is greater than or equal to the preset time period as the split time period;
[0027] Segmenting the driving trajectory according to all the segmented time periods to obtain at least one trajectory segment;
[0028] If the number of trajectory points included in the trajectory segment is less than a preset parameter, the trajectory segment is deleted from the driving trajectory, and a driving trajectory is generated according to all remaining trajectory segments.
[0029] It should be understood that after deleting the stop points in the trajectory points, the remaining trajectory points are all position points where the vehicle is in a driving state, and there is no parking state. Therefore, when the number of positions moved by the vehicle in a certain trajectory segment is lower than the normal number of driving position points, it can be assumed that the current trajectory segment may also be the trajectory segment corresponding to the stop point, and it needs to be deleted from the driving data to improve the accuracy of the confirmed driving trajectory.
[0030] In a possible implementation manner of the first aspect, before selecting at least one stop point satisfying a preset track stop condition from the N track points of the driving data, the method further includes:
[0031] Obtaining the number of positioning satellites and the driving speed of N trajectory points from the driving data;
[0032] If the travel speed of the trajectory point is greater than the preset maximum speed, the trajectory point is regarded as an invalid trajectory point; or, if the travel speed of the trajectory point is less than the preset minimum speed and the number of positioning satellites of the trajectory point is less than the preset number, the trajectory point is regarded as an invalid trajectory point;
[0033] At least one invalid track point is deleted from the driving data.
[0034] In a possible implementation manner of the first aspect, after deleting at least one invalid trajectory point from the driving data, the method further includes:
[0035] For each trajectory point P i , select the trajectory point P i All the corresponding adjacent trajectory points, including P i-2 , P i-1 , P i+1 and P i+2 , where i is a positive integer greater than 2 and less than N-2;
[0036] For P i For each adjacent trajectory point, determine P i The adjacent distance and the adjacent time interval between the adjacent trajectory points, and determine P according to the adjacent distance and the adjacent time interval i The adjacent speeds between the adjacent trajectory points;
[0037] When the trajectory point P i-2 and P i-1 When all are normal trajectory points, if P i If the adjacent speed between each adjacent trajectory point is less than the preset maximum speed, then P i is a normal trajectory point, otherwise it is determined that P i is an abnormal trajectory point;
[0038] P i+1 and P i+2 As a tentative trajectory point Px, for each tentative trajectory point, when P i With P i-2 Between and P i With P i-2 When the adjacent speeds between are all less than the preset maximum speed, if P iThe adjacent average speed between Px and Px is greater than the preset maximum speed, then it is determined that P i P i It is a suspected abnormal trajectory point;
[0039] All adjacent trajectory points of Px are selected. When Px is determined to be a normal trajectory point based on all adjacent trajectory points of Px, the suspected abnormal trajectory point P i When Px is determined to be a normal trajectory point, the suspected abnormal trajectory point P i When Px is determined to be a suspected abnormal trajectory point, the suspected abnormal trajectory point P i Determined as an abnormal trajectory point.
[0040] In a possible implementation manner of the first aspect, after generating a driving trajectory according to the data of the at least one target trajectory point, the method further includes:
[0041] Storing the generated driving trajectory in a database according to a preset frequency;
[0042] Accepting a query instruction sent by the application terminal, and acquiring a corresponding driving trajectory from the database according to the query instruction;
[0043] The driving trajectory is sent to the application terminal.
[0044] In a second aspect, an embodiment of the present application provides a vehicle trajectory generation device, the device comprising:
[0045] An acquisition module, used to acquire driving data of a vehicle, wherein the driving data includes N trajectory points, wherein N is a positive integer;
[0046] A selection module, configured to select at least one stop point satisfying a preset track stop condition from the N track points of the driving data, wherein the preset track stop condition refers to a track point generated when the vehicle is in a stationary state;
[0047] A generating module is used to obtain at least one target trajectory point other than the at least one stop point from the N trajectory points, and generate a driving trajectory according to data of the at least one target trajectory point.
[0048] In a third aspect, an embodiment of the present application provides an electronic device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the vehicle trajectory generation method as described in any one of the first aspects is implemented.
[0049] It can be understood that the beneficial effects of the second to third aspects mentioned above can be found in the relevant description of the first aspect mentioned above, and will not be repeated here.
[0050] Compared with the prior art, the embodiments of the present application have the following beneficial effects: by selecting at least one stop point that meets the preset trajectory stop condition from the N trajectory points of the vehicle's driving data, and obtaining at least one target trajectory point other than the at least one stop point from the N trajectory points, and finally generating a driving trajectory based on the data of the at least one target trajectory point, the purpose of improving the accuracy of the generated driving trajectory is achieved. BRIEF DESCRIPTION OF THE DRAWINGS
[0051] In order to more clearly illustrate the technical solutions in the embodiments of the present application, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative labor.
[0052] Figure 1 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 1 ;
[0053] Figure 2 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 2 ;
[0054] Figure 3 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 3 ;
[0055] Figure 4 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 4 ;
[0056] Figure 5 is a structural block diagram of a vehicle trajectory generating device provided in an embodiment of the present application;
[0057] Figure 6 It is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0058] In the following description, specific details such as specific system structures, technologies, etc. are provided for the purpose of illustration rather than limitation, so as to provide a thorough understanding of the embodiments of the present application. However, it should be clear to those skilled in the art that the present application may also be implemented in other embodiments without these specific details. In other cases, detailed descriptions of well-known systems, devices, circuits, and methods are omitted to prevent unnecessary details from obstructing the description of the present application.
[0059] It should be understood that when used in the present specification and the appended claims, the term "comprising" indicates the presence of described features, wholes, steps, operations, elements and / or components, but does not exclude the presence or addition of one or more other features, wholes, steps, operations, elements, components and / or combinations thereof.
[0060] It should also be understood that the term “and / or” used in the specification and appended claims refers to any and all possible combinations of one or more of the associated listed items, and includes these combinations.
[0061] As used in the specification and appended claims of this application, the term "if" can be interpreted as "when" or "uponce" or "in response to determining" or "in response to detecting", depending on the context. Similarly, the phrase "if it is determined" or "if [described condition or event] is detected" can be interpreted as meaning "uponce it is determined" or "in response to determining" or "uponce [described condition or event] is detected" or "in response to detecting [described condition or event]", depending on the context.
[0062] In addition, in the description of the present application specification and the appended claims, the terms "first", "second", "third", etc. are only used to distinguish the descriptions and cannot be understood as indicating or implying relative importance.
[0063] References to "one embodiment" or "some embodiments" etc. described in the specification of this application mean that one or more embodiments of the present application include specific features, structures or characteristics described in conjunction with the embodiment. Therefore, the phrases "in one embodiment", "in some embodiments", "in some other embodiments", "in some other embodiments", etc. appearing in different places in this specification do not necessarily refer to the same embodiment, but mean "one or more but not all embodiments", unless otherwise specifically emphasized in other ways.
[0064] Figure 1 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 1 As an example but not a limitation, the execution subject of this embodiment is an electronic device of a GPS positioning system, and this embodiment is not particularly limited here.
[0065] S101: Acquire driving data of a vehicle, where the driving data includes N trajectory points, where N is a positive integer.
[0066] Exemplarily, the vehicle-mounted positioning terminal sends GPS information to the GPS positioning system at preset time intervals, including data such as vehicle travel speed, travel time, and location information.
[0067] It should be understood that the transmission process of GPS information is affected by environmental interference and there is a situation of delayed transmission. Therefore, after the GPS positioning system collects the GPS information of the vehicle, it sorts the collected driving data in chronological order to obtain N track points.
[0068] Exemplarily, in order to improve the accuracy of the generated driving trajectory, the data of the trajectory points can be screened to remove abnormal data. Specifically, the number of positioning satellites and the driving speed of N trajectory points are obtained from the driving data. If the driving speed of the trajectory point is greater than the preset maximum speed, the trajectory point is regarded as an invalid trajectory point; or, if the driving speed of the trajectory point is less than the preset minimum speed and the number of positioning satellites of the trajectory point is less than the preset number, the trajectory point is regarded as an invalid trajectory point, and at least one invalid trajectory point is deleted from the driving data.
[0069] It should be understood that, on the one hand, when the speed of a trajectory point is greater than the preset maximum speed, the vehicle's speed does not meet the driving characteristics, and the trajectory point is determined to be an invalid trajectory point; on the other hand, when the speed of a trajectory point is less than the preset minimum speed, it means that the vehicle is traveling slowly at this time, and when the number of positioning satellites at the trajectory point is less than the preset number, it means that the signal is weak when the trajectory point data is collected, and there is a high possibility that the data has deviations, and the current trajectory point is determined to be an invalid trajectory point. By filtering out invalid trajectory points from driving data, the amount of calculation can be reduced, and the accuracy of the generated driving trajectory can also be improved.
[0070] S102: selecting at least one stop point satisfying a preset track stop condition from the N track points of the driving data, where the preset track stop condition refers to a track point generated when the vehicle is in a stationary state.
[0071] In an embodiment of the present invention, N trajectory points are screened according to the set trajectory stop conditions, and the trajectory points where the vehicle is stationary among the N trajectory points are screened out as stop points. It should be understood that, ideally, when the vehicle is stationary, the driving speed of the corresponding trajectory point is zero, and the position information does not change for a period of time. However, due to the instability of GPS signal transmission, the uploaded GPS position information drifts, and there is a situation where the vehicle is stationary but the position information of the trajectory point is always changing and the vehicle speed is not zero. Exemplarily, on the one hand, when the driving speed corresponding to the trajectory point can be set to zero, the vehicle is stationary and the current trajectory point is selected as the stop point; on the other hand, when multiple trajectory points are always in a small area for a short period of time, that is, the GPS position information uploaded by the vehicle drifts, it can be confirmed that the vehicle is stationary, and the corresponding multiple trajectory points are also stop points.
[0072] Exemplarily, the specific process of selecting at least one stop point that meets the preset trajectory stop condition from N trajectory points in the driving data is: obtaining the driving position and driving time of the N trajectory points from the driving data; determining at least one stop point set according to the driving position and driving time of the N trajectory points, wherein each stop point set includes at least two stop points, and the distance between the first stop point and the last stop point in each stop point set is less than the preset distance, and the time interval between the first stop point and the last stop point is greater than the preset time period; and taking the trajectory points in each stop point set as stop points.
[0073] Specifically, the N trajectory points are P1, P2 to P N The preset conditions are set as follows: the difference in travel time between the initial point and the target point is greater than the preset time difference, and the distance between the initial point and the target point is greater than the preset distance. First, take P1 as the initial point and determine whether there is a target point P according to the preset conditions. M , then according to the target point P M Determine the set of stop points as P1, P2 to P M , if the target point P that meets the preset conditions is not screened out M , then take the trajectory point P2 as the initial point, and repeat the process of judging whether there is a target point according to the preset conditions until it is determined that there is a target point P M ; Secondly, after obtaining the set of stop points P1, P2 to P M Afterwards, P M+1 As the new initial point, the process of determining the new target point and the new set of stay points according to the preset conditions is repeated until the last track point in the N track points is selected. At this time, in each stay set, the time interval and distance between each two stay points meet the preset conditions.
[0074] S103: Acquire at least one target trajectory point other than at least one stop point from the N trajectory points, and generate a driving trajectory according to data of the at least one target trajectory point.
[0075] In the embodiment of the present application, after all the stay points are screened out, all the stay points are deleted from the N track points, and the remaining track points are used as target track points. It should be understood that the target track points are the driving points corresponding to the vehicle being in a normal driving state, and the target track points do not include the driving points corresponding to the vehicle being misjudged to be driving due to the drift of the uploaded GPS position information.
[0076] Exemplarily, the generated driving trajectory is stored in the database according to the preset frequency; the query instruction sent by the application terminal is received, and the corresponding driving trajectory is obtained from the database according to the query instruction; the driving trajectory is sent to the application terminal. Specifically, after the driving trajectory is generated, the GPS positioning system stores the generated driving trajectory in the database according to the set transmission frequency. It should be understood that the driving trajectory stored in the database will not be changed. Among them, the set transmission frequency can be uploaded once a day. Specifically, the GPS positioning system collects the driving information of the vehicle-mounted GPS terminal at a time interval of 15 seconds, calculates all the collected driving information every 24 hours and generates the driving trajectory of the day. After the driving trajectory is stored in the database, the user can query the driving trajectory of yesterday and before by logging into the application terminal. After the GPS positioning system receives the query instruction, it obtains the corresponding driving trajectory from the database according to the query instruction and sends the driving trajectory to the application terminal. It should be understood that by storing the driving trajectory that cannot be changed in the database, the situation of multiple drops in the warehouse due to data supplementation is avoided, and the database pressure is reduced.
[0077] The vehicle trajectory generation method provided in this embodiment screens out the corresponding stop points when the vehicle is in a stationary state, deletes the stop points in the driving data, and uses the remaining trajectory points as target trajectory points. The vehicle's driving trajectory can be accurately restored based on all the target trajectory points, thereby improving the accuracy of the generated driving trajectory.
[0078] See also Figure 2 , Figure 2 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 2 It should be understood that during the period of time when the vehicle is driving in the tunnel, the location information collected is the location information when the vehicle first enters the tunnel, that is, the location of multiple consecutive track points remains unchanged in a short period of time, and it is mistakenly believed that the vehicle is stationary at this time, and the current multiple track points are stop points, which is inconsistent with the actual driving situation. Figure 2 As shown in FIG. 1 , when a vehicle is traveling in a tunnel, the processing process for the filtered set of wrong stop points includes:
[0079] S201: For each set of stay points, if the last track point P in the set of stay points n The position of the next trajectory point P n+1 The distance between them is greater than the preset driving distance. According to the driving time of the first trajectory point P1 in the stop point set and P n+1 The driving time is determined by the driving time, and the driving time interval is determined according to P1 and P n+1 The predicted average driving speed is determined based on the distance between the two and the driving time interval, where n is a positive integer greater than 1 and less than or equal to N.
[0080] It should be understood that when a vehicle is driving in a tunnel, the location information uploaded is the location information when it first enters the tunnel, and the vehicle uploads new location information as soon as it exits the tunnel. Therefore, the distance between the location uploaded just before the vehicle exits the tunnel and the location uploaded just after the vehicle exits the tunnel is very far, which does not conform to the driving law of the vehicle.
[0081] For example, P n is the position uploaded by the vehicle just before exiting the tunnel, P n+1 The vehicle uploads new location information as soon as it exits the tunnel. When the last track point P in the set of stop points is n The position of the next trajectory point P n+1 When the distance between the two is greater than the preset driving distance, it means that the trajectory points in the stop point set meet the characteristics of the trajectory points in the tunnel. In order to exclude abnormal data, it is necessary to determine the driving time of the first trajectory point P1 in the stop point set and P n+1 The average driving speed between.
[0082] S202: If the predicted average driving speed is greater than or equal to the preset driving speed, the trajectory point in the stop point set is determined to be a driving trajectory point.
[0083] For example, when the travel time of the first trajectory point P1 is equal to P n+1 When the average driving speed between the two stops meets the tunnel driving conditions, it can be determined that the stop points in the current stop point set are not the stop points of the vehicle in a stationary state, but the stop point set that is misjudged due to the inability to collect data in real time in the tunnel, that is, the trajectory points in the stop point set are the driving trajectory points, thereby improving the accuracy of the identified stop point set.
[0084] The vehicle trajectory generation method provided in this embodiment improves the accuracy of the generated driving trajectory by identifying the corresponding stop point set when the vehicle is driving in the tunnel and using the trajectory points in the misjudged stop point set as normal driving trajectory points.
[0085] In one possible scenario, for each stay point set, if the ratio of the number of trajectory points with a zero driving speed in the stay point set to the number of all trajectory points included in the stay point set is greater than a first preset percentage, a new stay point set is generated based on the trajectory points with a zero driving speed in the stay point set.
[0086] It should be understood that if the number of all trajectory points included in the stay point set is 100, the number of trajectory points with a driving speed of zero in the stay point set is 90, and the ratio of the number of trajectory points with a driving speed of zero in the stay point set to the number of all trajectory points included in the stay point set is 90%, which is greater than the first preset percentage of 80%, indicating that the accuracy of the collected GPS information is high, and the trajectory points with a driving speed not equal to zero are removed from the stay point set, and the remaining ones are all accurate stay points, thereby improving the accuracy of the generated driving trajectory.
[0087] In another possible scenario, for each stay point set, if the ratio of the number of trajectory points in the stay point set whose driving speed is greater than zero to the number of all trajectory points included in the stay point set is greater than a second preset percentage, a new stay point set is generated based on all trajectory points except the 1st to the Xth trajectory points and the Xth to the last trajectory points, where X is a positive integer greater than 1 and less than or equal to N.
[0088] It should be understood that when the proportion of trajectory points with non-zero driving speed in the stop point set is high, it means that the vehicle is driving at a low speed in an area and may be in the process of parking. However, the vehicle is not in a stationary state when it is parked, and it is wrong to regard all trajectory points in the parking process as stop points. The vehicle is not in a stationary state before it is parked and after it sets off, so it is necessary to remove the multiple trajectory points collected before the vehicle is parked and the multiple trajectory points collected after it sets off from the stop point set.
[0089] See also Figure 3 , is a schematic diagram of the vehicle trajectory generation method provided in the embodiment of the present application Figure 3 .like Figure 3 As shown in FIG. 1 , after the vehicle driving trajectory is generated, the process of optimizing the driving trajectory generated according to the invalid trajectory segment is as follows:
[0090] S301: Determine the driving time interval between every two adjacent trajectory points, and use the driving time interval that is greater than or equal to a preset time period as a segmentation time period.
[0091] It should be understood that after the driving trajectory is generated, the vehicle state corresponding to each trajectory point is the driving state. When the collection time interval between the two previous and subsequent trajectory points is long, that is, when the driving time interval between two adjacent trajectory points is greater than or equal to the preset time period, it means that the two trajectory points belong to two different driving stages.
[0092] S302: Segment the driving trajectory according to all the segmented time periods to obtain at least one trajectory segment.
[0093] Exemplarily, after all the segmented time periods are screened out, the driving trajectory is segmented into a plurality of trajectory segments according to all the segmented time periods. It should be understood that each trajectory segment represents a driving process of the vehicle.
[0094] S303: If the number of trajectory points included in the trajectory segment is less than a preset parameter, the trajectory segment is deleted from the driving trajectory, and a driving trajectory is generated according to all remaining trajectory segments.
[0095] It should be understood that during a period of driving, according to the time pattern of vehicle start and stop, the driving time corresponding to a track segment is at least 1 minute, and the time interval for GPS system to collect track points is 15 seconds. Therefore, if the number of track points contained in a track segment is less than 4, the track segment can be considered invalid and removed, and the driving track is generated based on all the remaining track segments.
[0096] The vehicle trajectory generation method provided in this embodiment improves the accuracy of the generated driving trajectory by segmenting the driving trajectory and screening out invalid trajectory segments that do not conform to the vehicle driving law according to the number of trajectory points contained in the trajectory segments.
[0097] See also Figure 4 , Figure 4 The process diagram of the vehicle trajectory generation method provided in the embodiment of the present application is as follows Figure 4 In a possible implementation, in addition to filtering out abnormalities in the data of a single trajectory point, abnormal trajectory points can also be filtered out based on the correlation between multiple consecutive trajectory points. Specifically, the joint screening process of multiple trajectory points is as follows:
[0098] S401: For each trajectory point P i , select the trajectory point P i All corresponding adjacent trajectory points, including P i-2 , P i-1 , P i+1 and P i+2 , where i is a positive integer greater than 2 and less than N-2.
[0099] Exemplarily, the two preceding and two following trajectory points of the current trajectory point are selected as adjacent trajectory points. When i is 5, all adjacent trajectory points corresponding to P5 are P3, P4, P6, and P7. It should be understood that when i is 1, all adjacent trajectory points corresponding to P1 are P2 and P3, and when i is 1, all adjacent trajectory points corresponding to P1 are P1, P3, and P4.
[0100] S402: For P i For each adjacent trajectory point, determine P iThe adjacent distance and adjacent time interval between adjacent trajectory points are used to determine P i The adjacent velocities between adjacent trajectory points.
[0101] Exemplarily, when i is 5, the adjacent distance and adjacent time interval between P5 and P3 are determined, and the adjacent speed between P5 and P3 is calculated accordingly. Similarly, the adjacent speed between P5 and P3, the adjacent speed between P5 and P6, and the adjacent speed between P5 and P7 are calculated in sequence.
[0102] S403: When the trajectory point P i-2 and P i-1 When all are normal trajectory points, if P i If the adjacent speed between each adjacent trajectory point is less than the preset maximum speed, then P i is a normal trajectory point, otherwise it is determined that P i is an abnormal trajectory point.
[0103] Exemplarily, when P3 and P4 have been confirmed as normal trajectory points, if the adjacent speeds between P5 and P3, P4, P6 and P7 are all less than the preset maximum speed, P5 is determined to be a normal trajectory point; if any of the adjacent speeds between P5 and P3, P4, P6 and P7 is greater than or equal to the preset maximum speed, P5 is determined to be an abnormal trajectory point.
[0104] S404: P i+1 and P i+2 As a tentative trajectory point Px, for each tentative trajectory point, when P i With P i-2 Between and P i With P i-2 When the adjacent speeds between are all less than the preset maximum speed, if P i The adjacent average speed between Px and Px is greater than the preset maximum speed, then it is determined that P i P i It is a suspected abnormal trajectory point.
[0105] Exemplarily, when the adjacent speeds between P5 and P3 and the adjacent speeds between P5 and P4 are both less than the preset maximum speed, if the adjacent speeds between P5 and P6 or the adjacent speeds between P5 and P7 are greater than or equal to the preset maximum speed, P5 is determined to be a suspected abnormal trajectory point, and the recognition result of P5 needs to be inferred based on the recognition results of P6 and P7.
[0106] S405: Screen and select all adjacent trajectory points of Px. When Px is determined to be a normal trajectory point based on all adjacent trajectory points of Px, the suspected abnormal trajectory point Px is iWhen Px is determined to be a normal trajectory point, the suspected abnormal trajectory point P i When Px is determined to be a suspected abnormal trajectory point, the suspected abnormal trajectory point P i Determined as an abnormal trajectory point.
[0107] Exemplarily, when the adjacent speed between P5 and P6 is greater than or equal to the preset maximum speed, resulting in P5 being a suspected abnormal trajectory point, if P6 is determined to be a normal trajectory point based on the adjacent trajectory points of P6, P5 is confirmed to be a normal trajectory point by reverse calculation; if P6 is determined to be an abnormal trajectory point based on the adjacent trajectory points of P6, P5 is confirmed to be an abnormal trajectory point by reverse calculation; if P6 is determined to be a suspected abnormal trajectory point based on the adjacent trajectory points of P6, P5 is confirmed to be an abnormal trajectory point by reverse calculation. For P7, the above judgment logic is repeatedly executed.
[0108] The vehicle trajectory generation method provided in this embodiment improves the accuracy of the generated driving trajectory by screening out abnormal trajectory points according to the correlation relationship between multiple continuous trajectory points.
[0109] It should be understood that the size of the serial numbers of the steps in the above embodiments does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiments of the present application.
[0110] Corresponding to the vehicle trajectory generation method of the above embodiment, Figure 5 : is a structural block diagram of a vehicle trajectory generating device provided in an embodiment of the present application. For the sake of convenience of explanation, only the parts related to the embodiment of the present application are shown.
[0111] Reference Figure 5 The vehicle trajectory generating device includes: an acquisition module 501, a selection module 502 and a generation module 503.
[0112] An acquisition module 501 is used to acquire driving data of a vehicle, wherein the driving data includes N track points, where N is a positive integer;
[0113] A selection module 502, configured to select at least one stop point satisfying a preset stop condition from the N track points of the driving data, wherein the preset stop condition refers to a track point generated when the vehicle is in a stationary state;
[0114] A generating module 503 is used to obtain at least one target trajectory point other than the at least one stop point from the N trajectory points, and generate a driving trajectory according to the data of the at least one target trajectory point.
[0115] It should be noted that the information interaction, execution process, etc. between the above-mentioned modules / units are based on the same concept as the method embodiment of the present application. Their specific functions and technical effects can be found in the method embodiment part and will not be repeated here.
[0116] in addition, Figure 5 The vehicle trajectory generating device shown may be a software unit, a hardware unit, or a combination of software and hardware units built into an existing vehicle controller, or may be integrated into the terminal device as an independent pendant, or may exist as an independent terminal device.
[0117] The technicians in the relevant field can clearly understand that for the convenience and simplicity of description, only the division of the above-mentioned functional units and modules is used as an example for illustration. In practical applications, the above-mentioned function allocation can be completed by different functional units and modules as needed, that is, the internal structure of the device can be divided into different functional units or modules to complete all or part of the functions described above. The functional units and modules in the embodiment can be integrated in a processing unit, or each unit can exist physically separately, or two or more units can be integrated in one unit. The above-mentioned integrated unit can be implemented in the form of hardware or in the form of software functional units. In addition, the specific names of the functional units and modules are only for the convenience of distinguishing each other, and are not used to limit the scope of protection of this application. The specific working process of the units and modules in the above-mentioned system can refer to the corresponding process in the aforementioned method embodiment, which will not be repeated here.
[0118] Figure 6 is a schematic diagram of the structure of an electronic device provided in an embodiment of the present application. The electronic device 60 provided in an embodiment of the present application includes: at least one processor 61 ( Figure 6 Only one is shown), a memory 62 and a computer program 63 stored in the memory 62 and executable on the at least one processor 61, wherein when the processor 61 executes the computer program 63, the steps executed by the electronic device in any of the above-mentioned vehicle trajectory generation method embodiments are implemented.
[0119] The processor 61 may be a central processing unit (CPU), or other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc.
[0120] In some embodiments, the memory 62 may be an internal storage unit of the electronic device 60, such as a hard disk or memory of the electronic device 60. In other embodiments, the memory 62 may also be an external storage device of the electronic device 60, such as a plug-in hard disk, a smart media card (SMC), a secure digital (SD) card, a flash card, etc. equipped on the electronic device 60. Further, the electronic device 60 may also include both an internal storage unit of the electronic device 60 and an external storage device. The memory 62 is used to store an operating system, an application program, a boot loader, data, and other programs, such as the program code of the computer program. The memory 62 may also be used to temporarily store data that has been output or is to be output.
[0121] An embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps executed by the electronic device in any of the above-mentioned vehicle trajectory generation method embodiments can be implemented.
[0122] An embodiment of the present application provides a computer program product. When the computer program product is run on a terminal device, the terminal device implements the steps performed by the electronic device in any of the above-mentioned vehicle trajectory generation method embodiments.
[0123] If the integrated unit is implemented in the form of a software functional unit and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the present application implements all or part of the processes in the above-mentioned embodiment method, which can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and the computer program can implement the steps of the above-mentioned various method embodiments when executed by the processor. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or some intermediate form. The computer-readable medium may at least include: any entity or device that can carry the computer program code to the device / terminal device, a recording medium, a computer memory, a read-only memory (ROM, Read-Only Memory), a random access memory (RAM, Random Access Memory), an electric carrier signal, a telecommunication signal, and a software distribution medium. For example, a USB flash drive, a mobile hard disk, a magnetic disk or an optical disk. In some jurisdictions, according to legislation and patent practice, computer-readable media cannot be electric carrier signals and telecommunication signals.
[0124] In the above embodiments, the description of each embodiment has its own emphasis. For parts that are not described or recorded in detail in a certain embodiment, reference can be made to the relevant descriptions of other embodiments.
[0125] Those of ordinary skill in the art will appreciate that the units and algorithm steps of each example described in conjunction with the embodiments disclosed herein can be implemented in electronic hardware, or a combination of computer software and electronic hardware. Whether these functions are performed in hardware or software depends on the specific application and design constraints of the technical solution. Professional and technical personnel can use different methods to implement the described functions for each specific application, but such implementation should not be considered to be beyond the scope of this application.
[0126] In the embodiments provided in the present application, it should be understood that the disclosed devices / terminal equipment and methods can be implemented in other ways. For example, the device / terminal equipment embodiments described above are only schematic. For example, the division of the modules or units is only a logical function division. There may be other division methods in actual implementation, such as multiple units or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the mutual coupling or direct coupling or communication connection shown or discussed can be through some interfaces, indirect coupling or communication connection of devices or units, which can be electrical, mechanical or other forms.
[0127] The units described as separate components may or may not be physically separated, and the components shown as units may or may not be physical units, that is, they may be located in one place or distributed on multiple network units. Some or all of the units may be selected according to actual needs to achieve the purpose of the solution of this embodiment.
[0128] The embodiments described above are only used to illustrate the technical solutions of the present application, rather than to limit them. Although the present application has been described in detail with reference to the aforementioned embodiments, a person skilled in the art should understand that the technical solutions described in the aforementioned embodiments may still be modified, or some of the technical features may be replaced by equivalents. Such modifications or replacements do not deviate the essence of the corresponding technical solutions from the spirit and scope of the technical solutions of the embodiments of the present application, and should all be included in the protection scope of the present application.
Claims
1. A vehicle trajectory generation method, characterized in that: The method comprises: Acquire driving data of the vehicle, wherein the driving data includes N trajectory points, where N is a positive integer; Selecting at least one stop point that satisfies a preset track stop condition from the N track points of the driving data, wherein the preset track stop condition refers to a track point generated when the vehicle is in a stationary state; At least one target trajectory point other than the at least one stop point is acquired from the N trajectory points, and a driving trajectory is generated according to data of the at least one target trajectory point.
2. The vehicle trajectory generation method according to claim 1, characterized in that: The selecting at least one stop point satisfying a preset track stop condition from the N track points of the driving data comprises: Obtaining the driving positions and driving times of N trajectory points from the driving data; Determine at least one stop point set according to the driving positions and driving times of the N trajectory points, wherein each stop point set includes at least two stop points, and the distance between the first stop point and the last stop point in each stop point set is less than a preset distance, and the time interval between the first stop point and the last stop point is greater than a preset time period; The trajectory points in each of the stop point sets are used as stop points.
3. The vehicle trajectory generation method according to claim 2, characterized in that: After determining at least one set of stop points according to the driving positions and driving times of the N trajectory points, the method further includes: For each set of stay points, if the last trajectory point P in the set of stay points n The position of the next trajectory point P n+1 The distance between them is greater than the preset driving distance, according to the driving time of the first trajectory point P1 in the set of stop points and P n+1 The driving time is determined by the driving time, and the driving time interval is determined according to P1 and P n+1 The predicted average driving speed is determined based on the distance between the two vehicles and the driving time interval, wherein n is a positive integer greater than 1 and less than or equal to N; If the predicted average driving speed is greater than or equal to the preset driving speed, the trajectory point in the set of stop points is determined to be a driving trajectory point.
4. The vehicle trajectory generation method according to claim 2, characterized in that: After determining at least one set of stop points according to the driving positions and driving times of the N trajectory points, the method further includes: Obtaining the driving speeds of N trajectory points from the driving data; For each stay point set, if the ratio of the number of trajectory points with a driving speed of zero in the stay point set to the number of all trajectory points included in the stay point set is greater than a first preset percentage, a new stay point set is generated according to the trajectory points with a driving speed of zero in the stay point set; For each stay point set, if the ratio of the number of trajectory points in the stay point set whose driving speed is greater than zero to the number of all trajectory points included in the stay point set is greater than a second preset percentage, a new stay point set is generated based on all trajectory points except the 1st trajectory point to the Xth trajectory point and the Xth to last trajectory point, where X is a positive integer greater than 1 and less than or equal to N.
5. The vehicle trajectory generation method according to claim 1, characterized in that: After generating the driving trajectory according to the data of the at least one target trajectory point, the method further comprises: Determine the driving time interval between every two adjacent trajectory points, and use the driving time interval that is greater than or equal to the preset time period as the split time period; Segmenting the driving trajectory according to all the segmented time periods to obtain at least one trajectory segment; If the number of trajectory points included in the trajectory segment is less than a preset parameter, the trajectory segment is deleted from the driving trajectory, and a driving trajectory is generated according to all remaining trajectory segments.
6. The vehicle trajectory generation method according to claim 1, characterized in that: Before selecting at least one stop point satisfying a preset stop condition of the track from the N track points of the driving data, the method further includes: Obtaining the number of positioning satellites and the driving speed of N trajectory points from the driving data; If the travel speed of the trajectory point is greater than the preset maximum speed, the trajectory point is regarded as an invalid trajectory point; or, if the travel speed of the trajectory point is less than the preset minimum speed and the number of positioning satellites of the trajectory point is less than the preset number, the trajectory point is regarded as an invalid trajectory point; At least one invalid track point is deleted from the driving data.
7. The vehicle trajectory generation method according to claim 6, characterized in that: After deleting at least one invalid track point from the driving data, the method further comprises: For each trajectory point P i , select the trajectory point P i All the corresponding adjacent trajectory points, including P i-2 , P i-1 , P i+1 and P i+2 , where i is a positive integer greater than 2 and less than N-2; For P i For each adjacent trajectory point, determine P i The adjacent distance and the adjacent time interval between the adjacent trajectory points, and determine P according to the adjacent distance and the adjacent time interval i The adjacent speeds between the adjacent trajectory points; When the trajectory point P i-2 and P i-1 When all are normal trajectory points, if P i If the adjacent speed between each adjacent trajectory point is less than the preset maximum speed, then P i is a normal trajectory point, otherwise it is determined that P i is an abnormal trajectory point; P i+1 and P i+2 As a tentative trajectory point Px, for each tentative trajectory point, when P i With P i-2 Between and P i With P i-2 When the adjacent speeds between are all less than the preset maximum speed, if P i The adjacent average speed between Px and Px is greater than the preset maximum speed, then it is determined that P i P i It is a suspected abnormal trajectory point; All adjacent trajectory points of Px are selected. When Px is determined to be a normal trajectory point based on all adjacent trajectory points of Px, the suspected abnormal trajectory point P i When Px is determined to be a normal trajectory point, the suspected abnormal trajectory point P i When Px is determined to be a suspected abnormal trajectory point, the suspected abnormal trajectory point P i Determined as an abnormal trajectory point.
8. The vehicle trajectory generation method according to any one of claims 1 to 7, characterized in that: After generating the driving trajectory according to the data of the at least one target trajectory point, the method further comprises: Storing the generated driving trajectory in a database according to a preset frequency; Accepting a query instruction sent by the application terminal, and acquiring a corresponding driving trajectory from the database according to the query instruction; The driving trajectory is sent to the application terminal.
9. A vehicle trajectory generating device, characterized in that: The device comprises: An acquisition module, used to acquire driving data of a vehicle, wherein the driving data includes N trajectory points, wherein N is a positive integer; A selection module, configured to select at least one stop point satisfying a preset track stop condition from the N track points of the driving data, wherein the preset track stop condition refers to a track point generated when the vehicle is in a stationary state; A generating module is used to obtain at least one target trajectory point other than the at least one stop point from the N trajectory points, and to generate a driving trajectory according to data of the at least one target trajectory point.
10. An electronic device, characterized in that: The method comprises a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the vehicle trajectory generation method according to any one of claims 1 to 8 when executing the computer program.
Citation Information
Cited By
Vehicle driving track processing method, device, equipment and medium
CN119599555A
