An automatic parking control method, device and storage medium
By acquiring information about the vehicle's surrounding environment and historical trajectory, calculating the desired target turning angle, and employing feedforward and feedback algorithms for coordinated control, the problem of large control errors in existing automatic parking technologies has been solved, enabling safe and accurate parking of vehicles.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- HUMAN HORIZONS (SHANGHAI) AUTONOMOUS TECH CO LTD
- Filing Date
- 2022-12-29
- Publication Date
- 2026-06-09
AI Technical Summary
Existing automatic parking control algorithms have large control errors when dealing with sudden changes in dynamic trajectories and irregular trajectories, resulting in uneven vehicle steering and inability to park safely and accurately.
By acquiring information about the vehicle's surrounding environment, the system determines the stitching trajectory for automatic parking, calculates the desired target turning angle based on historical trajectory types, and uses feedforward and feedback algorithms to coordinate and control the vehicle to park in the target parking space. This allows for flexible responses to sudden trajectory changes and reduces control errors.
It improves the accuracy and safety of parking vehicles in target spaces, reduces steering errors, and ensures that vehicles can be parked smoothly in the designated positions.
Smart Images

Figure CN115743097B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of vehicle driver assistance technology, and in particular to an automatic parking control method, device and storage medium. Background Technology
[0002] With the continuous increase in car ownership, parking is becoming increasingly difficult, leading to the development of automatic parking technology. Automatic parking mainly uses sensors such as cameras and ultrasonic radar to identify parking spaces, plans the target trajectory through a vehicle planning module, and finally controls the speed and steering through a vehicle control module to guide the vehicle into the target parking space.
[0003] However, existing control algorithms have large control errors when dealing with dynamic trajectory changes and irregular trajectories, such as S-shaped reverse tangent arc trajectories and J-shaped trajectories, resulting in uneven vehicle steering and inability to park safely and accurately. Summary of the Invention
[0004] Based on this, this application provides an automatic parking control method, device, and storage medium to reduce vehicle turning angle control errors, accurately park in the target parking space, and improve vehicle safety.
[0005] Firstly, an automatic parking control method is provided, the method comprising:
[0006] Obtain environmental information about the vehicle's surroundings, including the location of the target parking space and obstacle information;
[0007] Based on location and obstacle information, determine the stitching trajectory for automatic parking;
[0008] Based on historical trajectories, determine the trajectory type for splicing the trajectories;
[0009] Based on the trajectory type of the spliced trajectory, the desired target turning angle is calculated, which is used to control the vehicle to park in the target parking space.
[0010] According to one feasible method in an embodiment of this application, determining the stitching trajectory of automatic parking based on location information and obstacle information includes:
[0011] Based on location and obstacle information, a standard trajectory for automatic parking is determined;
[0012] Based on the standard trajectory, determine the stitching trajectory for automatic parking.
[0013] According to one feasible method in an embodiment of this application, determining the stitching trajectory of automatic parking based on a standard trajectory includes:
[0014] The curvature of the pre-aiming trajectory is determined based on the curvature of the endpoint of the standard trajectory and the total length of the standard trajectory.
[0015] Based on the curvature of the pre-aiming trajectory, the direction value of the endpoint, and the preset spacing, determine the central angle between every two points in the pre-aiming trajectory;
[0016] The pre-aiming trajectory is determined based on the central angle, preset spacing, direction value of the endpoint, and position information and heading angle of the endpoint of the standard trajectory.
[0017] By stitching together the standard trajectory and the pre-aimed trajectory, the stitched trajectory for automatic parking is obtained.
[0018] According to one feasible method in an embodiment of this application, the curvature of the pre-aiming trajectory is determined based on the curvature of the endpoint of the standard trajectory and the total length of the standard trajectory, including:
[0019] Within a preset range of the endpoint of the standard trajectory, determine the adaptive length value of the trajectory formed by the point with the same curvature as the endpoint;
[0020] The curvature of the preview trajectory is determined based on the adaptive length value, the total length of the standard trajectory, and the curvature of the endpoint of the standard trajectory.
[0021] According to one achievable method in the embodiments of this application, the trajectory type includes static trajectory and dynamic mutation trajectory; the trajectory type of the spliced trajectory is determined based on historical trajectories, including:
[0022] Compare the spliced trajectory with the historical trajectory;
[0023] When the spliced trajectory is the same as the historical trajectory, the trajectory type of the spliced trajectory is determined to be a static trajectory;
[0024] When the spliced trajectory differs from the historical trajectory, the trajectory type of the spliced trajectory is determined to be a dynamic mutation trajectory.
[0025] According to one feasible method in an embodiment of this application, the desired target turning angle is calculated based on the trajectory type of the spliced trajectory, including:
[0026] If the trajectory type of the splicing trajectory is a dynamic mutation trajectory, determine whether the curvature of the pre-aiming point of the splicing trajectory is greater than a preset threshold.
[0027] When the curvature of the pre-aiming point of the stitching trajectory is greater than the preset threshold, the first pose information of the vehicle, the initial pre-aiming distance, the driving speed, the wheelbase, and the second pose information of the point with the shortest distance to the vehicle in the standard trajectory are obtained.
[0028] The desired target turning angle is calculated based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information.
[0029] According to one feasible method in an embodiment of this application, the desired target turning angle is calculated based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information, including:
[0030] Calculate the first desired target turning angle based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information;
[0031] Calculate the second desired target rotation angle based on the curvature of the pre-aiming point and the wheelbase;
[0032] The desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain.
[0033] According to one achievable method in an embodiment of this application, the method further includes:
[0034] When the curvature of the pre-aiming point of the stitching trajectory is less than or equal to a preset threshold, the desired target angle is calculated based on the first desired target angle and the first preset gain.
[0035] According to one feasible method in an embodiment of this application, the desired target turning angle is calculated based on the trajectory type of the spliced trajectory, including:
[0036] If the trajectory type of the spliced trajectory is a static trajectory, determine the trajectory shape of the spliced trajectory;
[0037] If the shape of the spliced trajectory is S-shaped or J-shaped, the desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain.
[0038] If the shape of the spliced trajectory is neither S-shaped nor J-shaped, the first desired target turning angle is taken as the desired target turning angle.
[0039] Secondly, a computer device is provided, comprising:
[0040] At least one processor; and
[0041] A memory communicatively connected to the at least one processor; wherein,
[0042] The memory stores computer instructions that can be executed by the at least one processor to enable the at least one processor to perform the method involved in the first aspect above.
[0043] Thirdly, a computer-readable storage medium is provided having computer instructions stored thereon, characterized in that the computer instructions are used to cause a computer to perform the methods involved in the first aspect above.
[0044] According to the technical content provided in the embodiments of this application, environmental information of the vehicle's surrounding environment is obtained. This environmental information includes the location information of the target parking space and obstacle information. Based on the location information and obstacle information, a splicing trajectory for automatic parking is determined. Based on historical trajectories, the trajectory type of the splicing trajectory is determined. Based on the trajectory type of the splicing trajectory, the desired target turning angle is calculated. The desired target turning angle is used to control the vehicle to park in the target parking space. Since the pre-aiming trajectory used to calculate the desired target turning angle is a splicing trajectory, which is obtained by splicing a segment of the pre-aiming trajectory to the end point of the existing trajectory, it ensures that an accurate desired target turning angle can be obtained when the vehicle reaches the end point. Furthermore, different trajectory types of the splicing trajectory result in different calculated desired target turning angles, flexibly responding to trajectory changes, further reducing vehicle control errors, enabling the vehicle to accurately park in the target parking space, and improving vehicle safety. Attached Figure Description
[0045] Figure 1 This is an application environment diagram of an automatic parking control method in one embodiment;
[0046] Figure 2 This is a flowchart illustrating an automatic parking control method in one embodiment;
[0047] Figure 3 This is a schematic diagram of the standard trajectory and the spliced trajectory in one embodiment;
[0048] Figure 4 This is a schematic structural diagram of a computer device in one embodiment. Detailed Implementation
[0049] The present application will be further described in detail below with reference to the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the present application and are not intended to limit the scope of the present application.
[0050] For ease of understanding, the system to which this application applies will first be described. The automatic parking control method provided in this application can be applied to, for example... Figure 1 In the system architecture shown, vehicle 100 includes an on-board terminal 110. The on-board terminal 110 acquires environmental information about the vehicle's surroundings, including the location information of the target parking space and obstacle information. Based on the location and obstacle information, it determines the stitching trajectory for automatic parking. Based on historical trajectories, it determines the trajectory type of the stitching trajectory. Based on the trajectory type, it calculates the desired target turning angle, which is used to control the vehicle to park in the target parking space. The on-board terminal 110 can be, but is not limited to, various personal computers or laptops connected to the vehicle.
[0051] Figure 2 A flowchart of an automatic parking control method provided in this application embodiment is shown. This method can be performed by, for example... Figure 1 The vehicle-mounted terminal 110 in the system shown executes this. For example... Figure 2 As shown, the method may include the following steps:
[0052] S210, obtains environmental information about the environment surrounding the vehicle.
[0053] Specifically, the vehicle's surrounding environment map is acquired by the camera device installed in the vehicle. The surrounding environment map can be an environment map within a preset distance of the vehicle. The preset distance can be determined according to actual business needs, actual product needs, or actual application scenarios.
[0054] Environmental information is obtained through a map of the vehicle's surroundings. This environmental information includes the location of the target parking space and obstacle information. The target parking space is the space where the user plans to park the vehicle, and its location information includes the location of the parking lines and the boundary information of the target parking space. Obstacles are objects that interfere with the vehicle's movement, such as people, vehicles, flower beds, etc. Obstacle information includes the shape, location, and volume of the obstacles.
[0055] During parking, the camera devices around the vehicle are activated to capture video images in real time. The onboard terminal can obtain environmental information from the captured video images, or it can obtain images of the vehicle's surrounding environment captured and saved by the camera devices from the vehicle's storage module. Depending on the needs of different application scenarios, the appropriate acquisition method can be selected to obtain environmental information.
[0056] S220 determines the stitching trajectory for automatic parking based on location and obstacle information.
[0057] The onboard terminal determines the exact location of the target parking space based on its location information, and identifies any obstacles between the vehicle and the target parking space using obstacle information. Based on the specific location of the target parking space and the obstacles, a standard trajectory for automatic parking is planned.
[0058] When the vehicle's aiming point exceeds the end of the standard trajectory, the end point is generally taken as the aiming point. If the standard trajectory is an S-shaped or J-shaped trajectory, the turning angle error when the vehicle reaches the end point will be large, making it impossible to accurately park the vehicle in the target parking space. By splicing a segment of the aiming trajectory to the end of the standard trajectory, a spliced trajectory is obtained, providing a suitable aiming point for calculating the turning angle at the end of the standard trajectory, thus reducing the turning angle error when the vehicle reaches the end point.
[0059] The pre-aiming trajectory that needs to be spliced can be calculated by the proportion of the length of the trajectory segment with the same endpoint curvature as the standard trajectory to the length of the standard trajectory.
[0060] S230, determine the trajectory type for splicing trajectories based on historical trajectories.
[0061] The onboard terminal updates the stitching trajectory based on the vehicle's real-time movement. The historical trajectory consists of all stitched trajectories generated before the current one. By comparing the current stitching trajectory with the previous one, the trajectory type is determined.
[0062] The trajectory types include static trajectories and dynamic mutation trajectories. When the trajectory type of the spliced trajectory is static, it indicates that the spliced trajectory at the current moment has not changed significantly from the spliced trajectory at the previous moment. When the trajectory type of the spliced trajectory is dynamic mutation, it indicates that the spliced trajectory at the current moment has changed from the spliced trajectory at the previous moment.
[0063] S240, calculate the desired target turning angle based on the trajectory type of the spliced trajectory.
[0064] If the stitched trajectory is a static trajectory, the desired target turning angle is calculated using a feedback control algorithm. If the stitched trajectory is a dynamic, abrupt change trajectory, it is further determined whether the curvature of the pre-aiming point of the stitched trajectory meets preset conditions. If it does, the desired target turning angle is calculated jointly using a feedforward algorithm considering gain and a feedback algorithm. If it does not meet the conditions, the desired target turning angle is calculated using only a feedback algorithm considering gain. The feedback algorithm and the feedforward algorithm will be described in detail later.
[0065] After calculating the desired target turning angle, the vehicle's wheels are steered according to the desired target turning angle, thereby controlling the vehicle to park in the target parking space.
[0066] As can be seen, this embodiment of the application obtains environmental information about the vehicle's surroundings, determines the splicing trajectory for automatic parking based on location and obstacle information, determines the trajectory type of the splicing trajectory based on historical trajectories, and calculates the desired target turning angle based on the trajectory type of the splicing trajectory. While ensuring that the desired target turning angle can be obtained accurately when the vehicle reaches the destination, different desired target turning angles are calculated based on different trajectory types of splicing trajectories, flexibly responding to trajectory changes, further reducing vehicle control errors, accurately parking in the target parking space, and improving vehicle safety.
[0067] As one feasible approach, the stitching trajectory for automatic parking is determined based on location and obstacle information, including:
[0068] Based on location and obstacle information, a standard trajectory for automatic parking is determined;
[0069] Based on the standard trajectory, determine the stitching trajectory for automatic parking.
[0070] The standard trajectory is planned based on the real-world environment surrounding the vehicle, obtained from location and obstacle information by the onboard terminal. The onboard terminal determines the exact location of the target parking space based on its location information and identifies any obstacles between the vehicle and the target parking space using obstacle information. Based on the specific location of the target parking space and the obstacles, a standard trajectory for automatic parking is planned. Following this standard trajectory, the vehicle can avoid obstacles and park itself in the target parking space.
[0071] In order to provide a suitable aiming point for the end of the standard track and reduce the turning angle error when the vehicle reaches the end, a segment of the aiming track is spliced into the end of the standard track to obtain the spliced track.
[0072] Specifically, the curvature of the pre-aiming trajectory is determined based on the curvature of the endpoint of the standard trajectory and the total length of the standard trajectory;
[0073] Based on the curvature of the pre-aiming trajectory, the direction value of the endpoint, and the preset spacing, determine the central angle between every two points in the pre-aiming trajectory;
[0074] The pre-aiming trajectory is determined based on the central angle, preset spacing, direction value of the endpoint, and position information and heading angle of the endpoint of the standard trajectory.
[0075] By stitching together the standard trajectory and the pre-aimed trajectory, the stitched trajectory for automatic parking is obtained.
[0076] The curvature of the endpoint of the standard trajectory is related to the shape of the endpoint. If the endpoint is a straight line, the curvature is 0. If the endpoint is a curve, the curvature is the minimum turning radius curvature.
[0077] As an feasible approach, when determining the curvature of the pre-aiming trajectory based on the curvature of the endpoint of the standard trajectory and the total length of the standard trajectory, firstly, within a preset range of the endpoint of the standard trajectory, determine the adaptive length value of the trajectory formed by points with the same curvature as the endpoint.
[0078] Then, the curvature of the pre-aiming trajectory is determined based on the adaptive length value, the total length of the standard trajectory, and the curvature of the endpoint of the standard trajectory.
[0079] Within the preset range of the endpoint of the standard trajectory, that is, near the endpoint of the standard trajectory, the preset range can be within a straight line from the endpoint, or it can be a circular or fan-shaped range with the endpoint as the center. The size of the preset range can be set according to actual needs and is not limited here.
[0080] The adaptive length value is the length of the trajectory formed by points with the same curvature as the endpoint of the standard trajectory near its endpoint. The pre-aiming trajectory curvature is determined using the following formula based on the adaptive length value, the total length of the standard trajectory, and the curvature of the endpoint of the standard trajectory:
[0081]
[0082] Where, ρ preview K represents the curvature of the pre-aiming trajectory. a L represents the curvature adaptive factor. end L represents the adaptive length value. total ρ represents the total length of the standard trajectory. end The curvature at the endpoint of the standard trajectory.
[0083] The direction of the endpoint can include both forward and backward directions, and can be represented by different values; for example, +1 represents the forward direction and -1 represents the backward direction. The preset spacing represents the distance between two points on the pre-aimed trajectory, and this distance needs to be preset. The central angle between every two points on the pre-aimed trajectory is the heading angle increment. Based on the curvature of the pre-aimed trajectory, the direction value of the endpoint, and the preset spacing, the central angle between every two points on the pre-aimed trajectory is determined using the following formula:
[0084] Δ theta =dir*Δ dist *ρ preview (2)
[0085] Where, Δ theta The central angle between any two points in the pre-aimed trajectory is represented by dir, which represents the direction value of the endpoint. Δ dist Indicates the preset spacing, ρ preview This indicates the curvature of the pre-aiming trajectory.
[0086] The position information of the endpoint of the standard trajectory includes the endpoint's position coordinates. Based on the central angle, preset spacing, the direction value of the endpoint, and the position coordinates and heading angle of the endpoint of the standard trajectory, the position coordinates and heading angle of each pre-aiming point on the pre-aiming trajectory are determined using the following formula:
[0087]
[0088]
[0089]
[0090] Among them, (x i+1 y i+i () represents the position coordinates of the (i+1)th preview point on the preview trajectory. Let x represent the heading angle of the (i+1)th aiming point. i y i () represents the position coordinates of the i-th aiming point on the aiming trajectory. Let dir represent the heading angle of the i-th aiming point, dir represent the direction of the destination, and Δ distIndicates the preset spacing, Δ theta The central angle between any two points in the pre-aiming trajectory is represented by , and i represents the number of pre-aiming points on the pre-aiming trajectory.
[0091] After calculating the position coordinates and heading angle of each pre-aiming point on the pre-aiming trajectory according to formulas (3), (4), and (5), each pre-aiming point is connected in sequence according to the arrangement of position coordinates to obtain the pre-aiming trajectory.
[0092] The pre-aimed trajectory is stitched onto the end point of the standard trajectory to obtain the stitched trajectory for automatic parking. For example... Figure 3 As shown, the left side is the standard trajectory, and the right side is the spliced trajectory. The trajectory below the endpoint of the spliced trajectory is the pre-aiming trajectory.
[0093] As one feasible approach, the trajectory type for splicing trajectories is determined based on historical trajectories, including:
[0094] Compare the spliced trajectory with the historical trajectory;
[0095] When the spliced trajectory is the same as the historical trajectory, the trajectory type of the spliced trajectory is determined to be a static trajectory;
[0096] When the spliced trajectory differs from the historical trajectory, the trajectory type of the spliced trajectory is determined to be a dynamic mutation trajectory.
[0097] The historical trajectory consists of all stitched trajectories prior to the generation of the current stitched trajectory. The trajectory type of the stitched trajectory is determined by comparing the current stitched trajectory with the previous stitched trajectory.
[0098] When the spliced trajectory is the same as the historical trajectory, it indicates that the spliced trajectory has not changed significantly, and the trajectory type of the spliced trajectory is determined to be a static trajectory. When the spliced trajectory is different from the historical trajectory, it indicates that the spliced trajectory has undergone a sudden change, and the trajectory type of the spliced trajectory is determined to be a dynamic change trajectory.
[0099] As one feasible approach, the desired target turning angle is calculated based on the trajectory type of the spliced trajectory, including:
[0100] If the trajectory type of the splicing trajectory is a dynamic mutation trajectory, determine whether the curvature of the pre-aiming point of the splicing trajectory is greater than a preset threshold.
[0101] When the curvature of the pre-aiming point of the stitching trajectory is greater than the preset threshold, the first pose information of the vehicle, the initial pre-aiming distance, the driving speed, the wheelbase, and the second pose information of the point with the shortest distance to the vehicle in the standard trajectory are obtained.
[0102] The desired target turning angle is calculated based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information.
[0103] If the spliced trajectory is a dynamic abrupt change trajectory, it will often exhibit control oscillations and slow convergence, resulting in large turning angle deviations for automatic parking and making it difficult to accurately park the vehicle in the target parking space.
[0104] To further reduce the error caused by the dynamic abrupt trajectory changes in the calculation of the desired target turning angle, firstly, it is determined whether the curvature of the pre-aiming point of the stitched trajectory is greater than a preset threshold. When the curvature of the pre-aiming point of the stitched trajectory is greater than the preset threshold, it indicates that the abrupt change in the stitched trajectory is relatively large, and a feedforward and feedback coordinated control strategy is adopted. The preset threshold can be set according to actual needs. To ensure that a suitable control strategy is selected to make the calculated desired target turning angle more accurate, the smaller the preset threshold, the better; for example, 0.01.
[0105] The first pose information is the vehicle's current pose information, which includes the vehicle's current position coordinates and heading angle. The second pose information is the pose information of the point on the standard trajectory that is closest to the vehicle, including the point's position coordinates and heading angle. The initial aiming distance is the starting distance when the vehicle determines the aiming point. The wheelbase is the distance between the vehicle's front and rear wheels.
[0106] Based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information, the desired target turning angle is calculated, specifically including:
[0107] Calculate the first desired target turning angle based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information;
[0108] Calculate the second desired target rotation angle based on the curvature of the pre-aiming point and the wheelbase;
[0109] The desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain.
[0110] Based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information, a feedback algorithm is used to calculate the first desired target turning angle. The calculation formula for the feedback algorithm is as follows:
[0111]
[0112] Where, δ fb Indicates the first desired target turning angle, l d The distance indicated by the aiming point is L, where L represents the wheelbase and α represents the angle between the rear wheel and the front wheel and the aiming point.
[0113] Among them, the pre-aiming distance l d It can be calculated using the following formula:
[0114] l d =L0+Kv V+K l E lateral +K h E head (7)
[0115]
[0116]
[0117] Where L0 represents the initial aiming distance, K v K represents the velocity gain. l K represents the lateral error gain. h E represents the heading angle error gain. lateral E represents the lateral error. head Represents the heading angle error, (x, y, (x) represents the first pose information. r y r , ) represents the second pose information.
[0118] It should be noted that K l <0,K v >0, K h <0.
[0119] Based on the curvature of the pre-aiming point and the wheelbase, a feedforward algorithm is used to calculate the second desired target rotation angle. The calculation formula for the feedforward algorithm is as follows:
[0120]
[0121] Where, δ ff The second desired target turning angle is represented by L, where L represents the wheelbase and R represents the target turning angle. lookahead This indicates the curvature of the aiming point.
[0122] Combining the feedforward and feedback algorithms, the desired target angle is calculated using the following formula based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain:
[0123] δ=K ff δ ff +K fb δ fb (11)
[0124] Where δ represents the desired target turning angle, K fb Indicates the first preset gain, δ fb K represents the first expected target turning angle. ff Indicates the second preset gain, δ ff This indicates the second desired target turning angle.
[0125] Wherein, the first preset gain is the feedback gain, and the second preset gain is the feedforward gain. Since the feedforward algorithm primarily controls the vehicle to maintain the current trajectory curvature, and the feedback algorithm primarily corrects errors caused during the control process of maintaining the target curvature, K... ff Choose a value greater than or equal to 1, K fb It is greater than 0 and less than 1.
[0126] As an feasible approach, when the curvature of the pre-aiming point of the stitching trajectory is less than or equal to a preset threshold, it indicates that the abrupt change in the stitching trajectory is relatively small. In this case, error correction is the primary focus, and a feedback control strategy that considers control gain can be adopted.
[0127] Based on the first desired target turning angle and the first preset gain, the desired target turning angle is calculated using the following formula:
[0128] δ=K fb δ fb (12)
[0129] Where δ represents the desired target turning angle, K fb Indicates the first preset gain, δ fb This indicates the first expected target turning angle.
[0130] As one feasible approach, the desired target turning angle is calculated based on the trajectory type of the spliced trajectory, including:
[0131] If the trajectory type of the spliced trajectory is a static trajectory, determine the trajectory shape of the spliced trajectory;
[0132] If the shape of the spliced trajectory is S-shaped or J-shaped, the desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain.
[0133] If the shape of the spliced trajectory is neither S-shaped nor J-shaped, the first desired target turning angle is taken as the desired target turning angle.
[0134] If the stitched trajectory is a static trajectory, it means that the trajectory does not change significantly at different times, there are no abrupt changes in the trajectory, and the trajectory curvature remains basically unchanged. However, it is also necessary to consider whether the shape of the stitched trajectory is S-shaped or J-shaped, which inherently have large curvature abrupt changes. The shape of the stitched trajectory can be determined by the curvature of all points on the trajectory. By iterating through the curvature of all points on the stitched trajectory, if there is a curvature that changes from a negative value to a positive value, the shape of the stitched trajectory is determined to be S-shaped; if there is a curvature that changes from 0 to a positive value or from 0 to a negative value, the shape of the stitched trajectory is determined to be J-shaped.
[0135] When the trajectory type of the spliced trajectory is a static trajectory but the trajectory shape is S-shaped or J-shaped, the desired target angle is calculated using formula (11) based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain. When the trajectory type of the spliced trajectory is a static trajectory and the trajectory shape is neither S-shaped nor J-shaped, the angle calculated using formula (6) is taken as the desired target angle.
[0136] It should be understood that, although Figure 2 The steps in the flowchart are shown sequentially as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless explicitly stated in this application, there is no strict order restriction on the execution of these steps, and they can be executed in other orders. Furthermore, Figure 2 At least some of the steps in the process may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily completed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least some of the sub-steps or stages of other steps.
[0137] According to embodiments of this application, this application also provides a computer device and a computer-readable storage medium.
[0138] like Figure 4 The diagram shown is a block diagram of a computer device according to an embodiment of this application. The term "computer device" is intended to represent various forms of digital computers or mobile devices. The digital computer may include a desktop computer, a portable computer, a workbench, a personal digital assistant, a server, a mainframe computer, and other suitable computers. The mobile device may include a tablet computer, a smartphone, a wearable device, etc.
[0139] like Figure 4 As shown, device 400 includes a computing unit 401, a ROM 402, a RAM 403, a bus 404, and an input / output (I / O) interface 405. The computing unit 401, ROM 402, and RAM 403 are interconnected via the bus 404. The input / output (I / O) interface 405 is also connected to the bus 404.
[0140] The computing unit 401 can execute various processes in the method embodiments of this application according to computer instructions stored in the read-only memory (ROM) 402 or computer instructions loaded from the storage unit 408 into the random access memory (RAM) 403. The computing unit 401 can be various general-purpose and / or special-purpose processing components with processing and computing capabilities. The computing unit 401 can include, but is not limited to, a central processing unit (CPU), a graphics processing unit (GPU), various dedicated artificial intelligence (AI) computing chips, various computing units running machine learning model algorithms, a digital signal processor (DSP), and any suitable processor, controller, microcontroller, etc. In some embodiments, the methods provided in the embodiments of this application can be implemented as computer software programs, which are tangibly contained in a computer-readable storage medium, such as the storage unit 408.
[0141] RAM 403 can also store various programs and data required for the operation of device 400. Part or all of the computer program can be loaded and / or installed on device 400 via ROM 802 and / or communication unit 409.
[0142] The input unit 406, output unit 407, storage unit 408, and communication unit 409 in device 400 can be connected to I / O interface 405. The input unit 406 can be, for example, a keyboard, mouse, touchscreen, or microphone; the output unit 407 can be, for example, a display, speaker, or indicator light. Device 400 can exchange information and data with other devices through the communication unit 409.
[0143] It should be noted that the device may also include other components necessary for normal operation. It may also include only the components necessary for implementing the solution of this application, without necessarily including all the components shown in the figures.
[0144] Various implementations of the systems and techniques described herein can be implemented in digital electronic circuit systems, integrated circuit systems, field programmable gate arrays (FPGAs), application-specific integrated circuits (ASICs), application-specific standard products (ASSPs), systems-on-a-chip (SOCs), payload programmable logic devices (CPLDs), computer hardware, firmware, software, and / or combinations thereof.
[0145] The computer instructions used to implement the methods of this application may be written in any combination of one or more programming languages. These computer instructions may be provided to the computing unit 401 such that when executed by the computing unit 401, such as a processor, the computer instructions cause the execution of the steps involved in the embodiments of the methods of this application.
[0146] The computer-readable storage medium provided in this application can be a tangible medium that can contain or store computer instructions for performing the steps involved in the method embodiments of this application. The computer-readable storage medium can be, but is not limited to, electronic, magnetic, optical, electromagnetic, and other forms of storage media.
[0147] The specific embodiments described above do not constitute a limitation on the scope of protection of this application. Those skilled in the art should understand that various modifications, combinations, sub-combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of this application should be included within the scope of protection of this application.
Claims
1. An automatic parking control method, characterized in that, The method includes: Acquire environmental information about the vehicle's surroundings, including the location information of the target parking space and obstacle information; Based on the location information and the obstacle information, a standard trajectory for automatic parking is determined; Within a preset range of the endpoint of the standard trajectory, an adaptive length value is determined for the trajectory formed by a point with the same curvature as the endpoint. The curvature of the pre-aiming trajectory is determined based on the adaptive length value, the total length of the standard trajectory, and the curvature of the endpoint of the standard trajectory. Based on the curvature of the pre-aiming trajectory, the direction value of the endpoint, and the preset spacing, determine the central angle between every two points in the pre-aiming trajectory; The pre-aiming trajectory is determined based on the central angle, the preset spacing, the direction value of the endpoint, and the position information and heading angle of the endpoint of the standard trajectory. By stitching together the standard trajectory and the pre-aimed trajectory, the stitched trajectory for automatic parking is obtained; Based on historical trajectories, determine the trajectory type of the spliced trajectory; The trajectory types include static trajectories and dynamic mutation trajectories; determining the trajectory type of the spliced trajectory based on historical trajectories includes: Compare the spliced trajectory with the historical trajectory; When the spliced trajectory is the same as the historical trajectory, the trajectory type of the spliced trajectory is determined to be a static trajectory; When the spliced trajectory is different from the historical trajectory, the trajectory type of the spliced trajectory is determined to be a dynamic mutation trajectory; Based on the trajectory type of the spliced trajectory, the desired target turning angle is calculated, and the desired target turning angle is used to control the vehicle to park in the target parking space.
2. The method according to claim 1, characterized in that, Based on the trajectory type of the spliced trajectory, calculate the desired target turning angle, including: If the trajectory type of the splicing trajectory is a dynamic mutation trajectory, determine whether the curvature of the pre-aiming point of the splicing trajectory is greater than a preset threshold. When the curvature of the pre-aiming point of the stitching trajectory is greater than a preset threshold, the first pose information of the vehicle, the initial pre-aiming distance, the driving speed, the wheelbase, and the second pose information of the point with the shortest distance to the vehicle in the standard trajectory are obtained. The desired target turning angle is calculated based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information.
3. The method according to claim 2, characterized in that, The step of calculating the desired target turning angle based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information includes: Calculate the first desired target turning angle based on the first pose information, the initial aiming distance, the driving speed, the wheelbase, and the second pose information; Calculate the second desired target rotation angle based on the curvature of the pre-aiming point and the wheelbase; The desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain.
4. The method according to claim 3, characterized in that, The method further includes: When the curvature of the pre-aiming point of the stitching trajectory is less than or equal to a preset threshold, the desired target angle is calculated based on the first desired target angle and the first preset gain.
5. The method according to claim 4, characterized in that, Based on the trajectory type of the spliced trajectory, calculate the desired target turning angle, including: If the trajectory type of the spliced trajectory is a static trajectory, determine the trajectory shape of the spliced trajectory; If the shape of the splicing trajectory is S-shaped or J-shaped, the desired target angle is calculated based on the first desired target angle, the first preset gain, the second desired target angle, and the second preset gain. If the shape of the splicing trajectory is neither S-shaped nor J-shaped, the first desired target turning angle is taken as the desired target turning angle.
6. A computer device, comprising: At least one processor; as well as A memory communicatively connected to the at least one processor; wherein, The memory stores computer instructions executable by the at least one processor, which, when executed by the at least one processor, enables the at least one processor to perform the method of any one of claims 1 to 5.
7. A computer-readable storage medium storing computer instructions thereon, characterized in that, The computer instructions are used to cause the computer to perform the method according to any one of claims 1 to 5.