Method, device, system and vehicle for automatic driving of rudder logic conversion

CN122540192APending Publication Date: 2026-08-11GUANGZHOU XIAOMA HUIXING TECH CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2026-05-14
Publication Date
2026-08-11

AI Technical Summary

Technical Problem

(1)原生支持右舵行驶方案需要近乎从零开始重新开发一套右舵系统,开发工作量大、测试与数据成本高,且后续任何功能迭代都需在左右舵两套逻辑上同步进行,维护复杂、极易引入错误

Benefits of technology

[0017]上述自动驾驶左右舵逻辑的转换方法、装置、系统、车辆和存储介质,通过在第一驾驶规则与第二驾驶规则之间构建以反射矩阵和补偿矩阵为核心的联合变换机制,使变换后的车辆姿态仍为合法的右手坐标系旋转表示,从而降低因坐标系手性错误导致后续处理模块误解姿态数据的风险。借助该联合变换,在不修改规划模块等核心模块内部逻辑的前提下,即可使车辆在虚拟的镜像驾驶规则中运行,减少了针对不同驾驶规则重复开发算法逻辑的工作量。在此基础上,将原始输入数据选择性转换、在逻辑世界中完成运算、再将结果还原至原始驾驶规则,有利于降低系统维护复杂度,减轻在两套驾驶规则中同步修改的维护负担。

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN122540192A_ABST
    Figure CN122540192A_ABST
Patent Text Reader

Abstract

The embodiments of this application relate to the field of autonomous driving technology, specifically to a method, device, system, and vehicle for converting left and right steering logic in autonomous driving. The main steps of the aforementioned method include: acquiring first input data under a first driving rule, and converting the first input data into second input data under a second driving rule through a preset mathematical transformation; the preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data using a preset reflection matrix and a preset compensation matrix; acquiring first output data generated after processing the second input data under the second driving rule, and performing a preset mathematical transformation on the first output data to obtain the second output data required for vehicle control. By using a joint transformation centered on the reflection matrix and compensation matrix, the vehicle can operate within a virtual mirrored driving rule, avoiding the enormous workload of repeatedly developing algorithm logic for different driving rules.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of autonomous driving technology, and in particular to a method, apparatus, system, and vehicle for switching between left and right steering logic in autonomous driving. Background Technology

[0002] There are two main driving rules globally: left-hand drive and right-hand drive. Under left-hand drive, the driver's seat is on the left side of the vehicle, and the vehicle travels on the right; under right-hand drive, the driver's seat is on the right side of the vehicle, and the vehicle travels on the left. The two driving rules differ symmetrically in lane division, traffic sign layout, and right-of-way rules.

[0003] Current autonomous driving functions primarily train algorithms for left-hand drive rules. To deploy autonomous driving functions in right-hand drive areas, there are two main technical approaches in the industry. One is a native right-hand drive support approach, which involves fully adapting to right-hand drive rules from the underlying code logic. This includes reviewing and modifying all code modules related to driving behavior and traffic rule judgment, re-collecting data for right-hand drive scenarios and training core models such as perception, prediction, and planning, and conducting large-scale, full-process testing and verification. The other is a system-level mirror flip approach, which applies a global mirror flip operation at the very beginning of the data flow into the autonomous driving system and at the very end of the system control command output, so that all modules within the system believe that they are still operating in a left-hand drive world, while the actual behavior of the vehicle in the physical world conforms to right-hand drive rules.

[0004] However, the above solution has the following drawbacks: (1) Native support for right-hand drive driving scheme requires almost starting from scratch to develop a right-hand drive system. The development workload is large, the testing and data costs are high, and any subsequent functional iterations need to be carried out synchronously on both left and right rudder logics, which is complex to maintain and prone to introducing errors.

[0005] (2) In the system-level mirroring scheme, flipping the original sensor data will directly affect all modules that rely on the original data, which may cause the model to fail due to changes in the input distribution. At the same time, in order to maintain the consistency of offline and online data processing, it is usually necessary to store two sets of data such as the original and flipped maps, which will double the memory usage. In addition, the internal system is a flipped world, but the debugging information, logs and external interfaces are still the real world, which can easily cause cognitive confusion and increase the debugging difficulty for maintenance personnel. Summary of the Invention

[0006] Therefore, it is necessary to provide a method, device, system, and vehicle for switching between left and right steering logic in autonomous driving, addressing at least one of the aforementioned technical problems.

[0007] In a first aspect, embodiments of this application provide a method for switching between left and right steering logic in autonomous driving, the method comprising: The system acquires first input data under a first driving rule and transforms the first input data into second input data under a second driving rule through a preset mathematical transformation. The preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data through a preset reflection matrix M and a preset compensation matrix C. Wherein, the reflection matrix M is used to invert the coordinates of the vehicle attitude, and the compensation matrix C is used to restore the vehicle attitude after transformation by the reflection matrix M to a rotational representation that conforms to the right-hand coordinate system constraint; the first driving rule is a right-hand drive driving rule, and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule, and the second driving rule is a right-hand drive driving rule. Obtain the first output data generated after processing the second input data under the second driving rule, and perform the preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

