A Non-directional Force Sensor Control Method and System Based on Real-time Force Trend Prediction

By acquiring real-time force signals from an omnidirectional force sensor and using a pre-trained model to predict force trends, a multidimensional force compensation signal is generated to adjust control parameters. This solves the control lag and oscillation problems of omnidirectional force sensors in multidimensional force coupling scenarios, and improves the response speed and stability of the control system.

CN120620240BActive Publication Date: 2025-10-31BEIJING HANGXING TRANSMISSION TECH CO LTD
View PDF 1 Cites 0 Cited by

Patent Information

Application Number
CN202511130174.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2025-08-13
Publication Date
2025-10-31
Estimated Expiration
2045-08-13

AI Technical Summary

Technical Problem

Existing closed-loop control methods without directional force sensors lack the ability to perceive changes in force direction in multi-dimensional force coupling scenarios. This makes the control system susceptible to directional misjudgment, leading to oscillations or response lags, making it difficult to achieve accurate compensation and affecting control accuracy and system stability.

Method used

By collecting real-time force signal sequences and inputting them into a pre-trained force trend prediction model, the predicted force direction trend within a future time window is obtained. Multidimensional force compensation signals are then generated to correct closed-loop control parameters, and control parameters are dynamically adjusted to optimize the contact operation trajectory.

Benefits of technology

It enables rapid convergence of multi-dimensional force amplitude data output by non-directional force sensors to a preset range, improves the response speed and stability of the control system, avoids parameter conflicts caused by directional misjudgment, and provides a robust force interaction control scheme.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN120620240B_ABST
    Figure CN120620240B_ABST
Patent Text Reader

Abstract

This invention provides a non-directional force sensor control method and system based on real-time force trend prediction. The method involves acquiring real-time force signal sequences generated when a target mechanical device performs contact operations, inputting these sequences into a pre-trained force trend prediction model, obtaining the force direction trend prediction result output by the model, generating a multi-dimensional force compensation signal based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters, adjusting the proportional-integral-derivative coefficients in the current closed-loop control parameters based on the multi-dimensional force compensation signal, generating updated closed-loop control parameters, and inputting these updated closed-loop control parameters into the actuator of the target mechanical device. The actuator dynamically adjusts the contact operation trajectory of the target mechanical device according to the updated closed-loop control parameters, causing the multi-dimensional force amplitude data output by the non-directional force sensor to converge to a preset force control target range. This invention can improve the response speed and stability of the force control system.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This invention relates to the fields of data processing and intelligent control, and more specifically, to a non-directional force sensor control method and system based on real-time force trend prediction. Background Technology

[0002] In the fields of industrial automation and precision control, force control systems are a core technology for enabling safe interaction between mechanical devices and the external environment. Among these, non-directional force sensors are widely used in robotic arm contact operations and precision assembly due to their simple structure and low cost. Existing force control methods typically rely on real-time force amplitude data output from non-directional sensors, adjusting closed-loop control parameters using traditional proportional-integral-derivative (PID) algorithms to drive the actuator to correct the contact trajectory. However, these methods lack the ability to sense changes in force direction, relying solely on feedback of the current force signal amplitude for parameter adjustment. This makes the control system susceptible to directional misjudgment interference in dynamic contact operations, leading to oscillations or response lag. Especially in multi-dimensional force coupling scenarios, traditional PID parameter adjustment struggles to distinguish the directional trends of force amplitude changes in each dimension, failing to compensate for directional deviation components in advance. This results in parameter conflicts and the accumulation of steady-state errors, severely restricting force control accuracy and system stability. Achieving real-time prediction and accurate compensation of multi-dimensional force direction trends without relying on direction sensors has become a key challenge in improving the performance of non-directional force sensor closed-loop control. Summary of the Invention

[0003] In a first aspect, embodiments of the present invention provide a closed-loop control method based on real-time force trend prediction using a non-directional force sensor. The method includes: acquiring a real-time force signal sequence generated when a target mechanical device performs a contact operation, the real-time force signal sequence including multi-dimensional force amplitude data output by a non-directional force sensor; inputting the real-time force signal sequence into a pre-trained force trend prediction model to obtain a force direction trend prediction result output by the force trend prediction model, the force direction trend prediction result being used to characterize the vector distribution features of multi-dimensional force amplitude changes within a future preset time window; and adjusting the force direction trend prediction result in relation to the current closed-loop control method. The matching degree of the closed-loop control parameters is used to generate a multi-dimensional force compensation signal, which is used to correct the directional deviation component in the current closed-loop control parameters. Based on the multi-dimensional force compensation signal, the proportional-integral-derivative coefficients in the current closed-loop control parameters are adjusted to generate updated closed-loop control parameters, which are then input into the actuator of the target mechanical device. The actuator dynamically adjusts the contact operation trajectory of the target mechanical device according to the updated closed-loop control parameters, so that the multi-dimensional force amplitude data output by the non-directional force sensor converges to a preset force control target range.

[0004] Secondly, embodiments of the present invention provide a computer system, comprising: a memory storing a computer program; and a processor for loading the computer program to implement the non-directional force sensor closed-loop control method based on real-time force trend prediction as described above.

[0005] This invention provides a closed-loop control method for non-directional force sensors based on real-time force trend prediction. By inputting a real-time force signal sequence into a pre-trained force trend prediction model, it obtains the predicted force direction trend within a future time window. Based on the prediction results, it dynamically generates multi-dimensional force compensation signals to adjust the closed-loop control parameters, enabling the multi-dimensional force amplitude data output by the non-directional force sensor to quickly converge to a preset force control target range. This method creatively integrates a dynamic coupling mechanism between real-time prediction and closed-loop control, solving the control lag and oscillation problems caused by the lack of direction perception in traditional methods. By compensating for direction deviation components in advance through the prediction model and combining component decoupling processing of the multi-dimensional compensation signal, it effectively avoids parameter conflicts caused by direction misjudgment, significantly improving the response speed and stability of the force control system. Simultaneously, based on the adaptable architecture designed for non-directional sensors, this method directly maps multi-dimensional force amplitude data to a vector distribution feature space, eliminating the need for direction sensors or complex coordinate transformations. Through a dual feedback mechanism, it dynamically optimizes the gain weights of control parameters, achieving collaborative optimization of direction trend prediction and force amplitude control in complex contact operation scenarios. This provides a robust and highly adaptable force interaction control solution for scenarios such as precision assembly of robotic arms. Attached Figure Description

[0006] Figure 1 This is a flowchart of a non-directional force sensor closed-loop control method based on real-time force trend prediction provided by an embodiment of the present invention.

[0007] Figure 2 This is a schematic diagram of the composition of a computer system provided in an embodiment of the present invention. Detailed Implementation

[0008] Please see Figure 1 , Figure 1 The flowchart illustrates a closed-loop control method for a non-directional force sensor based on real-time force trend prediction, provided by an embodiment of the present invention. This closed-loop control method for a non-directional force sensor based on real-time force trend prediction can be executed by a computer system and includes the following steps:

[0009] Step S100: Collect the real-time force signal sequence generated when the target mechanical device performs contact operation. The real-time force signal sequence includes multi-dimensional force amplitude data output by the non-directional force sensor.

[0010] In this embodiment of the invention, the target mechanical device is a specific mechanical equipment performing a contact operation, such as the robotic arm of an industrial robot or processing equipment on an automated production line. A contact operation is the process by which the mechanical device comes into contact with an external object and generates an interaction force, such as a robot grasping an object or a processing device grinding a workpiece. The real-time force signal sequence is a sequence of force signals continuously collected at preset time intervals during the contact operation of the target mechanical device. An omnidirectional force sensor is a sensor that can measure the magnitude of a force but does not specify its direction. Its output multidimensional force amplitude data represents the magnitude of the force in different dimensions; for example, in three-dimensional space, it may include force amplitudes in the X, Y, and Z directions. The real-time force signal sequence is collected, for example, by using an omnidirectional force sensor connected to the target mechanical device to sample the force signals at a preset sampling frequency. For example, the sampling frequency is set to 100Hz, meaning 100 force signal data are collected per second. Each collected data point is a multidimensional force amplitude data point, and these data points are arranged in chronological order of collection time to form the real-time force signal sequence.

[0011] Step S200: Input the real-time force signal sequence into the pre-trained force trend prediction model, and obtain the force direction trend prediction result output by the force trend prediction model. The force direction trend prediction result is used to characterize the vector distribution characteristics of the multidimensional force amplitude change within a future preset time window.

[0012] The pre-trained force trend prediction model is a model that has been trained beforehand to predict the changing trend of multidimensional force amplitude over a future period based on the input real-time force signal sequence. The force direction trend prediction result uses vector distribution features to represent the changes in multidimensional force amplitude within a preset future time window. The preset future time window is a pre-defined time period within which the changes in multidimensional force amplitude are predicted; for example, the preset future time window can be set to the next 5 seconds.

[0013] As one implementation method, step S200 involves inputting the real-time force signal sequence into a pre-trained force trend prediction model to obtain the force direction trend prediction result output by the force trend prediction model. Specifically, this may include the following steps S210~S250:

[0014] Step S210: Perform sliding window segmentation on the real-time force signal sequence to generate input data pairs containing historical force signal subsequences and current force signal subsequences.

[0015] Sliding window segmentation involves sliding a fixed-size window across the real-time force signal sequence, capturing a subsequence of data within the window at each slide. The historical force signal subsequence comprises force signal data prior to the current time point within the window, containing force signal information over a past period. The current force signal subsequence comprises force signal data corresponding to the current time point within the window, reflecting the force signal state at the current moment. Input data pairs are combinations of the historical and current force signal subsequences, used for subsequent processing at different layers of the force trend prediction model.

[0016] For example, a sliding window with a size of 10 data points is set. Starting from the beginning of the real-time force signal sequence, the first 9 data points covered by the window are taken as the historical force signal subsequence, and the 11th data point is taken as the current force signal subsequence, forming an input data pair. Then, the window slides forward one data point, and new historical and current force signal subsequences are extracted again to form new input data pairs, and so on, until the end of the real-time force signal sequence is reached. In the scenario of an industrial robot grasping an object, assuming that the real-time force signal sequence is collected at a sampling frequency of 100 times per second, and the window size is set to 10 data points, the window covers a time range of 0.1 seconds. Through sliding window segmentation, input data pairs containing historical and current force signal subsequences are continuously generated, providing a data foundation for subsequent model processing.

[0017] Step S220: Input the historical force signal subsequence into the time-series coding layer of the force trend prediction model, and extract the time-series correlation features corresponding to the historical force signal subsequence. The time-series correlation features include the force amplitude fluctuation pattern under different time dimensions.

[0018] The temporal encoding layer of the force trend prediction model is used to encode the input historical force signal subsequences and extract their temporal correlation features. These temporal correlation features are the fluctuation patterns and relationships of force amplitudes across different time dimensions, such as rapid changes in force amplitude over short periods or slow trends over long periods. Specifically, when the historical force signal subsequences are input to the temporal encoding layer, this layer processes them using an encoding algorithm. For example, a Long Short-Term Memory (LSTM) network can be used as the structure of the temporal encoding layer, with a hidden layer dimension of 64, an activation function of Tanh, and an input dimension consistent with the force signal dimension (e.g., a 3D force signal input of 3). When processing the historical force signal subsequences, the LSTM learns the fluctuation patterns of force amplitudes across different time dimensions based on the input force amplitude data, and outputs temporal correlation features containing information about these fluctuation patterns.

[0019] Step S230: Input the current force signal subsequence into the dynamic weight allocation layer of the force trend prediction model, and generate a weight allocation vector corresponding to the time-series correlation features based on the rate of change of force amplitude at each time point in the current force signal subsequence.

[0020] The dynamic weight allocation layer of the force trend prediction model is a network layer used to assign different weights to temporally correlated features based on the characteristics of the current force signal subsequence. The rate of change of force amplitude at each time point in the current force signal subsequence is the proportion of change of force amplitude at each time point relative to the previous time point. The weight allocation vector is a vector with the same dimension as the temporally correlated features, where each element represents the weight of the corresponding temporally correlated feature, used for subsequent feature fusion operations.

