A follow-up control method and system for smart car camera

By constructing a camera servo control model based on XGBoost, and combining information from multiple sensors and the human eye's gaze area, the problem of blind spots in the field of vision of intelligent vehicle cameras under complex road conditions was solved, and multi-factor coupled control of the camera was realized, thereby improving the safety and reliability of autonomous driving.

CN118254689BActive Publication Date: 2024-08-23SHANDONG UNIV OF SCI & TECH
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410385023.2
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-04-01
Publication Date
2024-08-23
Estimated Expiration
2044-04-01

AI Technical Summary

Technical Problem

Existing smart car cameras cannot effectively follow changes in vehicle position and posture when facing complex road conditions, resulting in blind spots. Furthermore, traditional servo control methods only consider a single factor and are difficult to solve the problem of multi-factor coupling.

Method used

Using a data-driven approach, a camera servo control model based on XGBoost is constructed by collecting information from the human eye's gaze area and various sensors. This model combines vehicle posture, road surface images, and steering wheel angle features to achieve multi-factor coupled control of the camera.

Benefits of technology

It effectively eliminates the blind spots in the camera's field of vision caused by changes in the vehicle's position during driving, improving the accuracy and safety of image acquisition and approaching the field of vision of a human driver.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118254689B
    Figure CN118254689B
Patent Text Reader

Abstract

The present invention belongs to the field of intelligent vehicle control technology, and discloses a follow-up control method and system for intelligent vehicle cameras. The present invention takes into account the joint influence of multiple factors such as vehicle posture, road surface image, steering wheel angle, etc. on the camera follow-up control, and in view of this multi-factor coupling problem, converts the complex mathematical modeling problem into a data-driven machine learning problem. The present invention uses an eye tracker to collect the human eye gaze area of ​​an experienced driver in the actual vehicle posture, and provides a reference for the camera to simulate the driver's eye movement while driving. By adjusting the camera posture, the collected human eye gaze area is located at the center of the camera's field of view, that is, the camera posture is considered to be the optimal camera posture under the current vehicle posture. The present invention well realizes the follow-up control of the on-board camera of an intelligent vehicle, and overcomes the problem of blind spots in the camera's field of view caused by changes in the vehicle posture.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention belongs to the technical field of intelligent vehicle control, and relates to a follow-up control method and system for an intelligent vehicle camera. Background Art

[0002] With the development of science and technology, smart cars have been applied to more and more fields, so improving the safety and reliability of smart cars has become an urgent problem to be solved. Real-time perception of the environment is an important prerequisite for autonomous driving and an important part of autonomous driving technology. Visual perception achieved by cameras is an important autonomous driving perception technology. Improving its safety and reliability is of great significance to improving the safety and reliability of smart cars. During the driving process of smart cars, due to the complex and changeable road slope and curvature, the pitch angle and yaw angle of the vehicle will change continuously. The smart car camera currently used is fixed to the vehicle, and its detection direction is fixed. When the vehicle goes uphill or downhill or turns, the camera's field of view is easy to deviate from the correct detection area, resulting in a certain blind spot, and the greater the slope or turning angle, the more obvious this phenomenon is, and there are certain safety hazards. Therefore, applying a follow-up control device to the smart car camera, so that the camera can autonomously rotate and correct the detection area according to the change of the vehicle's posture, is of great significance to avoid the generation of blind spots and improve the safety of autonomous driving vehicles.

[0003] By analyzing the existing smart car camera layout scheme, it is not difficult to find that the front-view camera used in the existing unmanned driving scheme has a fixed posture. When dealing with complex road conditions with large changes in curvature and slope, the vehicle's yaw angle and pitch angle change, but the camera cannot follow the vehicle's posture to adjust its field of view, resulting in the camera's image acquisition area not being accurate enough, resulting in blind spots in the camera image acquisition. Therefore, it is necessary to arrange multiple front-view cameras at the same time or use fisheye cameras with fan-shaped fields of view to fill the blind spots. Although the above methods can effectively solve the problem of camera field of view blind spots, the use of multiple cameras at the same time inevitably has a series of problems such as high cost, large debugging and calibration workload, complex structure, and cumbersome installation. And to process the images collected by multiple cameras at the same time, it is inevitable that the workload of image or data processing is large, which to a certain extent increases the requirements for smart car image processing algorithms and hardware. In addition, at present, there are almost no precedents at home and abroad for applying the follow-up control device to the follow-up control of smart car cameras to eliminate the camera field of view blind spots.

[0004] After analyzing a series of existing follow-up control methods, it is found that there are still some imperfections if they are to be applied to smart car cameras. For example, the existing follow-up control methods generally only collect device status information such as device posture or vehicle steering wheel angle to make the camera follow the device status; in the actual autonomous driving process, the ideal acquisition area of ​​the camera should actually be consistent with the focus area of ​​the human eye when the human driver is driving. Only considering the vehicle posture or steering wheel angle and other status information for camera follow-up control will inevitably cause deviations in the image acquisition area. In addition, traditional follow-up control methods usually only consider the influence of a single factor. For example, most methods only consider the influence of device posture or steering wheel angle. If the follow-up control method is to be applied to smart car cameras, the rotation of the camera should be affected by multiple factors such as vehicle posture, camera image acquisition, steering wheel angle, etc.; and for this multi-factor coupling problem, it is bound to be very difficult to solve it by establishing a complex mathematical mapping relationship. Summary of the invention

[0005] The purpose of the present invention is to propose a follow-up control method for a smart car camera. The method fully considers the joint influence of multiple factors such as vehicle posture, road surface image, steering wheel angle, etc. on the camera follow-up control, and for this multi-factor coupling problem, the complex mathematical modeling problem is converted into a data-driven machine learning problem. At the same time, the present invention also solves the problem of how to determine the optimal posture of the camera under a specific vehicle posture, realizes the follow-up control of the smart car's on-board camera, and well solves the problem of camera field blind spots caused by changes in vehicle posture during driving of the smart car.

[0006] In order to achieve the above object, the present invention adopts the following technical scheme:

[0007] A follow-up control method for a smart car camera comprises the following steps:

[0008] Step 1. Collect the gaze area of ​​the human eye, and obtain the rotation angle of the three coordinate axes of the camera coordinate system to the imu coordinate system through the joint external parameter calibration of the camera and imu as the output feature data set;

[0009] Step 2. Obtain the perception information of the vehicle's current state from the vehicle's nine-axis accelerometer, smart car camera, and vehicle-mounted CAN, respectively, and perform feature extraction to obtain vehicle posture features, road surface image features, and steering wheel angle features; and use the multi-dimensional features formed by combining the vehicle posture features, road surface image features, and steering wheel angle features as the input feature data set;

[0010] Step 3. Preprocess the features extracted in steps 1 and 2 to construct a data set with multidimensional features;

[0011] Step 4. Build a camera follow-up control model based on XGBoost, and use the data set with multi-dimensional features built in step 3 to train the camera follow-up control model to obtain a trained camera follow-up control model;

[0012] Among them, the multi-dimensional features composed of vehicle posture features, road image features and steering wheel angle features are used as the input of the model, and the rotation angles of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system are used as the output of the model;

[0013] Step 5. Collect the perception information of the vehicle's current state in real time, extract features from the collected perception information, and then input the extracted features into the trained camera follow-up control model to output the rotation angle of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system, and realize the follow-up control of the smart car's on-board camera according to the rotation angle of the three coordinate axes.

[0014] In addition, the present invention also proposes a follow-up control system for a smart car camera, which includes a computer device, a camera and a camera rotating bracket; wherein the camera and the camera rotating bracket are respectively connected to the computer device; the computer device includes a memory, a processor and a computer program stored in the memory.

[0015] The processor executes the computer program to implement the steps of the method described above;

[0016] When the camera follow-up control model outputs the three-axis rotation angle transformed from the camera coordinate system to the imu coordinate system based on the real-time perception information of the vehicle's current state, the computer device controls the camera rotation bracket to drive the camera to rotate, and realizes the follow-up control of the smart car's on-board camera based on the obtained three-axis rotation angle.

[0017] The present invention has the following advantages:

[0018] As described above, the present invention relates to a follow-up control method and system for a smart car camera. The method innovatively applies the follow-up control method to the smart car camera to solve the problem of blind spots in the camera field of view caused by changes in the vehicle posture during driving. Different from the traditional follow-up control method that only considers a single factor for follow-up control, the present invention considers the joint influence of multiple factors such as vehicle posture, road surface image, steering wheel angle, etc. on the camera follow-up control, and for this multi-factor coupling problem, the complex mathematical modeling problem is converted into a data-driven machine learning problem. As for how to determine the optimal posture of the camera under a specific vehicle posture, the present invention does not simply use the posture of the vehicle to determine the posture of the camera, but considers the industry's goal of making autonomous driving "more like a human", and believes that the camera, as the "eye of autonomous driving", its ideal image acquisition area should be consistent with the area of ​​focus of the human eye when the human driver is driving. The present invention uses an eye tracker to collect the gaze area of ​​experienced drivers in actual vehicle postures, providing a reference for the camera to simulate the driver's eye movement while driving. By adjusting the camera posture, the collected gaze area is located at the center of the camera's field of view, that is, the camera posture is considered to be the best camera posture under the current vehicle posture. The present invention well implements the follow-up control of the on-board camera of the smart car, and solves the problem of blind spots in the camera's field of view caused by changes in the vehicle posture during driving. BRIEF DESCRIPTION OF THE DRAWINGS

[0019] Figure 1 The figure is a processing flow chart of a follow-up control method for a smart car camera in an embodiment of the present invention.

[0020] Figure 2 Schematic diagram of online deployment of a follow-up control method for a smart car camera in an embodiment of the present invention.

[0021] Figure 3 A schematic diagram of a camera coordinate system constructed for an embodiment of the present invention.

[0022] Figure 4 Schematic diagram of the imu coordinate system constructed for an embodiment of the present invention.

[0023] Figure 5 Schematic diagram of a vehicle coordinate system constructed for an embodiment of the present invention. DETAILED DESCRIPTION

[0024] The present invention is further described in detail below with reference to the accompanying drawings and specific embodiments:

[0025] Example 1

[0026] During the driving of smart cars, due to the generation and continuous changes of the vehicle's yaw angle and pitch angle, the camera's detection area is prone to deviation, resulting in the inability to provide sufficient forward field of view, causing certain blind spots for the smart car. Therefore, it is necessary to design a camera automatic rotation control method so that the on-board camera can automatically rotate a certain angle following the changes in the vehicle's yaw angle and pitch angle, realize the camera's follow-up control, and provide a sufficient forward field of view for the smart car.

[0027] In view of the above technical problems, the present invention discloses a follow-up control method for a smart car camera, which mainly includes two parts: offline training and online deployment of a camera follow-up control model. The camera follow-up control model is trained and optimized in the offline training stage. The flowchart is as follows: Figure 1 In the online deployment phase, the camera tracking control model established through offline training is deployed on the smart car for real-car testing and application. The specific flow chart is as follows Figure 2 shown.

[0028] like Figure 1 As shown, in the offline training stage, the present invention extracts the perception information of the vehicle's current state from the common on-board sensors and signals of smart cars, such as the vehicle's nine-axis accelerometer, smart car camera, and on-board CAN, and performs feature extraction on the perception information of different types of sensors, thereby constructing a data set with multi-dimensional features.

[0029] As for how to determine the optimal camera posture under a specific vehicle posture, the present invention uses an eye tracker to collect the gaze area of ​​the human eyes of an experienced driver in the current state of the vehicle, thereby providing a reference for the camera to simulate the eye movement of the driver while driving, and adjusts the camera posture so that the collected gaze area is located at the center of the camera field of view, that is, the camera posture is considered to be the optimal camera posture under the current vehicle posture, and the camera and imu joint external parameter calibration is performed on the camera posture with the help of imu, so that the rotation matrix of the camera coordinate system relative to the imu coordinate system in the current state can be obtained, and the rotation angle of the three coordinate axes from the camera coordinate system to the imu coordinate system can be obtained. Finally, the XGBoost model is used to train the relationship model between the vehicle perception information and the optimal camera posture data, which is the camera follow-up control model.

[0030] like Figure 2 As shown in the figure, during the online deployment process, the vehicle's current state features are extracted from the vehicle's nine-axis accelerometer, smart car camera, and on-board CAN in real time, and input into the trained camera follow-up control model. The model outputs the rotation angle of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system, and then outputs the rotation angle signal to the follow-up control system that can control the camera to rotate around the X and Y axes of the camera coordinate system, thereby realizing camera follow-up control.

[0031] The specific steps of the follow-up control method for the smart car camera in this embodiment are described in detail below.

[0032] like Figure 1 As shown, the follow-up control method for a smart car camera includes the following steps:

[0033] Step 1. Collect the gaze area of ​​the human eye, and obtain the three-axis rotation angle of the camera coordinate system relative to the IMU coordinate system through the joint external parameter calibration of the camera and IMU as the output feature data set.

[0034] Step 1.1. Collect the driver's eye gaze area under different vehicle postures, that is, when the driver drives through roads with various road conditions, use an eye tracker to measure the driver's eye movements and determine the driver's eye gaze area.

[0035] Among them, the eye tracker uses, for example, Qixin Yiwei aSee Glasses eye tracker.

[0036] Step 1.2. Through the joint external parameter calibration of the camera and imu, the three-axis rotation angle of the camera coordinate system relative to the imu coordinate system is obtained, and the output feature data set of the camera follow-up control model is constructed.

[0037] The specific process of step 1.2 is as follows:

[0038] Step 1.2.1. Camera layout and installation. Fix the camera in the center of the front roof through the camera rotating bracket to ensure that the camera has a wide field of view and clear image acquisition when rotating around the X and Y axes of the camera coordinate system.

[0039] In this embodiment, the camera rotation bracket is relatively conventional, for example, a pan-tilt bracket, a universal bracket, etc. can be used. As long as the bracket can meet the requirements of the camera rotating around the X and Y axes of the camera coordinate system, no specific limitation is made here.

[0040] Step 1.2.2. After determining the human eye gaze area in step 1.1, under the vehicle state corresponding to the current human eye gaze area, adjust the camera position by rotating the bracket so that the collected human eye gaze area is located in the center of the camera field of view.

[0041] Since the shape of the human eye gaze area captured by the eye tracker is approximately circular and the shape of the camera field of view is rectangular, the present invention takes the intersection of the diagonals of the camera field of view as the center of the camera field of view, so that the center of the human eye gaze area coincides with the center of the camera field of view, that is, the collected human eye gaze area can be located in the center of the camera field of view.

[0042] Step 1.2.3. Install and use the autonomous driving sensor calibration toolbox on the industrial computer equipped with Ubuntu system and ROS system on the smart car, use the on-board imu to calibrate the camera with external parameters, and obtain the rotation matrix of the camera coordinate system to the imu coordinate system; define the rotation matrix as R, and its expression is as follows:

[0043]

[0044] Among them, pitch represents the X-axis rotation angle, roll represents the Y-axis rotation angle, and yaw represents the Z-axis rotation angle.

[0045] Step 1.2.4. The rotation matrix obtained in step 1.2.3 can be used to calculate the X-axis rotation angle pitch, Y-axis rotation angle roll, and Z-axis rotation angle yaw of the rotation transformation from the camera coordinate system to the imu coordinate system.

[0046] The specific method for solving the three angles of pitch, roll, and yaw is as follows:

[0047] Step 1.2.4.1. From the element R in the third row and first column of the rotation matrix 31 = -sin(pitch) value, calculate the X-axis rotation angle pitch of the camera coordinate system to the imu coordinate system;

[0048] Step 1.2.4.2. The element R in the third row and second column of the rotation matrix 32 =cos(pitch)sin(roll) value and the pitch obtained in step 1.2.4.1, calculate the Y-axis rotation angle roll from the camera coordinate system to the imu coordinate system;

[0049] Step 1.2.4.3. The element R in the second row and first column of the rotation matrix 21 =sin(yaw)cos(pitch) and the pitch obtained in step 1.2.4.2, calculate the Z-axis rotation angle yaw from the camera coordinate system to the imu coordinate system.

[0050] Step 1.2.5. Combine pitch, roll, and yaw into a 3D feature vector as the output feature dataset.

[0051] The camera coordinate system is defined as follows: the center O of the main optical axis of the camera C is the coordinate origin, the right is the positive direction of the X axis, the downward is the positive direction of the Y axis, and the forward is the positive direction of the Z axis. Figure 3 shown.

[0052] The origin of the imu coordinate system is at the origin of the gyroscope and accelerometer, and the three coordinate axes X', Y', and Z' are parallel to the corresponding axes of the gyroscope and accelerometer, respectively. Figure 4 shown.

[0053] in, Figure 4 The three arrow directions in the figure correspond to the positive directions of rotation of the corresponding coordinate axes.

[0054] Regarding the problem of how to determine the optimal camera posture under a specific vehicle posture, the present invention takes into account the industry's goal of making autonomous driving "more human-like", and believes that the camera, as the "eye of autonomous driving", its ideal image acquisition area should be consistent with the area of ​​focus of the human eye when a human driver is driving. By using an eye tracker, the human eye gaze area under the actual vehicle posture is collected, providing a reference for the camera to simulate the driver's eye movements when driving. By adjusting the camera posture, the collected human eye gaze area is located in the center of the camera's field of view, that is, the camera posture is considered to be the optimal camera posture under the current vehicle posture.

[0055] Step 2. Obtain the perception information of the vehicle's current state from the vehicle's nine-axis accelerometer, smart car camera, and on-board CAN, and perform feature extraction to obtain vehicle posture features, road image features, and steering wheel angle features.

[0056] The present invention collects perception information of the current state of the vehicle from the vehicle's nine-axis accelerometer, smart car camera, and vehicle-mounted CAN, and performs feature extraction on the collected perception information, which is conducive to constructing a data set with multi-dimensional features.

[0057] The vehicle posture feature vector has 6 dimensions, the road image feature vector has 5 dimensions, and the steering wheel angle feature vector has 1 dimension; the multi-dimensional features composed of the vehicle posture features, the road image features and the steering wheel angle features are used as the input feature data set.

[0058] The specific process of obtaining the above vehicle posture features, road surface image features and steering wheel angle features is described below.

[0059] I. The vehicle posture feature extraction process is as follows:

[0060] The vehicle's velocity and acceleration in the three axes of the vehicle coordinate system are extracted from the vehicle's nine-axis accelerometer to generate a 6-dimensional vehicle posture feature vector, including the vehicle's x-axis velocity v x , vehicle y-axis speed v y 、Vehicle z-axis speed v z , vehicle acceleration in the x-axis direction a x , vehicle acceleration in the y-axis direction a y And the vehicle's z-axis acceleration a z .

[0061] The vehicle coordinate system takes the vehicle's center of mass O as its origin, the positive direction of the x-axis passes through the vehicle's center of mass and is parallel to the ground and points to the front of the vehicle, the positive direction of the y-axis passes through the vehicle's center of mass and is parallel to the ground and points to the driver's left, and the positive direction of the z-axis passes through the vehicle's center of mass and points upwards. Figure 5 shown.

[0062] in, Figure 5 The three arrow directions in the figure correspond to the positive directions of rotation of the corresponding coordinate axes.

[0063] II. The process of road surface image feature extraction is as follows:

[0064] The ResNeXt model of transfer learning is used to extract features from the road surface image during vehicle driving, and then the PCA algorithm is used to reduce the dimension of the extracted feature vector to obtain the feature vector of the road surface image. The process is as follows:

[0065] Step 2.1. Use a camera to capture road surface images to obtain road surface images during vehicle driving. In this embodiment, for example, 10,000 road surface images during vehicle driving can be selected.

[0066] Step 2.2. In order to ensure the effectiveness and stability of model training, image preprocessing is performed.

[0067] In order to avoid the interference of the surrounding environment on the image perception information, the collected road image is preprocessed, the preset pixel area is cropped with the bottom edge of the road image as the extension line, and the cropped image is normalized into a standard image with a preset pixel size.

[0068] The preset pixel area is, for example, a pixel area cut by 60% with the bottom edge of the original image as an extension line. When the image is normalized to a standard image with a preset pixel size, the preset pixel size is, for example, 256×256 pixels.

[0069] For deep learning, since the 10,000 standard images obtained in step 2.2 have a small amount of data, data enhancement is used to augment the original road image, including: scaling, mirror flipping, changing contrast, and changing brightness. After sample augmentation, the image samples increased from 10,000 to 34,780.

[0070] Step 2.3. Use the pre-trained ResNeXt model to extract features from the standard image preprocessed in step 2.2.

[0071] The process of ResNeXt model feature extraction for standard images is as follows:

[0072] Step 2.3.1. Import the required libraries in the Python script, mainly including Pytorch and torchvision.

[0073] Step 2.3.2. Load the ResNeXt model pre-trained in Python using the torchvision.models module provided by Pytorch, perform feature extraction on the image samples augmented in step 2.2, keep other model parameters unchanged, and change the number of neurons in the last fully connected layer to 25.

[0074] The 25 neurons in the fully connected layer represent 25 possible road types, including:

[0075] There are 5 types of pavement color characteristics (black, gray, yellow, white, brown), 5 types of pavement texture characteristics (texture roughness, texture uniformity, texture direction, texture shape, texture continuity), 5 types of pavement shape characteristics (curvature, length, width, slope, flatness), 3 types of pavement marking characteristics (left turn sign, right turn sign, straight sign), and 7 types of pavement materials and types (asphalt pavement, gravel pavement, cement concrete pavement, cobblestone pavement, floor tile pavement, ice and snow pavement, wading pavement).

[0076] Step 2.3.3. Use NVIDIA GeForce RTX 2080Ti GPU to retrain the ResNeXt model, with Mini-Batch Size set to 32, number of iterations set to 80, and initial learning rate set to 0.001.

[0077] Step 2.3.4. During the ResNeXt model training process, 80% of the image samples are used as training sets and 20% of the image samples are used as validation sets. After the training is completed, the validation set is used to validate the model.

[0078] Step 2.3.5. Extract feature vectors of all images from the penultimate fully connected layer of the ResNeXt model, totaling 2048-dimensional road image feature vectors.

[0079] Step 2.4. Use the PCA algorithm to reduce the dimension of the road surface image features to obtain the reduced dimension road surface image features.

[0080] The present invention uses the PCA algorithm to reduce the dimension of road surface image features and retain the main feature information.

[0081] Using Python, first import the numerical computing library numpy, then import the road surface image feature vector extracted in step 2.3, and run the Python code of PCA dimensionality reduction to reduce the dimension of the road surface image features, and only retain the feature vectors with a contribution rate greater than or equal to 95%. The road surface image feature vector after dimensionality reduction has a total of 5 dimensions, including: road surface length (1 dimension), road surface curvature (1 dimension), road surface width (1 dimension), road surface slope (1 dimension), and road surface flatness (1 dimension).

[0082] III. The process of steering wheel angle feature extraction is as follows: collect the vehicle CAN signal, parse the signal according to the CAN communication protocol, and extract the 1D vehicle steering wheel angle feature vector from the vehicle CAN signal.

[0083] The three types of vehicle current state features extracted, namely vehicle posture features (6 dimensions), road image features (5 dimensions), and steering wheel angle features (1 dimension), are combined to obtain a 12-dimensional feature vector as the input feature data set.

[0084] Step 3. Preprocess the features extracted in step 1 and step 2 to construct a data set with multi-dimensional features. The preprocessing process is specifically to align the timestamps of the data after the features are extracted in step 1 and step 2.

[0085] The present invention uses the message_filter provided by the ROS system and adopts a method of completely aligning timestamps to synchronize the features extracted in step 1 and step 2, ensuring that all feature vectors are in the same time series.

[0086] Step 4. Build a camera following control model based on XGBoost, and use the data set with multi-dimensional features constructed in step 3 to train the camera following control model to obtain a trained camera following control model.

[0087] Among them, the multi-dimensional features (specifically 12-dimensional feature vectors in this embodiment) composed of vehicle posture features, road image features and steering wheel angle features are used as the input of the camera tracking control model, and the three-axis rotation angle of the camera coordinate system relative to the imu coordinate system is used as the output of the camera tracking control model.

[0088] The principle framework of XGBoost is mainly divided into the following five parts: feature division, boosting strategy, objective function, parallel processing, and boosting algorithm. The following is an explanation of the process of building the XGBoost camera follow-up control model in the present invention.

[0089] Step 4.1. After extracting the 12-dimensional vehicle current state features, these feature vectors are passed into the XGBoost model. The XGBoost model will determine the optimal feature partitioning point for each node based on the greedy algorithm to minimize the value of the objective function.

[0090] Step 4.2. XGBoost uses a gradient boosting strategy. In each iteration of the actual training process, XGBoost trains a new decision tree model to fit the residual of the previous model, thereby gradually improving the performance of the model.

[0091] Step 4.3. During the camera tracking control model training process, an objective function is used to measure the performance of the model. The objective function consists of a loss function and a regularization term. The regularization term is used to control the complexity of the model.

[0092] The loss function is used to measure the difference between the model prediction value and the actual value, that is, the difference between the predicted value of the rotation angle of the camera coordinate system output by the model relative to the imu coordinate system and the actual value in the dataset.

[0093] Step 4.4. During the camera tracking control model training process, parallel processing is used to accelerate the model training process. GPU is used for model training, and multi-core processors and distributed computing frameworks are used to improve the model training efficiency.

[0094] Step 4.5. After the camera tracking control model training is completed, an integrated model consisting of multiple weak learners will be obtained. XGBoost uses the boosting algorithm to combine these weak learners and finally obtain a more powerful integrated model.

[0095] The present invention uses the XGBoost algorithm package in the Scikit-learn tool library of Python, takes the 12-dimensional feature data set in step 2 as input, and the 3-dimensional feature data set in step 1 as output, to train the model.

[0096] The specific process of the camera following control model includes the following steps:

[0097] a. Import the data set and divide it into training set and validation set.

[0098] 80% of the data is used as the training set of the camera following control model, and 20% of the data is used as the validation set of the model.

[0099] b. Optimize and adjust the parameters of the camera tracking control model.

[0100] To optimize the model, the following parameters need to be adjusted and set: number of decision trees, maximum tree depth, learning rate, minimum loss function, tree subsample ratio, L1 regularization coefficient, and L2 regularization coefficient.

[0101] By returning the parameter combination and the corresponding model score, the best parameter combination is finally determined.

[0102] c. Camera tracking control model training and verification.

[0103] The model is trained based on the optimal parameters determined by parameter adjustment, and the trained model is used to predict the input data of the validation set. The prediction results are compared with the actual output features of the validation set.

[0104] The model effect is judged by indicators such as correlation coefficient, root mean square error, accuracy, and F1 score.

[0105] Among them, the closer the correlation coefficient value is to 1 and the closer the root mean square error value is to 0, the better the model effect is.

[0106] After the camera tracking control model effect meets the requirements, the model can be exported and saved. If the prediction accuracy is not met, consider re-adjusting the model and training parameters until the model prediction accuracy meets the requirements.

