CN115345005A - Method and device for determining object road coordinates, electronic equipment and storage medium - Google Patents

Method and device for determining object road coordinates, electronic equipment and storage medium Download PDF

Info

Publication number
CN115345005A
CN115345005A CN202210979814.9A CN202210979814A CN115345005A CN 115345005 A CN115345005 A CN 115345005A CN 202210979814 A CN202210979814 A CN 202210979814A CN 115345005 A CN115345005 A CN 115345005A
Authority
CN
China
Prior art keywords
road
coordinate
determining
tangent
axis
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Pending
Application number
CN202210979814.9A
Other languages
Chinese (zh)
Inventor
胡大林
彭思阳
郝运泽
杨强
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Saimu Technology Co ltd
Original Assignee
Beijing Saimu 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 Beijing Saimu Technology Co ltd filed Critical Beijing Saimu Technology Co ltd
Priority to CN202210979814.9A priority Critical patent/CN115345005A/en
Publication of CN115345005A publication Critical patent/CN115345005A/en
Pending legal-status Critical Current

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F30/00Computer-aided design [CAD]
    • G06F30/20Design optimisation, verification or simulation

Landscapes

  • Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Computer Hardware Design (AREA)
  • Evolutionary Computation (AREA)
  • Geometry (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Image Analysis (AREA)

Abstract

The application provides a method and a device for determining object road coordinates, electronic equipment and a storage medium, wherein the method for determining the object road coordinates comprises the following steps: acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; determining a first distance expression from the object to a tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; according to the first distance expression and the second distance expression, the road coordinate parameters of the tangent points are obtained; and determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points. By the method, the road coordinate of the object in the road coordinate system can be accurately determined.

Description

Method and device for determining object road coordinates, electronic equipment and storage medium
Technical Field
The invention relates to the technical field of road simulation, in particular to a method and a device for determining object road coordinates, electronic equipment and a storage medium.
Background
The current road simulation standard specifies that a user needs to give coordinates of an off-road object relative to each road, so that the world coordinates of the object in a world coordinate system need to be converted into the road coordinates in a road coordinate system.
The road is composed of a plurality of piecewise parameter polynomials, the expression is complex to form, the tangential direction of the road changes all the time, the difficulty is brought to the coordinate transformation of people, and no corresponding solution exists at present.
Disclosure of Invention
In view of the above, an object of the present application is to provide a method, an apparatus, an electronic device and a storage medium for determining road coordinates of an object, which can accurately determine the road coordinates of the object in a road coordinate system.
In a first aspect, an embodiment of the present application provides a method for determining object road coordinates, where the method for determining object road coordinates includes:
acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is vertical to the tangent line;
determining a first distance expression from the object to a tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; the first distance expression and the second distance expression comprise road coordinate parameters of unique unknown tangent points;
according to the first distance expression and the second distance expression, the road coordinate parameters of the tangent points are obtained;
and determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points.
In one possible implementation, determining the first distance expression and the second distance expression includes:
determining a first distance expression by the following formula;
Figure BDA0003799927170000021
calculating a second distance expression by the following formula;
Figure BDA0003799927170000022
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
wherein t is a road coordinate parameter of the tangent point, dis1 (t) is a first distance expression, dis 2 (t) is a second distance expression, k (t) is a slope expression, X is the X-axis coordinate of the object in the world coordinate system, Y is the Y-axis coordinate of the object in the world coordinate system, X (t) is the X-axis coordinate of the tangent point in the world coordinate system, Y (t) is the Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In a possible implementation manner, the obtaining of the road coordinate parameter of the tangent point according to the first distance expression and the second distance expression includes:
determining road coordinate parameters of the tangent points through the following formula;
t=argmin(dis 1 (t * )-dis 2 (t * )) 2 ,t * ∈[0,1]。
in one possible embodiment, determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points comprises:
determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system according to the road coordinate parameters of the tangent point;
determining an X-axis coordinate in a road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system;
and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
In one possible implementation, determining the X-axis coordinate and the Y-axis coordinate of the tangent point in the world coordinate system according to the road coordinate parameter of the tangent point includes:
determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system by the following formula;
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3
y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
wherein t is a road coordinate parameter of the tangent point, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, and a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In one possible embodiment, determining the X-axis coordinate in the road coordinate system according to the X-axis coordinate of the tangent point in the world coordinate system includes:
determining an X-axis coordinate in the road coordinates by the following formula;
Figure BDA0003799927170000031
wherein, S is the X-axis coordinate in the road coordinate, X (v) is the X-axis coordinate of the point with the road coordinate parameter v in the road coordinate system in the world coordinate system, and Y (t) is the Y-axis coordinate of the point with the road coordinate parameter v in the road coordinate system.
In a second aspect, an embodiment of the present application further provides an apparatus for determining road coordinates of an object, where the apparatus includes:
the acquisition module is used for acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is vertical to the tangent line;
the determining module is used for determining a first distance expression from the object to the tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; the first distance expression and the second distance expression comprise road coordinate parameters of unique unknown tangent points;
the calculating module is used for calculating the road coordinate parameters of the tangent points according to the first distance expression and the second distance expression;
and the determining module is also used for determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points.
In a possible implementation, the determining module is specifically configured to determine the first distance expression by the following formula;
Figure BDA0003799927170000041
calculating a second distance expression by the following formula;
Figure BDA0003799927170000042
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3 (ii) a Wherein t is a road coordinate parameter of the tangent point, dis1 (t) is a first distance expression, dis 2 (t) is a second distance expression, k (t) is a slope expression, X is the X-axis coordinate of the object in the world coordinate system, Y is the Y-axis coordinate of the object in the world coordinate system, X (t) is the X-axis coordinate of the tangent point in the world coordinate system, Y (t) is the Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In a possible implementation manner, the solving module is specifically configured to determine a road coordinate parameter of the tangent point through the following formula; t = argmin (dis) 1 (t * )-dis 2 (t * )) 2 ,t * ∈[0,1]。
In one possible implementation, the determining module is specifically configured to determine an X-axis coordinate and a Y-axis coordinate of the tangent point in a world coordinate system according to the road coordinate parameter of the tangent point; determining an X-axis coordinate in a road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system; and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
In one possible implementation, the determining module is specifically configured to determine an X-axis coordinate and a Y-axis coordinate of the tangent point in the world coordinate system by the following formulas; x (t) = a 0 +a 1 t+a 2 t 2 +a 3 t 3 ;y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3 (ii) a Wherein t is a road coordinate parameter of the tangent point, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, and a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In a possible embodiment, the determining module is specifically configured to determine an X-axis coordinate in the road coordinates by the following formula;
Figure BDA0003799927170000051
wherein, S is the X-axis coordinate in the road coordinate, X (v) is the X-axis coordinate of the point with the road coordinate parameter v in the road coordinate system in the world coordinate system, and Y (t) is the Y-axis coordinate of the point with the road coordinate parameter v in the road coordinate system.
In a third aspect, an embodiment of the present application further provides an electronic device, including: the system comprises a processor, a storage medium and a bus, wherein the storage medium stores machine-readable instructions executable by the processor, when the electronic device runs, the processor and the storage medium are communicated through the bus, and the processor executes the machine-readable instructions to execute the steps of the method for determining the road coordinates of the object according to the first aspect.
In a fourth aspect, the present application further provides a computer-readable storage medium, on which a computer program is stored, where the computer program is executed by a processor to perform the steps of the method for determining road coordinates of an object according to any one of the first aspect.
The embodiment of the application provides a method and a device for determining object road coordinates, electronic equipment and a storage medium, wherein the method for determining the object road coordinates comprises the following steps: acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; determining a first distance expression from the object to a tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; according to the first distance expression and the second distance expression, the road coordinate parameters of the tangent points are obtained; and determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points. According to the method and the device, a first distance expression from the object to the tangent line and a second distance expression from the object to the tangent point are determined through the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system and the slope expression of the tangent line, then the road coordinate parameter is obtained according to the first distance expression and the second distance expression, finally the road coordinate of the object is determined according to the road coordinate parameter, and the road coordinate of the object in the road coordinate system can be accurately determined.
Drawings
To more clearly illustrate the technical solutions of the embodiments of the present application, the drawings needed in the embodiments will be briefly described below, it should be understood that the following drawings only illustrate some embodiments of the present application and therefore should not be considered as limiting the scope, and those skilled in the art can also obtain other related drawings based on the drawings without inventive efforts.
Fig. 1 is a schematic flow chart illustrating a method for determining road coordinates of an object according to an embodiment of the present disclosure;
FIG. 2 is a schematic view illustrating a scene of an object and a road according to an embodiment of the present disclosure;
FIG. 3 is a flow chart illustrating another method for determining road coordinates of an object according to an embodiment of the present disclosure;
FIG. 4 is a schematic diagram illustrating a scene of a distance from a tangent point to a start point of a road according to an embodiment of the present disclosure;
FIG. 5 is a schematic diagram illustrating a scene of a target distance from an object to a tangent point according to an embodiment of the present disclosure;
fig. 6 is a schematic structural diagram illustrating an apparatus for determining road coordinates of an object according to an embodiment of the present application;
fig. 7 shows a schematic structural diagram of an electronic device according to an embodiment of the present application.
Detailed Description
In order to make the purpose, technical solutions and advantages of the embodiments of the present application clearer, the technical solutions in the embodiments of the present application will be clearly and completely described below with reference to the drawings in the embodiments of the present application, and it should be understood that the drawings in the present application are for illustrative and descriptive purposes only and are not used to limit the scope of protection of the present application. Additionally, it should be understood that the schematic drawings are not necessarily drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of the present application. It should be understood that the operations of the flow diagrams may be performed out of order, and steps without logical context may be performed in reverse order or simultaneously. In addition, one skilled in the art, under the guidance of the present disclosure, may add one or more other operations to the flowchart, or may remove one or more operations from the flowchart.
In addition, the described embodiments are only a part of the embodiments of the present application, and not all of the embodiments. The components of the embodiments of the present application, generally described and illustrated in the figures herein, can be arranged and designed in a wide variety of different configurations. Thus, the following detailed description of the embodiments of the present application, presented in the accompanying drawings, is not intended to limit the scope of the claimed application, but is merely representative of selected embodiments of the application. All other embodiments, which can be derived by a person skilled in the art from the embodiments of the present application without making any creative effort, shall fall within the protection scope of the present application.
In order to enable a person skilled in the art to use the present disclosure, the following embodiments are given in conjunction with a specific application scenario "road simulation technology field". It will be apparent to those skilled in the art that the general principles defined herein may be applied to other embodiments and applications without departing from the spirit and scope of the application. Although the present application is described primarily in the context of "road simulation technology," it should be understood that this is merely one exemplary embodiment.
It should be noted that in the embodiments of the present application, the term "comprising" is used to indicate the presence of the features stated hereinafter, but does not exclude the addition of further features.
The following describes a method for determining the road coordinates of an object according to an embodiment of the present application in detail.
Referring to fig. 1, a schematic flow chart of a method for determining object road coordinates according to an embodiment of the present application is shown, and exemplary steps in the embodiment of the present application are described below:
s101, obtaining an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system, and a slope expression of a tangent line of a road.
In the embodiment of the present application, the coordinates of an object whose road coordinates are to be determined in a world coordinate system, which is a three-dimensional stereo coordinate system composed of an X axis, a Y axis, and a Z axis, the slope expression of the tangent line of the road, are acquired, but the present application considers only the X-axis coordinates and the Y-axis coordinates of the object in the world coordinate system. In addition, the road is winding and has countless tangent lines, but the tangent line of the road and the connecting line of the object and the tangent point are perpendicular to each other in the embodiment of the application, namely the connecting line of the object and the tangent point is perpendicular to the tangent line of the road; the tangent point refers to a tangent point of the road and a tangent point of the road.
Here, the road is expressed by the following polynomial with parameters in three terms:
the road expression is as follows:
Figure BDA0003799927170000081
wherein, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant, u is a road coordinate parameter characterizing the points in the road in a road coordinate systemAnd X (u) is the X-axis coordinate of the point with the road coordinate parameter u in the road in the world coordinate system, and Y (u) is the Y-axis coordinate of the point with the road coordinate parameter u in the road in the world coordinate system.
Here, when u is 0, a point where the X-axis coordinate and the Y-axis coordinate representing the world coordinate are X (0) and Y (0), respectively, is a starting point in the road coordinate system. When u is1, a point where the X-axis coordinate and the Y-axis coordinate representing the world coordinate are X (0) and Y (0), respectively, is an end point in the road coordinate system.
Further, deriving x (u) and y (u) in the road expression, we can obtain:
Figure BDA0003799927170000082
further, assuming that the road coordinate parameter of the tangent point is t, dx (t) and dy (t) can be obtained by the formula after the road derivation.
Since the tangent point is on the tangent line, the slope expression of the tangent line can be obtained by the following formula:
k(t)=dx(t)/dy(t)。
referring to fig. 2, which is a schematic view of a scene of an object and a road provided in an embodiment of the present application, a connection line 204 between the object 203 and a tangent point 205 is perpendicular to a tangent 202 of the road 201, and the tangent point 205 is an intersection of the tangent 202 and the road 201.
S102, determining a first distance expression from the object to a tangent line according to the slope expression and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; and determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system.
In the embodiment of the application, the slope expression is used for expressing the slope of the tangent, and in the case of an expression for clearly expressing the slope of the tangent, the first distance from the object to the tangent can be expressed according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system, that is, the first distance expression from the object to the tangent can be obtained. The road coordinate parameter of the tangent point is t, the X-axis coordinate of the tangent point in the world coordinate system and the Y-axis coordinate of the tangent point in the world coordinate system can be obtained through the road expression in step S101, and the second distance expression from the object to the tangent point can be determined according to the X-axis coordinate and the Y-axis coordinate of the tangent point in the world coordinate system and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system.
The first distance expression and the second distance expression comprise road coordinate parameters of unique unknown tangent points.
i. Determining a first distance expression from the object to the tangent line according to the slope expression, the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system:
specifically, the first distance expression is determined by the following formula:
Figure BDA0003799927170000091
wherein t is a road coordinate parameter of the tangent point, dis1 (t) is a first distance expression, k (t) is a slope expression, X is an X-axis coordinate of the object in the world coordinate system, Y is a Y-axis coordinate of the object in the world coordinate system, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, a is 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
ii. Determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system:
specifically, the second distance expression is calculated by the following formula;
Figure BDA0003799927170000101
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
wherein dis 2 (t) is a second distance expression, X is an objectThe X-axis coordinate of the body in the world coordinate system, Y is the Y-axis coordinate of the body in the world coordinate system, X (t) is the X-axis coordinate of the tangent point in the world coordinate system, Y (t) is the Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
S103, according to the first distance expression and the second distance expression, the road coordinate parameter of the tangent point is obtained.
Specifically, the road coordinate parameters of the tangent points are determined by the following formula:
t=argmin(dis 1 (t * )-dis 2 (t * )) 2 ,t * ∈[0,1]。
wherein t is a road coordinate parameter of the tangent point, dis1 (t) is a first distance expression, dis 2 (t) is a second distance expression.
In the embodiment of the present application, the first distance expression is a distance from the object to the tangent and the second distance expression is a distance from the object to the tangent point, and therefore, in theory, the first distance and the second distance should be equal. That is, when the first distance and the second distance are infinitely close, it is the optimal solution of the road coordinate parameter of the tangent point. That is, when the difference between the first distance and the second distance is the minimum value, t will be at that time * And a road coordinate parameter t as a tangent point.
And S104, determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points.
In the embodiment of the application, the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system are determined according to the road coordinate parameters of the tangent point; determining an X-axis coordinate in a road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system; and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
The embodiment of the application provides a method for determining the coordinates of an object road, which comprises the following steps: acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; determining a first distance expression from the object to a tangent line according to the slope expression and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; according to the first distance expression and the second distance expression, the road coordinate parameters of the tangent points are obtained; and determining the road coordinate of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent points. According to the method and the device, a first distance expression from the object to the tangent line and a second distance expression from the object to the tangent point are determined through the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system and the slope expression of the tangent line, then the road coordinate parameter is obtained according to the first distance expression and the second distance expression, finally the road coordinate of the object is determined according to the road coordinate parameter, and the road coordinate of the object in the road coordinate system can be accurately determined.
Referring to fig. 3, a schematic flow chart of another method for determining object road coordinates provided in the embodiment of the present application is shown, and exemplary steps in the embodiment of the present application are described below:
s301, determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system according to the road coordinate parameters of the tangent point.
In the present embodiment, when the road coordinate parameter of the tangent point is known, the obtained road coordinate parameter t of the tangent point is substituted into the road expression in step S101, and the X-axis coordinate of the tangent point in the world coordinate system and the Y-axis coordinate of the tangent point in the world coordinate system can be obtained.
Specifically, the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system are determined through the following formulas;
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3
y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
wherein t is the road coordinate parameter of the tangent point, and x (t) is the tangent pointX-axis coordinate in the world coordinate system, Y (t) is Y-axis coordinate of tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
And S302, determining the X-axis coordinate in the road coordinate according to the X-axis coordinate of the tangent point in the world coordinate system.
In the embodiment of the application, the distance from the tangent point in the road to the starting point of the road is obtained according to the X-axis coordinate of the tangent point in the world coordinate system; and determining the distance from the tangent point to the starting point of the road along the direction of the road as the X-axis coordinate of the object in the road coordinate system.
Fig. 4 is a schematic view of a scene of a distance from a tangent point to a start point of a road according to an embodiment of the present disclosure. The distance 402 from the tangent point 205 to the start 401 of the road along the direction of the road 201 is determined as the X-axis coordinate of the object in the road coordinate system.
Specifically, the X-axis coordinate in the road coordinates is determined by the following formula.
Figure BDA0003799927170000121
Wherein, S is the X-axis coordinate in the road coordinate, X (v) is the X-axis coordinate of the point with the road coordinate parameter v in the road coordinate system in the world coordinate system, and Y (t) is the Y-axis coordinate of the point with the road coordinate parameter v in the road coordinate system.
Here, the content expressed in the above formula is a distance from the tangent point to the start point of the road in the direction along the road.
And S303, substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
Fig. 5 is a schematic view of a scene of a target distance from an object to a tangent point according to an embodiment of the present disclosure. The target distance is the target distance 501 from the object 203 to the tangent point 205 in the figure.
Further, in the embodiment of the present application, the target distance from the object to the tangent point may also be determined in the following manner.
The first method is that road coordinate parameters of a tangent point are substituted into a first distance expression or a second distance expression to respectively obtain a first distance and a second distance, and the first distance and the second distance are weighted and averaged to obtain a target distance from an object to the tangent point.
Secondly, substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to respectively obtain a first distance and a second distance; and determining the average value of the first distance and the second distance as the target distance from the object to the tangent point.
Thirdly, the average value of the target distances obtained in the first and second modes is used as the final target distance.
The embodiment of the application provides another method for determining the road coordinates of an object, which comprises the following steps: determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system according to the road coordinate parameters of the tangent point; determining an X-axis coordinate in a road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system; and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate. By the method, the road coordinate of the object in the road coordinate system of the road can be accurately determined according to the road coordinate parameters of the tangent points.
Referring to fig. 6, a schematic structural diagram of an object road coordinate determination apparatus according to an embodiment of the present application is provided, where the object road coordinate determination apparatus includes:
the acquisition module 601 is used for acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is vertical to the tangent line;
the determining module 602 is configured to determine a first distance expression from the object to the tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; the first distance expression and the second distance expression comprise road coordinate parameters of unique unknown tangent points;
the calculating module 603 is configured to calculate a road coordinate parameter of the tangent point according to the first distance expression and the second distance expression;
the determining module 602 is further configured to determine a road coordinate of the object in a road coordinate system of the road according to the road coordinate parameter of the tangent point.
In a possible implementation, the determining module 602 is specifically configured to determine the first distance expression by the following formula;
Figure BDA0003799927170000141
calculating a second distance expression by the following formula;
Figure BDA0003799927170000142
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3 (ii) a Wherein t is a road coordinate parameter of the tangent point, dis1 (t) is a first distance expression, dis2 (t) is a second distance expression, k (t) is a slope expression, X is an X-axis coordinate of the object in the world coordinate system, Y is a Y-axis coordinate of the object in the world coordinate system, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In a possible implementation, the solving module 603 is specifically configured to determine a road coordinate parameter of the tangent point through the following formula; t = argmin (dis) 1 (t * )-dis 2 (t * )) 2 ,t * ∈[0,1]。
In a possible implementation manner, the determining module 602 is specifically configured to determine an X-axis coordinate and a Y-axis coordinate of the tangent point in the world coordinate system according to the road coordinate parameter of the tangent point; determining an X-axis coordinate in a road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system; and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
In one possible embodiment, the determining module 602 is specifically configured to determine the X-axis coordinate and the Y-axis coordinate of the tangent point in the world coordinate system by the following formulas; x (t) = a 0 +a 1 t+a 2 t 2 +a 3 t 3 ;y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3 (ii) a Wherein t is a road coordinate parameter of the tangent point, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, and a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
In one possible embodiment, the determining module 602 is specifically configured to determine an X-axis coordinate in the road coordinate by the following formula;
Figure BDA0003799927170000151
wherein, S is the X-axis coordinate in the road coordinate, X (v) is the X-axis coordinate of the point with the road coordinate parameter v in the road coordinate system in the world coordinate system, and Y (t) is the Y-axis coordinate of the point with the road coordinate parameter v in the road coordinate system.
The embodiment of the application provides a device for determining object road coordinates, which comprises: the acquisition module 601 is used for acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is vertical to the tangent line; the determining module 602 is configured to determine a first distance expression from the object to the tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system; the first distance expression and the second distance expression comprise road coordinate parameters of unique unknown tangent points; the calculating module 603 is configured to calculate a road coordinate parameter of the tangent point according to the first distance expression and the second distance expression; the determining module 602 is further configured to determine a road coordinate of the object in a road coordinate system of the road according to the road coordinate parameter of the tangent point. According to the method and the device, a first distance expression from the object to the tangent line and a second distance expression from the object to the tangent point are determined through the X-axis coordinate and the Y-axis coordinate of the object in the world coordinate system and the slope expression of the tangent line, then the road coordinate parameter is obtained according to the first distance expression and the second distance expression, finally the road coordinate of the object is determined according to the road coordinate parameter, and the road coordinate of the object in the road coordinate system can be accurately determined.
As shown in fig. 7, an electronic device 700 provided in an embodiment of the present application includes: a processor 701, a memory 702 and a bus, wherein the memory 702 stores machine-readable instructions executable by the processor 701, when the electronic device runs, the processor 701 communicates with the memory 702 through the bus, and the processor 701 executes the machine-readable instructions to execute the steps of the method for determining the road coordinates of the object.
Specifically, the memory 702 and the processor 701 can be general-purpose memory and processor, which are not limited to specific ones, and the determination method of the object road coordinates can be performed when the processor 701 runs a computer program stored in the memory 702.
In response to the method for determining the coordinates of the object road, an embodiment of the present application further provides a computer-readable storage medium, where a computer program is stored on the computer-readable storage medium, and the computer program is executed by a processor to perform the steps of the method for determining the coordinates of the object road.
It can be clearly understood by those skilled in the art that, for convenience and simplicity of description, the specific working process of the system and the apparatus described above may refer to the corresponding process in the method embodiment, and is not described in detail in this application. In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other ways. The above-described apparatus embodiments are merely illustrative, and for example, the division of the modules is merely a logical division, and there may be other divisions in actual implementation, and for example, a plurality of modules or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of devices or modules through some communication interfaces, and may be in an electrical, mechanical or other form.
The modules described as separate parts may or may not be physically separate, and parts displayed as modules 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 units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may exist alone physically, or two or more units are integrated into one unit.
The functions, if implemented in the form of software functional units and sold or used as a stand-alone product, may be stored in a non-volatile computer-readable storage medium executable by a processor. Based on such understanding, the technical solutions of the present application or portions thereof that substantially contribute to the prior art may be embodied in the form of a software product, where the computer software product is stored in a storage medium and includes several instructions for enabling 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 information processing method according to the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a U disk, a removable hard disk, a ROM, a RAM, a magnetic disk, or an optical disk.
The above description is only for the specific embodiments of the present application, but the scope of the present application is not limited thereto, and any person skilled in the art can easily conceive of the changes or substitutions within the technical scope of the present application, and shall be covered by the scope of the present application. Therefore, the protection scope of the present application shall be subject to the protection scope of the claims.