[0021] For example, when the current force signal subsequence is input into the dynamic weight allocation layer, this layer calculates the rate of change of force amplitude at each time point in the current force signal subsequence. For instance, the rate of change of force amplitude can be calculated using a first-order difference method: subtracting the force amplitude at the previous time point from the force amplitude at the current time point, and then dividing by the force amplitude at the previous time point. Then, based on the calculated rate of change of force amplitude, a weight allocation vector corresponding to the temporal correlation features is generated through a nonlinear mapping function. For example, the Sigmoid function can be used as the nonlinear mapping function to map the rate of change of force amplitude to the interval [0, 1], obtaining the values ​​of each element of the weight allocation vector.

[0022] Step S240: Through the feature fusion layer of the force trend prediction model, perform dot product operation on the temporal correlation features and the weight allocation vector to generate dynamically weighted temporal features.

[0023] The feature fusion layer of the force trend prediction model is used to fuse different features. In this embodiment of the invention, it fuses temporal correlation features and weight allocation vectors. The dot product operation multiplies corresponding elements of two vectors and sums them to obtain a new vector. Of course, in other implementations, element-wise multiplication can also be used. The dynamically weighted temporal features are the result of the dot product operation. They are features obtained by weighting the temporal correlation features according to the weight allocation vector, and can more accurately reflect the characteristics of the current force signal and the future force change trend.

[0024] It is understood that those skilled in the art, when performing calculations related to the embodiments of the present invention, can use their technical knowledge to unify or eliminate conflicts in calculations involving different dimensions, such as standardization or normalization. For example, in subsequent loss calculations, percentages can be used to eliminate dimensional differences. For subsequent PID parameters, the proportional, integral, and derivative coefficients can be normalized to [0,1] according to their type. Before calculating the rate of change, the normalized data can be restored. Furthermore, for two variables with inconsistent dimensions, those skilled in the art can align the dimensions using known techniques before calculation. For example, if the dimensions of the temporal correlation features output by the temporal coding layer and the weight vector generated by the dynamic weight allocation layer are inconsistent before performing the dot product operation, their dimensions can be aligned (e.g., through a fully connected layer) before subsequent calculations.

[0025] Step S250: Input the dynamically weighted time series features into the trend prediction layer of the force trend prediction model, output the multidimensional force amplitude prediction values ​​at each time point within the future preset time window, and generate the force direction trend prediction result based on the vector change direction of the multidimensional force amplitude prediction values.

[0026] The trend prediction layer of the force trend prediction model is used to predict the multidimensional force amplitude at each time point within a preset future time window based on the input dynamically weighted temporal features, and to generate the force direction trend prediction result. It can be implemented as a fully connected layer. The predicted multidimensional force amplitude at each time point within the preset future time window represents the predicted force magnitude in different dimensions at each time point within a pre-defined future time period. The force direction trend prediction result is generated based on the vector change direction of the predicted multidimensional force amplitude, using vector distribution characteristics to represent the future force change trend. For example, after inputting the dynamically weighted temporal features into the trend prediction layer, this layer uses its internal prediction algorithm to predict the multidimensional force amplitude within the preset future time window. For instance, using a fully connected neural network as the structure of the trend prediction layer, the fully connected neural network will, based on the input dynamically weighted temporal features, through a series of linear transformations and nonlinear activation functions, output the predicted multidimensional force amplitude at each time point within the preset future time window. Then, based on the vector change direction of these multidimensional force amplitude prediction values, for example, by calculating the difference between the multidimensional force amplitude vectors between adjacent time points, the direction of force change is obtained, and thus the force direction trend prediction result is generated.

[0027] Step S300: Based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters, generate a multi-dimensional force compensation signal. The multi-dimensional force compensation signal is used to correct the direction deviation component in the current closed-loop control parameters.

[0028] The force direction trend prediction result, obtained in step S200, represents the future force change trend. The current closed-loop control parameters are a set of parameters used to control the target mechanical device at the current moment, such as proportional coefficient, integral coefficient, and derivative coefficient. The matching degree represents the similarity or conformity between the force direction trend prediction result and the current closed-loop control parameters. The multidimensional force compensation signal is a signal generated based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters. Its function is to correct the directional deviation component in the current closed-loop control parameters, making the control of the target mechanical device more accurate. For example, the matching degree between the force direction trend prediction result and the current closed-loop control parameters is calculated. For example, a vector similarity calculation method, such as cosine similarity, can be used to calculate the similarity between the vector distribution characteristics corresponding to the force direction trend prediction result and the vector corresponding to the current closed-loop control parameters. Then, based on the calculated matching degree, a multidimensional force compensation signal is generated through a preset compensation signal generation algorithm. In the scenario of an industrial robot grasping an object, if the force direction trend prediction result shows that the force change trend of the robotic arm in a certain direction is inconsistent with the expectation of the current closed-loop control parameters, it indicates that there is a directional deviation. At this time, the generated multi-dimensional force compensation signal will be used to correct the current closed-loop control parameters, so that the movement of the robotic arm is more in line with the actual force change.

[0029] As one implementation method, step S300 generates a multi-dimensional force compensation signal based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters. Specifically, this may include the following steps S310~S350:

[0030] Step S310: Obtain the proportional coefficient vector, integral coefficient vector, and derivative coefficient vector in the current closed-loop control parameters, and normalize the proportional coefficient vector, integral coefficient vector, and derivative coefficient vector to generate the closed-loop control parameter feature matrix.

[0031] The proportional coefficient vector, integral coefficient vector, and derivative coefficient vector in the current closed-loop control parameters are parameters used for closed-loop control. The proportional coefficient vector is used to adjust the proportional relationship between the control quantity and the error, the integral coefficient vector is used to eliminate the steady-state error of the system, and the derivative coefficient vector is used to predict the trend of error changes and make adjustments in advance. As mentioned earlier, normalization is used to transform the data into a range, such as [0, 1] or [-1, 1], to eliminate the dimensional differences between different parameters and make the data comparable. The closed-loop control parameter characteristic matrix is ​​a matrix composed of the normalized proportional coefficient vector, integral coefficient vector, and derivative coefficient vector, which can more comprehensively represent the characteristics of the current closed-loop control parameters.

[0032] For example, proportional coefficient vector, integral coefficient vector, and derivative coefficient vector are extracted from the current closed-loop control parameters. For instance, suppose the proportional coefficient vector is [p1, p2, p3], the integral coefficient vector is [i1, i2, i3], and the derivative coefficient vector is [d1, d2, d3]. Then, these three vectors are normalized. A min-max normalization method can be used: for each vector, first find its minimum and maximum values, then subtract the minimum value from each element, and finally divide by the difference between the maximum and minimum values ​​to obtain the normalized vector. Finally, the normalized proportional coefficient vector, integral coefficient vector, and derivative coefficient vector are arranged in rows or columns to generate the closed-loop control parameter feature matrix. In the scenario of an industrial robot grasping an object, normalization and the generation of the closed-loop control parameter feature matrix can more accurately represent the characteristics of the current closed-loop control parameters, providing a foundation for subsequent similarity calculations and compensation signal generation.

[0033] Step S320: Calculate the similarity between the vector distribution characteristics corresponding to the force direction trend prediction results and the closed-loop control parameter feature matrix to generate the direction deviation feature vector.

[0034] The vector distribution feature corresponding to the force direction trend prediction result is the vector feature representing the future force change trend obtained in step S200. The closed-loop control parameter feature matrix is ​​the matrix representing the current closed-loop control parameter features generated in step S310. Similarity calculation calculates the degree of similarity between these two features, such as Euclidean distance or cosine similarity. The direction deviation feature vector is a vector generated based on the similarity calculation result; it represents the direction deviation between the force direction trend prediction result and the current closed-loop control parameters.

[0035] For example, the similarity between the vector distribution characteristics corresponding to the force direction trend prediction results and the closed-loop control parameter feature matrix is ​​calculated. For instance, a cosine similarity calculation method is used to calculate the cosine similarity between the vector distribution characteristics and each row of vectors in the closed-loop control parameter feature matrix. Then, based on the calculated similarity values, a direction deviation feature vector is generated. For example, a preset threshold can be subtracted from the similarity value to obtain the element values ​​of the direction deviation feature vector.

[0036] Step S330: Input the orientation deviation feature vector into the fully connected layer of the preset compensation signal generation network, and extract the preset oscillation component and preset offset component from the orientation deviation feature vector.

[0037] A pre-defined compensation signal generation network is used to generate a multi-dimensional force compensation signal based on the input direction deviation feature vector. Fully connected layers connect each input neuron to each output neuron. The pre-defined oscillation component is the part of the direction deviation feature vector with a high frequency of change, representing rapid fluctuations or noise in the system. The pre-defined offset component is the part of the direction deviation feature vector with a low frequency of change, representing slow trends or steady-state errors in the system. The definition of high or low frequency is set according to the specific situation; for example, frequencies above 100Hz are defined as high frequency, and frequencies below 100Hz are defined as low frequency.

[0038] In a specific implementation, for example, the orientation deviation feature vector generated in step S320 is input into the fully connected layer of a preset compensation signal generation network. The fully connected layer performs a linear transformation on the input orientation deviation feature vector, mapping it to a new feature space through a series of weight matrices and bias vectors. Then, a preset oscillation component and a preset offset component are extracted from the output feature vector using a filtering algorithm or signal processing method. For example, a low-pass filter can be used to extract the low-frequency offset component, and a high-pass filter can be used to extract the high-frequency oscillation component.

[0039] Step S340: The preset oscillation component and the preset offset component are fused across channels by the convolution kernel group of the compensation signal generation network to generate a preliminary compensation signal.

[0040] The convolutional kernel group of the compensation signal generation network is used to perform convolution operations on the input features. Cross-channel fusion combines features from different channels to extract richer feature information. The initial compensation signal is generated through cross-channel fusion and is an intermediate result in the multidimensional force compensation signal generation process.

[0041] For example, the preset oscillation component and preset offset component extracted in step S330 are input into the convolutional kernel group of the compensation signal generation network. The convolutional kernel group performs convolution operations on the preset oscillation component and preset offset component, extracting different feature information through different convolutional kernels. Then, the results obtained from the convolution operation are fused across channels, for example, by using feature concatenation or feature addition methods, to fuse the features of different channels together and generate a preliminary compensation signal.

[0042] As one implementation method, step S340 involves cross-channel fusion of the preset oscillation component and the preset offset component using the convolutional kernel group of the compensation signal generation network to generate a preliminary compensation signal. Specifically, this may include the following steps S341-S348:

[0043] Step S341: Split the preset oscillation component and the preset offset component into multiple parallel processing channels along the channel dimension to generate a preset oscillation component sub-channel group and a preset offset component sub-channel group.

[0044] The channel dimension represents the number of feature channels. Parallel processing channels are multiple independent channels obtained by splitting the feature data according to the channel dimension, and each channel can be processed independently. The preset oscillation component sub-channel group is a group of sub-channels obtained by splitting the preset oscillation component along the channel dimension, and the preset offset component sub-channel group is a group of sub-channels obtained by splitting the preset offset component along the channel dimension.

[0045] For example, for the preset oscillation component and the preset offset component, they are split into multiple parallel processing channels based on their channel dimensions. For instance, assuming the preset oscillation component has a channel dimension of 3, it is split into 3 preset oscillation component sub-channels; assuming the preset offset component has a channel dimension of 2, it is split into 2 preset offset component sub-channels. This splitting method allows for independent processing of different channels, improving processing efficiency and feature extraction accuracy. Splitting the preset oscillation component and the preset offset component into multiple parallel processing channels better captures feature information from different channels, providing more detailed data for subsequent convolution operations and feature fusion.

[0046] Step S342: Decompose the convolution kernel group into a first sub-convolution kernel set corresponding to the preset oscillation component sub-channel group, and a second sub-convolution kernel set corresponding to the preset offset component sub-channel group.

[0047] The first sub-kernel set is the portion of the convolution kernel group corresponding to the preset oscillation component sub-channel group, and the second sub-kernel set is the portion of the convolution kernel group corresponding to the preset offset component sub-channel group. By decomposing the convolution kernel group, different convolution kernels can be used for processing different sub-channel groups, improving the targeting and effectiveness of convolution operations.

