CN113670325A - Path deviation detection method and system and electronic equipment - Google Patents

Path deviation detection method and system and electronic equipment Download PDF

Info

Publication number
CN113670325A
CN113670325A CN202110958986.3A CN202110958986A CN113670325A CN 113670325 A CN113670325 A CN 113670325A CN 202110958986 A CN202110958986 A CN 202110958986A CN 113670325 A CN113670325 A CN 113670325A
Authority
CN
China
Prior art keywords
path
target
segmented
deviation threshold
equal
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
CN202110958986.3A
Other languages
Chinese (zh)
Other versions
CN113670325B (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.)
Unicom Intelligent Network Ruixing Technology Beijing Co Ltd
Original Assignee
Unicom Intelligent Network Ruixing Technology Beijing 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 Unicom Intelligent Network Ruixing Technology Beijing Co Ltd filed Critical Unicom Intelligent Network Ruixing Technology Beijing Co Ltd
Priority to CN202110958986.3A priority Critical patent/CN113670325B/en
Publication of CN113670325A publication Critical patent/CN113670325A/en
Application granted granted Critical
Publication of CN113670325B publication Critical patent/CN113670325B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G01MEASURING; TESTING
    • G01CMEASURING DISTANCES, LEVELS OR BEARINGS; SURVEYING; NAVIGATION; GYROSCOPIC INSTRUMENTS; PHOTOGRAMMETRY OR VIDEOGRAMMETRY
    • G01C21/00Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00
    • G01C21/26Navigation; Navigational instruments not provided for in groups G01C1/00 - G01C19/00 specially adapted for navigation in a road network
    • G01C21/34Route searching; Route guidance
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01BMEASURING LENGTH, THICKNESS OR SIMILAR LINEAR DIMENSIONS; MEASURING ANGLES; MEASURING AREAS; MEASURING IRREGULARITIES OF SURFACES OR CONTOURS
    • G01B21/00Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant
    • G01B21/02Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant for measuring length, width, or thickness
    • G01B21/04Measuring arrangements or details thereof, where the measuring technique is not covered by the other groups of this subclass, unspecified or not relevant for measuring length, width, or thickness by measuring coordinates of points
    • GPHYSICS
    • G01MEASURING; TESTING
    • G01SRADIO DIRECTION-FINDING; RADIO NAVIGATION; DETERMINING DISTANCE OR VELOCITY BY USE OF RADIO WAVES; LOCATING OR PRESENCE-DETECTING BY USE OF THE REFLECTION OR RERADIATION OF RADIO WAVES; ANALOGOUS ARRANGEMENTS USING OTHER WAVES
    • G01S19/00Satellite radio beacon positioning systems; Determining position, velocity or attitude using signals transmitted by such systems
    • G01S19/38Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system
    • G01S19/39Determining a navigation solution using signals transmitted by a satellite radio beacon positioning system the satellite radio beacon positioning system transmitting time-stamped messages, e.g. GPS [Global Positioning System], GLONASS [Global Orbiting Navigation Satellite System] or GALILEO
    • G01S19/42Determining position