Claims (10)

1. A method of determining object road coordinates, the method comprising:
acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is perpendicular to the tangent line;
determining a first distance expression from the object to the tangent according to the slope expression and the X-axis coordinate and the Y-axis coordinate of the object in a world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in a world coordinate system; the first distance expression and the second distance expression comprise unique unknown road coordinate parameters of the tangent points;
according to the first distance expression and the second distance expression, the road coordinate parameter of the tangent point is obtained;
and determining the road coordinate of the object under the road coordinate system of the road according to the road coordinate parameter of the tangent point.
2. The method of determining object road coordinates according to claim 1, wherein determining the first distance expression and the second distance expression includes:
determining the first distance expression by the following formula;
Figure FDA0003799927160000011
calculating the second distance expression by the following formula;
Figure FDA0003799927160000012
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
where t is the road coordinate parameter of the tangent point, dis 1 (t) is a first distance expression, dis 2 (t) is a second distance expression, k (t) is a slope expression, X is an X-axis coordinate of the object in the world coordinate system, Y is a Y-axis coordinate of the object in the world coordinate system, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
3. The method for determining the road coordinate of the object according to claim 2, wherein the obtaining the road coordinate parameter of the tangent point according to the first distance expression and the second distance expression includes:
determining road coordinate parameters of the tangent points through the following formula;
t=argmin(dis 1 (t * )-dis 2 (t * )) 2 ,t * ∈[0,1]。
4. the method for determining road coordinates of an object according to any one of claims 1-3, wherein the determining the road coordinates of the object in the road coordinate system of the road according to the road coordinate parameters of the tangent point comprises:
determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system according to the road coordinate parameter of the tangent point;
determining an X-axis coordinate in the road coordinate according to the X-axis coordinate of the tangent point in a world coordinate system;
and substituting the road coordinate parameters of the tangent points into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent points, and determining the value of the target distance as the Y-axis coordinate in the road coordinate.
5. The method for determining road coordinates of an object according to claim 4, wherein the determining the X-axis coordinates and the Y-axis coordinates of the tangent point in the world coordinate system according to the road coordinate parameters of the tangent point comprises:
determining the X-axis coordinate and the Y-axis coordinate of the tangent point in a world coordinate system by the following formula;
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3
y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
wherein t is a road coordinate parameter of the tangent point, X (t) is an X-axis coordinate of the tangent point in the world coordinate system, Y (t) is a Y-axis coordinate of the tangent point in the world coordinate system, and a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
6. The method for determining road coordinates of an object according to claim 5, wherein the determining the X-axis coordinates of the road coordinates according to the X-axis coordinates of the tangent point in the world coordinate system comprises:
determining an X-axis coordinate in the road coordinates by the following formula;
Figure FDA0003799927160000031
wherein, S is the X-axis coordinate in the road coordinate, X (v) is the X-axis coordinate of the point with the road coordinate parameter v in the road coordinate system in the world coordinate system, and Y (t) is the Y-axis coordinate of the point with the road coordinate parameter v in the road coordinate system.
7. An object road coordinate determination device, characterized by comprising:
the acquisition module is used for acquiring an X-axis coordinate and a Y-axis coordinate of an object in a world coordinate system and a slope expression of a tangent line of a road; the connecting line of the object and the tangent point is perpendicular to the tangent line;
the determining module is used for determining a first distance expression from the object to the tangent line according to the slope expression, and the X-axis coordinate and the Y-axis coordinate of the object in a world coordinate system; determining a second distance expression from the object to the tangent point according to the X-axis coordinate and the Y-axis coordinate of the object in a world coordinate system; the first distance expression and the second distance expression comprise unique unknown road coordinate parameters of the tangent points;
the calculating module is used for calculating the road coordinate parameters of the tangent points according to the first distance expression and the second distance expression;
the determining module is further used for determining the road coordinate of the object under the road coordinate system of the road according to the road coordinate parameters of the tangent points.
8. The apparatus for determining object road coordinates according to claim 7, wherein the determining module is specifically configured to:
determining the first distance expression by the following formula;
Figure FDA0003799927160000041
calculating the second distance expression by the following formula;
Figure FDA0003799927160000042
x(t)=a 0 +a 1 t+a 2 t 2 +a 3 t 3 ,y(t)=b 0 +b 1 t+b 2 t 2 +b 3 t 3
where t is the road coordinate parameter of the tangent point, dis 1 (t) is a first distance expression, dis 2 (t) is a second distance expression, k (t) is a slope expression, X is the X-axis coordinate of the object in the world coordinate system, Y is the Y-axis coordinate of the object in the world coordinate system, X (t) is the X-axis coordinate of the tangent point in the world coordinate system, Y (t) is the Y-axis coordinate of the tangent point in the world coordinate system, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 Is a constant.
9. An electronic device, comprising: a processor, a storage medium and a bus, the storage medium storing machine-readable instructions executable by the processor, the processor and the storage medium communicating via the bus when the electronic device is running, the processor executing the machine-readable instructions to perform the steps of the method for determining object road coordinates according to any one of claims 1 to 6.
10. A computer-readable storage medium, characterized in that a computer program is stored on the computer-readable storage medium, which computer program, when being executed by a processor, performs the steps of the object road coordinate determination method according to any one of claims 1 to 6.
CN202210979814.9A 2022-08-16 2022-08-16 Method and device for determining object road coordinates, electronic equipment and storage medium Pending CN115345005A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202210979814.9A CN115345005A (en) 2022-08-16 2022-08-16 Method and device for determining object road coordinates, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202210979814.9A CN115345005A (en) 2022-08-16 2022-08-16 Method and device for determining object road coordinates, electronic equipment and storage medium