[0048] For example, based on the number and characteristics of the preset oscillation component sub-channel groups and the preset offset component sub-channel groups, the convolution kernel group is decomposed into a first sub-convolution kernel set and a second sub-convolution kernel set. If the preset oscillation component sub-channel group has 3 channels and the preset offset component sub-channel group has 2 channels, then the convolution kernels in the convolution kernel group are allocated to the first and second sub-convolution kernel sets according to preset rules, so that the number of convolution kernels in the first sub-convolution kernel set matches the number of channels in the preset oscillation component sub-channel group, and the number of convolution kernels in the second sub-convolution kernel set matches the number of channels in the preset offset component sub-channel group. By decomposing the convolution kernel group into the first and second sub-convolution kernel sets, more effective convolution operations can be performed on the different characteristics of the preset oscillation component and the preset offset component, extracting more accurate feature information.

[0049] Step S343: Perform multi-scale convolution operation on the preset oscillation component sub-channel group through the first sub-convolution kernel set, extract the time-domain response features corresponding to different frequency fluctuation modes in the preset oscillation component sub-channel group, and generate a preset fusion feature map.

[0050] Multi-scale convolution operations use convolution kernels of different sizes to perform convolution operations on input features to extract feature information at different scales. Temporal response features are the response characteristics of the input signal in the time domain, reflecting the changes in the signal at different time points. The preset fusion feature map is the result of multi-scale convolution operations; it is a feature map obtained by fusing the temporal response features corresponding to different frequency fluctuation patterns in a preset oscillation component sub-channel group.

[0051] For example, a preset oscillation component sub-channel group is input into a first sub-convolutional kernel set. Convolutional kernels of different sizes in the first sub-convolutional kernel set perform convolution operations on the preset oscillation component sub-channel group. Then, these convolution results are fused, for example, using feature addition or feature concatenation methods, to generate a preset fused feature map. Through multi-scale convolution operations and feature fusion, the time-domain response features corresponding to different frequency fluctuation patterns in the preset oscillation component sub-channel group can be extracted, generating a more comprehensive and accurate preset fused feature map, providing important feature information for subsequent feature concatenation and compensation signal generation.

[0052] Step S344: Perform long-period convolution operation on the preset offset component sub-channel group through the second sub-convolution kernel set, extract the cumulative effect features corresponding to the trend offset in the preset offset component sub-channel group, and generate a preset fusion feature map.

[0053] Long-period convolution operations use large-size (e.g., 9×9) convolution kernels to perform convolution operations on input features to capture feature information over a longer time range. The cumulative effect feature corresponding to the trend offset is the cumulative effect of slowly changing trend offsets in the preset offset component sub-channel group over a longer period. The preset fused feature map is the result of long-period convolution operations; it is a feature map obtained by fusing the cumulative effect features corresponding to trend offsets in the preset offset component sub-channel group.

[0054] For example, a preset offset component sub-channel group is input into a second set of sub-convolutional kernels. Larger kernels in this set perform long-period convolution operations on the preset offset component sub-channel group. The convolution results are then fused, for example, using feature addition or feature concatenation, to generate a preset fused feature map. Through long-period convolution operations and feature fusion, the cumulative effect features corresponding to the trend offset in the preset offset component sub-channel group can be extracted, generating a more accurate preset fused feature map. This provides crucial feature information for subsequent feature concatenation and compensation signal generation.

[0055] Step S345: Perform feature stitching of the preset fusion feature map and the preset fusion feature map along the spatial dimension to generate a cross-channel fusion feature tensor.

[0056] Spatial dimension is one dimension of a feature map, representing its spatial location information. The cross-channel fusion feature tensor is obtained by concatenating preset fusion feature maps along their spatial dimensions. It integrates preset and preset feature information, providing richer feature representations for subsequent feature enhancement and compensation signal generation.

[0057] For example, the preset fusion feature map generated in step S343 and the preset fusion feature map generated in step S344 are concatenated in spatial dimension. For example, if the spatial dimensions of the preset fusion feature map and the preset fusion feature map are HW×C1 and H×W×C2 respectively (where H and W represent spatial dimensions, and C1 and C2 represent the number of channels), they are concatenated in channel dimension to obtain a cross-channel fusion feature tensor with spatial dimension H×W×(C1+C2). By generating a cross-channel fusion feature tensor through feature concatenation, the preset and preset feature information can be integrated, providing a more comprehensive feature representation for subsequent feature processing and compensation signal generation.

[0058] Step S346: Perform cross-layer feature enhancement on the cross-channel fusion feature tensor through the residual connection layer of the compensation signal generation network to generate enhanced fusion features.

[0059] The residual connection layer in a compensated signal generation network is a special type of network layer that adds the input features to the processed features through residual connections. This alleviates the vanishing gradient problem in deep neural networks and enhances the expressive power of the features. Cross-layer feature enhancement uses residual connection layers to fuse and enhance feature information from different layers, making the features more representative and expressive. Enhanced fused features are obtained by using residual connection layers to perform cross-layer feature enhancement on the cross-channel fused feature tensor.

[0060] For example, the cross-channel fusion feature tensor generated in step S345 is input into the residual connection layer of the compensation signal generation network. The residual connection layer takes the cross-channel fusion feature tensor as input and processes it through a series of convolutional layers and nonlinear activation functions to obtain a processed feature. Then, the processed feature is added to the input cross-channel fusion feature tensor to obtain the enhanced fusion feature. Through cross-layer feature enhancement of the residual connection layer, the gradient vanishing problem in deep neural networks can be alleviated, the expressive power of the cross-channel fusion feature tensor can be enhanced, and more representative and accurate enhanced fusion features can be generated, providing a better feature foundation for subsequent feature dimensionality reduction and compensation signal generation.

[0061] Step S347: Input the enhanced fusion feature into the depthwise separable convolutional layer of the compensation signal generation network to perform feature dimensionality reduction, and generate the dimensionality-reduced fusion feature vector.

[0062] The depthwise separable convolutional layer in the compensated signal generation network is a type of convolutional layer that decomposes the traditional convolution operation into two steps: depthwise convolution and pointwise convolution. This reduces computational cost while achieving feature dimensionality reduction. Feature dimensionality reduction transforms high-dimensional feature data into low-dimensional feature data, thereby reducing data complexity and computational cost. The fused feature vector after dimensionality reduction is obtained by using the depthwise separable convolutional layer to perform feature dimensionality reduction on the enhanced fused features.

[0063] For example, the enhanced fusion features generated in step S346 are input into the depthwise separable convolutional layer of the compensation signal generation network. The depthwise separable convolutional layer first performs depthwise convolution on the enhanced fusion features, that is, performs convolution operations on each channel separately to extract feature information within each channel. Then, it performs pointwise convolution on the result of the depthwise convolution, that is, it uses a 1×1 convolution kernel to convolve the result of the depthwise convolution to achieve feature dimensionality reduction. Finally, the result of the pointwise convolution is flattened into a vector to obtain the dimensionality-reduced fusion feature vector. Feature dimensionality reduction through the depthwise separable convolutional layer can reduce data complexity and computational cost, while retaining important information in the enhanced fusion features, generating a more concise and effective dimensionality-reduced fusion feature vector, providing suitable feature input for subsequent amplitude constraints and phase alignment.

[0064] Step S348: The amplitude constraint and phase alignment of the dimensionality-reduced fused feature vector are performed by a nonlinear mapping function to generate a preliminary compensation signal that matches the dimension of the closed-loop control parameter feature matrix.

[0065] Nonlinear mapping functions are functions that perform nonlinear transformations on input data, such as the Sigmoid function and the ReLU function. Amplitude constraint limits the amplitude of the dimensionality-reduced fused feature vector to a reasonable range. Phase alignment adjusts the phase of the dimensionality-reduced fused feature vector to match the phase of the closed-loop control parameter feature matrix. The preliminary compensation signal is generated by applying amplitude constraints and phase alignment to the dimensionality-reduced fused feature vector using the nonlinear mapping function. Its dimension matches the closed-loop control parameter feature matrix, providing a suitable signal input for subsequent nonlinear transformations and multidimensional force compensation signal generation. For example, the dimensionality-reduced fused feature vector generated in step S347 is input into the nonlinear mapping function. For example, the Sigmoid function is used to constrain the amplitude of the dimensionality-reduced fused feature vector, limiting its amplitude to the range [0, 1]. Then, a phase adjustment algorithm is used to adjust the phase of the dimensionality-reduced fused feature vector to match the phase of the closed-loop control parameter feature matrix. Finally, a preliminary compensation signal matching the dimension of the closed-loop control parameter feature matrix is ​​obtained. By constraining the amplitude and aligning the phase of the nonlinear mapping function, a preliminary compensation signal matching the dimension of the characteristic matrix of the closed-loop control parameters can be generated, providing a suitable signal input for the subsequent generation of multidimensional force compensation signals, and ensuring that the compensation signal can accurately correct the directional deviation component in the current closed-loop control parameters.

[0066] As one implementation method, the above-described process for generating multidimensional force compensation signals also includes the following constraints:

[0067] When the force direction trend prediction results show that the force amplitude changes in at least two dimensions are in opposite directions, the compensation signal amplitudes in those two dimensions are preferentially suppressed. This is because when the force amplitude changes in at least two dimensions are in opposite directions, it may lead to system instability or overcompensation. By preferentially suppressing the compensation signal amplitudes in these two dimensions, this situation can be avoided, making the system more stable. For example, if the force direction trend prediction results show that the force amplitude changes in the X and Y directions are in opposite directions, then when generating multidimensional force compensation signals, the amplitudes of the compensation signals in the X and Y directions will be preferentially reduced.

[0068] When the force amplitude changes in all dimensions of the force direction trend prediction result are consistent, the gain coefficient of the multidimensional force compensation signal in the dominant change direction is increased. The dominant change direction is the direction in which the force amplitude changes most significantly among all dimensions. When the force amplitude changes in all dimensions are consistent, increasing the gain coefficient of the multidimensional force compensation signal in the dominant change direction can more effectively correct the directional deviation component in the current closed-loop control parameters, making the control of the target mechanical device more accurate. For example, if the force direction trend prediction result shows that the force amplitude is increasing in the X, Y, and Z directions, and the increase in the force amplitude in the X direction is the most significant, then the gain coefficient of the multidimensional force compensation signal in the X direction will be increased when generating the multidimensional force compensation signal.

[0069] When the force direction trend prediction result contains periodic oscillation patterns, phase lag compensation is applied to the multidimensional force compensation signal. Periodic oscillation patterns are characterized by periodic fluctuations in force amplitude over time. Applying phase lag compensation to the multidimensional force compensation signal allows it to better track force changes and reduces system oscillations. For example, if the force direction trend prediction result shows periodic oscillations in the force amplitude in a certain direction, then phase lag compensation will be applied to the compensation signal in that direction when generating the multidimensional force compensation signal.

[0070] When the confidence level of the force direction trend prediction result is lower than a preset threshold, the multi-dimensional force compensation signal is reset to zero and the system switches to open-loop control mode. The confidence level of the force direction trend prediction result indicates the reliability of the prediction result. The preset threshold is a pre-set value used to determine whether the confidence level of the prediction result is high enough. When the confidence level of the force direction trend prediction result is lower than the preset threshold, it indicates that the reliability of the prediction result is low. In this case, resetting the multi-dimensional force compensation signal to zero and switching to open-loop control mode can avoid system instability caused by unreliable prediction results. For example, if the confidence level of the force direction trend prediction result is lower than the preset threshold, the multi-dimensional force compensation signal will be reset to zero and the system will switch to open-loop control mode until the confidence level of the prediction result increases.

[0071] The activation state of constraints is dynamically controlled by the prediction confidence index output by the force trend prediction model. The prediction confidence index is an indicator output by the force trend prediction model, used to represent the confidence level of the prediction results. Based on the value of the prediction confidence index, the aforementioned constraints can be dynamically activated or deactivated. For example, when the prediction confidence index value is high, it indicates that the reliability of the prediction results is high, and some constraints can be deactivated; when the prediction confidence index value is low, it indicates that the reliability of the prediction results is low, and some constraints can be activated to ensure the stability of the system and the accuracy of control.

[0072] Step S350: Input the preliminary compensation signal into the activation function layer of the compensation signal generation network for nonlinear transformation to generate a multidimensional force compensation signal, wherein the output range of the activation function layer matches the adjustable range of the closed-loop control parameters.

