CN114996380A - Road network intersection extraction method, device, equipment and storage medium - Google Patents

Road network intersection extraction method, device, equipment and storage medium Download PDF

Info

Publication number
CN114996380A
CN114996380A CN202210599556.1A CN202210599556A CN114996380A CN 114996380 A CN114996380 A CN 114996380A CN 202210599556 A CN202210599556 A CN 202210599556A CN 114996380 A CN114996380 A CN 114996380A
Authority
CN
China
Prior art keywords
intersection
track
road network
data
codes
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210599556.1A
Other languages
Chinese (zh)
Inventor
严俊
张宇
万龙
王磊
杨威
袁颖
吕程
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
South Sagittarius Integration Co Ltd
Original Assignee
South Sagittarius Integration Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by South Sagittarius Integration Co Ltd filed Critical South Sagittarius Integration Co Ltd
Priority to CN202210599556.1A priority Critical patent/CN114996380A/en
Publication of CN114996380A publication Critical patent/CN114996380A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/29Geographical information databases
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/20Information retrieval; Database structures therefor; File system structures therefor of structured data, e.g. relational data
    • G06F16/24Querying
    • G06F16/245Query processing
    • G06F16/2455Query execution
    • G06F16/24553Query execution of query operations
    • G06F16/24554Unary operations; Data partitioning operations
    • G06F16/24556Aggregation; Duplicate elimination
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/12Use of codes for handling textual entities
    • G06F40/126Character encoding

Abstract

The invention discloses a road network intersection point extraction method, a road network intersection point extraction device, road network intersection point extraction equipment and a storage medium, wherein the road network intersection point extraction method is used for carrying out code conversion on vehicle travel track data to obtain track point codes; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, and the road network intersection point extraction speed and efficiency are improved.

Description