[0008] In some embodiments, when the vehicle attitude is represented by a rotation matrix R, the joint transformation is: ;in, The target vehicle attitude after joint transformation.

[0009] In some embodiments, when the vehicle attitude is represented by a quaternion, the method for converting the left and right steering logic of autonomous driving further includes: Transform the original quaternion (w, x, y, z) into the target quaternion (-z, y, x, -w); where w, x, y, and z are one real part and three imaginary parts of the original quaternion, respectively.

[0010] In some embodiments, the preset mathematical transformation further includes: The world coordinate system position and world coordinate system velocity in the first input data are inverted using the reflection matrix; The vehicle body coordinate system acceleration in the first input data is inverted using a compensation matrix. The angular velocity of the vehicle body coordinate system in the first input data is inverted by using the compensation matrix after sign flipping.

[0011] In some embodiments, a preset mathematical transformation is performed on the first output data, including: For the target vehicle pose in the first output data, when the target vehicle pose is expressed by a rotation matrix... When representing, the mathematical transformation is assumed to be: ;in, The target vehicle posture after a preset mathematical transformation; When the target vehicle attitude is represented by a quaternion, the first output quaternion (w) will be... x y , z Convert ) to the second output quaternion (-z) y x , -w ); where w x y , z These are the real part and three imaginary parts of the first output quaternion, respectively.

[0012] In some embodiments, both the reflection matrix and the compensation matrix are diagonal matrices; the reflection matrix is ​​used to perform sign flipping on the first coordinate axis component of the target input data, while the remaining coordinate axis components remain unchanged; the compensation matrix is ​​used to perform sign flipping on the second coordinate axis component of the target input data, while the remaining coordinate axis components remain unchanged.

[0013] In a second aspect, embodiments of this application provide a switching device for left-hand drive logic in autonomous driving, the switching device comprising: A first conversion module is used to acquire first input data under a first driving rule and convert the first input data into second input data under a second driving rule through a preset mathematical transformation; the preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data through a preset reflection matrix M and a preset compensation matrix C; wherein, the reflection matrix M is used to invert the coordinates of the vehicle posture, and the compensation matrix C is used to restore the vehicle posture after transformation by the reflection matrix M to a rotational representation that conforms to the right-hand coordinate system constraint; the first driving rule is a right-hand drive driving rule, and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule, and the second driving rule is a right-hand drive driving rule; The second conversion module is used to obtain the first output data generated after processing the second input data under the second driving rules, and to perform a preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

[0014] In a third aspect, embodiments of this application provide an autonomous driving left-right steering logic conversion system, including a sensor group, a planning processor, a vehicle controller, and an autonomous driving left-right steering logic conversion device as provided in any embodiment of the second aspect of this application. The sensor array is used to collect the first input data under the first driving rule; The planning processor is used to perform operations on the second input data to generate the first output data; the second input data is obtained by the conversion device through a preset mathematical transformation of the first input data; The vehicle controller is used to receive the second output data and perform corresponding vehicle control based on the second output data; the second output data is obtained by the conversion device converting the first output data through a preset mathematical transformation; The automatic driving left and right steering logic conversion device is used to perform the automatic driving left and right steering logic conversion method provided in any embodiment of the first aspect of this application.

[0015] In a fourth aspect, embodiments of this application provide an autonomous vehicle including an autonomous driving left-right steering logic switching system as provided in the third aspect of this application.

[0016] In a fifth aspect, embodiments of this application provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method for switching between left and right steering logic for autonomous driving provided in any embodiment of the first aspect of this application.

[0017] The aforementioned method, device, system, vehicle, and storage medium for converting left-hand drive logic in autonomous driving utilize a joint transformation mechanism centered on reflection and compensation matrices between the first and second driving rules. This ensures that the transformed vehicle posture remains a valid right-handed coordinate system rotation representation, reducing the risk of subsequent processing modules misunderstanding posture data due to coordinate system chirality errors. This joint transformation allows the vehicle to operate within a virtual mirrored driving rule without modifying the internal logic of core modules such as the planning module, reducing the workload of repeatedly developing algorithm logic for different driving rules. Furthermore, selectively transforming the original input data, performing calculations in the logical world, and then restoring the results to the original driving rule helps reduce system maintenance complexity and alleviates the maintenance burden of simultaneously modifying two sets of driving rules. Attached Figure Description

[0018] Figure 1 This is an application environment diagram of the switching method for left and right steering logic in autonomous driving in some embodiments; Figure 2 This is a flowchart illustrating the switching method for left and right steering logic in some embodiments of autonomous driving. Figure 3 This is a flowchart illustrating the steps involving world coordinate system positioning in some embodiments; Figure 4 This is a structural block diagram of the switching device for left and right steering logic in some embodiments of autonomous driving; Figure 5 This is a block diagram of the switching system for left and right steering logic in some embodiments of autonomous driving. Detailed Implementation