[0073] The activation function layer of the compensation signal generation network performs a nonlinear transformation on the input signal. This nonlinear transformation enriches the signal's expressive power and improves the system's control performance. The multidimensional force compensation signal is generated after the activation function layer performs a nonlinear transformation on the initial compensation signal; it is used to correct the directional deviation component in the current closed-loop control parameters. The output range of the activation function layer matches the adjustable range of the closed-loop control parameters to ensure that the generated multidimensional force compensation signal can effectively function within that range.

[0074] For example, the preliminary compensation signal generated in step S348 is input into the activation function layer of the compensation signal generation network. The activation function layer can use different activation functions, such as the Sigmoid function or the ReLU function. Based on the adjustable range of the closed-loop control parameters, a suitable activation function is selected so that the output range of the activation function layer matches the adjustable range of the closed-loop control parameters. For example, if the adjustable range of the closed-loop control parameters is [-1, 1], the Sigmoid function can be selected as the activation function, and the preliminary compensation signal is nonlinearly transformed so that its output range is also within [-1, 1]. Finally, a multidimensional force compensation signal is obtained. By generating a multidimensional force compensation signal that matches the adjustable range of the closed-loop control parameters through the nonlinear transformation of the activation function layer, the directional deviation component in the current closed-loop control parameters can be more effectively corrected, making the control of the robotic arm more accurate.

[0075] Step S400: Adjust the proportional-integral-derivative coefficients in the current closed-loop control parameters based on the multidimensional force compensation signal to generate updated closed-loop control parameters, and input the updated closed-loop control parameters into the actuator of the target mechanical device.

[0076] The multidimensional force compensation signal is the signal generated in step S300 used to correct the directional deviation component in the current closed-loop control parameters. The proportional-integral-derivative (PI-DE) coefficients are components of the closed-loop control parameters. The proportional coefficient is used to adjust the proportional relationship between the control quantity and the error, the integral coefficient is used to eliminate the steady-state error of the system, and the derivative coefficient is used to predict the trend of error changes and make adjustments in advance. The updated closed-loop control parameters are obtained by adjusting the P-DE coefficients in the current closed-loop control parameters based on the multidimensional force compensation signal. The actuator of the target mechanical device is the component responsible for executing control commands, such as a motor or cylinder.

[0077] For example, the proportional-integral-derivative (PI-DE) coefficients in the current closed-loop control parameters are adjusted based on the multidimensional force compensation signal. Specifically, the P-DE signal is decomposed into proportional, integral, and derivative compensation terms, which are then superimposed on the proportional, integral, and derivative coefficient vectors in the current closed-loop control parameters. The superimposed coefficient vectors are then processed, such as through gradient constraint processing, integral saturation suppression, and noise filtering, to ensure the adjusted coefficient vectors remain within a reasonable range. Finally, the processed proportional, integral, and derivative coefficient vectors are concatenated to generate updated closed-loop control parameters. These updated parameters are then input to the actuator of the target mechanical device, which performs corresponding control actions based on them. By adjusting the P-DE coefficients based on the multidimensional force compensation signal to generate updated closed-loop control parameters and inputting them into the joint motors of the robotic arm, the robotic arm's movement becomes more consistent with actual force changes, improving the accuracy and stability of the grasping action.

[0078] As one implementation method, step S400, adjusting the proportional-integral-derivative coefficients in the current closed-loop control parameters based on the multi-dimensional force compensation signal, may specifically include the following steps S410~S450:

[0079] Step S410: Decompose the multidimensional force compensation signal into proportional compensation term, integral compensation term and differential compensation term, and superimpose them with the proportional coefficient vector, integral coefficient vector and differential coefficient vector in the current closed-loop control parameters respectively.

[0080] The multidimensional force compensation signal is a signal containing information from multiple dimensions. The proportional compensation term is the part of the multidimensional force compensation signal used to adjust the proportional coefficient, the integral compensation term is used to adjust the integral coefficient, and the derivative compensation term is used to adjust the derivative coefficient. The proportional coefficient vector, integral coefficient vector, and derivative coefficient vector in the current closed-loop control parameters are important parameters used for closed-loop control. The superposition operation adds the proportional compensation term to the proportional coefficient vector, the integral compensation term to the integral coefficient vector, and the derivative compensation term to the derivative coefficient vector element by element to obtain the adjusted coefficient vector.

[0081] For example, the multi-dimensional force compensation signal generated in step S350 is decomposed into proportional compensation terms, integral compensation terms, and differential compensation terms according to preset rules. For instance, it can be decomposed based on the signal's frequency or time characteristics, with preset portions used as differential compensation terms, preset portions as integral compensation terms, and intermediate frequency portions as proportional compensation terms. Then, the proportional compensation terms are superimposed with the proportional coefficient vector in the current closed-loop control parameters, the integral compensation terms are superimposed with the integral coefficient vector, and the differential compensation terms are superimposed with the differential coefficient vector. By decomposing the multi-dimensional force compensation signal into proportional, integral, and differential compensation terms and superimposing them with the corresponding coefficient vectors, the closed-loop control parameters can be adjusted in a timely manner according to actual force changes, improving the control performance of the robotic arm.

[0082] Step S420: Perform gradient constraint processing on the superimposed scaling factor vector to ensure that the magnitude of the adjusted scaling factor vector does not exceed the preset maximum scaling gain threshold.

[0083] Gradient constraint processing is a method for constraining vectors. It limits the gradient change of a vector to ensure that the vector's magnitude does not exceed a preset threshold. The superimposed scaling factor vector is the scaling factor vector obtained through the superposition operation in step S410. The preset maximum scaling gain threshold is a pre-set value used to limit the magnitude of the scaling factor vector and prevent the scaling factor from becoming too large, which could lead to system instability.

[0084] For example, the magnitude of the superimposed scaling factor vector is calculated. This can be done, for instance, using Euclidean distance. Then, it's determined whether the vector's magnitude exceeds a preset maximum scaling gain threshold. If it does, the scaling factor vector is adjusted so that its magnitude equals the preset maximum scaling gain threshold. This adjustment can be done using a normalization method, where each element of the scaling factor vector is divided by the vector's magnitude and then multiplied by the preset maximum scaling gain threshold. By applying gradient constraints to the superimposed scaling factor vector, it's possible to ensure that the scaling factor remains within a reasonable range, preventing instability in the robotic arm's movement due to an excessively large scaling factor.

[0085] Step S430: Perform integration saturation suppression processing on the superimposed integral coefficient vector, and limit the integration accumulation rate by dynamically adjusting the integration time constant.

[0086] Integral saturation suppression is a method used to prevent excessive accumulation of the integral term by dynamically adjusting the integral time constant to limit the rate of integral accumulation. The superimposed integral coefficient vector is the integral coefficient vector obtained through the superposition operation in step S410. The integral time constant is an important parameter in integral control, as it determines the accumulation rate of the integral term.

[0087] For example, during integral control, the accumulated value of the integral term is monitored in real time. When the accumulated value of the integral term approaches or reaches a preset saturation threshold, the integral time constant is dynamically adjusted. For example, increasing the integral time constant slows down the accumulation rate of the integral term, thus preventing integral saturation. By performing integral saturation suppression processing on the superimposed integral coefficient vector, excessive accumulation of the integral term can be prevented, avoiding deviations in the control of the robotic arm due to integral saturation.

[0088] Step S440: Perform noise filtering on the superimposed differential coefficient vector and use the moving average algorithm to eliminate the influence of preset noise on the differential term.

[0089] Noise filtering is a method used to remove noise from signals. The moving average algorithm is one such noise filtering algorithm. It smooths the signal and eliminates pre-existing noise by averaging multiple consecutive data points. The superimposed differential coefficient vector is the differential coefficient vector obtained through the superposition operation in step S410. Pre-existing noise refers to high-frequency noise components in the signal, which can interfere with the calculation of the differential term and affect the control performance of the system. For example, the superimposed differential coefficient vector can be used as input, and the moving average algorithm can be applied for noise filtering. For instance, a sliding window size can be set, such as 5 data points. For each data point, the average of the 5 data points within the window is calculated as the filtered value for that data point. In this way, the signal can be smoothed, and the influence of pre-existing noise on the differential term can be eliminated. By performing noise filtering on the superimposed differential coefficient vector, the accuracy of the differential term calculation can be improved, making the control of the robotic arm more stable.

[0090] Step S450: Concatenate the processed proportional coefficient vector, integral coefficient vector, and derivative coefficient vector to generate updated closed-loop control parameters.

[0091] The processed proportional coefficient vector is the proportional coefficient vector processed in step S420, the processed integral coefficient vector is the integral coefficient vector processed in step S430, and the processed derivative coefficient vector is the derivative coefficient vector processed in step S444. Vector concatenation connects these three vectors in sequence to form a new vector, i.e., the updated closed-loop control parameters. By concatenating the processed proportional coefficient vector, integral coefficient vector, and derivative coefficient vector to generate updated closed-loop control parameters, the adjusted and processed proportional-integral-derivative coefficients can be integrated to provide accurate control parameters for the actuator of the target mechanical device.

[0092] Step S500: The actuator dynamically adjusts the contact operation trajectory of the target mechanical device according to the updated closed-loop control parameters, so that the multi-dimensional force amplitude data output by the non-directional force sensor converges to the preset force control target range.

[0093] An actuator is a component in the target mechanical device responsible for executing control commands, such as a motor or cylinder. The updated closed-loop control parameters are the parameters generated in step S400 for controlling the target mechanical device. The contact operation trajectory of the target mechanical device is the motion trajectory of the device during contact operations. Dynamic adjustment continuously adjusts the motion trajectory of the target mechanical device based on real-time force signals and the updated closed-loop control parameters. The multidimensional force amplitude data output by the omnidirectional force sensor is the force signal data collected in real-time by the omnidirectional force sensor installed on the target mechanical device. The preset force control target range is a pre-defined range of force amplitude values, the goal of which is to converge the multidimensional force amplitude data output by the omnidirectional force sensor to this range.

[0094] For example, based on updated closed-loop control parameters, the actuator drives the joint motor of the target mechanical device to perform corresponding angle or displacement adjustments, thereby changing the contact trajectory of the target mechanical device. During the adjustment process, the multi-dimensional force amplitude data output by the non-directional force sensor is monitored in real time and compared with the preset force control target range. If the multi-dimensional force amplitude data is not within the force control target range, the updated closed-loop control parameters are further adjusted according to the deviation, and the contact trajectory is continued to be adjusted until the multi-dimensional force amplitude data output by the non-directional force sensor converges to the preset force control target range. By dynamically adjusting the contact trajectory of the robotic arm based on the updated closed-loop control parameters, the force situation of the robotic arm when grasping an object can be kept within the preset force control target range, improving the stability and accuracy of grasping.

[0095] As one implementation method, step S500 involves dynamically adjusting the contact operation trajectory of the target mechanical device by the actuator based on the updated closed-loop control parameters, so that the multi-dimensional force amplitude data output by the non-directional force sensor converges to the preset force control target range. Specifically, this may include the following steps S510~S560:

[0096] Step S510: Calculate the real-time position deviation vector between the current contact position and the desired contact position of the actuator based on the proportional coefficient vector in the updated closed-loop control parameters.

[0097] The proportional coefficient vector in the updated closed-loop control parameters is the vector generated in step S400 used to adjust the proportional relationship between the control quantity and the error. The current contact position of the actuator is the position of the actuator at the current moment, and the desired contact position is the position that the actuator should reach according to the job requirements. The real-time position deviation vector is the difference vector between the current contact position and the desired contact position of the actuator, reflecting the deviation between the current position and the desired position.

[0098] For example, the coordinates of the actuator's current contact position and the desired contact position are obtained. For instance, in three-dimensional space, the coordinates of the actuator's current contact position are (x1, y1, z1), and the coordinates of the desired contact position are (x2, y2, z2). Then, the real-time position deviation vector is calculated, i.e., (x2-x1, y2-y1, z2-z1). Based on the proportional coefficient vector in the updated closed-loop control parameters, the real-time position deviation vector is proportionally adjusted. For example, assuming the proportional coefficient vector is [p1, p2, p3], the adjusted real-time position deviation vector is [p1×(x2-x1), p2×(y2-y1), p3×(z2-z1)]. By calculating the real-time position deviation vector between the actuator's current contact position and the desired contact position, and by making proportional adjustments based on the proportional coefficient vector, accurate deviation information can be provided for subsequent trajectory adjustments.