Road network intersection extraction method, device, equipment and storage medium
Technical Field
The invention relates to the technical field of map and urban road network planning, in particular to a road network intersection extraction method, a road network intersection extraction device, road network intersection extraction equipment and a storage medium.
Background
Urban traffic construction is an essential important component for urban development and is closely related to daily life of people; with the rapid development of electronic communication technology, internet technology and internet of things technology, urban road network data is becoming more and more important in the aspects of urban planning, road supervision, map value-added service and the like; no matter the external expansion of cities and the optimization of internal structures, the change of urban road network can be caused.
The traditional urban road network data is mainly obtained by two modes of surveying and mapping by professional personnel and digitalizing a remote sensing image, but the two methods have high investment cost, high professional technical requirements of the professional personnel and long production period, and are difficult to meet the requirements of rapid development and change of cities on the network data; the acquisition efficiency and accuracy of road network data are low, and the speed and quality of urban road network planning are influenced.
Disclosure of Invention
The invention mainly aims to provide a road network intersection extraction method, a road network intersection extraction device, road network intersection extraction equipment and a storage medium, and aims to solve the technical problems that in the prior art, the urban road network data acquisition efficiency and accuracy are low, and the speed and quality of urban road network planning are influenced.
In a first aspect, the present invention provides a road network intersection extraction method, including the following steps:
carrying out code conversion on the vehicle travel track data to obtain track point codes;
acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information;
and aggregating the intersection point sets to be selected, and recoding to obtain the intersection output codes.
Optionally, before performing code conversion on the vehicle travel track data to obtain track point codes, the road network intersection extraction method further includes:
obtaining historical vehicle track data through a calculation engine;
and filtering the boundary-crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
Optionally, the obtaining, by the calculation engine, historical vehicle trajectory data includes:
historical vehicle trajectory data was obtained by spark sql query from hive or spark streaming consumption Kafka data.
Optionally, the filtering the out-of-range data in the historical vehicle trajectory data to obtain filtered vehicle travel trajectory data includes:
and taking the track data which does not exceed the preset track length in the historical vehicle track data as boundary crossing data, and removing and filtering the boundary crossing data from the historical vehicle track data to obtain filtered vehicle travel track data.
Optionally, the performing code conversion on the vehicle travel track data to obtain track point codes includes:
and performing geohash code conversion on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain track point codes.
Optionally, the acquiring intersection information of the track according to the track point code, and generating an intersection point set to be selected according to the intersection information includes:
comparing each time sequence track in the vehicle travel track data with other time sequence tracks, searching a target code of a track point next to the same track point code in the two time sequence tracks, and calculating a longitude and latitude distance before the target code is converted;
when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information;
and traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating each intersection information to obtain an intersection point set to be selected.
Optionally, the aggregating the intersection point set to be selected and recoding the intersection point set to obtain an intersection output code includes:
acquiring a grid area determined according to the number of coding bits in the intersection point set to be selected;
and aggregating the same intersection which repeatedly occupies the grid area or falls into a plurality of grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
In a second aspect, in order to achieve the above object, the present invention further provides a road network intersection extraction device, including:
the conversion module is used for carrying out code conversion on the vehicle travel track data to obtain track point codes;
the set generation module is used for acquiring intersection information of the track according to the track point codes and generating an intersection point set to be selected according to the intersection information;
and the aggregation module is used for aggregating the intersection point set to be selected and recoding to obtain the intersection output code.
In a third aspect, to achieve the above object, the present invention further provides a road network intersection extraction device, including: a memory, a processor and a road network intersection extraction program stored on said memory and operable on said processor, said road network intersection extraction program being configured to implement the steps of the road network intersection extraction method as described above.
In a fourth aspect, in order to achieve the above object, the present invention further provides a storage medium, on which a road network intersection extraction program is stored, wherein the road network intersection extraction program, when executed by a processor, implements the steps of the road network intersection extraction method as described above.
The road network intersection extraction method provided by the invention obtains track point codes by carrying out code conversion on vehicle travel track data; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, and the road network intersection point extraction speed and efficiency are improved.
Drawings
FIG. 1 is a schematic diagram of an apparatus architecture of a hardware operating environment according to an embodiment of the present invention;
FIG. 2 is a schematic flow chart of a road network intersection extraction method according to a first embodiment of the present invention;
FIG. 3 is a flowchart illustrating a road network intersection extraction method according to a second embodiment of the present invention;
FIG. 4 is a flow chart illustrating a road network intersection extraction method according to a third embodiment of the present invention;
FIG. 5 is a flow chart illustrating a road network intersection extraction method according to a fourth embodiment of the present invention;
FIG. 6 is a flow chart illustrating a fifth embodiment of a road network intersection extraction method according to the present invention;
FIG. 7 is a flowchart illustrating a road network intersection extraction method according to a sixth embodiment of the present invention;
FIG. 8 is a flow chart illustrating a road network intersection extraction method according to a seventh embodiment of the present invention;
fig. 9 is a functional block diagram of the road network intersection extracting apparatus according to the first embodiment of the present invention.
The implementation, functional features and advantages of the objects of the present invention will be further explained with reference to the accompanying drawings.
Detailed Description
It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
The solution of the embodiment of the invention is mainly as follows: obtaining track point codes by carrying out code conversion on the vehicle travel track data; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, the road network intersection point extraction speed and efficiency are improved, the technical problems that the urban road network data acquisition efficiency and accuracy are low in the prior art, and the urban road network planning speed and quality are influenced are solved.
Referring to fig. 1, fig. 1 is a schematic device structure diagram of a hardware operating environment according to an embodiment of the present invention.
As shown in fig. 1, the apparatus may include: a processor 1001, such as a CPU, a communication bus 1002, a user interface 1003, a network interface 1004, and a memory 1005. Wherein a communication bus 1002 is used to enable connective communication between these components. The user interface 1003 may include a Display screen (Display), an input unit such as a Keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface, a wireless interface. The network interface 1004 may optionally include a standard wired interface, a wireless interface (e.g., a Wi-Fi interface). The Memory 1005 may be a high-speed RAM Memory or a Non-Volatile Memory (Non-Volatile Memory), such as a disk Memory. The memory 1005 may alternatively be a storage device separate from the processor 1001 described previously.
Those skilled in the art will appreciate that the configuration of the apparatus shown in fig. 1 is not intended to be limiting of the apparatus and may include more or fewer components than those shown, or some components may be combined, or a different arrangement of components.
As shown in fig. 1, a memory 1005 as a storage medium may include an operating device, a network communication module, a user interface module, and a road network intersection extracting program.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and performs the following operations:
carrying out code conversion on the vehicle travel track data to obtain track point codes;
acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information;
and aggregating the intersection point sets to be selected, and recoding to obtain an intersection output code.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
obtaining historical vehicle track data through a calculation engine;
and filtering the boundary-crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
historical vehicle trajectory data was obtained by spark sql query from hive or spark streaming consumption Kafka data.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
and taking the track data which does not exceed the preset track length in the historical vehicle track data as boundary crossing data, and removing and filtering the boundary crossing data from the historical vehicle track data to obtain filtered vehicle travel track data.
The device of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
and performing geohash coding conversion on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain track point codes.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
comparing each time sequence track in the vehicle travel track data with other time sequence tracks, searching a target code of a next track point of the same track point code in the two time sequence tracks, and calculating a longitude and latitude distance before the target code is converted;
when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information;
traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating the intersection information to obtain an intersection point set to be selected.
The apparatus of the present invention calls the road network intersection extraction program stored in the memory 1005 by the processor 1001, and further performs the following operations:
acquiring a grid area determined according to the number of coding bits in the intersection point set to be selected;
and aggregating the same intersection which repeatedly occupies the grid area or falls into a plurality of grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
According to the scheme, the track point codes are obtained by performing code conversion on the vehicle travel track data; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, and the road network intersection point extraction speed and efficiency are improved.
Based on the hardware structure, the embodiment of the road network intersection extraction method is provided.
Referring to fig. 2, fig. 2 is a flowchart illustrating a road network intersection extraction method according to a first embodiment of the present invention.
In a first embodiment, the road network intersection extraction method includes the following steps:
and step S10, carrying out code conversion on the vehicle travel track data to obtain track point codes.
It should be noted that the vehicle travel track data is track data generated in the process of driving a large number of vehicles at a road intersection, and track point codes can be obtained by performing code conversion on the vehicle travel track data.
And step S20, acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information.
It can be understood that intersection information of different vehicle driving tracks can be obtained through the track point codes, and a corresponding intersection point set to be selected can be generated through the intersection information.
And step S30, aggregating the intersection point sets to be selected, and recoding to obtain an intersection output code.
It should be understood that after the intersection candidate point set is aggregated and recoded, the intersection code can be obtained.
According to the scheme, the track point codes are obtained by performing code conversion on the vehicle travel track data; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, and the road network intersection point extraction speed and efficiency are improved.
Further, fig. 3 is a schematic flow chart of a road network intersection extraction method according to a second embodiment of the present invention, and as shown in fig. 3, the road network intersection extraction method according to the second embodiment of the present invention is proposed based on the first embodiment, in this embodiment, before the step S10, the road network intersection extraction method further includes the following steps:
step S01, the calculation engine acquires the historical vehicle trajectory data.
It should be noted that the calculation engine may acquire data related to the vehicle trajectory in the past period of time, that is, historical vehicle trajectory data.
And step S02, filtering the boundary crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
It can be understood that the filtered vehicle travel track data can be obtained by cleaning, filtering and removing the boundary-crossing data in the historical vehicle track data.
According to the scheme, the historical vehicle track data is obtained through the calculation engine; filtering the boundary crossing data in the historical vehicle track data to obtain filtered vehicle travel track data; the initial vehicle running track data can be filtered, and the speed and the efficiency of road network intersection extraction are further improved.
Further, fig. 4 is a schematic flow chart of a road network intersection extraction method according to a third embodiment of the present invention, and as shown in fig. 4, the third embodiment of the road network intersection extraction method according to the present invention is proposed based on the second embodiment, in this embodiment, the step S01 specifically includes the following steps:
and S011, inquiring from hive through spark ksql or consuming Kafka data through spark streaming to obtain historical vehicle track data.
It should be noted that, the vehicle trajectory data is obtained by querying real-time new data from hive through spark ksql or by consuming Kafka data through spark streaming, so that historical vehicle trajectory data in a certain period of time can be obtained.
According to the scheme, historical vehicle track data can be obtained quickly in a certain time period by querying from hive through spark ql or obtaining the historical vehicle track data through spark streaming Kafka consumption data.
Further, fig. 5 is a schematic flowchart of a road network intersection extraction method according to a fourth embodiment of the present invention, and as shown in fig. 5, the road network intersection extraction method according to the fourth embodiment of the present invention is proposed based on the second embodiment, in this embodiment, the step S02 specifically includes the following steps:
and S021, taking the track data which does not exceed the preset track length in the historical vehicle track data as boundary crossing data, and removing and filtering the boundary crossing data from the historical vehicle track data to obtain filtered vehicle travel track data.
It should be noted that, the track data which does not exceed the preset track length in the historical vehicle track data is used as the boundary crossing data, and then the boundary crossing data is removed and filtered, so that the filtered vehicle travel track data can be obtained.
In the concrete implementation, the vehicle track data of the previous day can be acquired and processed as historical vehicle track data, the situation that long tracks contain short tracks which do not exceed the preset track length exists in the track data, the contained short tracks can be removed, and then the filtered vehicle travel track data is acquired, so that the subsequent calculated amount is reduced, and in the actual operation, a vehicle travel track data set of the time sequence track point longitude and latitude, the course angle and the vehicle speed corresponding to each section of travel (namely, the travel id) can be acquired.
According to the scheme, the track data which do not exceed the preset track length in the historical vehicle track data are used as the boundary crossing data, the boundary crossing data are removed from the historical vehicle track data and filtered, the filtered vehicle travel track data are obtained, the number of track points can be greatly reduced, the calculated amount is greatly reduced, and the speed and the efficiency of road network intersection extraction are improved.
Further, fig. 6 is a schematic flow chart of a fifth embodiment of the road network intersection extraction method of the present invention, and as shown in fig. 6, the fifth embodiment of the road network intersection extraction method of the present invention is proposed based on the first embodiment, in this embodiment, the step S10 specifically includes the following steps:
and step S11, performing geohash coding conversion on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain track point codes.
It should be noted that the geohash code conversion is performed on the longitude and latitude of the time sequence track points in the vehicle travel track data, so that converted geohash codes, namely track point codes, can be obtained, and the purpose of the codes is to uniformly map track points adjacent to each other to one code, so as to facilitate comparison and calculation.
In the concrete implementation, longitude and latitude are reserved, the distance and intersection to be selected are calculated later and need to be aggregated, 7-bit codes are temporarily set, the error is 76 meters, the reporting frequency of data acquired by the vehicle-mounted terminal is 10s at present, if the data acquisition reporting time period is shorter, the length of the geohash codes can be correspondingly increased, the more the number of the coded bits is, the smaller the position range represented by the codes is, the higher the precision is, but the number of the coded bits is not too long, and the extracted data is too fragmented due to too long time, so that the initial coded bits need to be determined according to the actual situation.
It can be understood that, in the data conversion process, if the track data obtained at one time is large, the spare may be used to re-partition according to the track run id field (runs are not associated and independent from each other, and can be split and processed arbitrarily), and then the data conversion related operation is processed according to the partition, so that the memory overflow can be avoided.
According to the embodiment, the geohash code conversion is carried out on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain the track point codes, the number of the track points is greatly reduced, the calculated amount is greatly reduced, and the road intersection points can be updated according to the newly added track in real time.
Further, fig. 7 is a schematic flowchart of a sixth embodiment of the road network intersection extraction method according to the present invention, and as shown in fig. 7, the sixth embodiment of the road network intersection extraction method according to the present invention is proposed based on the first embodiment, in this embodiment, the step S20 specifically includes the following steps:
and step S21, comparing each time sequence track in the vehicle travel track data with other time sequence tracks, searching a target code of a next track point of the same track point code in the two time sequence tracks, and calculating the longitude and latitude distance before the target code is converted.
It should be noted that, by comparing each time sequence track in the vehicle travel track data with other time sequence tracks, the same track point code and the next track point code in the two tracks can be found, and then the longitude and latitude distance before conversion can be calculated.
In the specific implementation, the set after the track filtering is made to be P, then, for the real-time newly added track data, the real-time newly added track data can be compared with P, if the included track does not exist, the included track is added into P, and if the included track does not exist, the included track is not added; comparing each section of track in the P with other tracks (undirected combination, two identical tracks are compared only once), and for comparing the newly added track in real time with all tracks in the P, the logic of comparing every two tracks and extracting intersection information is as follows: and searching for the same geohash code S of two time sequence tracks, wherein the codes (A1 and A2) of the following track points are different, and calculating the longitude and latitude distances before the conversion of A1 and A2.
And step S22, when the longitude and latitude distance exceeds a preset distance threshold value, the changes of the corresponding course angles of the two vehicles are inconsistent, and any vehicle has a deceleration behavior, taking the longitude and latitude information of the track point corresponding to the same track point code as the intersection information.
It can be understood that, when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information corresponding to the same track point code can be used as the intersection information.
In a specific implementation, if the distance exceeds a threshold (e.g., 76 meters) and the changes of the heading angles of the two vehicles are inconsistent, any one of the vehicles has a deceleration behavior before and after the track S, and if the conditions are met, the original longitude and latitude corresponding to S are added to the intersection point-to-be-selected set R (the codes and the corresponding longitude and latitude).
And step S23, traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating each intersection information to obtain an intersection point set to be selected.
It should be understood that, by traversing each time sequence track in the vehicle travel track data, intersection information can be obtained, and intersection information can be integrated to obtain an intersection point set to be selected.
In a specific implementation, roads between intersections can be further identified based on the output intersections, and finally a road network can be formed.
According to the scheme, each time sequence track in the vehicle travel track data is compared with other time sequence tracks, the target code of the next track point of the same track point code in the two time sequence tracks is searched, and the longitude and latitude distance before the target code is converted is calculated; when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information; each section of time sequence track in the vehicle travel track data is traversed, intersection information of each section of time sequence track and other time sequence tracks is obtained, the intersection information is integrated, intersection point selection sets are obtained, the number of track points can be greatly reduced, the calculated amount is greatly reduced, road intersections can be updated according to the newly added track in real time, and the method is good in real-time performance, simple in logic, strong in practicability and good in effect.
Further, fig. 8 is a schematic flow chart of a road network intersection extraction method according to a seventh embodiment of the present invention, and as shown in fig. 8, the road network intersection extraction method according to the seventh embodiment of the present invention is proposed based on the first embodiment, in this embodiment, the step S30 specifically includes the following steps:
and step S31, acquiring a grid area determined according to the number of coding bits in the intersection point set to be selected.
It should be understood that the corresponding squares can be determined according to the number of coded bits in the intersection point set to be selected, that is, the area range defined by each square frame is determined after the number of coded bits of the geohash is determined.
And step S32, aggregating the same intersection repeatedly occupying the grid area or falling into a plurality of grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
In a specific implementation, some intersections in the intersection point set to be selected may fall into multiple squares (vertices of squares near the center of the intersection), and particularly when the number of coding bits is long, there is also a case where a coding area of a traffic intersection with a large floor area is not enough to cover, so that the two cases need to be aggregated, and more appropriate shorter codes for identifying a larger area are set for recoding.
According to the scheme, the grid area determined according to the number of the coding bits in the intersection point set to be selected is obtained; the intersection point acquisition method based on the multi-point clustering comprises the steps of repeatedly occupying square areas or aggregating the same intersection falling into a plurality of square areas in an intersection point set to be selected, recoding intersection track points in an aggregation result to obtain intersection output codes, greatly reducing the number of the track points, greatly reducing the calculated amount, updating road intersections according to real-time newly increased tracks, achieving good real-time performance, simple logic and easy implementation, improving the urban road network data acquisition efficiency and accuracy, and improving the speed and efficiency of road network intersection extraction.
Correspondingly, the invention further provides a road network intersection extraction device.
Referring to fig. 9, fig. 9 is a functional block diagram of a road network intersection extracting apparatus according to a first embodiment of the present invention.
In a first embodiment of the road network intersection extracting apparatus according to the present invention, the road network intersection extracting apparatus includes:
and the conversion module 10 is used for performing code conversion on the vehicle travel track data to obtain track point codes.
And the set generating module 20 is configured to obtain intersection information of the track according to the track point codes, and generate an intersection set of points to be selected according to the intersection information.
And the aggregation module 30 is configured to aggregate the intersection point sets to be selected, and recode the intersection point sets to obtain an intersection output code.
The conversion module 10 is further configured to obtain historical vehicle trajectory data through a calculation engine; and filtering the boundary crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
The conversion module 10 is further configured to obtain historical vehicle trajectory data by querying from hive through spark ksql or by consuming Kafka data through spark streaming.
The conversion module 10 is further configured to take track data that does not exceed a preset track length in the historical vehicle track data as boundary crossing data, remove and filter the boundary crossing data from the historical vehicle track data, and obtain filtered vehicle travel track data.
The conversion module 10 is further configured to perform geohash code conversion on the longitude and latitude of the time sequence track point in the vehicle travel track data to obtain a track point code.
The set generating module 20 is further configured to compare each time sequence track in the vehicle travel track data with other time sequence tracks, find a target code of a next track point of the same track point code in the two time sequence tracks, and calculate a longitude and latitude distance before the target code is converted; when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information; traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating the intersection information to obtain an intersection point set to be selected.
The aggregation module 30 is further configured to obtain a square grid area determined according to the number of coding bits in the intersection point set to be selected; and aggregating the same intersection which repeatedly occupies the grid area or falls into a plurality of grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
The steps implemented by each functional module of the road network intersection extraction device may refer to each embodiment of the road network intersection extraction method of the present invention, and are not described herein again.
Furthermore, an embodiment of the present invention further provides a storage medium, where a road network intersection extraction program is stored on the storage medium, and when executed by a processor, the road network intersection extraction program implements the following operations:
carrying out code conversion on the vehicle travel track data to obtain track point codes;
acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information;
and aggregating the intersection point sets to be selected, and recoding to obtain an intersection output code.
Further, the road network intersection extraction program when executed by the processor further realizes the following operations:
obtaining historical vehicle track data through a calculation engine;
and filtering the boundary-crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
Further, the road network intersection extraction program, when executed by the processor, further implements the following operations:
historical vehicle trajectory data was obtained by spark sql query from hive or spark streaming consumption Kafka data.
Further, the road network intersection extraction program, when executed by the processor, further implements the following operations:
and taking the track data which does not exceed the preset track length in the historical vehicle track data as boundary crossing data, and removing and filtering the boundary crossing data from the historical vehicle track data to obtain filtered vehicle travel track data.
Further, the road network intersection extraction program, when executed by the processor, further implements the following operations:
and performing geohash coding conversion on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain track point codes.
Further, the road network intersection extraction program, when executed by the processor, further implements the following operations:
comparing each time sequence track in the vehicle travel track data with other time sequence tracks, searching a target code of a next track point of the same track point code in the two time sequence tracks, and calculating a longitude and latitude distance before the target code is converted;
when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information;
and traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating each intersection information to obtain an intersection point set to be selected.
Further, the road network intersection extraction program, when executed by the processor, further implements the following operations:
acquiring a grid area determined according to the number of coding bits in the intersection point set to be selected;
and aggregating the same intersection which repeatedly occupies the square grid area or falls into a plurality of square grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
According to the scheme, the track point codes are obtained by performing code conversion on the vehicle travel track data; acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information; the intersection point set to be selected is aggregated and recoded to obtain intersection output codes, the number of track points can be greatly reduced, the calculated amount is greatly reduced, the road intersection points can be updated according to the newly added track in real time, the method is good in real-time performance, simple in logic and easy to realize, the urban road network data acquisition efficiency and accuracy are improved, and the road network intersection point extraction speed and efficiency are improved.
It should be noted that, in this document, the terms "comprises," "comprising," or any other variation thereof, are intended to cover a non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements does not include only those elements but may include other elements not expressly listed or inherent to such process, method, article, or apparatus. Without further limitation, an element defined by the phrase "comprising an … …" does not exclude the presence of other like elements in a process, method, article, or apparatus that comprises the element.
The above-mentioned serial numbers of the embodiments of the present invention are merely for description and do not represent the merits of the embodiments.
The above description is only a preferred embodiment of the present invention, and not intended to limit the scope of the present invention, and all modifications of equivalent structures and equivalent processes, which are made by using the contents of the present specification and the accompanying drawings, or directly or indirectly applied to other related technical fields, are included in the scope of the present invention.