[0019] To make the technical solutions and advantages of this application clearer, the embodiments and related technical content of this application will be further described in detail below with reference to the accompanying drawings and text description. It should be understood that the embodiments described below are only used to explain the technical solutions of the embodiments of this application and are not intended to limit more possible implementations of this application.

[0020] It should be noted that, in the description of this application, the terms "comprising," "including," or any other variations thereof are intended to cover non-exclusive inclusion, such that a process, method, article, or apparatus that comprises a list of elements includes not only those elements but also other elements not expressly listed, or elements inherent to such process, method, article, or apparatus.

[0021] Globally, two parallel traffic systems exist: left-hand drive and right-hand drive. Under left-hand drive, the driver is on the left side of the vehicle, and the vehicle travels on the right; under right-hand drive, the driver is on the right side of the vehicle, and the vehicle travels on the left. These two systems exhibit a spatial mirror relationship in terms of lane layout, traffic sign orientation, and right-of-way allocation. Existing autonomous driving systems are mostly developed based on a single driving rule (such as left-hand drive). When adapting to another rule, native reconstruction or a system-level global mirroring solution is often used. The former leads to a significant increase in development and maintenance costs, while the latter easily causes problems such as perception model failure, data redundancy, debugging chaos, and excessive computational overhead. In particular, it is difficult to ensure that the vehicle's posture (such as rotation matrices or orientation represented by quaternions) still satisfies the right-hand coordinate system constraints after mirroring, thus affecting the physical consistency and numerical stability of modules such as path planning and motion control.

[0022] Based on this, embodiments of this application provide a method for switching between left and right steering logic in autonomous driving.

[0023] For ease of understanding, Figure 1 An application environment is illustrated, in which a conversion device 110 is built into a vehicle 120 to execute the steps of a method for converting the left and right steering logic of autonomous driving. During execution, the conversion device 110 can communicate with other devices or modules of the vehicle 120 via a network to obtain relevant data on the conversion of the left and right steering logic of autonomous driving sent by sensors or other devices or modules installed on the vehicle 120. The conversion device 110 can be implemented using a standalone controller or a controller cluster consisting of multiple controllers.

[0024] The conversion device can be implemented in hardware form using at least one of the following: programmable logic array (PLA), field-programmable gate array (FPGA), digital signal processor (DSP), application-specific integrated circuit (ASIC), general-purpose processor, or other programmable logic device.

[0025] Of course, the method for switching between left and right steering logic in autonomous driving provided in this application embodiment can also be applied to more scenarios not shown in the figure.

[0026] In a first aspect, embodiments of this application provide a method for switching between left and right steering logic in autonomous driving, which can be applied to... Figure 1 In the application environment shown, it can be applied to Figure 1 Taking the conversion device 110 in the middle as an example, in some embodiments, such as Figure 2 As shown, the method for switching between left and right steering logic in autonomous driving includes steps S210 and S220 that can be executed by the switching device 110.

[0027] Step S210: Obtain the first input data under the first driving rule, and convert the first input data into the second input data under the second driving rule through a preset mathematical transformation.

[0028] The preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data using a preset reflection matrix and a preset compensation matrix.

[0029] The reflection matrix is ​​used to invert the coordinates of the vehicle's attitude, and the compensation matrix is ​​used to restore the vehicle's attitude after transformation by the reflection matrix to a rotational representation that conforms to the constraints of the right-hand coordinate system.

[0030] The reflection matrix is ​​a linear transformation matrix used to flip the direction of the spatial coordinate axes. Its function is to map physical quantities in the original world coordinate system to corresponding quantities in the mirror world coordinate system. The compensation matrix is ​​a linear transformation matrix used to correct the change in the chirality of the coordinate system caused by the transformation of the reflection matrix. Its function is to work with the reflection matrix to form a composite transformation that maintains the SO(3) (rotation group) group structure, ensuring that the rotation representation after the transformation still belongs to the legal rotation in the right-hand coordinate system.

[0031] In some embodiments, the first driving rule is a right-hand drive driving rule and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule and the second driving rule is a right-hand drive driving rule.

[0032] Right-hand drive driving rules refer to a traffic rule system where the driver's seat is located on the right side of the vehicle and vehicles drive on the left. Under right-hand drive driving rules, the driver's seat is on the right, the overtaking lane is usually the right lane, and the driving direction in a roundabout is clockwise.

[0033] Left-hand drive driving rules refer to a traffic rule system where the driver's seat is on the left side of the vehicle and vehicles drive on the right. Under left-hand drive driving rules, the driver's seat is on the left, the overtaking lane is the left lane, and the driving direction in a roundabout is counterclockwise.

[0034] The method for converting between left-hand drive and right-hand drive logic in autonomous driving embodiments of this application can be applied to scenarios where left-hand drive driving rules are converted to right-hand drive driving rules, or vice versa, depending on actual deployment requirements. This bidirectional reversible design allows the same technical framework to simultaneously serve product lines entering different markets, eliminating the need to develop two independent conversion logics for different conversion directions, thus significantly reducing the costs of technology development and product maintenance.