[0099] Step S520: Based on the integral coefficient vector in the updated closed-loop control parameters, perform a weighted integral operation on the historical cumulative value of the real-time position deviation vector within the continuous time window to generate an integral correction vector.

[0100] The integral coefficient vector in the updated closed-loop control parameters is the vector generated in step S400 used to eliminate the system's steady-state error. The historical cumulative value of the real-time position deviation vector within a continuous time window is the cumulative sum of each element of the real-time position deviation vector within that continuous time window. The weighted integration operation involves multiplying the elements of the real-time position deviation vector at each time point by the corresponding integral coefficient during the integration process, and then summing them up. The integral correction vector is the vector obtained through the weighted integration operation; it is used to correct the actuator's motion trajectory and eliminate the system's steady-state error.

[0101] For example, historical data of the real-time position deviation vector is recorded within a continuous time window. For instance, the time window is set to 10 sampling periods, and the real-time position deviation vector is recorded for each sampling period. Then, based on the integral coefficient vector in the updated closed-loop control parameters, a weighted integral is performed on the historical cumulative value of the real-time position deviation vector. By performing a weighted integral on the historical cumulative value of the real-time position deviation vector within the continuous time window, an integral correction vector is generated, which can eliminate steady-state errors during the robot arm's movement, making the robot arm's movement more accurate.

[0102] Assume a robotic arm performs a contact operation in three-dimensional space, with a force sensor without orientation collecting force signals in real time to adjust the arm's movement. A continuous time window is set to 5 sampling periods, during which historical data of the real-time position deviation vector is recorded. The real-time position deviation vector corresponds to three dimensions in the three-dimensional space: X, Y, and Z. The integral coefficient vector in the updated closed-loop control parameters is generated in step S400 to eliminate system steady-state errors. For example, after analyzing system characteristics and operational requirements using an optimization algorithm (such as a genetic algorithm), the integral coefficient vector is determined to be [0.2, 0.3, 0.5]. This means that in the weighted integral operation, the weights of the real-time position deviation vector elements in the X direction are 0.2, in the Y direction 0.3, and in the Z direction 0.5. Assume that within the 5 consecutive sampling periods, the elements of the real-time position deviation vector in the X direction are 1, -2, 3, -1, 2; in the Y direction, 2, 1, -1, 3, -2; and in the Z direction, -1, 2, 1, -3, 2. The weighted integral of the historical cumulative values ​​in the X direction is calculated as follows: 0.2 × (1 - 2 + 3 - 1 + 2) = 0.6; in the Y direction: 0.3 × (2 + 1 - 1 + 3 - 2) = 0.9; in the Z direction: 0.5 × (-1 + 2 + 1 - 3 + 2) = 0.5. The final integral correction vector is [0.6, 0.9, 0.5], which is used to correct the robot arm's motion trajectory and eliminate the system's steady-state error.

[0103] Step S530: Based on the differential coefficient vector in the updated closed-loop control parameters, perform sliding window differential operation on the rate of change of the real-time position deviation vector in adjacent sampling periods to generate a differential suppression vector.

[0104] The differential coefficient vector in the updated closed-loop control parameters is the vector generated in step S400 for predicting error change trends and making adjustments in advance. The rate of change of the real-time position deviation vector within adjacent sampling periods is the difference between two adjacent sampling periods divided by the time interval between the sampling periods. The sliding window differential operation calculates the rate of change of the real-time position deviation vector within a sliding window. The differential suppression vector is a vector obtained through the sliding window differential operation; it is used to suppress rapid changes during actuator motion and improve system stability.

[0105] For example, set the size of a sliding window, such as 3 sampling periods. In each sampling period, calculate the rate of change of the real-time position deviation vector within the adjacent sampling period. For example, suppose the real-time position deviation vector of the current sampling period is [(x2-x1)_n, (y2-y1)_n, (z2-z1)_n], the real-time position deviation vector of the previous sampling period is [(x2-x1)_(n-1), (y2-y1)_(n-1), (z2-z1)_(n-1)], and the time interval of the sampling period is Δt. Then the rate of change of the real-time position deviation vector within the adjacent sampling period is [((x2-x1)_n-(x2-x1)_(n-1)) / Δt, ((y2-y1)_n-(y2-y1)_(n-1)) / Δt, ((z2-z1)_n-(z2-z1)_(n-1)) / Δt]. Then, based on the differential coefficient vector in the updated closed-loop control parameters, the rate of change of the real-time position deviation vector is differentially adjusted. For example, assuming the differential coefficient vector is [d1, d2, d3], the differential suppression vector is [d1×((x2-x1)_n-(x2-x1)_(n-1)) / Δt, d2×((y2-y1)_n-(y2-y1)_(n-1)) / Δt, d3×((z2-z1)_n-(z2-z1)_(n-1)) / Δt]. By performing sliding-window differential operations on the rate of change of the real-time position deviation vector within adjacent sampling periods, a differential suppression vector is generated, which can suppress rapid changes during the robot arm's movement and improve the stability of the robot arm's movement.

[0106] Step S540: Superimpose the real-time position deviation vector, integral correction vector, and differential suppression vector to generate a trajectory adjustment command, and convert the trajectory adjustment command into a drive signal for the actuator to drive the joint motor of the target mechanical device to perform the corresponding angle adjustment or displacement adjustment.

[0107] The real-time position deviation vector is the deviation vector between the current contact position and the desired contact position of the actuator, calculated in step S510. The integral correction vector is the vector generated in step S520 to eliminate the steady-state error of the system. The differential suppression vector is the vector generated in step S530 to suppress rapid changes during the actuator's movement. Vector superposition involves adding or weighted summing the corresponding elements of these three vectors to obtain a new vector, namely the trajectory adjustment command. The trajectory adjustment command is used to adjust the contact trajectory of the target mechanical device. The actuator's drive signal is the signal obtained after converting the trajectory adjustment command, used to drive the joint motor of the target mechanical device to perform the corresponding angle or displacement adjustment.

[0108] For example, the real-time position deviation vector, integral correction vector, and differential suppression vector are superimposed. Then, the trajectory adjustment command is converted into a drive signal for the actuator. For instance, a conversion function is used to convert each element of the trajectory adjustment command into a corresponding voltage or current value, which serves as the actuator's drive signal. The actuator drives the joint motor of the target mechanical device to perform corresponding angle or displacement adjustments based on the drive signal, thereby adjusting the contact operation trajectory of the target mechanical device. By superimposing the real-time position deviation vector, integral correction vector, and differential suppression vector to generate a trajectory adjustment command and converting it into a drive signal for the actuator, the contact operation trajectory of the robotic arm can be accurately adjusted, making the movement of the robotic arm more in line with the operational requirements.

[0109] As one implementation method, the process of generating trajectory adjustment instructions further includes the following steps S541~S545:

[0110] S541: Real-time monitoring of whether the multi-dimensional force amplitude data output by the non-directional force sensor exceeds the boundary threshold of the force control target range.

[0111] The multidimensional force amplitude data output by the omnidirectional force sensor is force signal data collected in real time by the omnidirectional force sensor installed on the target mechanical device. The force control target range is a pre-set range of force amplitude values, and the boundary thresholds are the upper and lower limits of the force control target range. Real-time monitoring involves continuously acquiring the multidimensional force amplitude data output by the omnidirectional force sensor during the operation of the target mechanical device and comparing it with the boundary thresholds of the force control target range. For example, the multidimensional force amplitude data output by the omnidirectional force sensor can be acquired in real time through a data acquisition system. For example, force amplitude data in three-dimensional space can be acquired in the X, Y, and Z directions. Then, the force amplitude data in each direction is compared with the boundary thresholds of the force control target range. If the force amplitude data in a certain direction is greater than the upper threshold or less than the lower threshold of the force control target range, it is considered that the force amplitude data in that direction exceeds the boundary threshold of the force control target range. By monitoring whether the multidimensional force amplitude data output by the omnidirectional force sensor exceeds the boundary thresholds of the force control target range in real time, abnormal force conditions on the robotic arm can be detected in a timely manner, providing a basis for subsequent emergency handling.

[0112] S542: When the boundary threshold is exceeded, an emergency braking command is generated based on the direction and magnitude of the exceedance, and the execution of the trajectory adjustment command is interrupted.

[0113] The out-of-direction refers to the direction in which the force amplitude data exceeds the boundary threshold of the force control target range, such as the X, Y, or Z direction. The out-of-amplitude refers to the magnitude by which the force amplitude data exceeds the boundary threshold of the force control target range. The emergency braking command is generated based on the out-of-direction and amplitude, and is used to immediately stop the movement of the target mechanical device to avoid potential danger or damage. The execution of the interrupted trajectory adjustment command stops the currently executing trajectory adjustment command, causing the target mechanical device to pause its movement.