Claims (10)

1. A road network intersection extraction method is characterized by comprising the following steps:
carrying out code conversion on the vehicle travel track data to obtain track point codes;
acquiring intersection information of the track according to the track point codes, and generating an intersection point set to be selected according to the intersection information;
and aggregating the intersection point sets to be selected, and recoding to obtain the intersection output codes.
2. The road network intersection extraction method according to claim 1, wherein before said transcoding vehicle travel trajectory data to obtain track point codes, said road network intersection extraction method further comprises:
obtaining historical vehicle track data through a calculation engine;
and filtering the boundary-crossing data in the historical vehicle track data to obtain filtered vehicle travel track data.
3. The road network intersection extraction method of claim 2, wherein said obtaining historical vehicle trajectory data by a computational engine comprises:
historical vehicle trajectory data is obtained by querying from hive through spark ksql or consuming Kafka data through spark streaming.
4. The road network intersection extraction method according to claim 2, wherein said filtering out border-crossing data in said historical vehicle trajectory data to obtain filtered vehicle travel trajectory data comprises:
and taking the track data which does not exceed the preset track length in the historical vehicle track data as boundary crossing data, and removing and filtering the boundary crossing data from the historical vehicle track data to obtain filtered vehicle travel track data.
5. The road network intersection extraction method according to claim 1, wherein said transcoding the vehicle travel trajectory data to obtain track point codes comprises:
and performing geohash coding conversion on the longitude and latitude of the time sequence track points in the vehicle travel track data to obtain track point codes.
6. The road network intersection extraction method according to claim 1, wherein the acquiring intersection information of the track according to the track point codes and generating an intersection point set to be selected according to the intersection information comprises:
comparing each time sequence track in the vehicle travel track data with other time sequence tracks, searching a target code of a next track point of the same track point code in the two time sequence tracks, and calculating a longitude and latitude distance before the target code is converted;
when the longitude and latitude distance exceeds a preset distance threshold value, the course angle changes of two corresponding vehicles are inconsistent, and any vehicle has a deceleration behavior, the longitude and latitude information of the track point corresponding to the same track point code is used as intersection information;
and traversing each time sequence track in the vehicle travel track data, obtaining each intersection information of each time sequence track and other time sequence tracks, and integrating each intersection information to obtain an intersection point set to be selected.
7. The road network intersection extraction method according to claim 1, wherein said aggregating the intersection point set to be selected and recoding to obtain an intersection output code comprises:
acquiring a grid area determined according to the number of coding bits in the intersection point set to be selected;
and aggregating the same intersection which repeatedly occupies the square grid area or falls into a plurality of square grid areas in the intersection point set to be selected, and recoding the intersection track points in the aggregated result to obtain the intersection output codes.
8. A road network intersection extraction device, characterized by comprising:
the conversion module is used for carrying out code conversion on the vehicle travel track data to obtain track point codes;
the set generation module is used for acquiring intersection information of the track according to the track point codes and generating an intersection point set to be selected according to the intersection information;
and the aggregation module is used for aggregating the intersection point set to be selected and recoding to obtain the intersection output code.
9. A road network intersection extraction apparatus, characterized by comprising: memory, processor and road network intersection extraction program stored on said memory and operable on said processor, said road network intersection extraction program being configured to implement the steps of the road network intersection extraction method according to any of claims 1 to 7.
10. A storage medium having stored thereon a road network intersection extraction program, the road network intersection extraction program when executed by a processor implementing the steps of the road network intersection extraction method according to any one of claims 1 to 7.
CN202210599556.1A 2022-05-30 2022-05-30 Road network intersection extraction method, device, equipment and storage medium Pending CN114996380A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210599556.1A CN114996380A (en) 2022-05-30 2022-05-30 Road network intersection extraction method, device, equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210599556.1A CN114996380A (en) 2022-05-30 2022-05-30 Road network intersection extraction method, device, equipment and storage medium

