Method and device for determining object road coordinates, electronic equipment and storage medium
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- BEIJING SAIMO TECH CO LTD
- Filing Date
- 2022-08-16
- Publication Date
- 2026-08-07
AI Technical Summary
[0003]道路由多个分段带参多项式构成,表达式构成复杂,道路的切线方向时刻在发生变化,这给我们进行坐标变换带来了困难,目前还没有相应的解决办法
[0019]本申请实施例提供了一种物体道路坐标的确定方法、装置、电子设备及存储介质,该物体道路坐标的确定方法包括:获取物体在世界坐标系中的X轴坐标和Y轴坐标,道路的切线的斜率表达式;根据斜率表达式、物体在世界坐标系中的X轴坐标和Y轴坐标,确定物体到切线的第一距离表达式;根据物体在世界坐标系中的X轴坐标和Y轴坐标,确定物体到切点的第二距离表达式;根据第一距离表达式、第二距离表达式,求取切点的道路坐标参数;根据切点的道路坐标参数确定物体在道路的道路坐标系下的道路坐标。本申请通过物体在世界坐标系中的X轴坐标和Y轴坐标,以及切线的斜率表达式,确定物体到切线的第一距离表达式和物体到切点的第二距离表达式,然后根据第一距离表达式和第二距离表达式求取道路坐标参数,最后根据道路坐标参数确定物体的道路坐标,能够准确确定物体在道路坐标系中的道路坐标。
Smart Images