Landscapes

  • Engineering & Computer Science (AREA)
  • Radar, Positioning & Navigation (AREA)
  • Remote Sensing (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Computer Networks & Wireless Communication (AREA)
  • Automation & Control Theory (AREA)
  • Navigation (AREA)

Abstract

The embodiment of the application provides a path deviation detection method, a system and electronic equipment, wherein the method comprises the following steps: acquiring a target position and a defined path, wherein the defined path comprises a plurality of segmented paths; respectively obtaining the distance between the target position and each segmented path; based on the distance, obtaining a detection result, wherein the detection result is used for indicating whether the target deviates from the defined path.

Description

Path deviation detection method and system and electronic equipment
Technical Field
The present disclosure relates to the field of path deviation detection technologies, and in particular, to a method and a system for detecting path deviation and an electronic device.
Background
In the transportation industry, for example, vehicles for transporting goods such as coal cars, etc., there is a demand for a driver to complete a transportation task according to a designated route in order to improve the transportation efficiency or prevent the driver from changing goods midway, etc., for example, passenger cars such as taxis or network appointment cars, for ensuring the safety of passengers or preventing the driver from going around a long way, etc., there is a demand for the driver to complete a trip task according to the designated route, etc. Therefore, how to detect whether the vehicle deviates from the specified route during traveling is one of the important means to meet the above requirements.
Disclosure of Invention
The application provides a path deviation detection method, a system and an electronic device, which can detect whether an object such as a vehicle deviates from a defined path.
In a first aspect, the present application provides a path deviation detecting method, including:
acquiring a target position and a defined path, wherein the defined path comprises a plurality of segmented paths;
respectively obtaining the distance between the target position and each segmented path;
based on the distance, obtaining a detection result, wherein the detection result is used for indicating whether the target deviates from the defined path.
In one possible implementation manner, the obtaining a detection result based on the distance includes:
determining whether the target deviates from the segmented path based on the distance;
if the target does not deviate from at least one of the segmented paths, outputting the first result, wherein the first result is used for indicating that the target does not deviate from the defined path;
and if the target deviates from all the segmented paths, outputting the second result, wherein the second result is used for indicating that the target deviates from the defined path.
In one possible implementation manner, the determining, based on the distance, whether the target deviates from the segment path includes:
comparing the first connection line, the second connection line and the third connection line to obtain a minimum number, a middle number and a maximum number;
determining that the target does not deviate from the segmented path if the sum of the minimum number and the intermediate number is less than or equal to the maximum number and the maximum number is the third connection.
In one possible implementation manner, the determining whether the target deviates from the segmented path based on the distance further includes:
if the sum of the minimum number and the intermediate number is less than or equal to the maximum number, and the maximum number is not the third connection line, determining whether the first connection line is less than or equal to a preset deviation threshold and whether the second connection line is less than or equal to a preset deviation threshold, if the first connection line is less than or equal to the preset deviation threshold and the second connection line is less than or equal to the preset deviation threshold, determining that the target does not deviate from the segmented path, and if the first connection line is greater than the preset deviation threshold or the second connection line is greater than the preset deviation threshold, determining that the target deviates from the segmented path.
In one possible implementation manner, the determining whether the target deviates from the segmented path based on the distance further includes:
if the sum of the minimum number and the middle number is larger than the maximum number, judging whether a first included angle between the first connecting line and the third connecting line and a second included angle between the second connecting line and the third connecting line are obtuse angles;
if at least one of the first included angle and the second included angle is an obtuse angle, judging whether the first connecting line is smaller than or equal to a preset deviation threshold value or not and whether the second connecting line is smaller than or equal to a preset deviation threshold value or not, if the first connecting line is smaller than or equal to the preset deviation threshold value and the second connecting line is smaller than or equal to the preset deviation threshold value, determining that the target does not deviate from the segmented path, and if the first connecting line is larger than the preset deviation threshold value or the second connecting line is larger than the preset deviation threshold value, determining that the target deviates from the segmented path;
if the first included angle and the second included angle are not obtuse angles, whether the minimum distance between the target point and the segmented path is smaller than or equal to a preset deviation threshold value or not is judged, if the minimum distance is smaller than or equal to the preset deviation threshold value, it is determined that the target does not deviate from the segmented path, and if the minimum distance is larger than the preset deviation threshold value, it is determined that the target deviates from the segmented path.
In one possible implementation manner, the obtaining the restricted path includes:
acquiring a starting point position and an end point position;
selecting a target route from a map according to the starting position and the end position, wherein the target route comprises a plurality of coordinate points;
and connecting the coordinate points in the target route to obtain a defined path, wherein a segmented path in the defined path is a connecting line between adjacent coordinate points.
In one possible implementation manner, the method further includes:
and if the detection result is that the target deviates from the limited path, outputting deviation prompt information.
In a second aspect, the present application provides a path deviation detecting system, which establishes a connection with a vehicle-mounted terminal, the path deviation detecting system comprising a gateway, a message queue, a processing unit, and an executing device, wherein,
the gateway is used for receiving positioning information sent by the vehicle-mounted terminal and sending the positioning information to the message queue, wherein the positioning information comprises a vehicle position;
the message queue is used for storing the positioning information sent by the gateway;
the processing unit is configured to obtain the positioning information from the message queue, execute the method according to the first aspect, and output a detection result to the execution device;
and the execution device is used for controlling the detection result output by the processing unit to execute corresponding operation.
In a third aspect, the present application provides an electronic device, comprising:
one or more processors; a memory; and one or more computer programs, wherein the one or more computer programs are stored in the memory, the one or more computer programs comprising instructions which, when executed by the apparatus, cause the apparatus to perform the method of the first aspect.
In a fourth aspect, the present application provides a computer readable storage medium having stored thereon a computer program which, when run on a computer, causes the computer to perform the method according to the first aspect.
In a fifth aspect, the present application provides a computer program for performing the method of the first aspect when the computer program is executed by a computer.
In a possible design, the program of the fifth aspect may be stored in whole or in part on a storage medium packaged with the processor, or in part or in whole on a memory not packaged with the processor.
Drawings
FIG. 1 is a schematic diagram of a method for detecting a deviation in a path according to an embodiment of the present invention;
FIG. 2 is a schematic diagram of an embodiment of a deviation path detection system according to the present application;
FIG. 3 is a schematic diagram of a map showing a defined route in a map according to an embodiment of the deviation detection method for a route of the present application;
FIG. 4 is a schematic flow chart illustrating a process of determining whether a target deviates from a restricted path according to an embodiment of the method for detecting a deviation of a path of the present application;
FIG. 5 is a schematic flow chart illustrating a process of determining whether a target deviates from a segmented path according to an embodiment of the method for detecting a path deviation of the present application;
fig. 6 is a schematic structural diagram of an embodiment of an electronic device according to the present application.
Detailed Description
The terminology used in the description of the embodiments section of the present application is for the purpose of describing particular embodiments of the present application only and is not intended to be limiting of the present application.
The path deviation detection method of one embodiment shown in fig. 1 is applied to a path deviation detection system, the path deviation detection system is connected with a vehicle-mounted terminal, the vehicle-mounted terminal is mounted on a vehicle, the vehicle-mounted terminal acquires positioning information of the vehicle through a positioning module (such as GPS/Beidou satellite positioning) during power-on operation, and then continuously transmits the positioning information to the path deviation detection system through a network (such as a 3G, 4G or 5G network), for example, the vehicle-mounted terminal acquires current positioning information of the vehicle every 30 seconds and uploads the current positioning information to the path deviation detection system. The path deviation detection system is used for executing a path deviation detection method to detect whether a vehicle deviates from a limited path (or a designated path, a route and the like) in the driving process, and if the vehicle deviates from the limited path in the driving process, the path deviation system can timely send prompt information such as alarm and the like to inform related personnel, so as to improve the transportation efficiency or avoid the driver exchanging goods in the midway, or ensure the safety of passengers or avoid the driver from detouring the way.
In this embodiment, as shown in fig. 2, the path deviation detecting system may include a gateway, a message queue, a processing unit, and an execution device, which are electrically connected to each other to implement path deviation detection.
The gateway is in communication connection with the vehicle-mounted terminal and is used for receiving the positioning information sent by the vehicle-mounted terminal and sending the positioning information to the message queue. After receiving the positioning information (or data packet) reported by the vehicle-mounted terminal, the gateway analyzes the positioning information (or data packet) according to a specific data transmission protocol, for example, the positioning information is identified by 16-system bits, and the data transmission protocol defines the data content represented by different 16-system bits, including a reporting instruction ID corresponding to the data packet, a specific data field value and the like. The parsed positioning information (or data packet) format is encapsulated according to a gateway and processing unit protocol format, such as JSON format, and a field in the positioning information may include vehicle identification such as license plate number, serial number, ID (deviceId, string type), whether the positioning information is supplementary transmission data (real, string type), communication time (string type), vehicle acc state (accStatus, int type), positioning time (string type), direction (direction, int type), positioning position or coordinate, latitude (latitude, double type), longitude (longitude, double type), speed (speed, double type), satellite number (stages, int type), mileage (mileage, double type), oil consumption (oil, double type), voltage (intake, double type), engine speed (engine rpm, int type), engine temperature (terminal type), terminal time (terminal time), string type), and ignition time such as last ignition time (last ignition time, double type), etc., and the fields in the analyzed positioning information are protocol fields.
And the message queue is used for storing the positioning information sent by the gateway. Because the positioning information of the vehicle-mounted terminal is reported frequently, and when the number of the vehicle-mounted terminals is large, the requirement on the concurrent processing performance of the processing unit is high, the gateway sends the positioning information of the vehicle-mounted terminal to the message queue, the data queue waits for processing, and the positioning information of the vehicle-mounted terminal is obtained from the message queue according to the actual consumption capacity of the processing unit and is processed, so that the processing pressure of the processing unit is relieved. In addition, the message queue can store data in a certain period in a persistent mode, even if the processing unit goes down or has other faults, the unprocessed data in the message queue cannot be lost, and after the processing unit is recovered to be normal, the processing unit can continue to process the data from the break point, so that data loss is avoided. Preferably, the message queue may include middleware such as Kafka, RabbitMQ, ActiveMQ, and the like.
And the processing unit is used for acquiring the positioning information from the message queue, executing the path deviation detection method and outputting a detection result to the executing device, wherein the detection result can be used for indicating whether the vehicle deviates from the defined path or not, or indicating the position or the coordinates of the vehicle when the vehicle deviates from the defined path and the like.
Further, the path deviation detection system may further include a non-relational database and a relational database, the path deviation detection system further includes a non-relational database and a relational database, the non-relational database is configured to store the positioning information, and the relational database is configured to store the path deviation detection result.
Specifically, the processing unit periodically acquires the reported positioning information through message queuing and stores the reported positioning information into the non-relational database. Because the reporting frequency of the positioning information is high and the data volume is large, compared with a relational database, the embodiment of the invention adopts a non-relational database to store the positioning information, and has the advantages of high read-write performance, strong horizontal expansion capability of data stored in a Key-Value form, no upper limit of a storage space and the like, and the non-relational database is, for example, MongoDB and the like. Because the relevance between the path deviation detection result of the vehicle and the service is strong (for example, the user can view the path deviation detection result of the specified vehicle, etc.), and the data format is fixed, a relational database such as Mysql, Oracle, etc. is selected to store the path deviation detection result of the vehicle.
And the execution device is used for controlling the detection result output by the processing unit to execute corresponding operation. For example, the executing device is an alarm device, and if the detection result is that the vehicle deviates from the defined path, the alarm device executes an alarm operation, such as sounding an alarm, to prompt the relevant person. The execution device is used for displaying the path deviation detection result of the vehicle, such as whether the position of the vehicle deviates from the defined path or not, or the position or the coordinate when the vehicle deviates from the defined path, and the like, by utilizing the map interface on the browser map.
It is understood that the executing device may also perform other operations according to the detection result output by the processing unit, for example, if the vehicle is an unmanned vehicle, when the detection result is that the vehicle deviates from the defined path, the executing device sends a control instruction to the vehicle-mounted terminal of the vehicle to control the vehicle to return to the defined path or stop running, so as to improve traffic efficiency or guarantee safety, and the like, without limitation herein.
Further, the path deviation detection method executed by the processing unit specifically refers to the path deviation detection method of the method embodiment shown in fig. 1.
Fig. 1 is a flowchart of an embodiment of a method for detecting a path deviation according to the present application, and as shown in fig. 1, the method for detecting a path deviation may include:
s101, acquiring a target position and a defined path, wherein the defined path comprises a plurality of segmented paths.
Preferably, the target position may include a positioning position or coordinates of the vehicle, for example, the vehicle-mounted terminal uploads current positioning information of the vehicle, which includes the target position, to the route deviation detection system at regular intervals.
In some alternative embodiments, the location information may comprise location information that is retransmitted. That is to say, in the process of disconnecting the vehicle-mounted terminal from the route deviation detection system, the vehicle-mounted terminal cannot upload the current positioning information to the route deviation detection system, the vehicle-mounted terminal stores the current positioning information in the vehicle-mounted terminal or a vehicle memory, after the vehicle-mounted terminal is in communication connection with the route deviation detection system again, the vehicle-mounted terminal supplements the positioning information stored in the memory to the route deviation detection system, and the supplemented positioning information includes the target position.
As shown in fig. 3, the limited route is used to indicate a designated route, or the like, and may be determined based on the start point position and the end point position of the vehicle, or may be set by a person, or the like. For example, the route deviation detection system may further include an input device for receiving user input information, and related personnel may add, change or delete a limited route on a browser map through the input device, which is highly applicable.
In one possible implementation manner, step S101 may include:
s201, acquiring a starting point position and an end point position;
s202, selecting a target route from a map according to the starting position and the end position, wherein the target route comprises a plurality of coordinate points;
s203, connecting the coordinate points in the target route to obtain a defined path, wherein a segmented path in the defined path is a connecting line between adjacent coordinate points.
The start point position and the end point position are used to indicate a start point (or a departure point) and an end point (or a destination) of the vehicle in the driving task, which may be manually input.
In step S202, a plurality of selectable driving routes may be displayed in the map according to the starting point position and the ending point position, and a target route is selected from the plurality of selectable driving routes by using a selection method such as a shortest driving route, a shortest driving time, or manual selection, and a plurality of coordinate points, such as longitude and latitude coordinate points, are acquired from the target route along an extending direction of the target route by using a preset route or distance.
In step S203, preferably, each adjacent coordinate point is connected by a straight line, so as to obtain a plurality of straight line segments, where the straight line segments are segment paths, two end points of each straight line segment are a start point and an end point of each segment path, respectively, and an entire line segment formed by connecting the plurality of straight line segments is a defined path, that is, adjacent segment paths in the defined path are connected end to end. It is understood that the length of the straight line segment may be determined according to the size of the preset route or distance, so that the defined path is substantially overlapped or consistent with the target route, and the like, so as to improve the detection accuracy.
In some other optional embodiments, the target route is defined as a defined path, the target route is segmented by a preset distance or distance along the extending direction of the target route to obtain a plurality of segmented paths, and the coordinate point for segmenting is the starting point or the ending point of the segmented path.
S102, respectively obtaining the distance between the target position and each segmented path.
Preferably, the distance between the target position and the segment path may include a first connection line between the target position and the start point of the segment path, a second connection line between the target position and the end point of the segment path, and a third connection line between the start point of the segment path and the end point of the segment path. The first link may be used to indicate a distance, such as a straight distance, between the target position and the start point of the piecewise path, the second link may be used to indicate a distance, such as a straight distance, between the target position and the end point of the piecewise path, and the third link may be used to indicate a distance, such as a straight distance, between the start point of the piecewise path and the end point of the piecewise path, or an extended length or course of the piecewise path.
Further, the distance between the target position and the segmented path may further include a minimum distance (e.g., a vertical distance, etc.) or a maximum distance, etc. between the target position and the segmented path.
S103, obtaining a detection result based on the distance, wherein the detection result is used for indicating whether the target deviates from the defined path.
In this embodiment, the detection result may include a first result and a second result, the first result being used for indicating that the target does not deviate from the defined path, and the second result being used for indicating that the target deviates from the defined path.
In one possible implementation manner, as shown in fig. 4, step S103 may include:
s301, judging whether the target deviates from the segmented path or not based on the distance;
s302, if the target does not deviate from at least one segmented path, outputting the first result;
s303, if the target deviates from all the segmented paths, outputting the second result.
For example, if the minimum distance between the target position and at least one of the segment paths is less than or equal to a preset deviation threshold, it is determined that the target does not deviate from the segment path, and a first result is output, and if the minimum distance between the target position and all the segment paths is greater than the preset deviation threshold, it is determined that the target deviates from all the segment paths, and a second result is output.
In some optional embodiments, step S103 may include: the method comprises the steps of selecting a target segmented path with the minimum distance (such as the minimum distance) to a target position from a plurality of segmented paths in a limited path, judging whether a target deviates from the target segmented path or not (such as judging whether the minimum distance is smaller than or equal to a preset deviation threshold value or not) based on the distance between the target segmented path and the target position, outputting a first result if the target deviates from the target segmented path, and outputting a second result if the target does not deviate from the target segmented path, so that the method is beneficial to reducing the calculation amount and shortening the detection time.
In one possible implementation manner, as shown in fig. 5, the determining whether the target deviates from the segmented path (or the target segmented path) in step S103 based on the distance includes:
s401, comparing the first connection line, the second connection line and the third connection line to obtain a minimum number, a middle number and a maximum number;
s402, if the sum of the minimum number and the intermediate number is less than or equal to the maximum number, and the maximum number is the third connecting line, determining that the target does not deviate from the segmented path.
That is, a first link is defined as a, a second link is defined as b, a third link is defined as c, the minimum number is m1, the intermediate number is m2, and the maximum number is m3, and if m1+ m2 ≦ m3 and m3 ≦ c, it indicates that the target position is within the piecewise path or infinitely close to the piecewise path, it is determined that the target is not deviated from the piecewise path.
In one possible implementation manner, in step S103, determining whether the target deviates from the segmented path (or the target segmented path) based on the distance further includes:
s403, if the sum of the minimum number and the middle number is less than or equal to the maximum number, and the maximum number is not the third connection line, determining whether the first connection line is less than or equal to a preset deviation threshold and whether the second connection line is less than or equal to a preset deviation threshold, if the first connection line is less than or equal to the preset deviation threshold and the second connection line is less than or equal to the preset deviation threshold, determining that the target does not deviate from the segment path, and if the first connection line is greater than the preset deviation threshold or the second connection line is greater than the preset deviation threshold, determining that the target deviates from the segment path.
That is, if m1+ m2 ≦ m3, and m3 ≠ c, it means that the target position is on or infinitely close to the extension line of the piecewise path, so if a ≦ d (d is a preset deviation threshold), and b ≦ d, it is determined that the target is not deviated from the piecewise path, and if a > d, or b > d, it is determined that the target is deviated from the piecewise path.
In one possible implementation manner, in step S103, determining whether the target deviates from the segmented path (or the target segmented path) based on the distance further includes:
s404, if the sum of the minimum number and the intermediate number is larger than the maximum number, judging whether a first included angle between the first connecting line and the third connecting line and a second included angle between the second connecting line and the third connecting line are obtuse angles;
s405, if at least one of the first included angle and the second included angle is an obtuse angle, judging whether the first connection line is smaller than or equal to a preset deviation threshold value or not and whether the second connection line is smaller than or equal to a preset deviation threshold value or not, if the first connection line is smaller than or equal to the preset deviation threshold value and the second connection line is smaller than or equal to the preset deviation threshold value, determining that the target does not deviate from the segmented path, and if the first connection line is larger than the preset deviation threshold value or the second connection line is larger than the preset deviation threshold value, determining that the target deviates from the segmented path;
s406, if the first included angle and the second included angle are not obtuse angles, judging whether the minimum distance between the target point and the segmented path is smaller than or equal to a preset deviation threshold, if the minimum distance is smaller than or equal to the preset deviation threshold, determining that the target does not deviate from the segmented path, and if the minimum distance is larger than the preset deviation threshold, determining that the target deviates from the segmented path.
That is, if m1+ m2 > m3, it means that the first, second and third connecting lines a, B and c form a triangle, and a first angle between the first and third connecting lines a and c is defined as a, and a second angle between the second and third connecting lines B and c is defined as B.
Preferably, in step S404, a is determined according to the formula R ═ a2+b2-c2And calculating to obtain R, if R is less than or equal to 0, determining that the first included angle A or the second included angle B is an acute angle or a right angle, namely that neither the first included angle A nor the second included angle B is an obtuse angle, and if R is more than 0, determining that at least one of the first included angle A or the second included angle B is an obtuse angle.
Optionally, in step S404, if the first included angle a is less than or equal to 90 ° and the second included angle B is less than or equal to 90 °, it is determined that the first included angle a or the second included angle B is an acute angle or a right angle, and if the first included angle a is greater than 90 ° or the second included angle B is greater than 90 °, it is determined that at least one of the first included angle a or the second included angle B is an obtuse angle.
It should be understood by those skilled in the art that the manner of determining whether the first included angle a and the second included angle B are obtuse angles is not limited to the manner set forth in the present embodiment, and is not limited thereto.
In step S405, in the case that at least one of the first included angle A or the second included angle B is an obtuse angle, if a is not greater than d (d is a preset deviation threshold) and B is not greater than d, it is determined that the target does not deviate from the piecewise path, and if a > d or B > d, it is determined that the target deviates from the piecewise path.
In step S406, a minimum distance between the target position and the segment path is defined as h, and if the first included angle a or the second included angle B is not an obtuse angle, it is determined that the target does not deviate from the segment path if the minimum distance h is not greater than d, and if h > d, it is determined that the target deviates from the segment path.
It is understood that in the case that neither the first angle a nor the second angle B is an obtuse angle, the minimum distance h between the target position and the segmented path can be expressed as the vertical distance between the target position and the segmented path, or the height of the third line c of the triangle, and the minimum distance h is expressed by the helron equation:
triangle perimeter p ═ a + b + c)/2
Area of triangle
Figure BDA0003221460290000091
The minimum distance h is calculated as 2S/c.
In one possible implementation manner, the method may further include:
and S104, if the detection result is that the target deviates from the limited path, outputting deviation prompt information.
That is, deviation-prompting information may be used to prompt a deviation of the target from the defined path. For example, the deviation prompt message may include an audio alarm or a light alarm, and if the detection result is that the target deviates from the defined path, an alarm device may send an audio alarm, or a light alarm (e.g., flashing red light) may be sent by the lighting device. Further, if the detection result shows that the target does not deviate from the limited path, outputting non-deviation prompt information, such as that the alarm device does not give out an audible alarm or the lighting equipment emits green light.
Further, deviation prompt information may be displayed through an interactive interface such as a browser, and the deviation prompt information may include a target position (or a positioning position or coordinates, etc.) when the target deviates from the defined path. For example, a user may enter a designated vehicle (e.g., a license plate number) on a browser to see on a browser map whether the location of the vehicle deviates from a defined path, or the location or coordinates of the vehicle when deviating from the defined path, etc., to facilitate vehicle management.
It is to be understood that some or all of the steps or operations in the above-described embodiments are merely examples, and other operations or variations of various operations may be performed by the embodiments of the present application. Further, the various steps may be performed in a different order presented in the above-described embodiments, and it is possible that not all of the operations in the above-described embodiments are performed.
It should be understood that the division of the modules of the path deviation detecting system shown in fig. 2 is only a logical division, and the actual implementation may be wholly or partially integrated into one physical entity or may be physically separated. And these modules can be realized in the form of software called by processing element; or may be implemented entirely in hardware; and part of the modules can be realized in the form of calling by the processing element in software, and part of the modules can be realized in the form of hardware. For example, the processing unit may be a separate processing element, or may be integrated into a chip of the electronic device. Other modules are implemented similarly. In addition, all or part of the modules can be integrated together or can be independently realized. In implementation, each step of the above method or each module above may be implemented by an integrated logic circuit of hardware in a processor element or an instruction in the form of software.
For example, the above modules may be one or more integrated circuits configured to implement the above methods, such as: one or more Application Specific Integrated Circuits (ASICs), one or more microprocessors (DSPs), one or more Field Programmable Gate Arrays (FPGAs), etc. For another example, these modules may be integrated together and implemented in the form of a System-On-a-Chip (SOC).
Fig. 6 is a schematic structural diagram of an embodiment of an electronic device of the present application, and as shown in fig. 6, the electronic device may include: one or more processors; a memory; and one or more computer programs.
The electronic device may be an intelligent terminal such as a mobile phone, a computer, a server, a path deviation detection device, and the like.
Wherein the one or more computer programs are stored in the memory, the one or more computer programs comprising instructions which, when executed by the apparatus, cause the apparatus to perform the steps of:
acquiring a target position and a defined path, wherein the defined path comprises a plurality of segmented paths;
respectively obtaining the distance between the target position and each segmented path;
based on the distance, obtaining a detection result, wherein the detection result is used for indicating whether the target deviates from the defined path.
In one possible implementation manner, the obtaining the detection result includes a first result and a second result, and when the instruction is executed by the apparatus, the apparatus is caused to perform the obtaining the detection result based on the distance, including:
determining whether the target deviates from the segmented path based on the distance;
if the target does not deviate from at least one of the segmented paths, outputting the first result, wherein the first result is used for indicating that the target does not deviate from the defined path;
and if the target deviates from all the segmented paths, outputting the second result, wherein the second result is used for indicating that the target deviates from the defined path.
In one possible implementation manner, the determining, by the apparatus, whether the target deviates from the segment path based on the distance includes:
comparing the first connection line, the second connection line and the third connection line to obtain a minimum number, a middle number and a maximum number;
determining that the target does not deviate from the segmented path if the sum of the minimum number and the intermediate number is less than or equal to the maximum number and the maximum number is the third connection.
In one possible implementation manner, when the instructions are executed by the apparatus, the apparatus is caused to perform the determining whether the target deviates from the segmented path based on the distance, and the method further includes:
if the sum of the minimum number and the intermediate number is less than or equal to the maximum number, and the maximum number is not the third connection line, determining whether the first connection line is less than or equal to a preset deviation threshold and whether the second connection line is less than or equal to a preset deviation threshold, if the first connection line is less than or equal to the preset deviation threshold and the second connection line is less than or equal to the preset deviation threshold, determining that the target does not deviate from the segmented path, and if the first connection line is greater than the preset deviation threshold or the second connection line is greater than the preset deviation threshold, determining that the target deviates from the segmented path.
In one possible implementation manner, when the instructions are executed by the apparatus, the apparatus is caused to perform the determining whether the target deviates from the segmented path based on the distance, and the method further includes:
if the sum of the minimum number and the middle number is larger than the maximum number, judging whether a first included angle between the first connecting line and the third connecting line and a second included angle between the second connecting line and the third connecting line are obtuse angles;
if at least one of the first included angle and the second included angle is an obtuse angle, judging whether the first connecting line is smaller than or equal to a preset deviation threshold value or not and whether the second connecting line is smaller than or equal to a preset deviation threshold value or not, if the first connecting line is smaller than or equal to the preset deviation threshold value and the second connecting line is smaller than or equal to the preset deviation threshold value, determining that the target does not deviate from the segmented path, and if the first connecting line is larger than the preset deviation threshold value or the second connecting line is larger than the preset deviation threshold value, determining that the target deviates from the segmented path;
if the first included angle and the second included angle are not obtuse angles, whether the minimum distance between the target point and the segmented path is smaller than or equal to a preset deviation threshold value or not is judged, if the minimum distance is smaller than or equal to the preset deviation threshold value, it is determined that the target does not deviate from the segmented path, and if the minimum distance is larger than the preset deviation threshold value, it is determined that the target deviates from the segmented path.
In one possible implementation manner, when the instruction is executed by the apparatus, the apparatus is caused to execute the acquiring a restricted path, including:
acquiring a starting point position and an end point position;
selecting a target route from a map according to the starting position and the end position, wherein the target route comprises a plurality of coordinate points;
and connecting the coordinate points in the target route to obtain a defined path, wherein a segmented path in the defined path is a connecting line between adjacent coordinate points.
In one possible implementation manner, when the instruction is executed by the apparatus, the apparatus is further caused to perform:
and if the detection result is that the target deviates from the limited path, outputting deviation prompt information.
The electronic device shown in fig. 6 may be a terminal device or a circuit device built in the terminal device. The apparatus may be used to perform the functions/steps of the method provided by the embodiment of fig. 1 of the present application.
As shown in fig. 6, the electronic device 900 includes a processor 910 and a memory 920. Wherein, the processor 910 and the memory 920 can communicate with each other through the internal connection path to transmit control and/or data signals, the memory 920 is used for storing computer programs, and the processor 910 is used for calling and running the computer programs from the memory 920.
The memory 920 may be a read-only memory (ROM), other types of static storage devices that can store static information and instructions, a Random Access Memory (RAM), or other types of dynamic storage devices that can store information and instructions, an electrically erasable programmable read-only memory (EEPROM), a compact disc read-only memory (CD-ROM) or other optical disc storage, optical disc storage (including compact disc, laser disc, optical disc, digital versatile disc, blu-ray disc, etc.), magnetic disc storage media or other magnetic storage devices, or any other medium that can be used to carry or store desired program code in the form of instructions or data structures and that can be accessed by a computer, etc.
The processor 910 and the memory 920 may be combined into a processing device, and more generally, independent components, and the processor 910 is configured to execute the program codes stored in the memory 920 to realize the functions. In particular implementations, the memory 920 may be integrated with the processor 910 or may be separate from the processor 910.
It should be appreciated that the electronic device 900 shown in fig. 6 is capable of implementing the processes of the methods provided by the embodiments shown in fig. 1 of the present application. The operations and/or functions of the respective modules in the electronic device 900 are respectively for implementing the corresponding flows in the above-described method embodiments. Reference may be made specifically to the description of the embodiment of the method illustrated in fig. 1 of the present application, and a detailed description is appropriately omitted herein to avoid redundancy.
It should be understood that the processor 910 in the electronic device 900 shown in fig. 6 may be a system on chip SOC, and the processor 910 may include a Central Processing Unit (CPU), and may further include other types of processors, such as: an image Processing Unit (hereinafter, referred to as GPU), and the like.
In summary, various portions of the processors or processing units within the processor 910 may cooperate to implement the foregoing method flows, and corresponding software programs for the various portions of the processors or processing units may be stored in the memory 930.
The application also provides an electronic device, the device includes a storage medium and a central processing unit, the storage medium may be a non-volatile storage medium, a computer executable program is stored in the storage medium, and the central processing unit is connected with the non-volatile storage medium and executes the computer executable program to implement the method provided by the embodiment shown in fig. 1 of the application.
In the above embodiments, the processors may include, for example, a CPU, a DSP, a microcontroller, or a digital Signal processor, and may further include a GPU, an embedded Neural Network Processor (NPU), and an Image Signal Processing (ISP), and the processors may further include necessary hardware accelerators or logic Processing hardware circuits, such as an ASIC, or one or more integrated circuits for controlling the execution of the program according to the technical solution of the present application. Further, the processor may have the functionality to operate one or more software programs, which may be stored in the storage medium.
Embodiments of the present application further provide a computer-readable storage medium, in which a computer program is stored, and when the computer program runs on a computer, the computer is enabled to execute the method provided by the embodiment shown in fig. 1 of the present application.
Embodiments of the present application also provide a computer program product, which includes a computer program, when the computer program runs on a computer, causing the computer to execute the method provided by the embodiment shown in fig. 1 of the present application.
In the embodiments of the present application, "at least one" means one or more, "a plurality" means two or more. "and/or" describes the association relationship of the associated objects, and means that there may be three relationships, for example, a and/or B, and may mean that a exists alone, a and B exist simultaneously, and B exists alone. Wherein A and B can be singular or plural. The character "/" generally indicates that the former and latter associated objects are in an "or" relationship. "at least one of the following" and similar expressions refer to any combination of these items, including any combination of singular or plural items. For example, at least one of a, b, and c may represent: a, b, c, a and b, a and c, b and c or a and b and c, wherein a, b and c can be single or multiple.
Those of ordinary skill in the art will appreciate that the various elements and algorithm steps described in connection with the embodiments disclosed herein can be implemented as electronic hardware, computer software, or combinations of electronic hardware. Whether such functionality is implemented as hardware or software depends upon the particular application and design constraints imposed on the implementation. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present application.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, any function, if implemented in the form of a software functional unit and sold or used as a separate product, may be stored in a computer readable storage medium. Based on such understanding, the technical solution of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product stored in a storage medium and including instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute all or part of the steps of the method according to the embodiments of the present application. And the aforementioned storage medium includes: a U disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk or an optical disk, and other various media capable of storing program codes.
The above description is only for the specific embodiments of the present application, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present disclosure, and all the changes or substitutions should be covered by the protection scope of the present application. The protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. A method of path deviation detection, the method comprising:
acquiring a target position and a defined path, wherein the defined path comprises a plurality of segmented paths;
respectively obtaining the distance between the target position and each segmented path;
based on the distance, obtaining a detection result, wherein the detection result is used for indicating whether the target deviates from the defined path.
2. The method of claim 1, wherein the detecting results comprise a first result and a second result, and wherein obtaining the detecting results based on the distance comprises:
determining whether the target deviates from the segmented path based on the distance;
if the target does not deviate from at least one of the segmented paths, outputting the first result, wherein the first result is used for indicating that the target does not deviate from the defined path;
and if the target deviates from all the segmented paths, outputting the second result, wherein the second result is used for indicating that the target deviates from the defined path.
3. The method of claim 2, wherein the distance comprises a first connection of the target location to a start point of the segment path, a second connection of the target location to an end point of the segment path, and a third connection of the start point of the segment path to the end point of the segment path, and wherein determining whether the target deviates from the segment path based on the distance comprises:
comparing the first connection line, the second connection line and the third connection line to obtain a minimum number, a middle number and a maximum number;
determining that the target does not deviate from the segmented path if the sum of the minimum number and the intermediate number is less than or equal to the maximum number and the maximum number is the third connection.
4. The method of claim 3, wherein said determining whether the target deviates from the segmented path based on the distance further comprises:
if the sum of the minimum number and the intermediate number is less than or equal to the maximum number, and the maximum number is not the third connection line, determining whether the first connection line is less than or equal to a preset deviation threshold and whether the second connection line is less than or equal to a preset deviation threshold, if the first connection line is less than or equal to the preset deviation threshold and the second connection line is less than or equal to the preset deviation threshold, determining that the target does not deviate from the segmented path, and if the first connection line is greater than the preset deviation threshold or the second connection line is greater than the preset deviation threshold, determining that the target deviates from the segmented path.
5. The method of claim 3, wherein said determining whether the target deviates from the segmented path based on the distance further comprises:
if the sum of the minimum number and the middle number is larger than the maximum number, judging whether a first included angle between the first connecting line and the third connecting line and a second included angle between the second connecting line and the third connecting line are obtuse angles;
if at least one of the first included angle and the second included angle is an obtuse angle, judging whether the first connecting line is smaller than or equal to a preset deviation threshold value or not and whether the second connecting line is smaller than or equal to a preset deviation threshold value or not, if the first connecting line is smaller than or equal to the preset deviation threshold value and the second connecting line is smaller than or equal to the preset deviation threshold value, determining that the target does not deviate from the segmented path, and if the first connecting line is larger than the preset deviation threshold value or the second connecting line is larger than the preset deviation threshold value, determining that the target deviates from the segmented path;
if the first included angle and the second included angle are not obtuse angles, whether the minimum distance between the target point and the segmented path is smaller than or equal to a preset deviation threshold value or not is judged, if the minimum distance is smaller than or equal to the preset deviation threshold value, it is determined that the target does not deviate from the segmented path, and if the minimum distance is larger than the preset deviation threshold value, it is determined that the target deviates from the segmented path.
6. The method of claim 1, wherein the obtaining a defined path comprises:
acquiring a starting point position and an end point position;
selecting a target route from a map according to the starting position and the end position, wherein the target route comprises a plurality of coordinate points;
and connecting the coordinate points in the target route to obtain a defined path, wherein a segmented path in the defined path is a connecting line between adjacent coordinate points.
7. The method according to any one of claims 1 to 6, further comprising:
and if the detection result is that the target deviates from the limited path, outputting deviation prompt information.
8. A path deviation detection system, which establishes a connection with a vehicle-mounted terminal, is characterized by comprising a gateway, a message queue, a processing unit and an execution device, wherein,
the gateway is used for receiving positioning information sent by the vehicle-mounted terminal and sending the positioning information to the message queue, wherein the positioning information comprises a vehicle position;
the message queue is used for storing the positioning information sent by the gateway;
the processing unit is used for acquiring the positioning information from the message queue, executing the method according to any one of claims 1 to 7, and outputting a detection result to the executing device;
and the execution device is used for controlling the detection result output by the processing unit to execute corresponding operation.
9. An electronic device, comprising:
one or more processors; a memory; and one or more computer programs, wherein the one or more computer programs are stored in the memory, the one or more computer programs comprising instructions which, when executed by the apparatus, cause the apparatus to perform the method of any of claims 1-7.
10. A computer-readable storage medium, in which a computer program is stored which, when run on a computer, causes the computer to carry out the method according to any one of claims 1 to 7.
CN202110958986.3A 2021-08-20 2021-08-20 Path deviation detection method and system and electronic equipment Active CN113670325B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202110958986.3A CN113670325B (en) 2021-08-20 2021-08-20 Path deviation detection method and system and electronic equipment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202110958986.3A CN113670325B (en) 2021-08-20 2021-08-20 Path deviation detection method and system and electronic equipment