[0035] Vehicle attitude is a geometric representation of the orientation of a vehicle in three-dimensional space, including but not limited to rotation matrices, quaternions, etc.

[0036] Joint transformation can refer to a composite transformation operation formed by applying the reflection matrix and the compensation matrix to the vehicle attitude in a specific multiplication order.

[0037] In some embodiments, when the vehicle attitude is represented by a rotation matrix, the specific operation of the joint transformation is to multiply the reflection matrix on the left by the rotation matrix and to multiply the compensation matrix on the right by the rotation matrix.

[0038] Left multiplication refers to performing matrix multiplication by placing the reflection matrix as the multiplier on the left side of the rotation matrix; right multiplication refers to performing matrix multiplication by placing the compensation matrix as the multiplier on the right side of the rotation matrix. The mathematical form of this operation is: Where R is the original vehicle attitude, M is the reflection matrix, and C is the compensation matrix. The vehicle attitude after joint transformation.

[0039] The reflection matrix acts on one side of the world coordinate system, flipping the sign of a specified coordinate axis component while leaving the other components unchanged. The compensation matrix acts on one side of the vehicle body coordinate system, flipping the sign of a specified coordinate axis component while leaving the other components unchanged. When performing a joint transformation on the rotation matrices, the reflection matrix multiplied on the left corresponds to the expression of the transformed world coordinate system, and the compensation matrix multiplied on the right corresponds to the expression of the transformed body coordinate system.

[0040] Specifically, both the reflection matrix and the compensation matrix are diagonal matrices; the reflection matrix is ​​used to flip the sign of the first coordinate axis component of the target input data while keeping the other coordinate axis components unchanged; the compensation matrix is ​​used to flip the sign of the second coordinate axis component of the target input data while keeping the other coordinate axis components unchanged.

[0041] Wherein, when the target input data is a three-dimensional vector, the first coordinate axis component represents the first element of the three-dimensional vector; when the target input data is a three-dimensional matrix, the first coordinate axis component represents the first row element of the three-dimensional matrix.

[0042] For example, reflection matrix Compensation matrix .

[0043] In a typical scenario involving left-hand drive switching, the first coordinate component of the vehicle's attitude is the X-axis. Taking the "East-North-Sky" (ENU) world coordinate system as an example, the X-axis corresponds to the east direction. The reflection matrix flips the sign of the first coordinate component, which geometrically means mirroring the world coordinate system along the YZ plane, i.e., swapping the east and west directions. After this reflection, a traffic scenario that originally drove on the right under left-hand drive rules appears as a traffic scenario that drives on the left in the mirrored world coordinate system. This corresponds to the mirror relationship between the driver's position and the lane direction in left-hand drive driving rules.

[0044] The second coordinate axis component refers to the coordinate axis that needs additional compensation. In a typical scenario, the second coordinate axis component is the Y-axis. Taking the "front-left-up" body coordinate system as an example, the Y-axis corresponds to the left side of the vehicle. After the reflection matrix is ​​multiplied by the rotation matrix on the left, the determinant of the result changes from +1 to -1, and no longer belongs to the special orthogonal group SO(3), that is, it is no longer a valid right-handed coordinate system rotation representation. The compensation matrix restores the determinant to +1 by flipping the sign of the Y-axis component of the body coordinate system and multiplying it on the right by the rotation matrix, so that the transformed rotation matrix satisfies the SO(3) constraint again.

[0045] By clearly defining the form and target of the reflection matrix and the compensation matrix, it is mathematically guaranteed that the transformed rotation matrix still satisfies the properties of the SO(3) group, providing a valid attitude input that conforms to the right-hand coordinate system constraint for subsequent processing modules, and avoiding planning decision deviations caused by incorrect attitude representation.

[0046] In some optional embodiments, when the vehicle attitude is represented by quaternions, the specific operation of the joint transformation can be equivalent to converting the original quaternion (w, x, y, z) into the target quaternion (-z, y, x, -w), where w, x, y, and z are the real part and three imaginary parts of the original quaternion, respectively.

[0047] The primitive quaternion (w, x, y, z) is a non-singular mathematical representation of a vehicle's orientation in three-dimensional space that satisfies the unit modulus constraint. Its four components correspond to a real part and an imaginary part along three orthogonal axes, respectively.

[0048] The target quaternion (-z, y, x, -w) is a new quaternion obtained by performing a fixed index rearrangement and sign flipping operation on each component of the original quaternion. This operation does not change its unit modulus property and is mathematically equivalent to the joint transformation process mentioned above when using a rotation matrix to represent vehicle attitude.

[0049] This application can determine the target quaternion by means of quaternion component index rearrangement and sign reversal, or by means of mapping rules derived from the algebraic isomorphism between the original quaternion and the reflection matrix and compensation matrix.

[0050] By directly mapping the original quaternion to the target quaternion, the vehicle attitude can still satisfy the rotation consistency constraint of the right-hand coordinate system in the mirror world without introducing matrix operation overhead. This allows the attitude transformation to be completed in a single cycle, significantly improving the real-time performance and stability under high-frequency control.