Figure CN115345005B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of road simulation technology, and more specifically, to a method, apparatus, electronic device, and storage medium for determining the road coordinates of an object. Background Technology
[0002] Current road simulation standards require users to provide the coordinates of objects outside the road relative to each road. Therefore, we need to convert the world coordinates of the objects in the world coordinate system to the road coordinates in the road coordinate system.
[0003] The road is composed of multiple segmented parameterized polynomials, resulting in a complex expression. The tangent direction of the road is constantly changing, which makes coordinate transformation difficult, and there is currently no corresponding solution. Summary of the Invention
[0004] In view of this, the purpose of this application is to provide a method, apparatus, electronic device and storage medium for determining the road coordinates of an object, which can accurately determine the road coordinates of an object in a road coordinate system.
[0005] In a first aspect, embodiments of this application provide a method for determining the road coordinates of an object, the method comprising: Obtain the X-axis and Y-axis coordinates of the object in the world coordinate system, and the slope expression of the tangent line of the road; the line connecting the object and the point of tangency is perpendicular to the tangent line; Based on the slope expression, the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, determine the first distance expression from the object to the tangent; based on the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, determine the second distance expression from the object to the tangent point; the first and second distance expressions include the road coordinate parameters of the uniquely unknown tangent point; Based on the first distance expression and the second distance expression, the road coordinate parameters of the tangent point are obtained; The road coordinates of the object in the road coordinate system are determined based on the road coordinate parameters of the tangent point.
[0006] In one possible implementation, determining the first distance expression and the second distance expression includes: The first distance expression is determined using the following formula; ; The second distance expression is calculated using the following formula; ; , ; Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, dis2(t) is the second distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
[0007] In one possible implementation, the road coordinate parameters of the tangent point are obtained based on the first distance expression and the second distance expression, including: The road coordinate parameters of the tangent point are determined using the following formula; .
[0008] In one possible implementation, determining the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point includes: Determine the X-axis and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point; Determine the X-axis coordinate of the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system; Substitute the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and then determine the value of the target distance as the Y-axis coordinate in the road coordinate system.
[0009] In one possible implementation, determining the X-axis and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point includes: The X-axis and Y-axis coordinates of the tangent point in the world coordinate system are determined using the following formulas; ; ; Where t is the road coordinate parameter of the tangent point, x(t) is the X-axis coordinate of the tangent point in the world coordinate system, and 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.
[0010] In one possible implementation, determining the X-axis coordinate in the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system includes: The X-axis coordinate in the road coordinate system is determined using the following formula; ; Where S is the X-axis coordinate in the road coordinate system, x(v) is the X-axis coordinate of the point with 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 road coordinate parameter v in the road coordinate system.
[0011] Secondly, embodiments of this application also provide a device for determining the road coordinates of an object, the device comprising: The acquisition module is used to obtain the X-axis and Y-axis coordinates of an object in the world coordinate system, the slope expression of the tangent line of the road, and the line connecting the object and the tangent point is perpendicular to the tangent line. The determination module is used to determine the first distance expression from the object to the tangent line based on the slope expression and the object's X-axis and Y-axis coordinates in the world coordinate system; and to determine the second distance expression from the object to the tangent point based on the object's X-axis and Y-axis coordinates in the world coordinate system; the first and second distance expressions include the road coordinate parameters of the uniquely unknown tangent point; The calculation module is used to calculate the road coordinate parameters of the tangent point based on the first distance expression and the second distance expression; The determination module is also used to determine the road coordinates of an object in the road coordinate system based on the road coordinate parameters of the tangent point.
[0012] In one possible implementation, the determining module is specifically configured to determine the first distance expression using the following formula; The second distance expression is calculated using the following formula; ; , Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, dis2(t) is the second distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
[0013] In one possible implementation, the calculation module is specifically used to determine the road coordinate parameters of the tangent point using the following formula; .
[0014] In one possible implementation, the determining module is specifically used to determine the X-axis coordinates and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point; determine the X-axis coordinate in the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system; substitute the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and determine the value of the target distance as the Y-axis coordinate in the road coordinate system.
[0015] In one possible implementation, the determining module is specifically used to determine the X-axis and Y-axis coordinates of the tangent point in the world coordinate system using the following formula; ; Where t is the road coordinate parameter of the tangent point, x(t) is the X-axis coordinate of the tangent point in the world coordinate system, and 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.
[0016] In one possible implementation, the determining module is specifically used to determine the X-axis coordinate in the road coordinates using the following formula; Where S is the X-axis coordinate in the road coordinate system, x(v) is the X-axis coordinate of the point with 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 road coordinate parameter v in the road coordinate system.
[0017] Thirdly, embodiments of this application also provide an electronic device, including: a processor, a storage medium, and a bus. The storage medium stores machine-readable instructions executable by the processor. When the electronic device is running, the processor communicates with the storage medium via the bus, and the processor executes the machine-readable instructions to perform the steps of the method for determining the road coordinates of an object as described in any of the first aspects.
[0018] Fourthly, embodiments of this application also provide a computer-readable storage medium storing a computer program, which, when run by a processor, performs the steps of the method for determining the coordinates of an object road as described in any of the first aspects.
[0019] This application provides a method, apparatus, electronic device, and storage medium for determining the road coordinates of an object. The method includes: obtaining the X-axis and Y-axis coordinates of the object in a world coordinate system, and the slope expression of the tangent line of the road; determining a first distance expression from the object to the tangent line based on the slope expression and the X-axis and Y-axis coordinates of the object in the world coordinate system; determining a second distance expression from the object to the tangent point based on the X-axis and Y-axis coordinates of the object in the world coordinate system; calculating the road coordinate parameters of the tangent point based on the first and second distance expressions; and determining the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point. This application determines the first distance expression from the object to the tangent line and the second distance expression from the object to the tangent point using the X-axis and Y-axis coordinates of the object in the world coordinate system and the slope expression of the tangent line, then calculates the road coordinate parameters based on the first and second distance expressions, and finally determines the road coordinates of the object based on the road coordinate parameters, thus accurately determining the road coordinates of the object in the road coordinate system. Attached Figure Description
[0020] To more clearly illustrate the technical solutions of the embodiments of this application, the accompanying drawings used in the embodiments will be briefly introduced below. It should be understood that the following drawings only show some embodiments of this application and should not be regarded as a limitation of the scope. For those skilled in the art, other related drawings can be obtained based on these drawings without creative effort.
[0021] Figure 1 A flowchart illustrating a method for determining the road coordinates of an object according to an embodiment of this application is shown. Figure 2 This illustration shows a scene diagram of an object and a road according to an embodiment of this application; Figure 3 A flowchart illustrating another method for determining the road coordinates of an object provided in an embodiment of this application is shown. Figure 4 This illustration shows a scenario diagram illustrating the distance from a tangent point to the starting point of a road, as provided in an embodiment of this application. Figure 5 This illustration shows a scene diagram illustrating the target distance from an object to a tangent point, as provided in an embodiment of this application. Figure 6 A schematic diagram of the structure of a device for determining the road coordinates of an object provided in an embodiment of this application is shown; Figure 7 A schematic diagram of the structure of an electronic device provided in an embodiment of this application is shown. Detailed Implementation
[0022] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. It should be understood that the accompanying drawings in this application are for illustrative and descriptive purposes only and are not intended to limit the scope of protection of this application. Furthermore, it should be understood that the schematic drawings are not drawn to scale. The flowcharts used in this application illustrate operations implemented according to some embodiments of this application. It should be understood that the operations in the flowcharts may not be implemented in sequence, and steps without logical contextual relationships may be reversed or implemented simultaneously. In addition, those skilled in the art, guided by the content of this application, may add one or more other operations to the flowcharts, or remove one or more operations from the flowcharts.
[0023] Furthermore, the described embodiments are merely some, not all, of the embodiments of this application. The components of the embodiments of this application described and illustrated herein can typically be arranged and designed in various different configurations. Therefore, the following detailed description of the embodiments of this application provided in the accompanying drawings is not intended to limit the scope of the claimed application, but merely to illustrate selected embodiments of the application. All other embodiments obtained by those skilled in the art based on the embodiments of this application without inventive effort are within the scope of protection of this application.
[0024] To enable those skilled in the art to utilize the content of this application, and in conjunction with the specific application scenario of "road simulation technology," the following embodiments are provided. For those skilled in the art, the general principles defined herein can be applied to other embodiments and application scenarios without departing from the spirit and scope of this application. Although this application is primarily described within the "road simulation technology field," it should be understood that this is merely an exemplary embodiment.
[0025] It should be noted that the term "comprising" will be used in the embodiments of this application to indicate the presence of the features declared thereafter, but does not exclude the addition of other features.
[0026] The following is a detailed description of a method for determining the road coordinates of an object provided in an embodiment of this application.
[0027] Reference Figure 1 The diagram shown is a flowchart illustrating a method for determining the road coordinates of an object according to an embodiment of this application. The exemplary steps of this embodiment are described below: S101. Obtain the X-axis and Y-axis coordinates of the object in the world coordinate system, and the slope expression of the tangent line of the road.
[0028] In this application embodiment, the coordinates of the object whose road coordinates are to be determined are obtained in the world coordinate system, along with the slope expression of the road's tangent. The world coordinate system is a three-dimensional coordinate system composed of the X-axis, Y-axis, and Z-axis; however, this application only considers the X-axis and Y-axis coordinates of the object in the world coordinate system. Furthermore, while roads are winding and have numerous tangents, in this application embodiment, the tangent of the road and the line connecting the object and the point of tangency are perpendicular to each other; that is, the line connecting the object and the point of tangency is perpendicular to the tangent of the road. The point of tangency refers to the point where the tangent of the road is tangent to the road.
[0029] Here, the road is expressed using the following parameterized trinomial polynomial: Road expression: ; in, a 0 、a 1 、a 2 、b 0 、b 1 、b 2 is a constant, and u is a road coordinate parameter used to characterize the position of a point on the road in the road coordinate system. x (u) represents the X-axis coordinate of a point in the road with road coordinate parameter u in the world coordinate system, and y(u) represents the Y-axis coordinate of a point in the road with road coordinate parameter u in the world coordinate system.
[0030] Here, when u is 0, the X-axis and Y-axis coordinates of the world coordinates are respectively x The points (0) and y(0) are the starting points in the road coordinate system. When u is 1, the X-axis and Y-axis coordinates representing the world coordinates are respectively... x The points (0) and y(0) are the endpoints in the road coordinate system.
[0031] Furthermore, regarding the road expression... x Differentiating (u) and y(u), we get: ; Furthermore, assuming the road coordinate parameter of the tangent point is t, d can be obtained from the formula after differentiating the road coordinates. x (t) and dy(t).
[0032] Since the point of tangency lies on the tangent line, the slope of the tangent line can be expressed using the following formula: .
[0033] Reference Figure 2As shown, this is a scene diagram of an object and a road provided in an embodiment of this application. The line 204 connecting the object 203 and the tangent point 205 is perpendicular to the tangent line 202 of the road 201. The tangent point 205 is the intersection of the tangent line 202 and the road 201.
[0034] S102. Based on the slope expression and the X-axis and Y-axis coordinates of the object in the world coordinate system, determine the first distance expression from the object to the tangent; based on the X-axis and Y-axis coordinates of the object in the world coordinate system, determine the second distance expression from the object to the point of tangency.
[0035] In this embodiment, the slope expression is used to express the slope of the tangent. Knowing the expression for the slope of the tangent, the first distance from the object to the tangent can be expressed based on the slope expression, the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, i.e., the expression for the first distance from the object to the tangent can be obtained. The road coordinate parameter of the tangent point is t. Using the road expression in step S101, the X-axis coordinates and Y-axis coordinates of the tangent point in the world coordinate system can be obtained. Based on the X-axis and Y-axis coordinates of the tangent point in the world coordinate system, and the X-axis and Y-axis coordinates of the object in the world coordinate system, the second distance expression from the object to the tangent point can be determined.
[0036] The first and second distance expressions include the road coordinate parameters of the unique, unknown tangent point.
[0037] i. Based on the slope expression and the object's X-axis and Y-axis coordinates in the world coordinate system, determine the first distance expression from the object to the tangent: Specifically, the first distance expression is determined by the following formula: ; Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
[0038] ii. Based on the X-axis and Y-axis coordinates of the object in the world coordinate system, determine the second distance expression from the object to the tangent point: Specifically, the second distance expression is calculated using the following formula; ; , ; Where dis2(t) is the second distance expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
[0039] S103. Based on the first distance expression and the second distance expression, obtain the road coordinate parameters of the tangent point.
[0040] Specifically, the road coordinate parameters of the tangent point are determined using the following formula: .
[0041] Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, and dis2(t) is the second distance expression.
[0042] In this embodiment, the first distance expression is the distance from the object to the tangent line, and the second distance expression is the distance from the object to the tangent point. Therefore, theoretically, the first distance and the second distance should be equal. That is, when the first distance and the second distance are infinitely close, it represents the optimal solution for the road coordinate parameters of the tangent point. In other words, when the difference between the first distance and the second distance is at its minimum, t is considered optimal. * The road coordinate parameter t is used as the point of tangency.
[0043] S104. Determine the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point.
[0044] In this embodiment, the X-axis and Y-axis coordinates of the tangent point in the world coordinate system are determined based on the road coordinate parameters of the tangent point; the X-axis coordinate in the road coordinate system is determined based on the X-axis coordinate of the tangent point in the world coordinate system; the road coordinate parameters of the tangent point are substituted into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and the value of the target distance is determined as the Y-axis coordinate in the road coordinate system.
[0045] This application provides a method for determining the road coordinates of an object. The method includes: obtaining the X-axis and Y-axis coordinates of the object in a world coordinate system, and the slope expression of the tangent line to the road; determining a first distance expression from the object to the tangent line based on the slope expression and the X-axis and Y-axis coordinates of the object in the world coordinate system; determining a second distance expression from the object to the tangent point based on the X-axis and Y-axis coordinates of the object in the world coordinate system; calculating the road coordinate parameters of the tangent point based on the first and second distance expressions; and determining the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point. This application determines the first distance expression from the object to the tangent line and the second distance expression from the object to the tangent point using the X-axis and Y-axis coordinates of the object in the world coordinate system and the slope expression of the tangent line, then calculates the road coordinate parameters based on the first and second distance expressions, and finally determines the road coordinates of the object based on the road coordinate parameters, thus accurately determining the road coordinates of the object in the road coordinate system.
[0046] Reference Figure 3 The diagram shown is a flowchart illustrating another method for determining the road coordinates of an object according to an embodiment of this application. The exemplary steps of this embodiment are described below: S301. Determine the X-axis and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point.
[0047] In this embodiment of the application, when the road coordinate parameters of the tangent point are known, the obtained road coordinate parameters t of the tangent point are substituted into the road expression in step S101 to obtain the X-axis coordinate and Y-axis coordinate of the tangent point in the world coordinate system.
[0048] Specifically, the X-axis and Y-axis coordinates of the tangent point in the world coordinate system are determined by the following formulas; ; ; Where t is the road coordinate parameter of the tangent point, x(t) is the X-axis coordinate of the tangent point in the world coordinate system, and y(t) is the Y-axis coordinate of the tangent point in the world coordinate system. .
[0049] S302. Determine the X-axis coordinates of the road coordinates based on the X-axis coordinates of the tangent point in the world coordinate system.
[0050] In this embodiment of the application, the distance from the tangent point to the starting point of the road is obtained based on the X-axis coordinate of the tangent point in the world coordinate system; along the direction of the road, the distance from the tangent point to the starting point of the road is determined as the X-axis coordinate of the object in the road coordinate system.
[0051] Reference Figure 4 The diagram shown is a scenario illustration of the distance from the tangent point to the starting point of the road according to an embodiment of this application. Along the direction of the road 201, the distance 402 from the tangent point 205 to the starting point 401 of the road is determined as the X-axis coordinate of the object in the road coordinate system.
[0052] Specifically, the X-axis coordinate in the road coordinate system is determined using the following formula.
[0053] ; Where S is the X-axis coordinate in the road coordinate system, x(v) is the X-axis coordinate of the point with 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 road coordinate parameter v in the road coordinate system.
[0054] Here, the formula above expresses the distance from the point of tangency to the starting point of the road along the direction of the road.
[0055] S303. Substitute the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and determine the value of the target distance as the Y-axis coordinate in the road coordinate system.
[0056] Reference Figure 5 The diagram shown is a scene illustration of the target distance from an object to a tangent point according to an embodiment of this application. The target distance is the target distance 501 from object 203 to tangent point 205 in the diagram.
[0057] Furthermore, in the embodiments of this application, the target distance from the object to the tangent point can also be determined in the following ways.
[0058] The first method involves substituting the road coordinate parameters of the tangent point into either the first distance expression or the second distance expression to obtain the first distance and the second distance, respectively. The first distance and the second distance are then weighted and averaged to obtain the target distance from the object to the tangent point.
[0059] The second method involves substituting the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the first distance and the second distance, respectively; the average of the first distance and the second distance is then determined as the target distance from the object to the tangent point.
[0060] The third method is to take the average of the target distances obtained from the first and second methods as the final target distance.
[0061] This application provides another method for determining the road coordinates of an object. The method includes: determining the X-axis and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point; determining the X-axis coordinate in the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system; substituting the road coordinate parameters of the tangent point into a first distance expression or a second distance expression to obtain the target distance from the object to the tangent point, and determining the value of the target distance as the Y-axis coordinate in the road coordinate system. Using this method, the road coordinates of an object in the road coordinate system can be accurately determined based on the road coordinate parameters of the tangent point.
[0062] Reference Figure 6 The diagram shown is a structural schematic of a device for determining the road coordinates of an object according to an embodiment of this application. The device for determining the road coordinates of an object includes: The acquisition module 601 is used to acquire the X-axis and Y-axis coordinates of the object in the world coordinate system, the slope expression of the tangent line of the road, and the line connecting the object and the tangent point is perpendicular to the tangent line. The determination module 602 is used to determine the first distance expression from the object to the tangent line based on the slope expression and the X-axis and Y-axis coordinates of the object in the world coordinate system; and to determine the second distance expression from the object to the tangent point based on the X-axis and Y-axis coordinates of the object in the world coordinate system; the first distance expression and the second distance expression include the road coordinate parameters of the unique unknown tangent point; The calculation module 603 is used to calculate the road coordinate parameters of the tangent point based on the first distance expression and the second distance expression; The determination module 602 is also used to determine the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point.
[0063] In one possible implementation, the determining module 602 is specifically used to determine the first distance expression using the following formula; The second distance expression is calculated using the following formula; ; , Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, dis2(t) is the second distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
[0064] In one possible implementation, the calculation module 603 is specifically used to determine the road coordinate parameters of the tangent point using the following formula; .
[0065] In one possible implementation, the determining module 602 is specifically used to determine the X-axis coordinates and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point; determine the X-axis coordinate in the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system; substitute the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and determine the value of the target distance as the Y-axis coordinate in the road coordinate system.
[0066] In one possible implementation, the determining module 602 is specifically used to determine the X-axis coordinates and Y-axis coordinates of the tangent point in the world coordinate system using the following formula; ; Where t is the road coordinate parameter of the tangent point, x(t) is the X-axis coordinate of the tangent point in the world coordinate system, and y(t) is the Y-axis coordinate of the tangent point in the world coordinate system. .
[0067] In one possible implementation, the determining module 602 is specifically used to determine the X-axis coordinate in the road coordinates using the following formula; Where S is the X-axis coordinate in the road coordinate system, x(v) is the X-axis coordinate of the point with 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 road coordinate parameter v in the road coordinate system.
[0068] This application provides a device for determining the road coordinates of an object. The device includes: an acquisition module 601, used to acquire the X-axis and Y-axis coordinates of the object in a world coordinate system, and the slope expression of the tangent line of the road; the line connecting the object and the tangent point is perpendicular to the tangent line; a determination module 602, used to determine a first distance expression from the object to the tangent line based on the slope expression and the X-axis and Y-axis coordinates of the object in the world coordinate system; and a second distance expression from the object to the tangent point based on the X-axis and Y-axis coordinates of the object in the world coordinate system; the first and second distance expressions include the road coordinate parameters of the uniquely unknown tangent point; a calculation module 603, used to calculate the road coordinate parameters of the tangent point based on the first and second distance expressions; the determination module 602 is further used to determine the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point. This application determines the first distance expression from the object to the tangent and the second distance expression from the object to the tangent point by using the X-axis and Y-axis coordinates of the object in the world coordinate system and the slope expression of the tangent. Then, the road coordinate parameters are obtained based on the first and second distance expressions. Finally, the road coordinates of the object are determined based on the road coordinate parameters, which can accurately determine the road coordinates of the object in the road coordinate system.
[0069] like Figure 7 As shown in the embodiment of this application, an electronic device 700 includes a processor 701, a memory 702, and a bus. The memory 702 stores machine-readable instructions that can be executed by the processor 701. When the electronic device is running, the processor 701 communicates with the memory 702 via the bus, and the processor 701 executes the machine-readable instructions to perform the steps of the method for determining the road coordinates of an object as described above.
[0070] Specifically, the memory 702 and processor 701 mentioned above can be general-purpose memory and processor, without any specific limitations. When the processor 701 runs the computer program stored in the memory 702, it can execute the above-mentioned method for determining the coordinates of the object road.
[0071] Corresponding to the above-described method for determining the road coordinates of an object, this application also provides a computer-readable storage medium storing a computer program, which, when executed by a processor, performs the steps of the above-described method for determining the road coordinates of an object.
[0072] Those skilled in the art will clearly understand that, for the sake of convenience and brevity, the specific working processes of the systems and devices described above can be referred to the corresponding processes in the method embodiments, and will not be repeated here. In the several embodiments provided in this application, it should be understood that the disclosed systems, devices, and methods can be implemented in other ways. The device embodiments described above are merely illustrative. For example, the division of modules is only a logical functional division, and in actual implementation, there may be other division methods. Furthermore, multiple modules or components can be combined or integrated into another system, or some features can be ignored or not executed. Another point is that the displayed or discussed mutual coupling or direct coupling or communication connection can be through some communication interfaces; the indirect coupling or communication connection of devices or modules can be electrical, mechanical, or other forms.
[0073] The modules described as separate components may or may not be physically separate. The components shown as modules may or may not be physical units; that is, they may be located in one place or distributed across multiple network units. Some or all of the units can be selected to achieve the purpose of this embodiment according to actual needs.
[0074] In addition, the functional units in the various embodiments of this application can be integrated into one processing unit, or each unit can exist physically separately, or two or more units can be integrated into one unit.
[0075] If the aforementioned functions are implemented as software functional units and sold or used as independent products, they can be stored in a processor-executable, non-volatile, computer-readable storage medium. Based on this understanding, the technical solution of this application, in essence, or the part that contributes to the prior art, or a portion of the technical solution, can be embodied in the form of a software product. This computer software product is stored in a storage medium and includes several instructions to cause a computer device (which may be a personal computer, server, or network device, etc.) to execute all or part of the steps of the information processing methods described in the various embodiments of this application. The aforementioned storage medium includes various media capable of storing program code, such as USB flash drives, portable hard drives, ROM, RAM, magnetic disks, or optical disks.
[0076] The above are merely specific embodiments of this application, but the scope of protection of this application is not limited thereto. Any variations or substitutions that can be easily conceived by those skilled in the art within the scope of the technology disclosed in this application should be included within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the scope of the claims.
Claims
1. A method for determining the road coordinates of an object, characterized in that, The method for determining the road coordinates of the object includes: Obtain the X-axis and Y-axis coordinates of the object in the world coordinate system, and the slope expression of the tangent line of the road; the line connecting the object and the tangent point is perpendicular to the tangent line; Based on the slope expression, the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, a first distance expression is determined from the object to the tangent; based on the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, a second distance expression is determined from the object to the tangent point; the first distance expression and the second distance expression include the uniquely unknown road coordinate parameters of the tangent point; Based on the first distance expression and the second distance expression, the road coordinate parameters of the tangent point are obtained; The road coordinates of the object in the road coordinate system are determined based on the road coordinate parameters of the tangent point. The first distance expression is determined by the following formula; ; Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x (t) represents the X-axis coordinate of the tangent point in the world coordinate system, and y(t) represents the Y-axis coordinate of the tangent point in the world coordinate system. The second distance expression is calculated using the following formula; ; , ; Where t is the road coordinate parameter of the tangent point, dis2(t) is the second distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
2. The method for determining the road coordinates of an object according to claim 1, characterized in that, The step of obtaining the road coordinate parameters of the tangent point based on the first distance expression and the second distance expression includes: The road coordinate parameters of the tangent point are determined using the following formula; 。 3. The method for determining the road coordinates of an object according to claim 1 or 2, characterized in that, Determining the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point includes: Determine the X-axis and Y-axis coordinates of the tangent point in the world coordinate system based on the road coordinate parameters of the tangent point; Based on the X-axis coordinates of the tangent point in the world coordinate system, determine the X-axis coordinates of the road coordinate system; Substitute the road coordinate parameters of the tangent point into the first distance expression or the second distance expression to obtain the target distance from the object to the tangent point, and determine the value of the target distance as the Y-axis coordinate in the road coordinate system.
4. The method for determining the road coordinates of an object according to claim 3, characterized in that, Determining the X-axis coordinate of the road coordinate system based on the X-axis coordinate of the tangent point in the world coordinate system includes: The X-axis coordinate in the road coordinate system is determined using the following formula; ; Where S is the X-axis coordinate in the road coordinate system, x(v) is the X-axis coordinate of the point with 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 road coordinate parameter v in the road coordinate system.
5. A device for determining the road coordinates of an object, characterized in that, The device for determining the road coordinates of the object includes: The acquisition module is used to acquire the X-axis and Y-axis coordinates of an object in the world coordinate system, and the slope expression of the tangent line of the road; the line connecting the object and the tangent point is perpendicular to the tangent line; The determination module is used to determine a first distance expression from the object to the tangent line based on the slope expression, the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system, and to determine a second distance expression from the object to the tangent point based on the X-axis coordinates and Y-axis coordinates of the object in the world coordinate system; the first distance expression and the second distance expression include the uniquely unknown road coordinate parameters of the tangent point; The calculation module is used to calculate the road coordinate parameters of the tangent point based on the first distance expression and the second distance expression; The determining module is further configured to determine the road coordinates of the object in the road coordinate system based on the road coordinate parameters of the tangent point; The determining module is specifically used to determine the first distance expression using the following formula; ; Where t is the road coordinate parameter of the tangent point, dis1(t) is the first distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x (t) represents the X-axis coordinate of the tangent point in the world coordinate system, and y(t) represents the Y-axis coordinate of the tangent point in the world coordinate system. The determining module is specifically used to calculate the second distance expression using the following formula; ; , ; Where t is the road coordinate parameter of the tangent point, dis2(t) is the second distance expression, k(t) is the slope expression, and X is the X-axis coordinate of the object in the world coordinate system. Y Let Y be the object's Y-axis coordinate in the world coordinate system. x Let y(t) be the X-axis coordinate of the point of tangency in the world coordinate system, and y(t) be the Y-axis coordinate of the point of tangency in the world coordinate system. .
6. An electronic device, characterized in that, include: The device includes a processor, a storage medium, and a bus, wherein the storage medium stores machine-readable instructions executable by the processor, and when the electronic device is running, the processor communicates with the storage medium via the bus, and the processor executes the machine-readable instructions to perform the steps of the method for determining the road coordinates of an object as described in any one of claims 1 to 4.
7. A computer-readable storage medium, characterized in that, The computer-readable storage medium stores a computer program that, when executed by a processor, performs the steps of the method for determining the coordinates of an object road as described in any one of claims 1 to 4.
Citation Information
Patent Citations
Highway route automatic extraction method based on remote-sensing digital image
CN103218618A
Method and system for determining coordinates of road targets
CN110379155A