Publications (2)

Publication Number Publication Date
CN113670325A true CN113670325A (en) 2021-11-19
CN113670325B CN113670325B (en) 2024-07-02

Family

ID=78544364

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202110958986.3A Active CN113670325B (en) 2021-08-20 2021-08-20 Path deviation detection method and system and electronic equipment

Country Status (1)

Country Link
CN (1) CN113670325B (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN116935656A (en) * 2023-09-18 2023-10-24 浙江中控信息产业股份有限公司 Road traffic data processing method and device, electronic equipment and storage medium
CN117029851A (en) * 2023-07-31 2023-11-10 赛马物联科技(宁夏)有限公司 Freight vehicle driving auxiliary system and method

Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103185593A (en) * 2011-12-30 2013-07-03 上海博泰悦臻电子设备制造有限公司 Navigation method and navigation device
CN103185597A (en) * 2011-12-30 2013-07-03 上海博泰悦臻电子设备制造有限公司 Navigation method and navigation apparatus
WO2016090781A1 (en) * 2014-12-12 2016-06-16 中兴通讯股份有限公司 Positioning and navigating method, device and system
US20180238697A1 (en) * 2017-02-22 2018-08-23 Clarion Co., Ltd. Navigation device, route search server, and route search method
CN108922173A (en) * 2018-06-20 2018-11-30 青岛海信网络科技股份有限公司 A kind of vehicle deviation detection method and device
CN109443370A (en) * 2018-09-13 2019-03-08 中通国脉物联科技南京有限公司 A method of deviate detection track
CN110986980A (en) * 2019-11-28 2020-04-10 北京百度网讯科技有限公司 Planned route detection method and device and electronic equipment
CN112991806A (en) * 2021-02-18 2021-06-18 安徽中科美络信息技术有限公司 Vehicle track monitoring method and device

Patent Citations (8)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103185593A (en) * 2011-12-30 2013-07-03 上海博泰悦臻电子设备制造有限公司 Navigation method and navigation device
CN103185597A (en) * 2011-12-30 2013-07-03 上海博泰悦臻电子设备制造有限公司 Navigation method and navigation apparatus
WO2016090781A1 (en) * 2014-12-12 2016-06-16 中兴通讯股份有限公司 Positioning and navigating method, device and system
US20180238697A1 (en) * 2017-02-22 2018-08-23 Clarion Co., Ltd. Navigation device, route search server, and route search method
CN108922173A (en) * 2018-06-20 2018-11-30 青岛海信网络科技股份有限公司 A kind of vehicle deviation detection method and device
CN109443370A (en) * 2018-09-13 2019-03-08 中通国脉物联科技南京有限公司 A method of deviate detection track
CN110986980A (en) * 2019-11-28 2020-04-10 北京百度网讯科技有限公司 Planned route detection method and device and electronic equipment
CN112991806A (en) * 2021-02-18 2021-06-18 安徽中科美络信息技术有限公司 Vehicle track monitoring method and device

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
丁学敏;李枫;: "LAVIA系统GPS定位点路径偏离调整算法", 数据采集与处理, no. 1, 15 October 2009 (2009-10-15) *

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN117029851A (en) * 2023-07-31 2023-11-10 赛马物联科技(宁夏)有限公司 Freight vehicle driving auxiliary system and method
CN116935656A (en) * 2023-09-18 2023-10-24 浙江中控信息产业股份有限公司 Road traffic data processing method and device, electronic equipment and storage medium
CN116935656B (en) * 2023-09-18 2023-12-01 浙江中控信息产业股份有限公司 Road traffic data processing method and device, electronic equipment and storage medium

Also Published As

Publication number Publication date
CN113670325B (en) 2024-07-02

Similar Documents

Publication Publication Date Title
US20210125492A1 (en) Method, apparatus, and system for detecting a merge lane traffic jam
US11105640B1 (en) Using train telematics data to reduce accident risk
US10859388B2 (en) Route generation using road lane line quality
US11156474B2 (en) ADAS horizon and vision supplemental V2X
CN108022450B (en) Auxiliary driving method based on cellular network and traffic control unit
US10690507B2 (en) Network based storage of vehicle and infrastructure data for optimizing vehicle routing
US11037382B2 (en) System and method for evaluating operation of environmental sensing systems of vehicles
US10043384B2 (en) Management of mobile objects and service platform for mobile objects
CN113670325B (en) Path deviation detection method and system and electronic equipment
US9165465B2 (en) System and method for providing traffic information
US11248917B2 (en) Method, apparatus, and computer program product for determining the criticality of an emergency
CN113748316B (en) System and method for vehicle telemetry
US10168424B1 (en) Management of mobile objects
US20190189003A1 (en) Method, device and system for wrong-way driver detection
JP2018055208A (en) Traffic obstruction risk displaying device
US12008895B2 (en) Vehicle-to-everything (V2X) misbehavior detection using a local dynamic map data model
CN113240919B (en) Emergency vehicle priority passing method based on Internet of vehicles
US20190139404A1 (en) Method, device and system for wrong-way driver detection
CN111323035A (en) Detection method and detection device for driving yaw and readable storage medium
JP2005313658A (en) Vehicle accident prevention system and vehicle accident prevention method
US20190176848A1 (en) Method, device and system for wrong-way driver detection
JP2022096497A (en) Information processing system
US20220198923A1 (en) Method, apparatus, and computer program product for determining a split lane traffic pattern
US11348456B2 (en) Systems and methods for detecting wrong way travel of a vehicle
WO2022159173A1 (en) Vehicle-to-everything (v2x) misbehavior detection using a local dynamic map data model

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
CB02 Change of applicant information
CB02 Change of applicant information

Country or region after: China

Address after: 2nd Floor, No. 48 Renmin East Road, Jinjiang District, Chengdu City, Sichuan Province, 610017

Applicant after: Unicom Smart Network Ruixing Technology (Chengdu) Co.,Ltd.

Address before: Room 501-7, floor 5, building 52, No. 2, Jingyuan North Street, Beijing Economic and Technological Development Zone, Daxing District, Beijing 100176

Applicant before: China Unicom Zhiwang Ruihang Technology (Beijing) Co.,Ltd.

Country or region before: China

GR01 Patent grant