Publications (1)

Publication Number Publication Date
CN114996380A true CN114996380A (en) 2022-09-02

Family

ID=83029027

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210599556.1A Pending CN114996380A (en) 2022-05-30 2022-05-30 Road network intersection extraction method, device, equipment and storage medium

Country Status (1)

Country Link
CN (1) CN114996380A (en)

Similar Documents

Publication Publication Date Title
CN108959466B (en) Taxi passenger carrying hot spot visualization method and system based on BCS-DBSCAN
EP3719716A1 (en) Machine learning system for classifying an area as vehicle way
CN104050817B (en) Speed limiting information base generation and speed limiting information detection method and system
CN112015835B (en) Geohash compressed map matching method
US11335191B2 (en) Intelligent telematics system for defining road networks
US11341846B2 (en) Traffic analytics system for defining road networks
CN104331422A (en) Road section type presumption method
CN104422451A (en) Road recognition method and road recognition apparatus
US11335189B2 (en) Method for defining road networks
CN110807552B (en) Urban electric bus driving condition construction method based on improved K-means
WO2021236006A1 (en) Route deviation quantification and vehicular route learning based thereon
CN112579921B (en) Track indexing and query method and system based on inverted sorting index and prefix tree
CN111046049A (en) Truck GPS track data compression method
CN111178577A (en) Service station site selection method based on GEOHASH algorithm
CN112215427A (en) Vehicle driving track reconstruction method and system under condition of bayonet data loss
CN108022006B (en) Data-driven accessibility probability and region generation method
CN111008255A (en) Method and device for identifying violation location, electronic equipment and storage medium
CN116824868B (en) Method, device, equipment and medium for identifying illegal parking points and predicting congestion of vehicles
CN114996380A (en) Road network intersection extraction method, device, equipment and storage medium
CN111444286A (en) Long-distance traffic node relevance mining method based on trajectory data
CN108596381B (en) Urban parking demand prediction method based on OD data
CN115662124A (en) GPS track data road section flow matching method based on network coding
CN108346299B (en) Vehicle speed evaluation method and device
CN106649341B (en) Data processing method and device
EP3922947A2 (en) Traffic analytics system for defining road networks

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination