A Method for Predicting and Controlling the Trajectory of Goods Placement on a Clamping Cart Based on Transformer Networks
By using a Transformer network-based cargo placement trajectory prediction model for unmanned gripper trucks, the accuracy and adaptability issues of trajectory prediction in complex environments were resolved, achieving efficient and precise cargo placement control and improving the automated warehousing efficiency of unmanned driving systems.
Patent Information
- Application Number
- CN202411893698.4
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-12-02
- Estimated Expiration
- 2044-12-20
AI Technical Summary
Existing methods for predicting the cargo stacking trajectory of unmanned gripper vehicles suffer from insufficient accuracy, poor adaptability, and high computational complexity in complex environments, especially due to long-term reliance on modeling and insufficient environmental adaptability.
A cargo placement trajectory prediction model based on Transformer network is adopted. By combining the input embedding layer, multi-layer Transformer encoder and output layer, combined with self-attention mechanism and feedforward neural network, the motion trajectory of the clamping vehicle is predicted. The model is optimized by cross-entropy loss function, and the control command is adjusted in real time to achieve accurate placement.
It improves the accuracy and real-time performance of trajectory prediction, enhances the adaptability of the clamping vehicle in complex environments, ensures accurate stacking of goods, and improves operational efficiency and safety.
Smart Images

Figure CN119960438B_ABST
Abstract
Description
Technical Field
[0001] This invention relates to the field of unmanned gripper vehicle technology, and in particular to a method for predicting and controlling the cargo stacking trajectory of a gripper vehicle based on a Transformer network. Background Technology
[0002] With the rapid development of intelligent driving technology and deep learning, the application of unmanned vehicles in logistics and warehousing has gradually become widespread, becoming an important technological means to promote industry automation. As a core piece of equipment in modern warehousing and logistics systems, the unmanned gripper truck's main task is to transport goods (such as bales, pallets, etc.) from the storage area to a designated location and perform precise stacking operations.
[0003] A top-down view of the unmanned gripper vehicle's working scene as follows: Figure 1 If the stacking error is too large, such as Figure 2 The diagram shows a risk of collapse. This invention aims to improve the accuracy and efficiency of unmanned gripper trucks in complex warehousing environments by introducing a Transformer deep learning network, thereby reducing deviations, ensuring operational safety, and contributing to the modernization and intelligent development of agriculture.
[0004] In recent years, deep learning algorithms based on Recurrent Neural Networks (RNNs) have demonstrated outstanding performance in time series modeling. However, RNNs have certain limitations in modeling long-term dependencies, and the introduction of attention mechanisms provides an effective solution to this problem. Attention mechanisms, by dynamically weighting relevant information, can significantly improve the model's predictive ability and robustness in complex environments. However, currently, there are no algorithms that combine attention mechanisms with recurrent neural networks to address the problem of cargo stacking deviation in unmanned cargo-carrying vehicles.
[0005] Fujii et al. proposed a trajectory prediction model based on a two-block RNN to address the problem of incomplete trajectory prediction caused by missed detections. This model borrows from the Bayesian filtering framework, using two RNNs to handle successful and failed detections respectively, thus optimizing the estimation of the hidden state. Experimental results show that this method significantly improves performance compared to baseline methods on the public datasets ETH and UCY. (R. Fujii, J. Vongkulbhisal, R. Hachiuma and H. Saito, "A Two-Block RNN-Based Trajectory Prediction From Incomplete Trajectory," in IEEE Access, vol. 9, pp. 56140-56151, 2021, doi:10.1109 / ACCESS.2021.3072135.)
[0006] Lan You et al. proposed an extended sequence-to-sequence model based on AIS data. A gated recurrent unit (GRU) network encodes historical spatiotemporal sequences into context vectors, preserving the sequential relationships between trajectory positions and mitigating the gradient descent problem. The GRU network acts as a decoder, outputting the target trajectory position sequence. Real AIS data from the Chongqing and Wuhan sections of the Yangtze River were selected as typical experimental areas for evaluation. The proposed ST-Seq2Seq model was compared with baseline models LSTM-RNN and GRU-RNN in short-term trajectory prediction experiments. A 10-minute historical trajectory sequence was used to predict the trajectory sequence for the next 5 minutes. Overall, the results show that the accuracy of LSTM and GRU networks decreases with the increase of the number of predicted trajectory points when using recursive methods to predict continuous trajectory point sequences. In contrast, the extended sequence-to-sequence model exhibits satisfactory stability in different shipping channels. (L.You et al., "ST-Seq2Seq: ASpatio-Temporal Feature-Optimized Seq2Seq Model for Short-Term VesselTrajectory Prediction," in IEEEAccess, vol.8, pp.218565-218574, 2020, doi: 10.1109 / ACCESS.2020.3041762.)
[0007] A research team from Chang'an University proposed a vehicle lane-changing trajectory prediction method based on random forest and an improved Informer model. This method collects vehicle driving information using onboard sensors and natural driving datasets. After preprocessing and feature selection using a random forest algorithm, the improved Informer model is used for trajectory prediction. (CN117807413B Vehicle Lane-Changing Trajectory Prediction Method Based on Random Forest and Improved Informer Model [ZH])
[0008] In summary, current trajectory prediction research has shown promising methods in specific application scenarios such as pedestrian, ship, and vehicle lane changes, including biblock RNNs, extended Seq2Seq models, and improved Informer models. However, these studies also reveal some common shortcomings, including limited model generalization ability, declining long-term prediction accuracy, insufficient adaptability in complex environments, dependence on large amounts of high-quality data, and high computational complexity.
[0009] To overcome the above problems, this invention proposes a method for predicting and controlling the trajectory of cargo stacking on a clamping vehicle based on a Transformer network. Summary of the Invention
[0010] The purpose of this invention is to address the technical deficiencies in the existing technology for predicting the trajectory of goods placed on clamping vehicles, and to provide a method for predicting and controlling the trajectory of goods placed on clamping vehicles based on Transformer networks.
[0011] The technical solution adopted to achieve the purpose of this invention is:
[0012] A method for predicting and controlling the trajectory of cargo stacking on a clamping vehicle based on a Transformer network includes the following steps:
[0013] Step 1: Construct a cargo placement trajectory prediction model for the clamping vehicle. This model includes an input embedding layer, multiple Transformer encoder layers, and an output layer. Each Transformer encoder layer includes a self-attention mechanism and a feedforward neural network. The dynamic state of the clamping vehicle is input into the model, and the predicted trajectory Y at time t is output. pred (t);
[0014] Step 2: Calculate the predicted trajectory Y obtained in Step 1. pred (t) and the actual trajectory Y actual Bias(t) is the deviation of (t).
[0015] Step 3: Construct training and test sets. Using the training set, train the cargo placement trajectory prediction model of the clamping vehicle based on the cross-entropy loss function. Use the test set to verify the prediction ability of the cargo placement trajectory prediction model of the clamping vehicle.
[0016] Step 4: Based on the deviation Bias(t) obtained in Step 2, obtain the control command U(t) of the adjusted clamping vehicle to ensure the accuracy of the position of the goods during the stacking process.
[0017] In the above technical solution, in step 1, the dynamic state includes multiple features, including the position, speed, accelerator pedal travel, and brake pedal travel of the clamping vehicle.
[0018] In the above technical solution, in step 1, the dynamic state is input into the input embedding layer to obtain a high-dimensional feature vector X. embed (t), the high-dimensional feature vector X embed The formula for calculating (t) is:
[0019] X embed (t) = Embedding(X(t)),
[0020] Where X(t) is the input feature at time t, X embed (t) is the high-dimensional feature vector after embedding.
[0021] In the above technical solution, in step 1, the high-dimensional feature vector X embed (t) serves as the input to the first Transformer encoder layer, and outputs H. (t) H (t) =TransformerEncoder(X embed (t)), the output of the adjacent previous Transformer encoder layer is used as the input of the next Transformer encoder layer, and the output of the last Transformer encoder layer is H. (T) .
[0022] In the above technical solution, in step 1, H (T) As the input to the output layer, the predicted trajectory Y at output time t is... pred (t), Y pred (t)=f Output (H (T) ).
[0023] In the above technical solution, in step 2, Bias(t) = Y actual (t)-Y pred (t).
[0024] In the above technical solution, the calculation formula for the cross-entropy loss function in step 3 is as follows:
[0025]
[0026] Among them, Y true (i) represents the true trajectory at time i, Y pred (i) represents the predicted trajectory at time i, and n represents the time step. The parameters of the cargo placement trajectory prediction model for the clamping vehicle are optimized by minimizing the cross-entropy loss Loss.
[0027] In the above technical solution, in step 4, U(t) = U base +K·Bias(t), U base K is the basic control command, and K is the compensation coefficient.
[0028] In the above technical solution, the method for predicting and controlling the cargo placement trajectory of a clamping vehicle based on a Transformer network further includes step 5, which involves conducting actual operation tests on the constructed cargo placement trajectory prediction model of the clamping vehicle, and verifying the accuracy of the prediction of the cargo placement trajectory prediction model and the operating efficiency of the clamping vehicle through quantitative indicators.
[0029] In the above technical solution, the quantitative indicator is the average trajectory deviation or operation time.
[0030] Compared with the prior art, the beneficial effects of the present invention are:
[0031] 1. Improved Prediction Accuracy: Traditional methods for predicting cargo placement trajectories on clamp-on trucks often rely on linear models or simple neural networks, which fail to fully capture the dynamic characteristics of the trucks in complex environments. By utilizing a deep Transformer network and effectively integrating input features through a self-attention mechanism, the accuracy of trajectory prediction is improved.
[0032] 2. Enhanced Real-Time Performance and Adaptability: Through real-time data acquisition and processing, combined with the parallel computing capabilities of Transformer, accurate trajectory predictions can be generated in a short time, adapting to rapidly changing warehousing environments. This feature enables the clamping vehicle to respond promptly to environmental changes, ensuring accurate placement of goods.
[0033] 3. Comprehensive consideration of multiple state information: By taking multiple state information such as the position, speed, and throttle and brake pedal travel of the clamping vehicle as input, the dynamic behavior of the clamping vehicle is fully reflected. This provides richer feature support for trajectory prediction and can more comprehensively understand the motion mode of the clamping vehicle compared with existing technologies.
[0034] 4. Optimized Control Strategy: By calculating the deviation between the predicted trajectory and the actual trajectory, the model can adjust the control commands of the clamping vehicle in a timely manner, achieving precise cargo stacking. Compared with traditional methods, the model can provide a more intelligent feedback control strategy in dynamic environments, improving operational efficiency. Attached Figure Description
[0035] Figure 1 It is a top-down view of the application scenario;
[0036] Figure 2 It's due to placement errors. Detailed Implementation
[0037] The present invention will be further described in detail below with reference to specific embodiments. It should be understood that the specific embodiments described herein are merely illustrative of the invention and are not intended to limit the invention.
[0038] A method for predicting and controlling the trajectory of cargo stacking on a clamping vehicle based on a Transformer network includes the following steps:
[0039] Step 1, construct a cargo placement trajectory prediction model for the clamping vehicle:
[0040] This step aims to construct a cargo placement trajectory prediction model for a clamping vehicle using a Transformer network. This model predicts the movement trajectory of the clamping vehicle during cargo placement by analyzing its dynamic state in real time. The prediction model mainly consists of multiple network layers, including an input embedding layer, multi-layer Transformer encoder layers, and an output layer. The dynamic features of the clamping vehicle are extracted through the combination of these layers to perform effective trajectory prediction.
[0041] In the input embedding layer, the input dynamic state is transformed into a high-dimensional feature vector X through embedding processing. embed (t), the dynamic state includes features such as the position (position, direction) of the clamping vehicle, speed, accelerator pedal travel, and brake pedal travel.
[0042] High-dimensional feature vector X embed The formula for (t) is:
[0043] X embed (t) = Embedding(X(t)),
[0044] Where X(t) is the input feature at time t, X embed (t) is the high-dimensional feature vector after embedding. Through the embedding layer, the model can transform the original input into a high-dimensional representation suitable for subsequent processing.
[0045] In the multi-layer Transformer encoder layer, the high-dimensional feature vector X embed (t) The embedded features are sequentially processed through multiple Transformer encoder layers. Each Transformer encoder layer includes a self-attention mechanism and a feedforward neural network to capture the complex relationships between the input features. The output of the first Transformer encoder layer is:
[0046] H (t) =TransformerEncoder(X embed (t)),
[0047] Among them, H (t) This represents the feature output at time t. Through multi-layer stacking, the cargo placement trajectory prediction model for clamp trucks can refine feature information layer by layer, enhancing the understanding of the dynamic characteristics of the clamp trucks.
[0048] The output of the adjacent previous Transformer encoder layer serves as the input to the next Transformer encoder layer, and the output of the last Transformer encoder layer serves as the input to the output layer, which predicts the motion trajectory of the gripping vehicle. This process combines historical states and real-time features to generate future motion trajectories.
[0049] The formula for predicting motion trajectory is:
[0050] Y pred (t) = fOutput(H (T) ),
[0051] Among them, Y pred (t) represents the predicted trajectory at time t output by the cargo placement trajectory prediction model for the clamping vehicle, H (T) This is the final feature output of the last layer of the Transformer encoder. Through this step, the model can output the expected trajectory of the clamping vehicle during the cargo stacking process, providing a basis for subsequent control.
[0052] Step 2, trajectory deviation calculation:
[0053] By comparing the deviation between the predicted trajectory and the actual trajectory, the operating commands of the clamping vehicle can be quickly adjusted to achieve accurate cargo stacking. Calculating this deviation is crucial for achieving precise control and optimizing the operation of the clamping vehicle.
[0054] The formula for calculating deviation is:
[0055] Bias(t) = Y actual (t)-Y pred (t),
[0056] Among them, Y actual (t) represents the actual trajectory of the clamping vehicle at time t, Y pred (t) represents the predicted trajectory at time t. By analyzing the deviation, corresponding compensation can be made to optimize the running path of the clamping vehicle.
[0057] Step 3, Training and optimization of the cargo placement trajectory prediction model for the clamping vehicle:
[0058] To construct training and testing sets, data on the clamping vehicle under different operating environments and cargo layouts needs to be collected. The choice of loss function is crucial during model training. This invention employs the cross-entropy loss function to measure the difference between predicted and actual results, adapting to the needs of trajectory prediction problems.
[0059] The formula for calculating the cross-entropy loss function is:
[0060]
[0061] Among them, Y true (i) represents the true trajectory at time i, Y pred(i) represents the predicted trajectory at time i, and n is the time step. By minimizing the cross-entropy loss (Loss), the cargo placement trajectory prediction model for the clamp-and-grip vehicle can continuously optimize its parameters to improve prediction accuracy. The Adam optimization algorithm is used to train the cargo placement trajectory prediction model for the clamp-and-grip vehicle to minimize the loss function. During training, hyperparameter tuning is performed using a validation set to ensure the model adapts to different operating environments and task requirements. Through multiple rounds of training and validation, the model's generalization ability is improved.
[0062] Step 4, Real-time data input and feedback control:
[0063] By monitoring the dynamic information of the clamping vehicle in real time and combining it with the prediction results, feedback control is implemented to ensure the precise placement of goods during the stacking process. Real-time data collection is crucial. Monitoring the clamping vehicle's posture (position and orientation), speed, accelerator pedal travel, and brake pedal travel, etc., ensures high-frequency data acquisition. This allows the model to obtain the latest information for real-time prediction, improving the overall system's responsiveness and accuracy. Based on the trajectory deviation predicted by the model, the control system adjusts the clamping vehicle's movement commands in real time to ensure accurate goods stacking. During this process, the control system continuously receives prediction results from the vehicle-cargo stacking trajectory prediction model and adjusts the clamping vehicle's operation commands according to the deviation.
[0064] The control command adjustment formula is:
[0065] U(t)=U base +K·Bias(t),
[0066] Where U(t) is the control command for the adjusted clamping vehicle, U base K represents the basic control command and K represents the compensation coefficient. In this way, the clamping vehicle can respond promptly to dynamic changes, ensuring accurate placement of goods.
[0067] Step 5, Practical Application and Verification:
[0068] The constructed cargo placement trajectory prediction model for clamp-and-grip carts was subjected to actual operational testing, recording its performance under different environments, particularly its prediction accuracy and the operational efficiency of the clamp-and-grip carts. This included simulating different cargo layouts and clamp-and-grip cart operation scenarios to evaluate the adaptability and stability of the model. By comparing it with traditional methods, the model's superiority in terms of accuracy, real-time performance, and adaptability was analyzed. In performance evaluation, quantitative indicators (such as average trajectory deviation and operation time) were used to objectively reflect the model's actual effectiveness, verifying its validity and reliability in real-time cargo placement.
[0069] This invention provides an innovative and efficient solution for predicting the cargo placement trajectory of unmanned gripper vehicles by comprehensively utilizing Transformer networks, which greatly improves the operational efficiency and accuracy of automated warehousing systems.
[0070] The above description is only a preferred embodiment of the present invention. It should be noted that, for those skilled in the art, several improvements and modifications can be made without departing from the principle of the present invention, and these improvements and modifications should also be considered within the scope of protection of the present invention.
Claims
1. A method for predicting and controlling the trajectory of cargo stacking on a clamping vehicle based on a Transformer network, characterized in that, Includes the following steps: Step 1: Construct a cargo placement trajectory prediction model for the clamping vehicle. This model includes an input embedding layer, multiple Transformer encoder layers, and an output layer. Each Transformer encoder layer includes a self-attention mechanism and a feedforward neural network. The dynamic state of the clamping vehicle is input into the model, and the predicted trajectory Y at time t is output. pred (t); In step 1, the dynamic state includes multiple features, including the position of the clamping vehicle, speed, accelerator pedal travel, and brake pedal travel. In step 1, the dynamic state is input into the input embedding layer to obtain a high-dimensional feature vector X. embed (t), the high-dimensional feature vector X embed The formula for calculating (t) is: X embed (t)=Embedding(X(t)), Where X(t) is the input feature at time t, X embed (t) is the high-dimensional feature vector after embedding; In step 1, the high-dimensional feature vector X embed (t) serves as the input to the first Transformer encoder layer, and outputs H. (t) H (t) =TransformerEncoder(X embed (t)), the output of the adjacent previous Transformer encoder layer is used as the input of the next Transformer encoder layer, and the output of the last Transformer encoder layer is H. (T) ; In step 1, H (T) As the input to the output layer, the predicted trajectory Y at output time t is... pred (t), Y pred (t)=f Output (H (T) ); Step 2: Calculate the predicted trajectory Y obtained in Step 1. pred (t) and the actual trajectory Y actual Bias(t) is the deviation of (t). Step 3, Model Optimization: Construct training and test sets. Using the training set, train the cargo placement trajectory prediction model of the clamping vehicle based on the cross-entropy loss function. Use the test set to verify the prediction ability of the cargo placement trajectory prediction model of the clamping vehicle. In step 3, the formula for calculating the cross-entropy loss function is: Among them, Y true (i) represents the true trajectory at time i, Y pred (i) represents the predicted trajectory at time i, and n represents the time step. The parameters of the cargo placement trajectory prediction model for the clamping vehicle are optimized by minimizing the cross-entropy loss Loss. Step 4: Based on the deviation Bias(t) obtained in Step 2, obtain the control command U(t) of the adjusted clamping vehicle to ensure the accuracy of the position of the goods during the stacking process. In step 4, U(t) = U base +K·Bias(t), U base K is the basic control command, and K is the compensation coefficient.
2. The method for predicting and controlling the trajectory of cargo placement on a clamping vehicle based on a Transformer network as described in claim 1, characterized in that, In step 2, Bias(t) = Y actual (t)-Y pred (t).
3. The method for predicting and controlling the trajectory of cargo placement on a clamping vehicle based on a Transformer network as described in claim 1, characterized in that, The method for predicting and controlling the cargo placement trajectory of a clamping vehicle based on a Transformer network further includes step 5, which involves conducting actual operation tests on the constructed cargo placement trajectory prediction model of the clamping vehicle, and verifying the accuracy of the prediction and the operating efficiency of the clamping vehicle through quantitative indicators.
4. The method for predicting and controlling the trajectory of cargo placement on a clamping vehicle based on a Transformer network as described in claim 3, characterized in that, The quantitative indicators are average trajectory deviation or operation time.
Citation Information
Patent Citations
Vehicle lane-changing trajectory prediction method based on random forest and improved Informer model
CN117807413B
Multi-modal trajectory prediction method for pedestrians in complex scene
CN110781838A
Iterative optimization multi-scale fusion vehicle speed prediction algorithm for intelligent connected vehicle
CN113095558A