Publications (1)

Publication Number Publication Date
CN115345005A true CN115345005A (en) 2022-11-15

Family

ID=83951313

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202210979814.9A Pending CN115345005A (en) 2022-08-16 2022-08-16 Method and device for determining object road coordinates, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN115345005A (en)

Similar Documents

Publication Publication Date Title
CN107223269B (en) Three-dimensional scene positioning method and device
US20190335034A1 (en) Input method, device and system
US10147240B2 (en) Product image processing method, and apparatus and system thereof
CN114723888B (en) Three-dimensional hair model generation method, device, equipment, storage medium and product
CN111107278B (en) Image processing method and device, electronic equipment and readable storage medium
CN113205041A (en) Structured information extraction method, device, equipment and storage medium
CN113486845A (en) Weather identification method and device, electronic equipment and storage medium
CN110782534B (en) 3D character color gradient method, medium, equipment and device
CN104077768B (en) Method and device for calibrating fish-eye lens radial distortion
CN109740511B (en) Facial expression matching method, device, equipment and storage medium
CN115345005A (en) Method and device for determining object road coordinates, electronic equipment and storage medium
CN115409951B (en) Image processing method, image processing device, electronic equipment and storage medium
CN112506465A (en) Method and device for switching scenes in panoramic roaming
CN113190150B (en) Method, apparatus and storage medium for displaying overlay
CN110765926A (en) Drawing book identification method and device, electronic equipment and storage medium
CN112348069B (en) Data enhancement method, device, computer readable storage medium and terminal equipment
CN113610944A (en) Line drawing method, device, equipment and storage medium
CN114283398A (en) Method and device for processing lane line and electronic equipment
CN110008911B (en) Image processing method, image processing device, electronic equipment and computer readable storage medium
CN112580744A (en) Optimized fusion method for measuring data of same lane line in crowdsourced data road segment
CN111754632A (en) Business service processing method, device, equipment and storage medium
CN112115215A (en) Method and device for determining lane center line
CN115601793B (en) Human body bone point detection method and device, electronic equipment and storage medium
JP7425169B2 (en) Image processing method, device, electronic device, storage medium and computer program
CN110895827B (en) Pasting prompting method and device for electrocardiogram detection equipment and 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