[0114] For example, when the multidimensional force amplitude data output by the non-directional force sensor exceeds the boundary threshold of the force control target range, the first step is to accurately determine the direction of the excess. Taking an industrial robot grasping an object as an example, suppose the threshold range of the force control target range in the X direction is [F x_min , F x_max ], in the Y direction is [F y_min , F y_max ], in the Z direction is [F z_min ,F z_max When the real-time collected X-direction force amplitude F x Greater than F x_max Or less than F x_min When the X direction exceeds the boundary threshold, it is determined that the X direction exceeds the threshold. Similarly, the Y and Z directions can be determined.

[0115] After determining the out-of-direction, calculate the out-of-direction amplitude. The out-of-direction amplitude can be expressed as the difference between the actual force amplitude and the corresponding boundary threshold, for example, the out-of-direction amplitude ΔF in the X direction. x =|F x -F x_max |(When F x > F x_max (time) or ΔF x =|F x -F x_min |(When F x < F x_min hour).

[0116] An emergency braking command is generated based on the direction and amplitude of the out-of-range force. This command contains explicit stop information to control the actuators of the target mechanical device to immediately cease movement. For example, for the joint motors of an industrial robot, the emergency braking command could be an electrical signal that rapidly cuts off power to the motor, thereby stopping the joint's movement. The specific parameters of this electrical signal can be adjusted based on the out-of-range amplitude; if the out-of-range amplitude is large, a stronger braking signal may be needed to ensure the mechanical device stops quickly.

[0117] Simultaneously, the system will immediately interrupt the ongoing trajectory adjustment command. This can be achieved through software-level control logic, such as setting an interrupt flag in the control system. When an exceedance of the boundary threshold is detected, the flag is set to an active state, causing the trajectory adjustment command execution program to immediately stop sending and executing subsequent commands upon receiving the flag signal. This ensures that the target mechanical device will not continue to move according to the original trajectory adjustment command, avoiding further danger or damage.

[0118] S543: After the emergency braking command takes effect, the real-time force signal sequence is reacquired and the rapid recalculation process of the force trend prediction model is initiated.

[0119] After the emergency braking command takes effect, the target mechanical device stops moving. At this time, it is necessary to re-acquire the real-time force signal sequence to obtain the force signal information under the current state. The re-acquisition process is similar to step S100. The force signal generated by the target mechanical device when performing contact operation is collected by a non-directional force sensor at a preset sampling frequency to form a new real-time force signal sequence.

[0120] The fast recalculation process for the force trend prediction model is initiated. Previous force trend prediction results may become inapplicable due to force amplitudes exceeding boundary thresholds, necessitating recalculation. The fast recalculation process is essentially the same as the normal force trend prediction process, but with higher computational speed requirements. For example, when performing sliding window segmentation on the real-time force signal sequence (step S210), the size of the sliding window can be appropriately reduced to decrease data processing volume and thus accelerate computation. Simultaneously, more efficient algorithms and optimization strategies can be employed in the computation of various layers of the force trend prediction model (such as the temporal coding layer and the dynamic weight allocation layer), such as using parallel computing techniques to improve computational efficiency.

[0121] In scenarios where industrial robots grasp objects, re-acquiring real-time force signal sequences after emergency braking allows for accurate acquisition of the current force situation of the robotic arm. Initiating a rapid recalculation process for the force trend prediction model quickly yields new force direction trend predictions, providing a basis for subsequent adjustments, shortening system response time, and improving system stability and reliability.

[0122] S544: Based on the updated force direction trend prediction results obtained from rapid recalculation, generate a new multidimensional force compensation signal to cover the original compensation signal.

[0123] The updated force direction trend prediction result obtained from the rapid recalculation is the output of the force trend prediction model, representing the future force change trend, after the rapid recalculation process. Based on this updated result, a new multidimensional force compensation signal is generated according to step S300 and its subsequent sub-steps.

[0124] First, a multi-dimensional force compensation signal is generated based on the matching degree between the updated force direction trend prediction result and the current closed-loop control parameters. Specifically, the proportional coefficient vector, integral coefficient vector, and derivative coefficient vector in the current closed-loop control parameters are obtained and normalized to generate a closed-loop control parameter feature matrix (step S310). Then, the similarity between the vector distribution features corresponding to the updated force direction trend prediction result and the closed-loop control parameter feature matrix is ​​calculated to generate a direction deviation feature vector (step S320). Next, the direction deviation feature vector is input into the fully connected layer of a preset compensation signal generation network to extract preset oscillation components and preset offset components (step S330). Then, the preset oscillation components and preset offset components are fused across channels through the convolutional kernel group of the compensation signal generation network to generate a preliminary compensation signal (step S340). In the process of generating the preliminary compensation signal, corresponding constraints must also be followed, such as prioritizing the suppression of the compensation signal amplitude in two dimensions when the force amplitude changes in at least two dimensions in the updated force direction trend prediction result are opposite. Finally, the preliminary compensation signal is input into the activation function layer of the compensation signal generation network for nonlinear transformation to generate a new multidimensional force compensation signal (step S350).

[0125] The newly generated multidimensional force compensation signal will override the original compensation signal because the original signal was generated based on previous force trend predictions. Since the current situation has changed, the new compensation signal can more accurately reflect the current force change trend, thus better correcting the directional deviation component in the current closed-loop control parameters. In scenarios where industrial robots grasp objects, the new multidimensional force compensation signal allows the robotic arm to better adapt to actual force changes in subsequent movements, improving the accuracy and stability of the grasping action.

[0126] S545: After the new multi-dimensional force compensation signal takes effect, release the emergency braking command and resume the execution of the trajectory adjustment command.

[0127] Once the new multidimensional force compensation signal takes effect, it indicates that the system has generated a suitable compensation signal based on the current force change trend, and this signal has begun to adjust the closed-loop control parameters. At this point, the emergency braking command can be released, and the movement of the target mechanical device can be resumed.

[0128] The emergency braking command can be released through software-level control logic, such as resetting the previously set interrupt flag, allowing the control system to continue sending and executing trajectory adjustment commands. After resuming the execution of the trajectory adjustment command, the actuator will dynamically adjust the contact trajectory of the target mechanical device according to the updated closed-loop control parameters. The specific process includes calculating the real-time position deviation vector between the current contact position and the desired contact position of the actuator based on the proportional coefficient vector in the updated closed-loop control parameters (step S510), performing a weighted integral operation on the historical cumulative value of the real-time position deviation vector within a continuous time window based on the integral coefficient vector to generate an integral correction vector (step S520), performing a sliding window differential operation on the rate of change of the real-time position deviation vector within adjacent sampling periods based on the differential coefficient vector to generate a differential suppression vector (step S530), and then superimposing the real-time position deviation vector, integral correction vector, and differential suppression vector to generate a trajectory adjustment command. The trajectory adjustment command is then converted into a drive signal for the actuator, driving the joint motor of the target mechanical device to perform the corresponding angle adjustment or displacement adjustment (step S540).

[0129] In scenarios where industrial robots grasp objects, releasing the emergency braking command and resuming the execution of the trajectory adjustment command allows the robotic arm to continue moving along the adjusted trajectory. Under the action of the new multi-dimensional force compensation signal, it can complete the grasping task more accurately.

[0130] Step S550: Monitor in real time whether the multidimensional force amplitude data output by the non-directional force sensor enters the force control target range. If it does not enter, dynamically adjust the gain weight of the proportional-integral-derivative coefficients in the updated closed-loop control parameters according to the boundary distance between the multidimensional force amplitude data and the force control target range, and generate the secondary corrected closed-loop control parameters.

[0131] The process of real-time monitoring of whether the multidimensional force amplitude data output by the non-directional force sensor enters the force control target range is similar to step S541. The multidimensional force amplitude data output by the non-directional force sensor is acquired in real time through a data acquisition system and compared with the boundary threshold of the force control target range. If the force amplitude data in all dimensions are within the force control target range, the multidimensional force amplitude data is considered to have entered the force control target range; otherwise, it is considered not to have entered.

[0132] If the multidimensional force amplitude data does not fall within the force control target range, the gain weights of the proportional-integral-derivative coefficients in the updated closed-loop control parameters need to be dynamically adjusted based on the boundary distance between the multidimensional force amplitude data and the force control target range. For example, in the X direction, if the force amplitude data F x The upper limit threshold F of the force control target range is greater than x_max Calculate the boundary distance ΔF x =F x -Fx_max If F x Less than the lower threshold F x_min Calculate the boundary distance ΔF x =F x_min -F x Based on this boundary distance, the gain weights of the proportional-integral-derivative coefficients are dynamically adjusted.

[0133] For the proportional gain, if the boundary distance is large, it indicates that the current control strength may be insufficient. The gain weight of the proportional gain needs to be increased to strengthen the proportional relationship between the control quantity and the error, allowing the actuator to adjust its position more quickly. For example, let the original proportional gain be p, and the gain weight adjustment coefficient be k. p The adjusted proportionality coefficient is p'=p×k p , where k p It can be adjusted linearly or nonlinearly based on the magnitude of the boundary distance.

[0134] If the boundary distance persists for the integral coefficients, it indicates a potential steady-state error in the system. Therefore, it's necessary to increase the gain weight of the integral coefficients to accelerate the accumulation of the integral term and eliminate the steady-state error. Similarly, let the original integral coefficients be *i* and the gain weight adjustment coefficient be *k*. i The adjusted integral coefficient is i'=i×k i .

[0135] For differential coefficients, if the boundary distance changes rapidly, it indicates significant dynamic changes in the system. Therefore, it's necessary to increase the gain weight of the differential coefficients to better predict error trends and make adjustments in advance. Let the original differential coefficients be d, and the gain weight adjustment coefficient be k. d The adjusted differential coefficients are d'=d×k d .

[0136] The adjusted proportional, integral, and derivative coefficients are vector-concatenated to generate secondary corrected closed-loop control parameters. By dynamically adjusting the gain weights of the proportional-integral-derivative coefficients, secondary corrected closed-loop control parameters are generated, enabling the robotic arm to more effectively adjust its motion trajectory when the multidimensional force amplitude data has not entered the force control target range, thus allowing the force amplitude data to converge into the force control target range as quickly as possible.

[0137] Step S560: Input the secondary correction closed-loop control parameters into the actuator to trigger the compensation adjustment of the contact operation trajectory of the target mechanical device until the multi-dimensional force amplitude data is stable and continuous within the force control target range for a preset time.

[0138] The secondary correction closed-loop control parameters are input to the actuator. The actuator drives the joint motor of the target mechanical device to perform corresponding angle or displacement adjustments based on these parameters, thereby triggering the compensation adjustment of the contact operation trajectory of the target mechanical device. The compensation adjustment process is similar to step S540, including calculating the real-time position deviation vector based on the proportional coefficient vector in the secondary correction closed-loop control parameters, generating an integral correction vector based on the integral coefficient vector, generating a differential suppression vector based on the differential coefficient vector, and then superimposing these vectors to generate a trajectory adjustment command, which is then converted into a drive signal for the actuator.

[0139] During the compensation and adjustment process, the multidimensional force amplitude data output by the non-directional force sensor is continuously monitored in real time to ensure it remains within the force control target range. Once the multidimensional force amplitude data enters the force control target range, timing begins to determine whether it remains stable for a preset duration. The preset duration is a pre-set time value, such as 5 seconds, used to ensure that the multidimensional force amplitude data remains stable within the force control target range, avoiding misjudgments due to brief fluctuations.

[0140] If the multidimensional force amplitude data remains stable and continuous within the force control target range for a preset duration, the contact operation trajectory of the target mechanical device is considered successfully adjusted, and the system achieves the expected force control effect. By inputting the secondary correction closed-loop control parameters into the actuator, compensation adjustments are made to the contact operation trajectory until the multidimensional force amplitude data remains stable and continuous within the force control target range for a preset duration. This ensures that the force applied to the robotic arm when grasping an object remains stable within the preset range, improving the quality and stability of the grasping process.

[0141] In one implementation, the training process of the pre-trained force trend prediction model includes the following steps S10-S50:

[0142] Step S10: Collect historical force signal sequences and corresponding actual force direction change data of multiple sets of mechanical devices under various contact operation conditions, and construct a training dataset.

[0143] Mechanical devices generate different force signals under various contact operation conditions. These force signals reflect the force experienced by the device under different operating conditions. The historical force signal sequence is a sequence of force signal data collected over a past period, while the actual force direction change data is the actual change in force direction corresponding to the historical force signal sequence.

[0144] The process of collecting multiple sets of historical force signal sequences and corresponding actual force direction change data is as follows: Different types of mechanical devices are selected, such as industrial robots and automated processing equipment, and various contact operation conditions are set. For industrial robots, different grasping tasks can be set, such as grasping objects of different shapes and weights; for automated processing equipment, different processing techniques can be set, such as grinding and drilling. Under each contact operation condition, a non-directional force sensor is used to collect the force signals generated when the mechanical device performs its operation. These signals are sampled according to the sampling frequency to form a historical force signal sequence. Simultaneously, other measurement methods (such as high-precision angle sensors and displacement sensors) are used to record the actual changes in force direction, forming corresponding actual force direction change data.

[0145] The collected historical force signal sequences and corresponding actual force direction change data were organized and labeled to construct a training dataset. This training dataset, used to train the force trend prediction model, contains rich information on force signals and force direction changes, enabling the model to learn the force variation patterns under different contact working conditions.

[0146] Step S20: Perform time alignment and noise filtering on the historical force signal sequence to generate standardized force signal samples.

[0147] Time alignment accurately arranges data points in the historical force signal sequence according to time order, ensuring that each data point corresponds to the correct timestamp. Noise filtering removes noise interference from the historical force signal sequence, making the signal cleaner and facilitating subsequent analysis and processing. Standardized force signal samples are force signal samples obtained after time alignment and noise filtering. They have a uniform time scale and low noise level, which is beneficial for improving the training effect of force trend prediction models.

[0148] As one implementation method, step S20 involves performing time alignment and noise filtering on the historical force signal sequence to generate standardized force signal samples, which may specifically include the following steps:

[0149] Step S21: Perform baseline drift correction on the historical force signal sequence to eliminate preset interference components caused by sensor zero-point offset.

[0150] Sensor zero-point offset is the phenomenon where a sensor outputs a non-zero signal value even when no force is applied. This zero-point offset introduces pre-existing interference components into the historical force signal sequence, affecting signal accuracy. Baseline drift correction aims to eliminate these pre-existing interference components, restoring the signal baseline to the correct position.

[0151] For example, first, the preset characteristics of the historical force signal sequence are analyzed, and preset components are extracted using a filtering algorithm (such as a low-pass filter). Then, the mean or median of the preset components is calculated and used as an estimate of the baseline drift. Finally, the baseline drift estimate is subtracted from each data point in the historical force signal sequence to achieve baseline drift correction.

[0152] Step S22: Perform sliding window variance analysis on the corrected historical force signal sequence to identify abnormal noise segments with sudden changes in force amplitude within the window.

[0153] Sliding window analysis of variance (ANOVA) is a method used to analyze the local variation characteristics of a signal. It calculates the variance of the signal within a fixed-size window by sliding it across the signal. Variance reflects the degree of fluctuation of the signal within the window; when the amplitude of the signal changes abruptly within the window, the variance increases significantly.

[0154] For example, a sliding window size can be set, such as 20 data points. Starting from the beginning of the corrected historical force signal sequence, the 20 data points covered by the window are considered as one window, and the variance of the signal within the window is calculated. Then, the window is slid forward by one data point, and the variance of the signal within the new window is calculated again, and so on, until the end of the sequence is reached. A variance threshold is set; when the variance within a window exceeds this threshold, it is considered that there is an abnormal noise segment with abrupt changes in force amplitude within that window. For example, a variance threshold of 1 can be set; when the variance calculated within a window is 1.5, that window is identified as an abnormal noise segment.

[0155] Step S23: Use an adaptive filtering algorithm to perform local smoothing on the abnormal noise segment, while preserving the dynamic characteristics of the non-noise segment in the original signal.

[0156] Adaptive filtering algorithms are algorithms that automatically adjust filtering parameters based on the local characteristics of a signal. They can remove noise while preserving the dynamic features of the signal. The purpose of local smoothing of abnormal noise segments is to eliminate abnormal noise, making the signal smoother, without affecting the dynamic changes of non-noise segments in the original signal.

[0157] For example, for identified abnormal noise segments, an adaptive filtering algorithm is used. For instance, an adaptive median filtering algorithm is used, which adaptively adjusts the size of the filtering window and the filtering coefficients based on the median of the data within the window and the distribution of the neighboring data. For each data point in the abnormal noise segment, an appropriate filtering coefficient is selected based on the median and distribution of its neighboring data to obtain a smoothed signal value. During processing, only the abnormal noise segments are processed, while the non-noise data in the original signal remains unchanged, thus preserving the dynamic characteristics of the original signal.

[0158] Step S24: Resample the smoothed historical force signal sequence with timestamps so that the sampling interval is consistent with the recording frequency of the actual force direction change data.

[0159] Timestamp resampling adjusts the sampling interval of the smoothed historical force signal sequence to match the recording frequency of the actual force direction change data, enabling subsequent matching and analysis. The recording frequency of the actual force direction change data may differ from the original sampling frequency of the historical force signal sequence; timestamp resampling ensures temporal alignment between the two.

[0160] For example, determine the recording frequency of actual force direction change data, such as 10 times per second. Based on this recording frequency, timestamp resample the smoothed historical force signal sequence. A linear interpolation method can be used. If there is no original data at the resampled time point, linear interpolation is performed based on adjacent original data points to obtain the signal value at the resampled time point. For example, if there is no original data at the resampled time point t, but the adjacent original data points are t1 and t2, with corresponding signal values ​​x1 and x2, then the signal value x at the resampled time point t can be calculated using the linear interpolation formula x = x1 + (x2 - x1) × (t - t1) / (t2 - t1).

[0161] Step S25: Normalize the amplitude of the resampled historical force signal sequence according to the dimension, so that the force amplitudes of each dimension are aligned in time under the same dimension, and generate standardized force signal samples.

[0162] Amplitude normalization transforms the force amplitude of each dimension in the resampled historical force signal sequence to a predefined range, typically [0, 1] or [-1, 1], to eliminate dimensional differences between different dimensions and align the force amplitudes of each dimension in time under the same dimension.

[0163] For example, for each dimension of the resampled historical force signal sequence, find the maximum and minimum values ​​in that dimension. For example, for the force amplitude sequence in the X direction, find the maximum value F. x_max and minimum value F x_min Then, for each data point F in that dimension... xi Using the normalization formula F xi_normalized =(F xi -F x_min ) / (F x_max -F x_min Normalize it to the range [0,1]. Perform the same normalization process on the force amplitude sequence of all dimensions to obtain the historical force signal sequence after amplitude normalization by dimension, that is, the standardized force signal sample.

[0164] Step S30: Input the standardized force signal sample into the initial force trend prediction model and obtain the predicted force direction trend result output by the initial force trend prediction model.

[0165] The initial force trend prediction model is an untrained or pre-trained model, requiring training to optimize its parameters and improve prediction accuracy. The standardized force signal sample is a force signal sample that has undergone time alignment, noise filtering, and amplitude normalization; it contains the force signal characteristics of the mechanical device under different contact operating conditions.

[0166] After standardized force signal samples are input into the initial force trend prediction model, the model processes and analyzes the input signals, using its internal algorithms and structures to calculate the predicted force direction trend. The predicted force direction trend is the model's prediction of the future trend of force direction changes, represented using vector distribution characteristics, etc. For example, in a scenario where an industrial robot grasps an object, the initial force trend prediction model, based on the input standardized force signal samples, predicts the changing trend of the robotic arm's force in different directions over a future period, and outputs the predicted force direction trend.

[0167] Step S40: Calculate the trend error loss between the predicted force direction trend result and the actual force direction change data, and calculate the closed-loop control error loss of the predicted force direction trend result in the closed-loop control simulation environment.

[0168] Trend error loss is the degree of difference between the predicted force direction trend and the actual force direction change data; it reflects the accuracy of the model in predicting the force direction trend. Closed-loop control error loss is the control error in the closed-loop control simulation environment where the predicted force direction trend is applied; it reflects the impact of the model's predictions on the performance of the closed-loop control system.

[0169] As one implementation method, step S40, calculating the closed-loop control error loss of the predicted force direction trend result in the closed-loop control simulation environment, may specifically include the following steps:

[0170] Step S41: Input the predicted force direction trend result into the preset closed-loop control parameter response simulator to generate simulated force control trajectory data containing multi-dimensional force adjustment instructions.

[0171] The preset closed-loop control parameter response simulator is a pre-designed simulator that can simulate the response process of a closed-loop control system based on the input predicted force direction trend, generating simulated force control trajectory data containing multi-dimensional force adjustment commands. The simulated force control trajectory data, generated in the closed-loop control simulation environment based on the predicted force direction trend, corresponds to the force control trajectory data of the multi-dimensional force adjustment commands. It includes multi-dimensional force amplitudes and corresponding contact trajectory changes at different time points.

[0172] For example, the predicted force direction trend is input into a preset closed-loop control parameter response simulator. Based on the predicted force direction trend and preset closed-loop control parameters (such as proportional, integral, and derivative coefficients), the simulator simulates the operation of the closed-loop control system. During the simulation, corresponding multi-dimensional force adjustment commands are generated based on the predicted force direction trend. These commands are used to adjust the motion trajectory of the mechanical device. The multi-dimensional force amplitude and corresponding contact trajectory changes at different time points during the simulation are recorded to form simulated force control trajectory data. For example, the preset closed-loop control parameter response simulator simulates the motion of a robotic arm under closed-loop control based on the predicted force direction trend, generating simulated force control trajectory data containing force adjustment commands in the X, Y, and Z directions.

[0173] Step S42: Extract real force control trajectory data synchronized with actual force direction change data from the training dataset. The real force control trajectory data includes the time series of multi-dimensional force amplitude and the corresponding contact trajectory change vector.

[0174] Real force control trajectory data is force control trajectory data collected during actual contact operations. It reflects the force conditions and motion trajectory of the mechanical device during actual operation. Extracting real force control trajectory data synchronized with actual force direction changes from the training dataset is to compare the simulated force control trajectory data with the real force control trajectory data and calculate the closed-loop control error loss.

[0175] For example, in the training dataset, the time range corresponding to the actual force direction change data is found, and the real force control trajectory data within that time range is extracted. The real force control trajectory data includes a time series of multi-dimensional force amplitudes, i.e., the force amplitude in different dimensions at each time point, and the corresponding contact trajectory change vector, i.e., the position and attitude change information of the mechanical device at each time point. For example, in a scenario where an industrial robot grasps an object, real force control trajectory data synchronized with the actual force direction change data is extracted from the training dataset. This includes the time series of force amplitudes of the robotic arm in the X, Y, and Z directions, as well as contact trajectory change information such as the angle change vectors of the robotic arm joints.

[0176] Step S43: Align the simulated force control trajectory data with the real force control trajectory data in a windowed manner according to the time dimension, and extract the instantaneous fluctuation difference and cumulative trend deviation of the multidimensional force amplitude within each alignment window.

[0177] Windowing alignment divides simulated and real force control trajectory data along the time dimension, forming aligned windows. Each window contains simulated and real force control trajectory data within the same time range. Instantaneous fluctuation difference is the difference in multidimensional force amplitude between the simulated and real force control trajectory data at each time point within each aligned window. Cumulative trend deviation is the difference in the cumulative trend of multidimensional force amplitude changes between the simulated and real force control trajectory data within each aligned window.

[0178] For example, set a window size, such as 10 time points. Starting from the initial time points of the simulated force control trajectory data and the actual force control trajectory data, use the data from the 10 time points covered by the window as an alignment window. For each time point within each alignment window, calculate the difference in multidimensional force amplitude between the simulated and actual force control trajectory data to obtain the instantaneous fluctuation difference. Simultaneously, calculate the cumulative change in multidimensional force amplitude between the simulated and actual force control trajectory data within that window, and calculate the difference between the two to obtain the cumulative trend deviation. For example, within an alignment window, for the force amplitude in the X direction, calculate the difference between the simulated and actual force amplitude at each time point to obtain the instantaneous fluctuation difference in the X direction; calculate the cumulative change in simulated and actual force amplitude within that window, and calculate the difference between the two to obtain the cumulative trend deviation in the X direction.

[0179] Step S44: Calculate the dynamic tracking error of force amplitude in each dimension by instantaneous fluctuation difference, and calculate the steady-state offset of force amplitude in each dimension by cumulative trend deviation.

[0180] Dynamic tracking error is the error in dynamically tracking force amplitude changes reflected by the instantaneous fluctuation differences of force amplitude in each dimension within each alignment window. Steady-state offset is the error in steady-state control reflected by the cumulative trend deviation of force amplitude in each dimension within each alignment window. For example, the average of the sum of squares of the instantaneous fluctuation differences of force amplitude in each dimension within each alignment window yields the dynamic tracking error for that dimension's force amplitude. For instance, for the force amplitude in the X direction, the instantaneous fluctuation difference at 10 time points within an alignment window is ΔF. x_1 , ΔF x_2 ,..., ΔF x_10 Then the dynamic tracking error E in the X direction xd ynamic=(ΔF x_1 2 +ΔF x_2 2 +...+ΔF x_10 2) / 10. For the cumulative trend deviation of the force amplitude in each dimension within each alignment window, take its absolute value as the steady-state offset of the force amplitude in that dimension.

[0181] Step S45: Linearly superimpose the dynamic tracking error and the steady-state offset according to a preset ratio to generate a closed-loop control error loss that characterizes the direction prediction accuracy and control stability.

[0182] The preset ratio is a pre-defined proportional coefficient used to adjust the weights of dynamic tracking error and steady-state offset in the closed-loop control error loss. Linear superposition multiplies the dynamic tracking error and steady-state offset by the preset ratio respectively, then adds them together to obtain the closed-loop control error loss. The closed-loop control error loss characterizes the direction prediction accuracy and control stability of the model's predicted force direction trend in the closed-loop control simulation environment. For example, let the preset ratios be α and β, where α represents the weight of the dynamic tracking error and β represents the weight of the steady-state offset, and α + β = 1. For the force amplitude value in each dimension, the dynamic tracking error E in that dimension is... d ynamic multiplied by α, steady-state offset E steady Multiply by β and then sum to obtain the closed-loop control error loss E in this dimension. closed_loop .

[0183] Step S50: Integrate the trend error loss and closed-loop control error loss to generate the total training loss value, and update the parameters of the initial force trend prediction model through the backpropagation algorithm until the total training loss value converges.

[0184] Trend error loss reflects the model's accuracy in predicting the direction of force trends, while closed-loop control error loss reflects the impact of the model's predictions on the performance of the closed-loop control system. Integrating trend error loss and closed-loop control error loss to generate a total training loss value allows for a comprehensive consideration of both the model's predictive accuracy and control performance.

[0185] For example, let's define a fusion coefficient γ, where γ represents the weight of the trend error loss and 1-γ represents the weight of the closed-loop control error loss. Multiply the trend error loss by γ, multiply the closed-loop control error loss by 1-γ, and then add them together to obtain the total training loss value. For example, the total training loss value L... total =γ×L trend +(1-γ)×L closed_loop L trend L represents the trend error loss. closed_loop This represents the error loss in closed-loop control.

[0186] The parameters of the initial force trend prediction model are updated using the backpropagation algorithm. The backpropagation algorithm calculates the gradient of the model parameters based on the total training loss value, and then updates the model parameters according to the gradient, gradually reducing the total training loss value. In each iteration, standardized force signal samples are input into the initial force trend prediction model to calculate the predicted force direction trend, and then calculate the trend error loss and closed-loop control error loss, fusing them to obtain the total training loss value. Then, the gradient of the total training loss value with respect to the model parameters is calculated using the backpropagation algorithm, and the model parameters are updated according to the gradient. This process is repeated until the total training loss value converges, meaning that the total training loss value no longer changes significantly in multiple iterations. At this point, the parameters of the initial force trend prediction model are considered optimized, training is complete, and a pre-trained force trend prediction model is obtained. In summary, by collecting real-time force signal sequences and using the pre-trained force trend prediction model to predict the force direction trend, multi-dimensional force compensation signals are generated to adjust the closed-loop control parameters, ultimately achieving dynamic adjustment of the contact operation trajectory of the target mechanical device, causing the multi-dimensional force amplitude data output by the non-directional force sensor to converge to the preset force control target range. Meanwhile, by training the force trend prediction model, the prediction accuracy and control performance of the model are improved, ensuring the stability and reliability of the entire closed-loop control system.

[0187] Please see Figure 2 , Figure 2 This is a schematic diagram of a computer system provided in an embodiment of the present invention. The computer system is connected to or built into a target mechanical device. The computer system includes at least a processor 101, a communication interface 102, and a memory 103. The processor 101, communication interface 102, and memory 103 can be connected via a bus or other means. The processor 101 (or Central Processing Unit, CPU) is the computing and control core of the computer system, capable of parsing various instructions and processing various data within the computer system. The communication interface 102 may optionally include a standard wired interface or a wireless interface (such as Wi-Fi, mobile communication interface, etc.), and can be used to send and receive data under the control of the processor 101; the communication interface 102 can also be used for data transmission and interaction within the computer system. The memory 103 is a memory device in the computer system used to store programs and data. It is understood that the memory 103 here can include the computer system's built-in memory, or it can include extended memory supported by the computer system. The memory 103 provides storage space, which stores the computer system's operating system; this invention does not limit this. In one embodiment, the processor 101 executes the non-directional force sensor closed-loop control method based on real-time force trend prediction provided in the above embodiments of the present invention by running a computer program in the memory 103.

Claims

1. A closed-loop control method based on real-time force trend prediction using a non-directional force sensor, characterized in that, The method includes: The real-time force signal sequence generated when the target mechanical device performs contact operation is collected, and the real-time force signal sequence includes multi-dimensional force amplitude data output by a non-directional force sensor; The real-time force signal sequence is input into a pre-trained force trend prediction model to obtain the force direction trend prediction result output by the force trend prediction model. Specifically, this includes: performing sliding window segmentation on the real-time force signal sequence to generate input data pairs containing historical force signal subsequences and current force signal subsequences; inputting the historical force signal subsequences into the temporal coding layer of the force trend prediction model to extract temporal correlation features corresponding to the historical force signal subsequences, the temporal correlation features including force amplitude fluctuation patterns under different time dimensions; and inputting the current force signal subsequence into the dynamic weight allocation layer of the force trend prediction model, based on the current force signal... The rate of change of force amplitude at each time point in the sequence is used to generate a weighted allocation vector corresponding to the temporal correlation feature. Through the feature fusion layer of the force trend prediction model, the temporal correlation feature and the weighted allocation vector are multiplied by a dot product to generate a dynamically weighted temporal feature. This dynamically weighted temporal feature is then input into the trend prediction layer of the force trend prediction model, which outputs the predicted multidimensional force amplitude at each time point within a future preset time window. Based on the vector change direction of the predicted multidimensional force amplitude, a force direction trend prediction result is generated. This force direction trend prediction result is used to characterize the vector distribution features of the multidimensional force amplitude changes within the future preset time window. Based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters, a multi-dimensional force compensation signal is generated. The multi-dimensional force compensation signal is used to correct the direction deviation component in the current closed-loop control parameters. Based on the multidimensional force compensation signal, the proportional-integral-derivative coefficients in the current closed-loop control parameters are adjusted to generate updated closed-loop control parameters, and the updated closed-loop control parameters are input into the actuator of the target mechanical device. The actuator dynamically adjusts the contact operation trajectory of the target mechanical device according to the updated closed-loop control parameters, so that the multi-dimensional force amplitude data output by the non-directional force sensor converges to the preset force control target range.

2. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 1, characterized in that, The step of generating a multidimensional force compensation signal based on the matching degree between the force direction trend prediction result and the current closed-loop control parameters includes: Obtain the proportional coefficient vector, integral coefficient vector, and derivative coefficient vector in the current closed-loop control parameters, and normalize the proportional coefficient vector, integral coefficient vector, and derivative coefficient vector to generate a closed-loop control parameter feature matrix. The similarity between the vector distribution characteristics corresponding to the force direction trend prediction result and the closed-loop control parameter feature matrix is ​​calculated to generate a direction deviation feature vector. The directional deviation feature vector is input into the fully connected layer of a preset compensation signal generation network to extract the preset oscillation component and preset offset component from the directional deviation feature vector. The preset oscillation component and the preset offset component are fused across channels by the convolutional kernel group of the compensation signal generation network to generate a preliminary compensation signal. The preliminary compensation signal is input into the activation function layer of the compensation signal generation network for nonlinear transformation to generate the multidimensional force compensation signal, wherein the output range of the activation function layer matches the adjustable range of the closed-loop control parameters.

3. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 2, characterized in that, The step of using the convolutional kernel group of the compensation signal generation network to perform cross-channel fusion of the preset oscillation component and the preset offset component to generate a preliminary compensation signal includes: The preset oscillation component and the preset offset component are respectively split into multiple parallel processing channels along the channel dimension to generate a preset oscillation component sub-channel group and a preset offset component sub-channel group. The convolution kernel group is decomposed into a first sub-convolution kernel set corresponding to the preset oscillation component sub-channel group, and a second sub-convolution kernel set corresponding to the preset offset component sub-channel group; Multi-scale convolution operation is performed on the preset oscillation component sub-channel group by the first sub-convolution kernel set to extract the time-domain response features corresponding to different frequency fluctuation modes in the preset oscillation component sub-channel group and generate an oscillation fusion feature map. The preset offset component sub-channel group is subjected to long-period convolution operation by the second sub-convolution kernel set to extract the cumulative effect features corresponding to the trend offset in the preset offset component sub-channel group and generate an offset fusion feature map. The oscillation fusion feature map and the offset fusion feature map are spliced ​​along the spatial dimension to generate a cross-channel fusion feature tensor. The residual connection layer of the compensation signal generation network is used to perform cross-layer feature enhancement on the cross-channel fusion feature tensor to generate enhanced fusion features; The enhanced fusion features are input into the depthwise separable convolutional layer of the compensation signal generation network for feature dimensionality reduction, generating a dimensionality-reduced fusion feature vector; The amplitude of the fused feature vector after dimensionality reduction is constrained and the phase is aligned by a nonlinear mapping function to generate a preliminary compensation signal that matches the dimension of the feature matrix of the closed-loop control parameters.

4. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 2, characterized in that, The adjustment of the proportional-integral-derivative coefficients in the current closed-loop control parameters based on the multidimensional force compensation signal includes: The multidimensional force compensation signal is decomposed into proportional compensation term, integral compensation term and differential compensation term, and then superimposed with the proportional coefficient vector, integral coefficient vector and differential coefficient vector in the current closed-loop control parameters, respectively. Gradient constraint processing is applied to the superimposed scaling factor vector to ensure that the magnitude of the adjusted scaling factor vector does not exceed the preset maximum scaling gain threshold. The superimposed integral coefficient vector is subjected to integral saturation suppression processing, and the integral accumulation rate is limited by dynamically adjusting the integral time constant. The superimposed differential coefficient vector is subjected to noise filtering, and the moving average algorithm is used to eliminate the influence of noise on the differential term. The processed proportional coefficient vector, integral coefficient vector, and derivative coefficient vector are concatenated to generate the updated closed-loop control parameters.

5. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 4, characterized in that, The step of dynamically adjusting the contact trajectory of the target mechanical device by the actuator based on the updated closed-loop control parameters, so that the multi-dimensional force amplitude data output by the non-directional force sensor converges to the preset force control target range, includes: Based on the proportional coefficient vector in the updated closed-loop control parameters, calculate the real-time position deviation vector between the current contact position and the desired contact position of the actuator; Based on the integral coefficient vector in the updated closed-loop control parameters, a weighted integral operation is performed on the historical cumulative value of the real-time position deviation vector within a continuous time window to generate an integral correction vector. Based on the differential coefficient vector in the updated closed-loop control parameters, a sliding window differential operation is performed on the rate of change of the real-time position deviation vector in adjacent sampling periods to generate a differential suppression vector. The real-time position deviation vector, integral correction vector, and differential suppression vector are superimposed to generate a trajectory adjustment command, which is then converted into a drive signal for the actuator to drive the joint motor of the target mechanical device to perform the corresponding angle adjustment or displacement adjustment. The system monitors in real time whether the multidimensional force amplitude data output by the non-directional force sensor enters the force control target range. If it does not enter, the system dynamically adjusts the gain weight of the proportional-integral-derivative coefficients in the updated closed-loop control parameters based on the boundary distance between the multidimensional force amplitude data and the force control target range, thereby generating secondary corrected closed-loop control parameters. The secondary correction closed-loop control parameters are input into the actuator to trigger the compensation adjustment of the contact operation trajectory of the target mechanical device until the multidimensional force amplitude data is stable and continuous within the force control target range for a preset duration.

6. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 1, characterized in that, The training process of the pre-trained force trend prediction model includes: Collect historical force signal sequences and corresponding actual force direction change data of multiple sets of mechanical devices under various contact operation conditions, and construct a training dataset; The historical force signal sequence is time-aligned and noise-filtered to generate standardized force signal samples; The standardized force signal sample is input into the initial force trend prediction model to obtain the predicted force direction trend result output by the initial force trend prediction model. Calculate the trend error loss between the predicted force direction trend result and the actual force direction change data, and calculate the closed-loop control error loss of the predicted force direction trend result in the closed-loop control simulation environment; The trend error loss and closed-loop control error loss are combined to generate a total training loss value, and the parameters of the initial force trend prediction model are updated through the backpropagation algorithm until the total training loss value converges.

7. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 6, characterized in that, The calculation of the closed-loop control error loss in the closed-loop control simulation environment based on the predicted force direction trend result includes: The predicted force direction trend result is input into a preset closed-loop control parameter response simulator to generate simulated force control trajectory data containing multi-dimensional force adjustment instructions; Extract real force control trajectory data synchronized with actual force direction change data from the training dataset. The real force control trajectory data includes a time series of multi-dimensional force amplitude and the corresponding contact trajectory change vector. The simulated force control trajectory data and the real force control trajectory data are windowed and aligned according to the time dimension, and the instantaneous fluctuation difference and cumulative trend deviation of the multidimensional force amplitude within each alignment window are extracted. The dynamic tracking error of force amplitude in each dimension is calculated by the instantaneous fluctuation difference, and the steady-state offset of force amplitude in each dimension is calculated by the cumulative trend deviation. The dynamic tracking error and the steady-state offset are linearly superimposed according to a preset ratio to generate a closed-loop control error loss that characterizes the direction prediction accuracy and control stability.

8. The non-directional force sensor closed-loop control method based on real-time force trend prediction according to claim 6, characterized in that, The step of performing time alignment and noise filtering on the historical force signal sequence to generate standardized force signal samples includes: Baseline drift correction is performed on the historical force signal sequence to eliminate preset interference components caused by sensor zero-point offset; Sliding window variance analysis was performed on the corrected historical force signal sequence to identify anomalous noise segments with sudden changes in force amplitude within the window. An adaptive filtering algorithm is used to locally smooth the abnormal noise segment, while preserving the dynamic characteristics of the non-noise segment in the original signal; The smoothed historical force signal sequence is resampled with timestamps so that the sampling interval is consistent with the recording frequency of the actual force direction change data. The resampled historical force signal sequence is normalized by dimension to ensure that the force amplitudes in each dimension are aligned in time under the same scale, thereby generating the standardized force signal sample.

9. A computer system, characterized in that, include: A memory, wherein a computer program is stored; A processor is configured to load the computer program to implement the non-directional force sensor closed-loop control method based on real-time force trend prediction as described in any one of claims 1-8.

Citation Information

Patent Citations

  • Robot dexterous hand micro-force control method and system for precise assembly

    CN120269571A