[0051] Step S220: Obtain the first output data generated after processing the second input data under the second driving rule, and perform a preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

[0052] Specifically, the first output data typically refers to the intermediate control quantity generated based on the second input data. For example, the first output data could be a sequence of planned trajectory points, the target heading angle, the desired lateral acceleration, etc.

[0053] In some embodiments, performing a preset mathematical transformation on the first output data may include the following steps: for the target vehicle posture in the first output data, when the target vehicle posture is transformed by a rotation matrix... When representing, the mathematical transformation is assumed to be: ,in, The target vehicle attitude is transformed using a preset mathematical method; when the target vehicle attitude is represented by a quaternion, the first output quaternion (w) will be used. x y , z Convert ) to the second output quaternion (-z) y x , -w ); where w x y , z These are the real part and three imaginary parts of the first output quaternion, respectively.

[0054] Specifically, when the target vehicle attitude is represented by a rotation matrix, the preset mathematical transformation is the same operation as the joint transformation of the reflection matrix and the compensation matrix. The only difference is that the object of the operation is changed to the target vehicle attitude in the first output data.

[0055] When the target vehicle attitude is represented by quaternions, as described in the preceding steps, the joint transformation converts the original quaternion (w,x,y,z) to (-z,y,x,-w). When performing a preset mathematical transformation on the first output data, the first output quaternion (w... x y , z ) converted to (-z y x , -w This transformation rule is consistent with the operation described above when performing joint transformation on vehicle attitude represented by quaternions, which also involves changing the object of operation to the target vehicle attitude in the first output data.

[0056] The second output data is the vehicle control commands restored to the original driving rules (i.e., the first driving rules), such as steering angle, longitudinal acceleration, yaw rate setpoints, etc.

[0057] By constructing a joint transformation mechanism centered on reflection and compensation matrices between the first and second driving rules, the transformed vehicle posture remains a valid right-handed coordinate system rotation representation, thereby reducing the risk of subsequent processing modules misunderstanding posture data due to coordinate system chirality errors. This joint transformation allows the vehicle to operate within a virtual mirrored driving rule without modifying the internal logic of core modules such as the planning module, reducing the workload of repeatedly developing algorithm logic for different driving rules. Furthermore, selectively transforming the original input data, performing calculations in the logical world, and then restoring the results to the original driving rule helps reduce system maintenance complexity and alleviates the maintenance burden of simultaneously modifying two sets of driving rules.

[0058] In some embodiments, such as Figure 3 As shown, in addition to vehicle attitude, the first input data may also include physical quantities such as vehicle position and vehicle speed. Therefore, the conversion method of the left and right steering logic of autonomous driving may also include steps S310, S320 and S330.

[0059] Step S310: Invert the world coordinate system position and world coordinate system velocity in the first input data using the reflection matrix.

[0060] World coordinate system position refers to the spatial coordinates of a vehicle or obstacle on the global map, usually represented as a (x, y, z) vector. World coordinate system velocity refers to the linear velocity vector of an object in the world coordinate system, also containing three components. These two physical quantities are polar vectors, and their transformation under spatial reflection is direct, that is, the coordinate axis components specified by the reflection matrix are inverted, while the other components remain unchanged.

[0061] Specifically, the reflection matrix is ​​multiplied on the left by the world coordinate system position vector p and the world coordinate system velocity vector v, respectively, to achieve... and The linear transformation is performed. Here, p and v represent the world coordinate system position vector and world coordinate system velocity vector before the transformation, respectively.

[0062] For example, when the reflection matrix M is applied to the world coordinate system position vector (x, y, z), it results in (-x, y, z), indicating that the X-axis coordinates are inverted while the Y and Z-axis coordinates remain unchanged. The transformation of the world coordinate system velocity vector is similar.

[0063] Step S320: Invert the vehicle body coordinate system acceleration in the first input data using the compensation matrix.

[0064] Vehicle coordinate system acceleration refers to the acceleration value measured in the vehicle's own coordinate system. Taking the "front-left-top" vehicle coordinate system as an example, it is usually expressed as acceleration components along the vehicle's forward direction, left-side direction, and vertical direction (α). x ,a y ,a z ).

[0065] Specifically, the compensation matrix is ​​multiplied on the left by the acceleration vector in the vehicle coordinate system to obtain the transformed vehicle coordinate system acceleration. , where a is the acceleration vector of the vehicle body coordinate system before the transformation.

[0066] For example, the compensation matrix C acts on the acceleration (a) of the vehicle body coordinate system. x ,a y ,a z After that, we get (a) x ,-a y ,a z ), which means that the Y-axis component is inverted, while the X-axis and Z-axis components remain unchanged.

[0067] Step S330: Invert the angular velocity of the vehicle body coordinate system in the first input data using the compensation matrix after sign flipping.