[0107] Step 5. Collect the perception information of the current state of the vehicle in real time and extract features from the collected perception information. Input the extracted features into the trained camera follow-up control model, output the rotation angle of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system, and realize the follow-up control of the smart car's on-board camera according to the rotation angle of the three coordinate axes.

[0108] Specifically, we first extract the perception information of the current state of the smart car and perform feature extraction. The feature extraction process is the same as step 2. We extract three types of features in real time during the driving process: vehicle posture features (6 dimensions), road image features (5 dimensions), and steering wheel angle features (1 dimension). We fuse them to construct a data set with 12-dimensional vehicle current state features.

[0109] The 12-dimensional data set of the vehicle's current state characteristics is input into the camera follow-up control model. The model outputs the rotation angles of the three coordinate axes from the camera coordinate system to the imu coordinate system based on the input vehicle's current state information. The follow-up control system in Example 2 controls the camera to rotate around the X and Y axes of the camera coordinate system, thereby realizing camera follow-up control.

[0110] Example 2

[0111] This embodiment 2 describes a follow-up control system for a smart car camera, which includes a computer device, a camera and a camera rotating bracket; wherein the camera and the camera rotating bracket are respectively connected to the computer device; the computer device includes a memory, a processor and a computer program stored in the memory.

[0112] The computer device in this embodiment is the control device on the smart car.

[0113] The camera is fixed at the center of the front roof through the camera rotating bracket to ensure that the camera has a wide field of view and clear image acquisition when rotating around the X and Y axes of the camera coordinate system.

[0114] The camera rotation bracket is relatively conventional, for example, a gimbal bracket, a universal bracket, etc., as long as the bracket can satisfy the rotation of the camera around the X and Y axes of the camera coordinate system, no specific limitation is made here.

[0115] When the processor executes the above computer program, the steps of the method described in the above embodiment 1 can be implemented.

[0116] Dangdang camera tracking control model collects the perception information of the current state of the vehicle in real time, outputs the three-axis rotation angle of the camera coordinate system relative to the imu coordinate system, and then the computer equipment controls the camera rotation bracket to drive the camera to rotate, and realizes the tracking control of the smart car's on-board camera according to the three-axis rotation angle of the camera coordinate system relative to the imu coordinate system.

[0117] The method and system described in the present invention, by innovatively applying the follow-up control method to the camera of the smart car, effectively solves the problem of camera blind spots caused by changes in vehicle posture during driving of the smart car.

[0118] Of course, the above description is only a preferred embodiment of the present invention, and the present invention is not limited to the above embodiments. It should be noted that all equivalent substitutions and obvious deformation forms made by any technician familiar with the field under the guidance of this specification fall within the essential scope of this specification and should be protected by the present invention.

Claims

1. A follow-up control method for a smart car camera, It is characterized in that The steps include: Step 1. Collect the gaze area of ​​the human eye, and obtain the rotation angle of the three coordinate axes from the camera coordinate system to the imu coordinate system by calibrating the camera and imu together with external parameters as the output feature data set; Step 1.

1. Collect the driver's eye gaze area under different vehicle postures, that is, when the driver drives through roads with various road conditions, use an eye tracker to measure the driver's eye movements and determine the driver's eye gaze area; Step 1.

2. Through the joint external parameter calibration of the camera and IMU, the rotation angles of the three coordinate axes transformed from the camera coordinate system to the IMU coordinate system are obtained, and the output feature data set of the camera follow-up control model is constructed; Step 1.2.

1. Fix the camera at the center of the front roof through the camera rotating bracket to ensure that the camera has a wide field of view and clear image acquisition when rotating around the X and Y axes of the camera coordinate system; Step 1.2.

2. After determining the human eye gaze area in step 1.1, in the vehicle state, adjust the camera posture so that the collected human eye gaze area is located at the center of the camera field of view; Step 1.2.

3. Use the on-board imu to calibrate the camera with external parameters and obtain the rotation matrix from the camera coordinate system to the imu coordinate system; define the rotation matrix as R, and its expression is as follows: Step 1.2.

4. The rotation matrix obtained in step 1.2.3 can be used to calculate the X-axis rotation angle pitch, Y-axis rotation angle roll and Z-axis rotation angle yaw of the camera coordinate system to the imu coordinate system; The specific method for solving the three angles of pitch, roll, and yaw is as follows: Step 1.2.4.

1. The element R in the third row and first column of the rotation matrix 31 = -sin(pitch) value, calculate the X-axis rotation angle pitch of the camera coordinate system to the imu coordinate system; Step 1.2.4.

2. The element R in the third row and second column of the rotation matrix 32 =cos(pitch)sin(roll) value and the pitch obtained in step 1.2.4.1, calculate the Y-axis rotation angle roll from the camera coordinate system to the imu coordinate system; Step 1.2.4.

3. The element R in the second row and first column of the rotation matrix 21 =sin(yaw)cos(pitch) value and pitch obtained in step 1.2.4.2, calculate the Z-axis rotation angle yaw from the camera coordinate system to the imu coordinate system; Step 1.2.

5. Combine pitch, roll and yaw into a 3D feature vector as the output feature dataset; The camera coordinate system is defined as follows: the center O of the main optical axis of the camera C is the coordinate origin, the right is the positive direction of the X axis, the downward is the positive direction of the Y axis, and the forward is the positive direction of the Z axis; Step 2. Obtain the perception information of the vehicle's current state from the vehicle's nine-axis accelerometer, smart car camera, and vehicle-mounted CAN, respectively, and perform feature extraction to obtain vehicle posture features, road surface image features, and steering wheel angle features; and use the multi-dimensional features formed by combining the vehicle posture features, road surface image features, and steering wheel angle features as the input feature data set; Step 3. Preprocess the features extracted in steps 1 and 2 to construct a data set with multidimensional features; Step 4. Build a camera follow-up control model based on XGBoost, and use the data set with multi-dimensional features built in step 3 to train the camera follow-up control model to obtain a trained camera follow-up control model; The multidimensional features composed of vehicle posture features, road image features and steering wheel angle features are used as the input of the model, and the rotation angles of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system are used as the output of the model; Step 5. Collect the perception information of the vehicle's current state in real time, extract features from the collected perception information, and then input the extracted features into the trained camera follow-up control model to output the rotation angle of the three coordinate axes transformed from the camera coordinate system to the imu coordinate system, and then realize the follow-up control of the smart car's on-board camera according to the rotation angle of the three coordinate axes.

2. The follow-up control method for a smart car camera according to claim 1, It is characterized in that In step 2, the process of extracting vehicle posture features is as follows: The vehicle's velocity and acceleration in the three axes of the vehicle coordinate system are extracted from the vehicle's nine-axis accelerometer to generate a 6-dimensional vehicle posture feature vector, including the vehicle's x-axis velocity v x , vehicle y-axis speed v y 、Vehicle z-axis speed v z , vehicle acceleration in the x-axis direction a x , vehicle acceleration in the y-axis direction a y And the vehicle's z-axis acceleration a z ; The vehicle coordinate system takes the vehicle's center of mass O as its origin. The positive direction of the x-axis passes through the vehicle's center of mass and is parallel to the ground, pointing to the front of the vehicle. The positive direction of the y-axis passes through the vehicle's center of mass and is parallel to the ground, pointing to the driver's left. The positive direction of the z-axis passes through the vehicle's center of mass and points upward.

3. The follow-up control method for a smart car camera according to claim 1, It is characterized in that In the step 2, a ResNeXt model of transfer learning is used to extract features of road surface images during vehicle driving, and then a PCA algorithm is used to perform dimensionality reduction processing on the extracted feature vectors to obtain feature vectors of the road surface images.

4. The follow-up control method for a smart car camera according to claim 3, It is characterized in that The step 2 is specifically as follows: Step 2.

1. Use a camera to capture a road surface image to obtain a road surface image during vehicle driving; Step 2.

2. Preprocess the road surface image collected in step 2.1, crop a preset pixel area with the bottom edge of the road surface image as an extension line, and normalize the cropped image into a standard image with a preset pixel size; Step 2.

3. Use the pre-trained ResNeXt model to extract features from the standard image preprocessed in step 2.2; Step 2.

4. Use the PCA algorithm to reduce the dimension of the road surface image features to obtain the reduced dimension road surface image features.

5. The follow-up control method for a smart car camera according to claim 1, It is characterized in that In step 3, the process of preprocessing the features extracted in step 1 and step 2 is as follows: The output feature vector obtained in step 1 and the input feature vector obtained in step 2 are synchronized in time by fully aligning the timestamps, ensuring that all feature vectors are in the same time series.

6. A follow-up control system for a smart car camera, comprising a computer device, a camera and a camera rotating bracket; in, The camera and the camera rotating bracket are respectively connected to a computer device; the computer device includes a memory, a processor and a computer program stored in the memory, wherein the processor executes the computer program to implement the follow-up control method for a smart car camera according to any one of claims 1 to 5; When the camera follow-up control model outputs the three-axis rotation angle transformed from the camera coordinate system to the imu coordinate system based on the real-time perception information of the vehicle's current state, the computer device controls the camera rotation bracket to drive the camera to rotate, and realizes the follow-up control of the smart car's on-board camera based on the obtained three-axis rotation angle.