CN110428631A - Determine the method and device for the public transit vehicle that user takes - Google Patents

Determine the method and device for the public transit vehicle that user takes Download PDF

Info

Publication number
CN110428631A
CN110428631A CN201910938465.4A CN201910938465A CN110428631A CN 110428631 A CN110428631 A CN 110428631A CN 201910938465 A CN201910938465 A CN 201910938465A CN 110428631 A CN110428631 A CN 110428631A
Authority
CN
China
Prior art keywords
vehicle
user
alternative
gps
preset threshold
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.)
Granted
Application number
CN201910938465.4A
Other languages
Chinese (zh)
Other versions
CN110428631B (en
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.)
Wuhan Yuanguang Technology Co Ltd
Original Assignee
Wuhan Yuanguang Technology 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 Wuhan Yuanguang Technology Co Ltd filed Critical Wuhan Yuanguang Technology Co Ltd
Priority to CN201910938465.4A priority Critical patent/CN110428631B/en
Publication of CN110428631A publication Critical patent/CN110428631A/en
Application granted granted Critical
Publication of CN110428631B publication Critical patent/CN110428631B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Classifications

    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • G08G1/0125Traffic data processing
    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/01Detecting movement of traffic to be counted or controlled
    • G08G1/0104Measuring and analyzing of parameters relative to traffic conditions
    • G08G1/0137Measuring and analyzing of parameters relative to traffic conditions for specific applications
    • GPHYSICS
    • G08SIGNALLING
    • G08GTRAFFIC CONTROL SYSTEMS
    • G08G1/00Traffic control systems for road vehicles
    • G08G1/123Traffic control systems for road vehicles indicating the position of vehicles, e.g. scheduled vehicles; Managing passenger vehicles circulating according to a fixed timetable, e.g. buses, trains, trams
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information
    • H04W4/023Services making use of location information using mutual or relative location information between multiple location based services [LBS] targets or of distance thresholds
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/02Services making use of location information
    • H04W4/029Location-based management or tracking services
    • HELECTRICITY
    • H04ELECTRIC COMMUNICATION TECHNIQUE
    • H04WWIRELESS COMMUNICATION NETWORKS
    • H04W4/00Services specially adapted for wireless communication networks; Facilities therefor
    • H04W4/30Services specially adapted for particular environments, situations or purposes
    • H04W4/40Services specially adapted for particular environments, situations or purposes for vehicles, e.g. vehicle-to-pedestrians [V2P]

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Signal Processing (AREA)
  • Chemical & Material Sciences (AREA)
  • Analytical Chemistry (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Traffic Control Systems (AREA)

Abstract

The present invention provides a kind of method and device of public transit vehicle that determining user takes, and method includes: the route for obtaining the public transit vehicle that user takes, and obtains the public transit vehicle of all operations on route;The set of all alternative vehicles is alternatively gathered the public transit vehicle of the corresponding operation of distance less than the first preset threshold alternately vehicle by the distance between public transit vehicle and the user for calculating each operation as vehicle;Judge that vehicle whether there is unique alternative the distance between vehicle and user less than the second preset threshold in alternatively gathering, and vehicle alternatively gather in the distance between other alternative vehicles in addition to unique alternative vehicle and user be all larger than or be equal to third predetermined threshold value, if so, the public transit vehicle that unique alternative vehicle is taken as user;Wherein, third predetermined threshold value is greater than the second preset threshold.The present invention can automatically determine the public transit vehicle of user's seating, and robustness is high, and universality is strong.

Description

Method and device for determining public transport vehicle taken by user
Technical Field
The invention belongs to the technical field of intelligent transportation, and particularly relates to a method and a device for determining a public transport vehicle taken by a user.
Background
In many scenarios of bus-related operations, it is often necessary to know which bus the user is riding. For example, complaints of users about buses are processed, the users lose things on the buses, or friends in the same row appoint to take the same bus at different bus-boarding stations for going out, and the like.
Currently, there is no method for automatically determining whether a user is riding a vehicle, and generally, the user is required to input the riding vehicle by himself or select the riding vehicle by the user from a vehicle list. In addition, a possible technical scheme is that a vehicle taken by a user is determined through data of card swiping on the bus, but due to the existence of a data island, card swiping data of the user is difficult to obtain in many scenes, and most bus card swiping data are not uploaded to a server in real time. In addition, due to the diversity of bus payment modes, if the user adopts cash payment and does not have card swiping information, the bus taken by the user cannot be determined.
In conclusion, the license plate number of the bus is input in a manual mode, the operation of a user is needed, time and labor are wasted, the user is likely to forget or remember by mistake, and the user is also required to get off to check the license plate number when forgetting; information islands exist in the card swiping data, and the user riding vehicle data cannot be acquired in a cash payment mode.
Disclosure of Invention
In order to overcome the problems of time and labor waste, high error probability and low universality of the existing method for determining the bus taken by the user or at least partially solve the problems, the embodiment of the invention provides a method and a device for determining the bus taken by the user.
According to a first aspect of embodiments of the present invention, there is provided a method of determining a public transport vehicle in which a user is riding, comprising:
the method comprises the steps of obtaining a route of a public transport vehicle taken by a user, and obtaining all operated public transport vehicles on the route;
calculating the distance between each operated public transport vehicle and the user, taking the operated public transport vehicles corresponding to the distance smaller than a first preset threshold value as alternative vehicles, and taking the set of all the alternative vehicles as a vehicle alternative set;
judging whether the distance between a unique candidate vehicle and the user is smaller than a second preset threshold value or not in the vehicle candidate set, and judging whether the distances between other candidate vehicles except the unique candidate vehicle in the vehicle candidate set and the user are larger than or equal to a third preset threshold value or not, if so, taking the unique candidate vehicle as a bus vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold.
According to a second aspect of the embodiments of the present invention, there is provided an apparatus for determining a public transportation vehicle taken by a user, including:
the system comprises an acquisition module, a display module and a control module, wherein the acquisition module is used for acquiring a route of the public transport vehicles taken by a user and acquiring all operated public transport vehicles on the route;
the calculation module is used for calculating the distance between each operated public transport vehicle and the user, taking the operated public transport vehicle corresponding to the distance smaller than a first preset threshold value as an alternative vehicle, and taking the set of all the alternative vehicles as a vehicle alternative set;
the determining module is used for judging whether the distance between the user and a unique candidate vehicle exists in the vehicle candidate set or not, and the distances between the user and other candidate vehicles in the vehicle candidate set except the unique candidate vehicle are larger than or equal to a third preset threshold, if yes, the unique candidate vehicle is taken as a public transport vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold.
According to a third aspect of the embodiments of the present invention, there is also provided an electronic device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, where the processor invokes the program instructions to perform the method for determining a public transportation vehicle occupied by a user provided in any one of the various possible implementations of the first aspect.
According to a fourth aspect of embodiments of the present invention, there is also provided a non-transitory computer readable storage medium storing computer instructions for causing a computer to perform a method of determining a public transportation vehicle occupied by a user as provided in any one of the various possible implementations of the first aspect.
The embodiment of the invention provides a method and a device for determining a bus taken by a user, wherein the method comprises the steps of acquiring a route of the bus taken by the user when the user takes the bus, acquiring all operated buses on the route, screening out alternative vehicles according to the distance between the user and each operated bus, and taking a unique alternative vehicle as the bus taken by the user if the distance between the unique alternative vehicle and the user is smaller than a second preset threshold value and the distances between other alternative vehicles and the user are larger than or equal to a third preset threshold value.
Drawings
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.
Fig. 1 is a schematic overall flow chart of a method for determining a public transport vehicle taken by a user according to an embodiment of the present invention;
fig. 2 is a schematic overall structure diagram of an apparatus for determining a public transportation vehicle taken by a user according to an embodiment of the present invention;
fig. 3 is a schematic view of an overall structure of an electronic device according to an embodiment of the present invention.
Detailed Description
In order to more clearly illustrate the embodiments of the present invention or the technical solutions in the prior art, the drawings used in the description of the embodiments or the prior art will be briefly described below, and it is obvious that the drawings in the following description are some embodiments of the present invention, and those skilled in the art can also obtain other drawings according to the drawings without creative efforts.
In an embodiment of the present invention, a method for determining a bus taken by a user is provided, and fig. 1 is an overall flowchart of the method for determining a bus taken by a user according to the embodiment of the present invention, where the method includes: s101, acquiring a route of a public transport vehicle taken by a user, and acquiring all operated public transport vehicles on the route;
the route of the public transportation vehicle taken by the user can be acquired in various ways. One method may be selected by user input, as the user generally knows the route of the bus he/she is taking; and the other method can also calculate the route of the bus taken by the user through the GPS data of the client uploaded by the client of the user. The present embodiment is not limited to these two ways. The client of the user can be a smart phone, the smart phone is very popular, and the smart phone is provided with a GPS data positioning function. When a user takes a bus, GPS data of the user client side is collected through a GPS data positioning function. Then according to the line L of the public transport vehicles taken by the user1Screening out the line L1And all the operated buses are started.
S102, calculating the distance between each operated public transport vehicle and the user, taking the operated public transport vehicles corresponding to the distance smaller than a first preset threshold value as alternative vehicles, and taking the set of all the alternative vehicles as a vehicle alternative set;
the distance between each operating public transport vehicle and the user is calculated. For any one operated bus, the distance between the operated bus and the user can be calculated according to the latest GPS (Global Positioning System) data of each operated bus and the latest GPS data of the client of the user. The client of the user and the operated public transport vehicles upload GPS data in real time, namely the GPS data of the client and the operated public transport vehicles can be collected in real time. And acquiring an operation public transport vehicle which is less than a first preset threshold value d from the user, wherein if d is 1000 meters. And taking the set of the operation public transport vehicles which are less than a first preset threshold value from the user as a vehicle alternative set. Namely the alternative vehicle set U = { < license plate number 1, gps1, time1>, < license plate number 2, gps2, time2>, … }. The license plate number 1 represents the license plate number of a first operation bus, the GPS1 represents the GPS data of the first operation bus, the time1 represents the GPS data acquisition time of the first operation bus, the license plate number 2 represents the license plate number of a second operation bus, the GPS2 represents the GPS data of the second operation bus, and the time2 represents the GPS data acquisition time of the second operation bus.
S103, judging whether the distance between the user and a unique candidate vehicle exists in the vehicle candidate set or not, wherein the distance between the user and other candidate vehicles except the unique candidate vehicle in the vehicle candidate set is smaller than a second preset threshold value, and the distance between the user and other candidate vehicles except the unique candidate vehicle in the vehicle candidate set is larger than or equal to a third preset threshold value, and if yes, taking the unique candidate vehicle as a bus vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold.
And judging whether the distance between the unique candidate vehicle and the user is smaller than a second preset threshold value minDis according to the distance between each candidate vehicle in the vehicle candidate set and the user, wherein if the distance between the unique candidate vehicle and the user is smaller than the second preset threshold value minDis, the distance between other candidate vehicles and the user is larger than or equal to a third preset threshold value. Preferably, the third preset threshold is 2 minDis. And if so, taking the only alternative vehicle with the distance to the user being less than minDis as the bus vehicle taken by the user, and quitting the execution. And determining the bus vehicle taken by the user according to the license plate number of the unique candidate vehicle in the vehicle candidate set.
In the embodiment, GPS data of a user client is acquired through a GPS positioning function, and then the GPS data of the public transport vehicle is combined, so that the relative relation and displacement condition of the user position and the vehicle position are judged by the two types of data of the user, whether the user is on a certain public transport vehicle or not is determined, and the public transport vehicle taken by the user is determined. The user client-side GPS data, the bus GPS data and the corresponding bus license plate number can be given when the user takes the bus, and the bus taking the user can be judged.
According to the method and the device, when the user takes the bus, the route of the bus taken by the user is obtained, all operated buses on the route are obtained, the alternative vehicles are screened out according to the distance between the user and each operated bus, if the distance between the unique alternative vehicle and the user is smaller than a second preset threshold value, and the distances between other alternative vehicles and the user are larger than or equal to a third preset threshold value, the unique alternative vehicle is used as the bus taken by the user.
On the basis of the foregoing embodiment, in this embodiment, after the step of taking the operated bus corresponding to the distance smaller than the first preset threshold as the candidate vehicle, the method further includes: calculating a difference between the GPS data update time of the client of the user and the GPS data update time of each alternative vehicle; corresponding to any one of the alternative vehicles, dividing the distance between the alternative vehicle and the user by the difference value to obtain the running speed of the alternative vehicle; and if the running speed of the candidate vehicle is not within the preset speed range, deleting the candidate vehicle from the vehicle candidate set.
The updating frequency of the GPS data of the user client is generally less than 30 seconds, and the updating frequency of the public transport vehicle is generally less than 15 seconds/time. For any candidate vehicle in the vehicle candidate set U, the distance between the candidate vehicle and the user is obtained S1, the time difference t1 of the GPS data update of the user client and the candidate vehicle is calculated, namely the time of the GPS data update of the user client-the time of the GPS data update of the candidate vehicle, and the running speed v = S1/t1 of the candidate vehicle is estimated. If v is not within the preset speed range, the vehicle is deleted from the vehicle candidate set. The preset speed range is set according to the reasonable speed range of the bus.
On the basis of the foregoing embodiment, in this embodiment, the step of determining whether the distance between the user and the only candidate vehicle in the vehicle candidate set is smaller than a second preset threshold, and the distances between the user and the other candidate vehicles in the vehicle candidate set except the only candidate vehicle are greater than or equal to a third preset threshold further includes: if the distance between a plurality of or no alternative vehicles in the vehicle alternative set and the user is smaller than a second preset threshold value, continuously acquiring the GPS data of the client of the user and the GPS data of each alternative vehicle;
if a plurality of candidate vehicles or no candidate vehicle is within the range from the user minDis, the riding vehicle of the user cannot be determined temporarily, the GPS data updated after the user client and the GPS data updated after each candidate vehicle are continuously acquired, and the riding vehicle of the user is judged by using more GPS data.
For any alternative vehicle, if the difference value between the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle is smaller than a fourth preset threshold value, constructing a GPS pair according to the current GPS data of the client, the latest GPS data of the alternative vehicle, the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle, and adding the GPS pair into a GPS pair list corresponding to the alternative vehicle;
for any alternative vehicle, if the difference between the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle is less than a fourth preset threshold t2, a GPS pair < the current GPS data of the client, the latest GPS data of the alternative vehicle, the current GPS data acquisition time of the client, the latest GPS data acquisition time of the alternative vehicle > is constructed, and the GPS pair is added to the GPS pair list corresponding to the alternative vehicle. For each candidate vehicle in the vehicle candidate set U, a LIST of GPS pairs is maintained, and the GPS pair of each candidate vehicle is added to the corresponding LIST of GPS pairs LIST.
If a plurality of GPS pairs exist in the GPS pair list, selecting a preset number of recently added GPS pairs from the GPS pair list; calculating the distance between the user and the alternative vehicle according to the selected GPS pairs, and calculating the moving distance of the user according to the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the earliest and the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the latest; and judging whether the distance between the user and the alternative vehicle is smaller than the second preset threshold value and whether the moving distance of the user is larger than a fifth preset threshold value, and if so, determining that the user takes the alternative vehicle.
For any alternative vehicle, if a plurality of GPS pairs, such as three or more, exist in the candidate vehicle's GPS pair list, a preset number of GPS pairs, such as three, that have recently been added are selected from the candidate vehicle's GPS pair list. And calculating the distance between the user and each alternative vehicle in the selected GPS pair according to the GPS data of the client in the selected GPS pair and the GPS data of the alternative vehicles. And calculating the moving distance of the user according to the GPS data of the client terminal of the GPS pair which is added in the earliest time in the selected GPS pair and the GPS data of the client terminal of the GPS pair which is added in the latest time in the selected GPS pair. If the preset number is 3, calculating the moving distance of the user according to the GPS data of the client of the first joined GPS pair and the GPS data of the client of the third joined GPS pair in the 3 GPS pairs. And if the distance between the user and each candidate vehicle in each selected GPS pair is smaller than the second preset threshold value minDis, and the moving distance of the user is larger than a fifth preset threshold value d2, determining that the user takes the candidate vehicle. d2 may take 200 to 500 meters. Execution then exits.
And constructing a GPS pair and adding the GPS pair into a GPS pair list every time the user client updates GPS data, and then judging until the bus taken by the user is judged.
In another embodiment of the present invention, an apparatus for determining a public transportation vehicle taken by a user is provided, and the apparatus is used for implementing the method in the foregoing embodiments. Therefore, the description and definition in the embodiments of the method for determining the public transportation vehicle taken by the user can be used for understanding the execution modules in the embodiments of the present invention. Fig. 2 is a schematic overall structure diagram of an apparatus for determining a public transportation vehicle taken by a user according to an embodiment of the present invention, where the apparatus includes an obtaining module 201, a calculating module 202, and a determining module 203, where:
the acquisition module 201 is configured to acquire a route of a bus taken by a user, and acquire all operated buses on the route;
the acquisition module 201 may acquire the route of the public transportation vehicle taken by the user in various ways. One method may be selected by user input, as the user generally knows the route of the bus he/she is taking; and the other method can also calculate the route of the bus taken by the user through the GPS data of the client uploaded by the client of the user. The present embodiment is not limited to these two ways. The client of the user can be a smart phone, the smart phone is very popular, and the smart phone is provided with a GPS data positioning function. When a user takes a bus, GPS data of the user client side is collected through a GPS data positioning function. Then, the obtaining module 201 screens out all the operated buses on the route according to the route of the buses taken by the user.
The calculating module 202 is configured to calculate a distance between each operated bus and the user, use the operated bus corresponding to the distance smaller than a first preset threshold as an alternative vehicle, and use a set of all the alternative vehicles as a vehicle alternative set;
the calculation module 202 calculates the distance between each operating public transport vehicle and the user. For any one bus in operation, the distance between the bus in operation and the user can be calculated according to the latest GPS data of each bus in operation and the latest GPS data of the client of the user. The client of the user and the operated public transport vehicles upload GPS data in real time, namely the GPS data of the client and the operated public transport vehicles can be collected in real time. And acquiring the operation public transport vehicles which are less than a first preset threshold value from the user. And taking the set of the operation public transport vehicles which are less than a first preset threshold value from the user as a vehicle alternative set.
The determining module 203 is configured to determine whether a distance between a unique candidate vehicle and the user in the vehicle candidate set is smaller than a second preset threshold, and distances between other candidate vehicles in the vehicle candidate set except the unique candidate vehicle and the user are both greater than or equal to a third preset threshold, and if yes, use the unique candidate vehicle as a bus vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold.
The determining module 203 determines whether the distance between the unique vehicle candidate and the user is smaller than a second preset threshold and the distances between the other vehicle candidates and the user are greater than or equal to a third preset threshold according to the distance between each vehicle candidate in the vehicle candidate set and the user. And if the alternative vehicles exist, taking the only alternative vehicles with the distance to the user smaller than a second preset threshold value as the buses taken by the user, and quitting the execution. And determining the bus vehicle taken by the user according to the license plate number of the unique candidate vehicle in the vehicle candidate set.
According to the method and the device, when the user takes the bus, the route of the bus taken by the user is obtained, all operated buses on the route are obtained, the alternative vehicles are screened out according to the distance between the user and each operated bus, if the distance between the unique alternative vehicle and the user is smaller than a second preset threshold value, and the distances between other alternative vehicles and the user are larger than or equal to a third preset threshold value, the unique alternative vehicle is used as the bus taken by the user.
On the basis of the foregoing embodiment, the obtaining module of this embodiment is specifically configured to: and determining the route of the bus taken by the user according to the GPS data of the client uploaded by the client of the user.
On the basis of the foregoing embodiment, the calculating module in this embodiment is specifically configured to: and calculating the distance between each operated bus and the user according to the latest GPS data of each operated bus and the latest GPS data of the client of the user.
On the basis of the above embodiment, the present embodiment further includes a deletion module, configured to calculate a difference between the GPS data update time of the client of the user and the GPS data update time of each candidate vehicle; corresponding to any one of the alternative vehicles, dividing the distance between the alternative vehicle and the user by the difference value to obtain the running speed of the alternative vehicle; and if the running speed of the candidate vehicle is not within the preset speed range, deleting the candidate vehicle from the vehicle candidate set.
On the basis of the foregoing embodiments, in this embodiment, the determining module is further configured to: if the distance between a plurality of or no alternative vehicles in the vehicle alternative set and the user is smaller than a second preset threshold value, continuously acquiring the GPS data of the client of the user and the GPS data of each alternative vehicle; for any alternative vehicle, if the difference value between the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle is smaller than a fourth preset threshold value, constructing a GPS pair according to the current GPS data of the client, the latest GPS data of the alternative vehicle, the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle, and adding the GPS pair into a GPS pair list corresponding to the alternative vehicle; if a plurality of GPS pairs exist in the GPS pair list, selecting a preset number of recently added GPS pairs from the GPS pair list; calculating the distance between the user and the alternative vehicle according to the selected GPS pairs, and calculating the moving distance of the user according to the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the earliest and the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the latest; and judging whether the distance between the user and the alternative vehicle is smaller than the second preset threshold value and whether the moving distance of the user is larger than a fifth preset threshold value, and if so, determining that the user takes the alternative vehicle.
On the basis of the above embodiment, in this embodiment, the third preset threshold is twice the second preset threshold.
The embodiment provides an electronic device, and fig. 3 is a schematic view of an overall structure of the electronic device according to the embodiment of the present invention, where the electronic device includes: at least one processor 301, at least one memory 302, and a bus 303; wherein,
the processor 301 and the memory 302 are communicated with each other through a bus 303;
the memory 302 stores program instructions executable by the processor 301, and the processor calls the program instructions to perform the methods provided by the above method embodiments, for example, the method includes: acquiring a route of a public transport vehicle taken by a user, and acquiring all operated public transport vehicles on the route; calculating the distance between each operated public transport vehicle and a user, taking the operated public transport vehicle corresponding to the distance smaller than a first preset threshold value as an alternative vehicle, and taking the set of all the alternative vehicles as a vehicle alternative set; judging whether the distance between the unique candidate vehicle and the user is smaller than a second preset threshold value or not in the vehicle candidate set, and judging whether the distances between other candidate vehicles except the unique candidate vehicle in the vehicle candidate set and the user are larger than or equal to a third preset threshold value or not, if so, taking the unique candidate vehicle as a public transport vehicle taken by the user; and the third preset threshold is greater than the second preset threshold.
The present embodiments provide a non-transitory computer-readable storage medium storing computer instructions that cause a computer to perform the methods provided by the above method embodiments, for example, including: acquiring a route of a public transport vehicle taken by a user, and acquiring all operated public transport vehicles on the route; calculating the distance between each operated public transport vehicle and a user, taking the operated public transport vehicle corresponding to the distance smaller than a first preset threshold value as an alternative vehicle, and taking the set of all the alternative vehicles as a vehicle alternative set; judging whether the distance between the unique candidate vehicle and the user is smaller than a second preset threshold value or not in the vehicle candidate set, and judging whether the distances between other candidate vehicles except the unique candidate vehicle in the vehicle candidate set and the user are larger than or equal to a third preset threshold value or not, if so, taking the unique candidate vehicle as a public transport vehicle taken by the user; and the third preset threshold is greater than the second preset threshold.
Those of ordinary skill in the art will understand that: all or part of the steps for implementing the method embodiments may be implemented by hardware related to program instructions, and the program may be stored in a computer readable storage medium, and when executed, the program performs the steps including the method embodiments; and the aforementioned storage medium includes: various media that can store program codes, such as ROM, RAM, magnetic or optical disks.
The above-described embodiments of the apparatus are merely illustrative, and the units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the modules may be selected according to actual needs to achieve the purpose of the solution of the present embodiment. One of ordinary skill in the art can understand and implement it without inventive effort.
Through the above description of the embodiments, those skilled in the art will clearly understand that each embodiment can be implemented by software plus a necessary general hardware platform, and certainly can also be implemented by hardware. With this understanding in mind, the above-described technical solutions may be embodied in the form of a software product, which can be stored in a computer-readable storage medium such as ROM/RAM, magnetic disk, optical disk, etc., and includes instructions for causing a computer device (which may be a personal computer, a server, or a network device, etc.) to execute the methods described in the embodiments or some parts of the embodiments.
Finally, it should be noted that: the above examples are only intended to illustrate the technical solution of the present invention, but not to limit it; although the present invention has been described in detail with reference to the foregoing embodiments, it will be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present invention.

Claims (9)

1. A method of determining a public transportation vehicle in which a user is traveling, comprising:
the method comprises the steps of obtaining a route of a public transport vehicle taken by a user, and obtaining all operated public transport vehicles on the route;
calculating the distance between each operated public transport vehicle and the user, taking the operated public transport vehicles corresponding to the distance smaller than a first preset threshold value as alternative vehicles, and taking the set of all the alternative vehicles as a vehicle alternative set;
calculating a difference between the GPS data update time of the client of the user and the GPS data update time of each alternative vehicle;
corresponding to any one of the alternative vehicles, dividing the distance between the alternative vehicle and the user by the difference value to obtain the running speed of the alternative vehicle;
if the running speed of the alternative vehicle is not within the preset speed range, deleting the alternative vehicle from the vehicle alternative set;
judging whether the distance between a unique candidate vehicle and the user is smaller than a second preset threshold value or not in the vehicle candidate set, and judging whether the distances between other candidate vehicles except the unique candidate vehicle in the vehicle candidate set and the user are larger than or equal to a third preset threshold value or not, if so, taking the unique candidate vehicle as a bus vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold.
2. The method according to claim 1, wherein the step of obtaining the route of the public transport vehicle taken by the user specifically comprises:
and determining the route of the bus taken by the user according to the GPS data of the client uploaded by the client of the user.
3. The method according to claim 1, wherein the step of calculating the distance between each of said operated buses and said user comprises:
and calculating the distance between each operated bus and the user according to the latest GPS data of each operated bus and the latest GPS data of the client of the user.
4. The method for determining the buses in which the user takes according to any one of claims 1 to 3, wherein the step of determining whether the distance between the user and a unique candidate vehicle in the vehicle candidate set is smaller than a second preset threshold, and the distances between the user and other candidate vehicles in the vehicle candidate set except the unique candidate vehicle are larger than or equal to a third preset threshold further comprises:
if the distance between a plurality of or no alternative vehicles in the vehicle alternative set and the user is smaller than a second preset threshold value, continuously acquiring the GPS data of the client of the user and the GPS data of each alternative vehicle;
for any alternative vehicle, if the difference value between the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle is smaller than a fourth preset threshold value, constructing a GPS pair according to the current GPS data of the client, the latest GPS data of the alternative vehicle, the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle, and adding the GPS pair into a GPS pair list corresponding to the alternative vehicle;
if a plurality of GPS pairs exist in the GPS pair list, selecting a preset number of recently added GPS pairs from the GPS pair list;
calculating the distance between the user and the alternative vehicle according to the selected GPS pairs, and calculating the moving distance of the user according to the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the earliest and the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the latest;
and judging whether the distance between the user and the alternative vehicle is smaller than the second preset threshold value and whether the moving distance of the user is larger than a fifth preset threshold value, and if so, determining that the user takes the alternative vehicle.
5. The method of determining the transit vehicle the user is traveling on according to claim 4, wherein the third preset threshold is twice the second preset threshold.
6. An apparatus for determining a mass-transit vehicle in which a user is traveling, comprising:
the system comprises an acquisition module, a display module and a control module, wherein the acquisition module is used for acquiring a route of the public transport vehicles taken by a user and acquiring all operated public transport vehicles on the route;
the calculation module is used for calculating the distance between each operated public transport vehicle and the user, taking the operated public transport vehicle corresponding to the distance smaller than a first preset threshold value as an alternative vehicle, and taking the set of all the alternative vehicles as a vehicle alternative set;
the determining module is used for judging whether the distance between the user and a unique candidate vehicle exists in the vehicle candidate set or not, and the distances between the user and other candidate vehicles in the vehicle candidate set except the unique candidate vehicle are larger than or equal to a third preset threshold, if yes, the unique candidate vehicle is taken as a public transport vehicle taken by the user; wherein the third preset threshold is greater than the second preset threshold;
wherein, still include the deletion module, be used for:
calculating a difference between the GPS data update time of the client of the user and the GPS data update time of each alternative vehicle;
corresponding to any one of the alternative vehicles, dividing the distance between the alternative vehicle and the user by the difference value to obtain the running speed of the alternative vehicle;
and if the running speed of the candidate vehicle is not within the preset speed range, deleting the candidate vehicle from the vehicle candidate set.
7. The apparatus for determining the mass transit vehicle the user is traveling in of claim 6, wherein the determination module is further configured to:
if the distance between a plurality of or no alternative vehicles in the vehicle alternative set and the user is smaller than a second preset threshold value, continuously acquiring the GPS data of the client of the user and the GPS data of each alternative vehicle;
for any alternative vehicle, if the difference value between the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle is smaller than a fourth preset threshold value, constructing a GPS pair according to the current GPS data of the client, the latest GPS data of the alternative vehicle, the current GPS data acquisition time of the client and the latest GPS data acquisition time of the alternative vehicle, and adding the GPS pair into a GPS pair list corresponding to the alternative vehicle;
calculating the distance between the user and the alternative vehicle according to the selected GPS pairs, and calculating the moving distance of the user according to the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the earliest and the GPS data of the client side of the GPS pair which is added in the selected GPS pair at the latest;
and judging whether the distance between the user and the alternative vehicle is smaller than the second preset threshold value and whether the moving distance of the user is larger than a fifth preset threshold value, and if so, determining that the user takes the alternative vehicle.
8. An electronic device comprising a memory, a processor and a computer program stored on the memory and executable on the processor, wherein the steps of the method of determining a public transport vehicle occupied by a user according to any one of claims 1 to 5 are implemented when the program is executed by the processor.
9. A non-transitory computer readable storage medium having stored thereon a computer program, wherein the computer program, when being executed by a processor, is adapted to carry out the steps of the method of determining a public transportation vehicle being occupied by a user according to any one of claims 1 to 5.
CN201910938465.4A 2019-09-30 2019-09-30 Method and device for determining public transport vehicle taken by user Active CN110428631B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910938465.4A CN110428631B (en) 2019-09-30 2019-09-30 Method and device for determining public transport vehicle taken by user

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910938465.4A CN110428631B (en) 2019-09-30 2019-09-30 Method and device for determining public transport vehicle taken by user

Publications (2)

Publication Number Publication Date
CN110428631A true CN110428631A (en) 2019-11-08
CN110428631B CN110428631B (en) 2020-01-10

Family

ID=68419105

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910938465.4A Active CN110428631B (en) 2019-09-30 2019-09-30 Method and device for determining public transport vehicle taken by user

Country Status (1)

Country Link
CN (1) CN110428631B (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112509317A (en) * 2020-11-09 2021-03-16 广州交信投科技股份有限公司 Bus real-time arrival prediction method, device and equipment based on machine learning algorithm

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040172194A1 (en) * 2003-02-28 2004-09-02 Yazaki Corporation Running route acquiring system and arrival notifying system for touring bus
CN1649434A (en) * 2004-01-28 2005-08-03 日本电气株式会社 Passenger position informaton system, portable information terminal and server device
CN104064051A (en) * 2014-06-23 2014-09-24 银江股份有限公司 Locating information dynamic matching method for passenger portable mobile terminal and taken bus
CN106251629A (en) * 2016-09-30 2016-12-21 福建工程学院 Identify the method and system of bus driver and passenger
CN106297288A (en) * 2016-08-23 2017-01-04 同济大学 A kind of bus passenger passenger flow data gathers and the method for analysis
CN109313039A (en) * 2016-06-23 2019-02-05 微软技术许可有限责任公司 The deviation of the public transit route of detection and plan
CN110136469A (en) * 2019-06-06 2019-08-16 武汉元光科技有限公司 The compensation method of the running data of bus and device

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US20040172194A1 (en) * 2003-02-28 2004-09-02 Yazaki Corporation Running route acquiring system and arrival notifying system for touring bus
CN1649434A (en) * 2004-01-28 2005-08-03 日本电气株式会社 Passenger position informaton system, portable information terminal and server device
CN104064051A (en) * 2014-06-23 2014-09-24 银江股份有限公司 Locating information dynamic matching method for passenger portable mobile terminal and taken bus
CN109313039A (en) * 2016-06-23 2019-02-05 微软技术许可有限责任公司 The deviation of the public transit route of detection and plan
CN106297288A (en) * 2016-08-23 2017-01-04 同济大学 A kind of bus passenger passenger flow data gathers and the method for analysis
CN106251629A (en) * 2016-09-30 2016-12-21 福建工程学院 Identify the method and system of bus driver and passenger
CN110136469A (en) * 2019-06-06 2019-08-16 武汉元光科技有限公司 The compensation method of the running data of bus and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
胡继华 等: "结合出行链的公交IC 卡乘客下车站点判断概率模型", 《交通运输系统工程与信息》 *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112509317A (en) * 2020-11-09 2021-03-16 广州交信投科技股份有限公司 Bus real-time arrival prediction method, device and equipment based on machine learning algorithm
CN112509317B (en) * 2020-11-09 2021-11-09 广州交信投科技股份有限公司 Bus real-time arrival prediction method, device and equipment based on machine learning algorithm

Also Published As

Publication number Publication date
CN110428631B (en) 2020-01-10

Similar Documents

Publication Publication Date Title
CN108763538B (en) A kind of method and device in the geographical location determining point of interest POI
US20210174681A1 (en) Parking occupancy estimation
US8156076B2 (en) Terminal and data distribution system
US9959339B2 (en) Journey time estimation
US20190390971A1 (en) Determining cumulative estimated time for requested services
US11668576B2 (en) Using sensor data for coordinate prediction
CN109084797B (en) Navigation path recommendation method and device
US20240219187A1 (en) Indoor/outdoor transition points based on satellite signal strength
CN111861643A (en) Riding position recommendation method and device, electronic equipment and storage medium
CN111858790A (en) Detour reminding method and device, electronic equipment and medium
CN111768254A (en) Order processing method and device
JP6206337B2 (en) Information providing apparatus and information providing method
CN111476389A (en) Method and device for pre-estimating order receiving waiting time
CN110428631B (en) Method and device for determining public transport vehicle taken by user
CN113254771B (en) Bank outlet recommendation method and device
US10635764B2 (en) Method and device for providing vehicle navigation simulation environment
CN113112850A (en) Crowdsourcing navigation system and method
WO2011013245A1 (en) Position estimating device
CN111008729A (en) Migration prediction method and device
US10955251B2 (en) Identifying incorrect coordinate prediction using route information
JP6443967B2 (en) Area attribute estimation apparatus and area attribute estimation method
CN111815006B (en) Vehicle type recommendation method, storage medium and system
CN107122837B (en) Hotel reservation method and device
WO2021188039A1 (en) Method and processing apparatus for determining optimal pick-up/drop-off locations for transport services
CN117308984A (en) Vehicle driving path prediction method and storage medium

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
GR01 Patent grant
GR01 Patent grant
PE01 Entry into force of the registration of the contract for pledge of patent right
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: Method and device for determining the bus users take

Effective date of registration: 20210330

Granted publication date: 20200110

Pledgee: Guanggu Branch of Wuhan Rural Commercial Bank Co.,Ltd.

Pledgor: WUHAN YUANGUANG TECHNOLOGY Co.,Ltd.

Registration number: Y2021420000016

PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20220323

Granted publication date: 20200110

Pledgee: Guanggu Branch of Wuhan Rural Commercial Bank Co.,Ltd.

Pledgor: WUHAN YUANGUANG TECHNOLOGY Co.,Ltd.

Registration number: Y2021420000016

PC01 Cancellation of the registration of the contract for pledge of patent right
PE01 Entry into force of the registration of the contract for pledge of patent right

Denomination of invention: Method and device for determining user's bus

Effective date of registration: 20220329

Granted publication date: 20200110

Pledgee: Guanggu Branch of Wuhan Rural Commercial Bank Co.,Ltd.

Pledgor: WUHAN YUANGUANG TECHNOLOGY Co.,Ltd.

Registration number: Y2022420000087

PE01 Entry into force of the registration of the contract for pledge of patent right
PC01 Cancellation of the registration of the contract for pledge of patent right

Date of cancellation: 20230327

Granted publication date: 20200110

Pledgee: Guanggu Branch of Wuhan Rural Commercial Bank Co.,Ltd.

Pledgor: WUHAN YUANGUANG TECHNOLOGY Co.,Ltd.

Registration number: Y2022420000087

PC01 Cancellation of the registration of the contract for pledge of patent right