[0068] The vehicle's angular velocity in the vehicle's coordinate system refers to the angular velocity of rotation around the three axes of its own coordinate system, usually represented as (ωx, ωy, ωz). Angular velocity is a pseudo-vector (also called an axis vector), and its mathematical essence is the cross product of two extreme vectors. Specifically, the transformation formula for the vehicle's angular velocity in the vehicle's coordinate system is ω' = -Cω, where ω is the original angular velocity in the vehicle's coordinate system. First, the compensation matrix C is flipped to obtain -C, which is then applied to the original angular velocity. In a typical scenario, -C applied to the angular velocity (ωx, ωy, ωz) results in (-ωx, ωy, -ωz), indicating that the X-axis and Z-axis components are inverted, while the Y-axis component remains unchanged.

[0069] In some embodiments, when performing a preset mathematical transformation on the first output data, the preset mathematical transformation is also performed by inverting the coordinates of the world coordinate system position and the world coordinate system velocity in the first output data through a reflection matrix.

[0070] For the vehicle body coordinate system acceleration in the first output data, the preset mathematical transformation is also to invert the coordinates of the vehicle body coordinate system acceleration in the first output data by using a compensation matrix.

[0071] For the angular velocity in the vehicle coordinate system in the first output data, the preset mathematical transformation is also to invert the coordinates of the angular velocity in the vehicle coordinate system in the first output data by using a compensation matrix after sign flipping.

[0072] In a complete autonomous driving scenario, by clearly distinguishing the transformation rules of world coordinate system position, world coordinate system velocity (polar vector), vehicle coordinate system acceleration (vehicle coordinate system polar vector), and vehicle coordinate system angular velocity (pseudo vector), a fine-grained classification and processing of various physical quantities is achieved, ensuring the mathematical accuracy of various physical quantities when converting between left and right steering rules. Furthermore, since both the reflection matrix and the compensation matrix are diagonal matrices, their calculation of vector data can be simplified to a simple sign adjustment of each component, without the need for complex matrix multiplication operations. In autonomous driving systems that require high-frequency processing of large amounts of perception data, this low-complexity calculation method can meet real-time requirements while ensuring mathematical accuracy.

[0073] It should be noted that the first input data in this application, as well as the second input data, first output data, and second output data obtained after subsequent processing, only involve geometric motion physical quantities such as vehicle position, speed, acceleration, attitude, and angular velocity, and do not include semantic traffic signs such as left turn signals and right turn signals.

[0074] The aforementioned methods and steps can be used to achieve the left and right steering logic conversion for autonomous driving, which will not be elaborated here.

[0075] For semantic traffic signs, semantic transformation can be performed on the structured data transmitted between modules in the autonomous driving system, thereby enabling the left and right steering logic conversion of autonomous driving.

[0076] For example, the semantic meaning of "left turn green light on" output by the perception module can be transformed into "right turn green light on" (represented as "LEFT<=>RIGHT" in engineering implementation), while the semantic meaning of "straight ahead red light" remains unchanged. The structured data after semantic transformation is then sent to the planning module. In the control information output to the control module after processing by the planning module, the control direction related to left and right is reversed, thus achieving correct driving control in the real physical world. Similarly, the remaining limited number of semantic traffic signs can be semantically mapped sequentially using enumeration.

[0077] It should be understood that, although Figures 2 to 3 The steps in the flowchart are shown sequentially according to the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Figures 2 to 3 Unless otherwise expressly stated herein, the steps illustrated and other steps involved in the embodiments are not subject to strict order restrictions and may be performed in other orders. Furthermore, at least some steps in the foregoing embodiments may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but may be performed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but may be performed alternately or in turn with other steps or at least a portion of the sub-steps or stages of other steps.

[0078] In a second aspect, embodiments of this application provide a switching device for left-right steering logic in autonomous driving, such as... Figure 4 As shown, the conversion device 110 includes: a first conversion module 111 and a second conversion module 112.

[0079] The first conversion module 111 is used to acquire first input data under a first driving rule and convert the first input data into second input data under a second driving rule through a preset mathematical transformation; the preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data through a preset reflection matrix M and a preset compensation matrix C; wherein, the reflection matrix M is used to invert the coordinates of the vehicle posture, and the compensation matrix C is used to restore the vehicle posture after transformation by the reflection matrix M to a rotational representation that conforms to the right-hand coordinate system constraint; the first driving rule is a right-hand drive driving rule, and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule, and the second driving rule is a right-hand drive driving rule.

[0080] The second conversion module 112 is used to obtain the first output data generated after processing the second input data under the second driving rules, and to perform a preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

[0081] In some embodiments, when the vehicle attitude is represented by a rotation matrix, the first conversion module 111 further includes: A rotation matrix transformation unit (not shown) is used to left-multiply the reflection matrix by the rotation matrix and right-multiply the compensation matrix by the rotation matrix.

[0082] In some embodiments, when the vehicle attitude is represented by a quaternion, the first conversion module 111 further includes: The quaternion conversion unit is used to convert the original quaternion (w, x, y, z) into the target quaternion (-z, y, x, -w); where w, x, y, and z are one real part and three imaginary parts of the original quaternion, respectively.

[0083] In some embodiments, the first conversion module 111 further includes: The polar vector transformation unit (not shown) is used to invert the world coordinate system position and world coordinate system velocity in the first input data using the reflection matrix; A standard vector transformation unit (not shown) is used to invert the vehicle body coordinate system acceleration in the first input data using a compensation matrix; The pseudo-vector transformation unit (not shown) is used to invert the angular velocity of the vehicle body coordinate system in the first input data using a compensation matrix after sign flipping.

[0084] In some embodiments, the second conversion module 112 further includes: The rotation matrix inverse transformation unit is used to multiply the reflection matrix on the left and the compensation matrix on the right for the target vehicle attitude in the first output data when the target vehicle attitude is represented by a rotation matrix. The quaternion inverse conversion unit is used to convert the first output quaternion (w) when the target vehicle attitude is represented by a quaternion. x y , z Convert ) to the second output quaternion (-z) y x , -w ); where w x y , z These are the real part and three imaginary parts of the first output quaternion, respectively.

[0085] In some embodiments, both the reflection matrix and the compensation matrix are diagonal matrices; the reflection matrix is ​​used to perform sign flipping on the first coordinate axis component of the target input data, while the remaining coordinate axis components remain unchanged; the compensation matrix is ​​used to perform sign flipping on the second coordinate axis component of the target input data, while the remaining coordinate axis components remain unchanged.

[0086] For further specific limitations regarding the conversion device for left-right steering logic in autonomous driving, please refer to the limitations of the conversion method for left-right steering logic in autonomous driving described above. The conversion device can also be used to execute further steps of the conversion method for left-right steering logic in autonomous driving as described in the embodiments of this application, which will not be repeated here. Each module in the aforementioned conversion device for left-right steering logic in autonomous driving can be implemented entirely or partially through software, hardware, or a combination thereof. Each module can be embedded in or independent of the processor in a computer device in hardware form, or stored in the memory of a computer device in software form, so that the processor can call and execute the operations corresponding to each module.

[0087] In a third aspect, embodiments of this application provide an automatic driving left-right steering logic conversion system 500, the conversion system 500 including: a sensor group 510, a planning processor 520, a vehicle controller 530, and an automatic driving left-right steering logic conversion device 400 provided in any embodiment of the second aspect of this application.

[0088] Sensor group 510 is used to collect the first input data under the first driving rule; The planning processor 520 is used to perform calculations on the second input data to generate the first output data; the second input data is obtained by the conversion device through a preset mathematical transformation of the first input data; The vehicle controller 530 is used to receive the second output data and perform corresponding vehicle control based on the second output data; the second output data is obtained by the conversion device converting the first output data through a preset mathematical transformation; The automatic driving left and right steering logic conversion device 400 is used to execute the automatic driving left and right steering logic conversion method provided in any embodiment of the first aspect of this application.

[0089] Sensor group 510 is the perception front end of the autonomous driving system, responsible for collecting information about the vehicle's own state and the surrounding environment. It typically includes various sensors such as cameras, LiDAR, millimeter-wave radar, GPS, and inertial measurement units. In typical autonomous driving scenarios, sensor group 510 usually corresponds to the perception module of the autonomous driving system.

[0090] The Planning Processor 520 is the decision-making core of the autonomous driving system, responsible for generating driving trajectories and strategies based on perception information. It typically runs on a hardware platform with powerful computing capabilities. In typical autonomous driving scenarios, the Planning Processor 520 usually corresponds to the planning module of the autonomous driving system.

[0091] The vehicle controller 530 is the execution terminal of the autonomous driving system, responsible for converting planning instructions into specific vehicle control signals, typically including steering controllers, throttle controllers, and brake controllers. The conversion device 400, as an independent logic unit, connects between the sensor group 510 and the planning processor 520, and between the planning processor 520 and the vehicle controller 530, forming a complete data processing closed loop. By using the conversion device 400 as an independent intermediate layer, the planning processor 520 does not need to perceive whether the vehicle is actually operating under left-hand drive or right-hand drive rules, maintaining a single logical world at all times. This decoupled design allows the same planning algorithm to be seamlessly deployed to vehicles in different global markets, eliminating the need to develop multiple algorithm versions for different markets, significantly reducing R&D investment and version management costs.

[0092] In a fourth aspect, embodiments of this application provide an autonomous vehicle (such as...) Figure 1 As shown, the vehicle includes an automatic driving left and right steering logic switching system 500 as provided in the embodiments of the third aspect of this application.

[0093] In a fifth aspect, embodiments of this application provide a computer-readable storage medium having a computer program stored thereon, wherein the computer program, when executed by a processor, implements the steps of the method for switching between left and right steering logic for autonomous driving provided in any embodiment of the first aspect of this application.

[0094] Those skilled in the art will understand that all or part of the processes in the methods of the above embodiments can be implemented by a computer program instructing related hardware. The aforementioned computer program can be stored in a non-volatile computer-readable storage medium. When executed, the computer program can include the processes of the embodiments of the above methods. Any references to memory, storage, databases, or other media used in the embodiments of this application can include non-volatile and / or volatile memory. Non-volatile memory may include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM), or flash memory. Volatile memory may include random access memory (RAM) or external cache memory. By way of illustration and not limitation, RAM is available in a variety of forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), dual data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link DRAM (SLDRAM), RAMbus direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM), etc.

[0095] The technical features of the above embodiments can be combined in any way. For the sake of brevity, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this application.

[0096] The above embodiments merely illustrate several implementation methods of this application, and their descriptions are relatively specific and detailed, but they should not be construed as limiting the scope of protection of this application. It should be noted that those skilled in the art can make various modifications and improvements without departing from the concept of this application, and these all fall within the scope of protection of this application. Therefore, the scope of protection of this application should be determined by the appended claims.

Claims

1. A method for automatic conversion of rudder logic, characterized in that, The method includes: First input data under a first driving rule is obtained, and the first input data is converted into second input data under a second driving rule through a preset mathematical transformation; the preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data through a preset reflection matrix M and a preset compensation matrix C; wherein, the first input data is the geometric motion physical quantity of the vehicle itself; Wherein, the reflection matrix M is used to invert the coordinates of the vehicle attitude, and the compensation matrix C is used to restore the vehicle attitude after transformation by the reflection matrix M to a rotational representation that conforms to the right-hand coordinate system constraint; the first driving rule is a right-hand drive driving rule, and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule, and the second driving rule is a right-hand drive driving rule. Obtain the first output data generated after processing the second input data under the second driving rule, and perform the preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

2. The method of claim 1, wherein, When the vehicle attitude is represented by a rotation matrix R, the joint transformation is: ; wherein, is the joint-transformed target vehicle pose.

3. The method of claim 1, wherein, When the vehicle attitude is represented by quaternions, the joint transformation includes: Transform the original quaternion (w, x, y, z) into the target quaternion (-z, y, x, -w); where w, x, y, and z are one real part and three imaginary parts of the original quaternion, respectively.

4. The method according to any one of claims 1 to 3, characterized in that, The preset mathematical transformation also includes: The world coordinate system position and world coordinate system velocity in the first input data are inverted using the reflection matrix. The vehicle body coordinate system acceleration in the first input data is inverted using the compensation matrix. The angular velocity of the vehicle body coordinate system in the first input data is inverted by using the compensation matrix after sign flipping.

5. The method of claim 1, wherein, The step of performing the preset mathematical transformation on the first output data includes: For a target vehicle pose in the first output data, when the target vehicle pose is represented by a rotation matrix , the preset mathematical transformation is ; wherein, is the target vehicle pose after the preset mathematical transformation. When the target vehicle attitude is represented by a quaternion, the first output quaternion (w) will be... x y , z Convert ) to the second output quaternion (-z) y x , -w ); where w x y , z These are the real part and three imaginary parts of the first output quaternion, respectively.

6. The method according to any one of claims 1 to 3, characterized in that, Both the reflection matrix and the compensation matrix are diagonal matrices; the reflection matrix is ​​used to flip the sign of the first coordinate axis component of the target input data while keeping the other coordinate axis components unchanged; the compensation matrix is ​​used to flip the sign of the second coordinate axis component of the target input data while keeping the other coordinate axis components unchanged.

7. A switching device for left and right steering logic in autonomous driving, characterized in that, The device includes: A first conversion module is used to acquire first input data under a first driving rule and convert the first input data into second input data under a second driving rule through a preset mathematical transformation; the preset mathematical transformation includes: performing a joint transformation on the vehicle posture in the first input data through a preset reflection matrix M and a preset compensation matrix C; wherein, the reflection matrix M is used to invert the coordinates of the vehicle posture, and the compensation matrix C is used to restore the vehicle posture after transformation by the reflection matrix M to a rotational representation that conforms to the right-hand coordinate system constraint; the first driving rule is a right-hand drive driving rule, and the second driving rule is a left-hand drive driving rule; or, the first driving rule is a left-hand drive driving rule, and the second driving rule is a right-hand drive driving rule; The second conversion module is used to obtain the first output data generated after processing the second input data under the second driving rule, and to perform the preset mathematical transformation on the first output data to obtain the second output data required for vehicle control.

8. A switching system for left and right steering logic in autonomous driving, characterized in that, The system includes: a sensor array, a planning processor, a vehicle controller, and a switching device for the left and right steering logic of autonomous driving as described in claim 7. The sensor group is used to collect the first input data under the first driving rule; The planning processor is used to perform calculations on the second input data to generate the first output data; the second input data is obtained by the conversion device through a preset mathematical transformation of the first input data; The vehicle controller is used to receive the second output data and perform corresponding vehicle control based on the second output data; the second output data is obtained by the conversion device converting the first output data through the preset mathematical transformation; The automatic driving left and right steering logic switching device is used to perform the steps of the method as described in any one of claims 1 to 6.

9. An autonomous vehicle, characterized in that, The vehicle includes the conversion system as described in claim 8.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that, When the computer program is executed by a processor, it implements the steps of the method according to any one of claims 1 to 6.