Data-driven robot control method and device, electronic equipment, computer readable storage medium and computer program product
By constructing a data-driven robot control strategy and simplifying the dynamic model using historical input-output sequences, the six-dimensional force on the sole of the foot can be directly determined. This solves the problems of large computational load and poor adaptability caused by relying on precise dynamic models in existing technologies, and achieves efficient robot control.
Patent Information
- Application Number
- CN202411749482.0
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-11-29
- Publication Date
- 2026-01-02
- Estimated Expiration
- 2044-11-29
AI Technical Summary
Existing technologies rely on precise dynamic models for robot control, which leads to poor control performance in complex environments, high computational costs, difficulty in adapting to uncertainties, and complex system design and implementation.
By acquiring the robot's historical input-output sequence, a data-driven control strategy is constructed. By utilizing the mapping relationship between historical six-dimensional forces and movement trajectories, the dynamic model is simplified, the computational burden is reduced, and the six-dimensional forces on the sole of the foot are directly determined to achieve target movement.
Robot control can be achieved without complex dynamic models, reducing computational load, improving control efficiency, adapting to complex environments, and simplifying system design.
Smart Images

Figure CN119772878B_ABST
Abstract
Description
TECHNICAL FIELD
[0001] The present application relates to the field of robot control, and in particular to a robot control method and device based on data driving, an electronic device, a computer readable storage medium and a computer program product. BACKGROUND
[0002] The related art builds a dynamic model of a humanoid robot through a model predictive control (MPC) method, and successfully realizes force control standing and gait of the robot when carrying a load. However, this control method is highly dependent on the accuracy of the dynamic model, and the inaccuracy or simplification of the model will affect the control performance, and further cause the robot to fail to achieve the expected effect in actual operation. Moreover, the dynamic model is complex and difficult to accurately describe, especially in actual application, the interaction between the robot and the environment will introduce many uncertain factors and nonlinear phenomena, which will increase the difficulty of building the dynamic model and greatly increase the computational load of the system. SUMMARY
[0003] The embodiments of the present application provide a robot control method and device based on data driving, an electronic device, a computer readable storage medium and a computer program product, which can simplify system design and implementation process, and reduce the implementation difficulty and computational burden of the model predictive control method.
[0004] The technical solutions of the embodiments of the present application are implemented as follows:
[0005] The embodiments of the present application provide a robot control method based on data driving, comprising:
[0006] Obtaining a historical input-output sequence of a robot, wherein the historical input data included in the historical input-output sequence is a historical six-dimensional force applied to the sole of the robot, and the historical output data is a historical movement trajectory of the robot;
[0007] Building a control strategy for the robot based on the historical input-output sequence, wherein the control strategy is used to represent the mapping relationship between the six-dimensional force applied to the sole of the robot and the movement trajectory of the robot;
[0008] Obtaining a target movement trajectory set for the robot;
[0009] Determining the six-dimensional force currently required to be applied to the sole of the robot based on the target movement trajectory and the control strategy.
[0010] The embodiments of the present application provide a robot control device based on data driving, comprising:
[0011] The acquisition module is configured to acquire a historical input-output sequence of the robot, wherein the historical input-output sequence comprises historical input data of historical six-dimensional forces applied to the sole of the robot and historical output data of a historical movement trajectory of the robot.
[0012] The construction module is configured to construct a control strategy for the robot based on the historical input-output sequence, wherein the control strategy is used to represent a mapping relationship between the six-dimensional forces applied to the sole of the robot and the movement trajectory of the robot.
[0013] The acquisition module is further configured to acquire a target movement trajectory set for the robot.
[0014] The determination module is configured to determine, based on the target movement trajectory and the control strategy, a six-dimensional force currently required to be applied to the sole of the robot.
[0015] In the above scheme, the acquisition module is further configured to acquire historical torques applied to leg motors of the robot when the robot is in a standing state; convert a plurality of the historical torques into historical six-dimensional forces applied to the sole of the robot by a virtual force principle; acquire a historical movement trajectory of the robot corresponding to the historical six-dimensional forces; and construct a historical input-output sequence of the robot based on the historical six-dimensional forces and the historical movement trajectory.
[0016] In the above scheme, the construction module is further configured to determine a sequence length of the historical input-output sequence; create a zero matrix based on the sequence length, wherein the number of rows and the number of columns of the zero matrix are less than or equal to half of the sequence length; fill elements included in the historical input-output sequence into the zero matrix to obtain a Hankel matrix, wherein each of the elements comprises a historical six-dimensional force and a historical movement trajectory corresponding to the historical six-dimensional force; and construct a control strategy for the robot based on the Hankel matrix.
[0017] In the above scheme, the construction module is further configured to construct an initial model predictive controller for the robot based on the Hankel matrix; determine a predicted time cost at each time point in a prediction interval corresponding to the historical input-output sequence based on the initial model predictive controller; add the predicted time costs corresponding to a plurality of the time points respectively, and take the addition result as a cost function; and construct a control strategy for the robot based on the cost function.
[0018] In the scheme, the constructing module is further configured to use the cost function as a first control condition; update parameters of the initialized model predictive controller based on the first control condition to obtain an updated model predictive controller; and use the updated model predictive controller as the control strategy for the robot.
[0019] In the scheme, the constructing module is further configured to obtain a terminal constraint condition set for the robot; and construct the control strategy for the robot based on the terminal constraint condition and the cost function.
[0020] In the scheme, the constructing module is further configured to combine the terminal constraint condition and the cost function to obtain a second control condition; update parameters of the initialized model predictive controller based on the second control condition to obtain an updated model predictive controller; and use the updated model predictive controller as the control strategy for the robot.
[0021] In the scheme, the apparatus further includes an updating module configured to add a six-dimensional force currently applied to a foot of the robot and the target movement trajectory to the historical input-output sequence to obtain an updated historical input-output sequence; and update the control strategy based on the updated historical input-output sequence.
[0022] In the scheme, the apparatus further includes an adjusting module configured to adjust a center of mass position of the robot when the robot moves to a posture that does not satisfy the zero moment point constraint, so that the robot returns to a posture that satisfies the zero moment point constraint.
[0023] An electronic device is provided in an embodiment of the present application, and the electronic device includes:
[0024] A memory is configured to store computer executable instructions or computer programs.
[0025] A processor is configured to execute the computer executable instructions or computer programs stored in the memory, so as to implement a robot control method based on data driving provided in an embodiment of the present application.
[0026] A computer readable storage medium is provided in an embodiment of the present application, and the computer readable storage medium stores computer programs or computer executable instructions, which are configured to be executed by a processor, so as to implement a robot control method based on data driving provided in an embodiment of the present application.
[0027] A computer program product is provided in an embodiment of the present application, and the computer program product includes computer programs or computer executable instructions, which are configured to be executed by a processor, so as to implement a robot control method based on data driving provided in an embodiment of the present application.
[0028] The embodiments of the present application have the following beneficial effects:
[0029] By acquiring a historical input-output sequence of the robot, wherein the historical input data included in the historical input-output sequence is historical six-dimensional force applied to the sole of the robot, and the historical output data is the historical movement trajectory of the robot, and determining a control strategy for the robot according to the historical input-output sequence, wherein the control strategy is used to represent the mapping relationship between the six-dimensional force applied to the sole of the robot and the movement trajectory of the robot, in this way, without creating a complex dynamic model, only the historical input and output data of the robot are used to determine the control strategy, without understanding the complex internal system of the robot, the system design and implementation process is simplified, the implementation difficulty and the calculation burden of the model predictive control method are effectively reduced; then, the control strategy is used to predict the six-dimensional force currently required to be applied to the sole of the robot according to the set target movement trajectory, without complex dynamic conversion, the input control of the robot can be obtained, the calculation amount of the system is greatly reduced, the occupation of the calculation resource is further reduced, and the control efficiency of the robot is improved. BRIEF DESCRIPTION OF DRAWINGS
[0030] Figure 1 is an architecture schematic diagram of a robot control system 100 based on data driving provided by the embodiments of the present application;
[0031] Figure 2 is a structure schematic diagram of an electronic device 500 provided by the embodiments of the present application;
[0032] Figure 3 is a flow schematic diagram of a robot control method based on data driving provided by the embodiments of the present application;
[0033] Figure 4 is a flow schematic diagram of a robot control method based on data driving provided by the embodiments of the present application;
[0034] Figure 5 is a structure schematic diagram of a humanoid robot provided by the embodiments of the present application;
[0035] Figure 6 is a structure schematic diagram of a robot force control standing system provided by the embodiments of the present application;
[0036] Figure 7 is a framework schematic diagram of a robot control method based on data driving provided by the embodiments of the present application. DETAILED DESCRIPTION
[0037] In order to make the purposes, technical solutions and advantages of the present application clearer, the following further describes the present application with reference to the accompanying drawings, the described embodiments should not be regarded as limitations to the present application, all other embodiments obtained by those skilled in the art without creative work fall within the scope of protection of the present application.
[0038] In the following description, "some embodiments" are referred to, which describe a subset of all possible embodiments, but it can be understood that "some embodiments" can be the same subset or different subsets of all possible embodiments, and can be combined with each other without conflict.
[0039] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program with a predetermined function, and works together with other related parts to achieve a predetermined target, and can be implemented entirely or partially by using software, hardware (such as a processing circuit or a memory) or a combination thereof. Similarly, one processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be a part of an integral module or unit that includes the functions of the module or unit.
[0040] In the following description, the term "first\second\..." referred to is only to distinguish similar objects, and does not represent a specific order of the objects. It can be understood that "first\second\..." can be interchanged in a specific order or sequence as allowed, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.
[0041] Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which the present application belongs. The terms used herein are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.
[0042] Before the embodiments of the present application are further described in detail, the terms and phrases involved in the embodiments of the present application are explained, and the terms and phrases involved in the embodiments of the present application are applicable to the following explanations.
[0043] 1) Model predictive control (MPC) method: predictive control method is an advanced process control strategy, which predicts the behavior of the system in the future through a mathematical model, and solves an optimization problem to determine the current control input to achieve the desired control target. The advantage of MPC is that it can handle complex systems with multiple variables, nonlinear, time-varying and constraints.
[0044] 2) Data-Driven Model Predictive Control (DDMPC): Data-Driven Model Predictive Control is a data-based control method that does not rely on traditional physical models, but instead learns control strategies directly from data. In traditional MPC, the design of the controller often requires an accurate system model, while Data-Driven MPC analyzes historical data to predict the future behavior of the system and develop control strategies accordingly. Through Data-Driven MPC, more flexible, adaptive and robust control system design can be achieved, especially in areas where traditional models are difficult to establish or the environment changes frequently.
[0045] (3) Zero Moment Point (ZMP): Zero Moment Point constraint refers to the total moment applied at a certain reference point (usually the joint center or foot center) of the robot or foot, which is zero. This means that after considering all the moments applied at the reference point, the rotational motion of the point is limited and will not produce additional rotation. By applying the Zero Moment Point constraint, the operational performance and safety of the robot in complex environments can be improved.
[0046] (4) Friction Cone Constraint: Friction Cone Constraint refers to the restriction of the movement of the robot foot when it contacts the ground due to the action of friction. This constraint is usually used to simulate and analyze the dynamics of the robot when walking or crawling, especially in biped or quadruped robots. The friction cone constraint reflects the relationship between friction and the direction of foot movement, ensuring that the robot does not exceed the maximum grip provided by friction when in contact with the ground.
[0047] (5) Hankel Matrix: Hankel Matrix is a special matrix characterized by the fact that each row has the same element as the previous row. This matrix has wide applications in signal processing, system identification and control systems.
[0048] (6) Cost Function: In the field of mathematical optimization and machine learning, the cost function is also used to measure the difference between the model prediction and the true value, in order to minimize this difference by adjusting the model parameters.
[0049] (7) Six-Directional Force: Six-Directional Force refers to the force an object receives in six different directions in three-dimensional space. These six directions usually include three orthogonal spatial directions (X, Y, Z axes) and their corresponding three rotational directions (rotation around X, Y, Z axes). Six-Directional Force is often used to describe the force and torque received by the end effector of a robot or robotic arm, and their impact on the movement of the robot.
[0050] (8) Virtual force principle: the virtual force principle, also known as the virtual work principle, is a principle that the sum of virtual work done by all forces in a system is zero under the assumption that the motion of the system is subject to certain ideal constraints. That is, when a system is subject to certain constraints, the components in the system cannot move freely, but can only move within the range allowed by the constraints. If a virtual displacement, i.e., an imaginary displacement that does not actually occur, is assumed to occur at a certain instant, then according to the virtual force principle, the sum of virtual work done by all forces in the system on this virtual displacement must be zero.
[0051] The model predictive control method in the related art has the following problems:
[0052] (1) The traditional control method usually relies on an accurate dynamic model to achieve control, and the inaccuracy or simplification of the model will affect the control performance, thereby causing the robot to fail to achieve the expected effect in actual operation, and the dynamic model is complex and difficult to accurately describe;
[0053] (2) The traditional control method is difficult to adapt to uncertain environmental changes, such as external force disturbance, bumping, etc., and the adaptability and robustness of the system are poor;
[0054] (3) The traditional control method usually needs to perform complex state estimation and feedback links, and the system design and implementation process is complex, which increases the implementation difficulty and computational burden.
[0055] In view of this, the embodiments of the present application provide a robot control method, device, electronic device, computer readable storage medium and computer program product based on data driving, which can simplify the system design and implementation process, and reduce the implementation difficulty and computational burden of the model predictive control method. The electronic device provided by the embodiments of the present application can be implemented as a server, or cooperatively implemented by a server and a terminal. The following will take the robot control method based on data driving cooperatively implemented by the server and the terminal as an example for description.
[0056] For example, referring to Figure 1 , Figure 1 is an architecture schematic diagram of the robot control system 100 based on data driving provided by the embodiments of the present application, for implementing a robot control application based on data driving, such as Figure 1 As shown in the figure, the robot control system 100 based on data driving includes a server 200, a network 300, a terminal 400 (for example, various types of robots), and the terminal 400 is connected to the server 200 through the network 300, wherein the network 300 can be a local area network or a wide area network, or a combination of the two.
[0057] In some embodiments, taking a biped robot as an example of the terminal 400, the biped robot can obtain a historical input-output sequence through its own sensors, where the historical input-output sequence includes historical input data of historical six-dimensional forces applied to the soles of the biped robot and historical output data of historical movement trajectories of the biped robot, and transmit the obtained historical input-output sequence to the server 200 through the network 300. Then, the server 200 can construct a control strategy for the biped robot based on the historical input-output sequence, where the control strategy is used to represent a mapping relationship between the six-dimensional forces applied to the soles of the robot and the movement trajectories of the robot. Subsequently, the server 200 obtains a target movement trajectory set by a user for the biped robot. Finally, the server 200 determines the six-dimensional forces currently required to be applied to the soles of the biped robot based on the target movement trajectory and the control strategy, and returns the six-dimensional forces currently required to be applied to the biped robot through the network 300, thereby realizing force-controlled standing control of the biped robot, for example, the biped robot can move according to the pre-set target movement trajectory.
[0058] Of course, the above process can also be implemented by the terminal 400 alone, for example, the terminal 400 can construct a control strategy for the robot based on its own computing power, so as to determine the six-dimensional forces currently required to be applied to the soles of the robot based on the control strategy and the target movement trajectory set for the robot, thereby realizing force-controlled standing control of the robot, for example, the robot can be controlled to move according to the pre-set target movement trajectory, which is not limited in the embodiments of the present application.
[0059] It should be noted that the technical solutions provided by the present application can be applied to various scenarios, such as biped robot walking, human-robot interaction, industrial robot operation, and other robot force-controlled standing control scenarios.
[0060] In some embodiments, taking a biped robot walking scenario as an example, first, the biped robot obtains a historical input-output sequence collected during walking, where the historical input-output sequence includes historical input data of historical six-dimensional forces applied to the soles of the robot and historical output data of historical movement trajectories of the robot. Then, a control strategy for the robot is constructed based on the historical input-output sequence, where the control strategy is used to represent a mapping relationship between the six-dimensional forces applied to the soles of the robot and the movement trajectories of the robot. Subsequently, a target movement trajectory set for the robot is also obtained. Finally, based on the target movement trajectory and the control strategy, the six-dimensional forces currently required to be applied to the soles of the robot are determined to control the robot to move according to the target movement trajectory.
[0061] In some embodiments, taking a humanoid robot interaction scenario as an example, firstly, the humanoid robot acquires historical input-output sequences collected while standing and interacting with humans. The historical input-output sequences include historical input data (historical six-dimensional forces applied to the robot's feet) and historical output data (the robot's historical movement trajectory). Next, a control strategy for the robot is constructed based on the historical input-output sequences. This control strategy characterizes the mapping relationship between the six-dimensional forces applied to the robot's feet and the robot's movement trajectory. Subsequently, a target movement trajectory is acquired for the robot. Finally, based on the target movement trajectory and the control strategy, the required six-dimensional force to be applied to the robot's feet is determined, enabling the humanoid robot to move according to the pre-set target movement trajectory.
[0062] In other embodiments, the embodiments of this application can also be implemented with the aid of cloud technology, which refers to a hosting technology that unifies a series of resources such as hardware, software, and networks within a wide area network or local area network to realize the computation, storage, processing, and sharing of data.
[0063] Cloud technology is a general term encompassing network technology, information technology, integration technology, management platform technology, and application technology based on the cloud computing business model. It can form resource pools, allowing for on-demand use with flexibility and convenience. Cloud computing technology will become a crucial support. The backend services of cloud computing systems require substantial computing and storage resources.
[0064] Example, Figure 1 The server 200 can be a standalone physical server, a server cluster or distributed system composed of multiple physical servers, or a cloud server providing basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communication, middleware services, domain name services, security services, content delivery networks (CDNs), and big data and artificial intelligence platforms. The terminal 400 can be various types of robots (e.g., humanoid robots, bipedal robots, agricultural robots, etc.), but is not limited to these. The terminal 400 and the server 200 can be directly or indirectly connected via wired or wireless communication, which is not limited in this embodiment.
[0065] The structure of the electronic device provided in the embodiments of this application will be described below. Taking the electronic device as a server as an example, see... Figure 2 , Figure 2 This is a schematic diagram of the structure of the electronic device 500 provided in the embodiments of this application. Figure 2The electronic device 500 shown includes at least one processor 510, a memory 540, at least one network interface 520. The various components in the electronic device 500 are coupled together by a bus system 530. It can be understood that the bus system 530 is used for realizing the connection communication between these components. In addition to including a data bus, the bus system 530 also includes a power supply bus, a control bus, and a status signal bus. However, for the sake of clarity, all the various buses are marked as the bus system 530 in the Figure 2
[0066] The processor 510 can be an integrated circuit chip having a processing capability of signals, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gates or transistor logic devices, discrete hardware components, etc., wherein the general-purpose processor can be a microprocessor or any conventional processor.
[0067] The memory 540 can be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memories, hard disk drives, optical disk drives, etc. The memory 540 can optionally include one or more storage devices that are physically located away from the processor 510.
[0068] The memory 540 includes volatile memory or non-volatile memory, and can also include both volatile and non-volatile memory. The non-volatile memory can be read-only memory (ROM), and the volatile memory can be random access memory (RAM). The memory 540 described in the embodiments of the present application is intended to include any suitable type of memory.
[0069] In some embodiments, the memory 540 is capable of storing data to support various operations, examples of which include programs, modules, and data structures or subsets or supersets thereof, which are exemplarily illustrated below.
[0070] The operating system 541 includes system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;
[0071] The network communication module 542 is used to reach other computing devices via one or more (wired or wireless) network interfaces 520, and exemplary network interfaces 520 include Bluetooth, wireless compatibility certification (WiFi), and universal serial bus (USB), etc.
[0072] In some embodiments, the device provided by the embodiments of the present application can be implemented in software, Figure 2 The data-driven robot control device 543 stored in the memory 540 is shown, which can be software in the form of programs and plug-ins, etc., including the following software modules: an acquisition module 5431, a construction module 5432, a determination module 5433, an update module 5434, and an adjustment module 5435, which are logical and thus can be combined or further split according to the implemented functions. It should be noted that, in order to facilitate expression, all the above modules are shown at once, but it should not be considered that the point cloud data processing device 543 excludes an implementation that only includes the acquisition module 5431, the construction module 5432, and the determination module 5433. The functions of the modules will be described below. Figure 2
[0073] The data-driven robot control method provided by the embodiments of the present application will be described in detail below in combination with exemplary applications and implementations of the terminal device provided by the embodiments of the present application.
[0074] Referring to Figure 3 , Figure 3 is a flowchart of the data-driven robot control method provided by the embodiments of the present application, which will be described in combination with the steps shown in Figure 3 .
[0075] In step 101, a historical input-output sequence of a robot is acquired.
[0076] Here, the historical input data included in the historical input-output sequence is historical six-dimensional force applied to the sole of the robot, and the historical output data is a historical moving trajectory of the robot.
[0077] In some embodiments, the step 101 described above can be implemented in the following manner: acquiring historical torques applied to the leg motors of the robot when the robot is in a standing state; converting a plurality of historical torques into historical six-dimensional force applied to the sole of the robot through the principle of virtual force; acquiring a historical moving trajectory of the robot corresponding to the historical six-dimensional force; and constructing a historical input-output sequence of the robot based on the historical six-dimensional force and the historical moving trajectory.
[0078] Here, each leg motor of the robot is equipped with a sensor capable of measuring torque, which can be a torque sensor directly built into the motor or an independent external torque sensor.
[0079] In some embodiments, first, develop or use ready-made data acquisition software, set appropriate sampling frequency, ensure that enough detailed data can be captured, and to ensure that the software can continuously record data during the robot standing, if necessary, the data of multiple sensors can be synchronized; then, before data acquisition, calibrate the torque sensor to ensure the accuracy of the data, and preliminarily test the acquisition system to verify the reliability and data quality of the data acquisition system; then, start the robot, use the control algorithm to execute the robot to stand, when the robot enters the standing state and stabilizes, start recording the torque data applied by the leg motor, and continuously collect the torque data during the robot standing, real-time monitor the collected torque data, ensure that the data is within the expected range, and there is no abnormal value, when the predetermined standing time is completed or other end conditions are reached, stop data acquisition; subsequently, store the collected torque data in a file or database for subsequent analysis and processing.
[0080] In some embodiments, after obtaining the historical torque applied by the leg motor of the robot, the dynamics of the robot can be modeled, including the connection relationship between each leg motor and the center of mass of the robot, and the influence of each motor torque on the overall motion of the robot; then, establish the robot foot coordinate system and the robot center of mass coordinate system, and clarify the coordinate transformation relationship between the two; then, analyze the torque applied by each leg motor, decompose it into force along the motor axis and torque around the motor axis, and map the force applied by each motor to the center of mass coordinate system of the robot through coordinate transformation; subsequently, according to the position and torque applied by each leg motor of the robot, calculate the total torque of the robot center of mass; then, through the virtual force principle, that is, under the assumption of virtual constraint, the resultant external force on the robot center of mass is equal to zero, to solve the reaction force on the foot; finally, convert the torque data at each time according to the above process, accumulate the force and torque applied by all motors, and obtain the historical six-dimensional force (including three-direction force and three-direction torque) applied by the robot foot at the corresponding time.
[0081] In some embodiments, after determining the historical six-dimensional force applied by the robot's foot, the data acquisition system can be started when the robot starts moving and applying the six-dimensional force, and the six-dimensional force and the robot's position and attitude data at each time point are recorded synchronously; then, the robot's historical movement trajectory is calculated according to the robot's position and attitude data, where the robot's displacement and speed can be calculated according to the encoder data, or the robot's acceleration and attitude change can be calculated using the IMU data, or the robot's historical movement trajectory can be calculated by integration combined with the initial position and attitude; subsequently, the processed historical movement trajectory data is associated with the six-dimensional force data at the corresponding time point to form a complete historical six-dimensional force-historical movement trajectory correspondence; finally, the processed historical movement trajectory data is stored in a file or a database for subsequent analysis and processing.
[0082] In some embodiments, after determining the input variable (i.e., the historical six-dimensional force) and the output variable (i.e., the historical movement trajectory), each historical six-dimensional force can be matched with the corresponding historical movement trajectory in time according to the obtained historical six-dimensional force-historical movement trajectory correspondence, where matching refers to matching the historical six-dimensional force as the input variable at the same time with the historical movement trajectory as the output variable at the same time; subsequently, the matched historical six-dimensional force and historical movement trajectory are combined into a sequence to form the robot's historical input-output sequence; finally, to ensure the accuracy of the later model training, the input-output sequence is normalized.
[0083] In step 102, a control strategy for the robot is constructed based on the historical input-output sequence.
[0084] Here, the control strategy can be used to represent the mapping relationship between the six-dimensional force applied by the robot's foot and the robot's movement trajectory.
[0085] In some embodiments, firstly, an appropriate initialization model predictive controller (MPC) (linear or nonlinear, depending on the robot's dynamic characteristics) is selected based on the robot's characteristics and control requirements; then, the robot's dynamic model is determined using historical input-output sequences through system identification techniques (e.g., least squares, maximum likelihood estimation, or machine learning); subsequently, model parameters (e.g., system matrix) are estimated from historical data based on the identified dynamic model; then, based on the identified MPC, control objectives (e.g., minimizing tracking error, maximizing efficiency), constraints (e.g., input and output limits), and performance metrics (e.g., cost function) are determined; finally, the parameters of the MPC are determined based on cost function weights, the prediction time domain, the control time domain, and constraint limits. In other words, the embodiments of this application can determine the mapping relationship between the six-dimensional force applied to the robot's feet and the robot's movement trajectory based on the historical input-output sequence. That is, a control strategy (i.e., the updated MPC) for the robot is constructed based on the historical input-output sequence. Thus, after obtaining the target movement trajectory set for the robot, the six-dimensional force that needs to be applied to the robot's feet can be deduced based on the above mapping relationship, thereby enabling the robot to move according to the preset target movement trajectory.
[0086] In some embodiments, step 102 described above can also be implemented by: determining the sequence length of the historical input-output sequence; creating a zero matrix based on the sequence length, wherein the number of rows and columns of the zero matrix is less than or equal to half the sequence length; filling the zero matrix with the elements included in the historical input-output sequence to obtain a Hankel matrix, wherein each element includes a historical six-dimensional force and a historical movement trajectory corresponding to the historical six-dimensional force; and constructing a control strategy for the robot based on the Hankel matrix.
[0087] For example, suppose there exists a robot whose historical input is a sequence of applied six-dimensional forces u = [u1, u2, ..., u...]. n The historical output is the robot's movement trajectory sequence y = [y1, y2, ..., y]. n The corresponding historical input-output sequence {u,y} = {(u1,y1),(u2,y2),…,(u...} n ,y n )}, where n is the length of the historical input-output sequence {u,y}; then, a zero matrix is created based on the sequence length n, where the number of rows (row) and columns (col) of the zero matrix are both less than or equal to half the sequence length. Next, the elements of the historical input-output sequence are filled into the zero matrix to obtain the Hankel matrix H (as shown in formula (1)), where each element includes a historical six-dimensional force u. ia historical moving trajectory y corresponding to a historical six-dimensional force i , the element in the i-th row and j-th column of the zero matrix is the i+j-1-th element in the historical input-output sequence {u, y}, i and j are both integer variables, and satisfy
[0088]
[0089] where n is the number of elements in the historical input-output sequence, r is the number of columns of the matrix, and c is the number of rows of the matrix.
[0090] Finally, a control strategy for the robot is constructed based on the Hankel matrix.
[0091] In some embodiments, the above-mentioned construction of a control strategy for the robot based on the Hankel matrix can also be implemented in the following way: an initialization model predictive controller for the robot is constructed based on the Hankel matrix; the predicted time cost at each time in the prediction interval corresponding to the historical input-output sequence is determined based on the initialization model predictive controller; the predicted time costs corresponding to multiple times are added respectively, and the addition result obtained is taken as a cost function; and a control strategy for the robot is constructed based on the cost function.
[0092] For example, assuming that there is a robot, the task is to track a predetermined path, and a historical input-output sequence of the robot is obtained, the input is a six-dimensional force sequence u = [u1, u2,..., u n ], and the output is a moving trajectory sequence y = [y1, y2,..., y n ] of the robot. The corresponding Hankel matrix H is generated based on the historical input-output sequence {u, y}, and each pair of input-output data corresponds to a timestamp t i . First, an initialization model predictive controller is constructed based on the input-output data in the Hankel matrix H, wherein the parameters in the initialization model predictive controller can be initial values set randomly or initial values set in advance; then, the historical input-output sequence is analyzed, and the predicted time cost at each time t is calculated; subsequently, the predicted time costs corresponding to multiple times are added respectively, the addition result is obtained, and the addition result is taken as a cost function; finally, a control strategy for the robot is constructed based on the obtained cost function.
[0093] In some embodiments, the above-mentioned construction of a control strategy for the robot based on the cost function can also be implemented in the following way: the cost function is taken as a first control condition; the parameters of the initialization model predictive controller are updated based on the first control condition to obtain an updated model predictive controller; and the updated model predictive controller is taken as the control strategy for the robot.
[0094] In an example, after obtaining the cost function, the cost function can be taken as the first control condition, where the first control condition refers to determining the control input sequence to minimize or maximize the cost function, which can be determined according to specific requirements, for example, the first control condition is to minimize the cost function, the processed cost function can be obtained by gradient descent method, and taken as the first control condition; then, according to the first control condition, the parameters of the initialized model predictive controller are updated to obtain an updated model predictive controller, where the corresponding control parameters can be extracted from the first control condition, and the control parameters are replaced with the parameters of the initialized model predictive controller to obtain the model predictive controller with updated parameters, and the obtained model predictive controller with updated parameters is taken as the control strategy for the robot.
[0095] In some embodiments, the above-mentioned construction of the control strategy for the robot based on the cost function can also be implemented by: obtaining the terminal constraint condition set for the robot; and constructing the control strategy for the robot based on the terminal constraint condition and the cost function.
[0096] In an example, assuming that there is a robot, according to the hardware or scene limit of the robot, the terminal constraint condition set for the robot is determined (for example, the torque of the leg motor should not exceed the maximum allowed value, friction cone constraint, etc.), then, according to the terminal constraint condition and the cost function, the control strategy for the robot is constructed, that is, when determining to minimize the cost function, the terminal constraint condition set for the robot also needs to be met, so as to construct the control strategy for the robot according to the terminal constraint condition and the cost function at the same time.
[0097] In some embodiments, the above-mentioned construction of the control strategy for the robot based on the terminal constraint condition and the cost function can also be implemented by: combining the terminal constraint condition and the cost function to obtain a second control condition; updating the initialized model predictive controller based on the second control condition to obtain an updated model predictive controller; and taking the updated model predictive controller as the control strategy for the robot.
[0098] For example, assuming that there is a robot, the robot needs to reach a target position accurately within a limited time. In order to ensure that the robot tracks the predetermined path while meeting the terminal constraint condition, first, a cost function of the current robot is constructed, and the terminal constraint condition and the cost function are combined to obtain a second control condition. Here, the second control condition can be that the input sequence is controlled first to minimize or maximize the cost function to obtain an optimized cost function, and the input sequence is controlled to minimize or maximize the terminal constraint condition to obtain an optimized terminal constraint condition, and then the optimized cost function and the optimized terminal constraint condition are combined to obtain the second control condition. The second control condition can also be that the cost function and the terminal constraint condition are combined to obtain a combination function, and then the input sequence is controlled to minimize or maximize the combination function to obtain the second control condition. The combination manner can be that the two functions are directly added, or the functions are combined, which is not limited herein. Then, the parameters of the initialized model predictive controller are updated according to the second control condition to obtain an updated model predictive controller. Here, the corresponding control parameters can be extracted from the second control condition, and the control parameters are replaced with the parameters of the initialized model predictive controller to obtain a model predictive controller with updated parameters, and the obtained model predictive controller with updated parameters is used as the control strategy for the robot.
[0099] It should be noted that the first control condition and the second control condition are used to distinguish different processing conditions, and the two conditions can be the same or different.
[0100] In step 103, a target movement trajectory set for the robot is obtained.
[0101] Here, the target movement trajectory can be determined by the robot based on the set planning path, or can be manually input by the user, which is not limited herein.
[0102] In some embodiments, the user can set an initial position and a target position for the target movement of the robot, and the robot plans a path according to the initial position and the target position to obtain the target movement trajectory. The user can also manually draw the target movement trajectory for the robot, so that the robot directly obtains the target movement trajectory.
[0103] In step 104, based on the target movement trajectory and the control strategy, a six-dimensional force currently required to be applied to the sole of the robot is determined.
[0104] In some embodiments, the step 104 described above can also be implemented in the following manner: the control strategy is called based on the target movement trajectory to make a prediction, and a six-dimensional force currently required to be applied to the sole of the robot is obtained.
[0105] For example, assuming that there is a robot, the target movement trajectory set for the robot is obtained, and the input data is predicted according to the target movement trajectory by calling the control strategy (i.e., the updated MPC), so as to obtain the six-dimensional force currently required to be applied to the sole of the robot. That is, after the target movement trajectory set for the robot is obtained, the six-dimensional force currently required to be applied to the sole of the robot when the robot needs to move according to the target movement trajectory can be deduced according to the mapping relationship between the six-dimensional force applied to the sole of the robot and the movement trajectory of the robot. Thus, after the corresponding six-dimensional force is applied to the sole of the robot, the robot can move according to the pre-set target movement trajectory.
[0106] For example, assuming that there is a robot, the target movement trajectory set for the robot is obtained, and the corresponding time t is determined according to the target movement trajectory. The input-output sequence at time t is predicted by calling the control strategy, and the deviation between the output data (predicted movement trajectory) in the input-output sequence and the target movement trajectory is calculated. When the deviation is less than the deviation threshold, the corresponding input data in the input-output sequence is determined as the control input of the robot at time t, that is, the six-dimensional force currently required to be applied to the sole of the robot is obtained. So that the robot can move according to the pre-set target movement trajectory.
[0107] In some embodiments, referring to Figure 4 , Figure 4 is a flowchart of the data-driven robot control method provided by the embodiments of the present application, as shown in Figure 4 After step 104 shown in Figure 3 is executed, steps 105 to 106 in Figure 4 may also be executed to achieve, which will be described in combination with the steps shown in Figure 4 .
[0108] In step 105, the six-dimensional force currently applied to the sole of the robot and the target movement trajectory are added to the historical input-output sequence to obtain an updated historical input-output sequence.
[0109] For example, after the six-dimensional force currently applied to the sole of the robot and the target movement trajectory are obtained, the six-dimensional force currently applied to the sole of the robot is added to the end of the historical input sequence, and the target movement trajectory is added to the end of the historical output sequence, so as to form a new historical input-output sequence, i.e., an updated historical input-output sequence.
[0110] In step 106, the control strategy is updated based on the updated historical input-output sequence.
[0111] Here, steps 102 to 104 are repeatedly performed based on the updated historical input-output sequence, so as to update the control policy. In this way, by updating the historical input-output sequence, more data can be provided for the control policy of the robot, so that the control policy dynamically adjusts the control policy according to real-time data, helps the control policy to better understand and predict the behavior of the robot, and enables the control policy to adapt to uncertain environmental changes, such as external force disturbance, collision, etc., thereby improving the adaptability and robustness of the system.
[0112] In some embodiments, when the robot moves to a posture that does not satisfy the zero-moment point constraint, the position of the center of mass of the robot is adjusted to make the robot return to a posture that satisfies the zero-moment point constraint. Thereby, the influence of extreme cases such as large torque applied by the neck motor of the robot or too large mass of the operating sphere on the stability of the robot is avoided.
[0113] In the following, an exemplary application of the embodiments of the present application in an actual application scenario will be described. The exemplary application describes the specific implementation process of the data-driven robot control method in the robot force control standing control scenario.
[0114] Referring to Figure 5 , Figure 5 is a structural schematic diagram of a humanoid robot provided by the embodiments of the present application. In the robot force control standing state, the torque of all the motors of the legs needs to be controlled, while the motors of the arms and the head are fixed in a certain initial position by position control. The motors on the two legs of the robot are arranged symmetrically, and the specific arrangement is in the order from the waist to the sole as follows: hip roll, hip yaw, hip pitch, knee pitch, ankle pitch, and ankle roll. Therefore, the actual control instruction actually applied to the robot is the torque of 12 joint motors.
[0115] Referring to Figure 6 , Figure 6 is a structural schematic diagram of a robot force control standing system provided by the embodiments of the present application. According to the principle of virtual force, the torque of the joint motors of the legs of the robot can be controlled to be equivalent to applying a six-dimensional force (including three-dimensional force and three-dimensional torque) to the sole of the robot. Then, the end six-dimensional force is converted to the joint space of the robot by inverse dynamics, and finally is issued to the joint motors.
[0116] F x , F y , F z respectively represent the three-dimensional force of the sole, M x , M y , M zrepresent the three-dimensional force moment of the foot, the control system state quantity is set as the position p at the center of mass (COM) of the robot c = [p cx ,p cy ,p cz ] T and the velocity of the COM of the robot, and the attitude angle θ = [α, β, γ] and the angular velocity w of the COM of the robot around the world coordinate system, where α, β, and γ represent the roll, pitch, and yaw angles of the COM, respectively, and g is the gravitational acceleration, so that formula (2), i.e., the control system state quantity expression, can be obtained.
[0117]
[0118] Through formulas (3) and (4), the control quantity is converted from the motor torque in the joint space of the robot to the six-dimensional force on the foot of the robot in the Cartesian space through the virtual force principle.
[0119] F1 = [F x ,F y ,F z ] T (3)
[0120] M1 = [M 1x ,M 1y ,M 1z ] T (4)
[0121] where F1 and M1 represent the three-dimensional force and moment of the left foot, respectively.
[0122] The system control quantity u can be represented by formula (5).
[0123] u = [F1, M1, F2, M2] (5)
[0124] Therefore, the dynamic system control problem can be represented by the discrete state equation (6).
[0125] X t+1 = AX t + Bu t (6)
[0126] where A ∈ R 13×13 is the system matrix, and B ∈ R 13×12 is the control matrix.
[0127] It should be noted that, in this embodiment, apart from the variables that can be directly measured by sensors or obtained by kinematics, the other variables of the system are unknown. The dynamic equations of the robot's force-controlled standing are unknown, and it is also impossible to establish the mathematical relationship expressions between the variables shown in the figure. Therefore, the system matrix and control matrix are unknown. For a system with unknown state equations, it is impossible to construct a state observer to estimate the system state of the humanoid robot when it is force-controlled standing. Therefore, this application uses the measurable system output to replace the system state as the control target. Let y represent the system output, which can be expressed by formula (7).
[0128] y t =CX t +Du t (7)
[0129] Wherein, the system output is equal to the system state, C∈I 12×12 , D∈I 12×1
[0130] In data-driven model prediction methods, the unknown system is controlled using only the input-output data; that is, there is no internal model or state information of the system, and it relies entirely on the measured inputs and outputs. The input-output sequence of a force-controlled standing system for a humanoid robot is used as an example. It is considered to be a trajectory of the system, for a sequence. The sequence is represented in the form of the Hankel matrix according to formula (8).
[0131]
[0132] The symbol 'a' represents the variable itself or the sequence. The word sequence of sequence a is represented as shown in formula (9).
[0133]
[0134] In some embodiments, Definition 1 is given: Hypothetical sequence It is the system's historical control input and output data, if Then it is believed It is a persistent excitation signal.
[0135] The above process gives a key constraint on system control: N (the number of data points) must satisfy the inequality N ≥ (n+1)L-1, where N is the length of the input-output data sequence, m is the dimension of the system input, n is the order of the system or the dimension of the state variables, and L is the system delay steps or time delay. That is, for a successful control system, the number of data points N must be at least equal to (n+1)L-1.
[0136] In some embodiments, Theorem 1 is given: Assume is a trajectory of the system, and satisfies the condition of persistent excitation signal, then is a trajectory of the system if and only if N-L+1 such that formula (10) holds.
[0137]
[0138] Here, Theorem 1 above is for linear systems, and for nonlinear systems, there is a more stringent restriction condition that all members of a should be equal to 1, that is, In addition, a sequence satisfies Definition 1, satisfies formula (9), then N can be replaced by any where
[0139] In the traditional data-driven MPC problem, for a given reference input-output sequence (u s , y s ), the cost function of the control system can be represented by formula (11).
[0140]
[0141] where Q and R are positive definite diagonal matrices with the same dimension as u and y, respectively; for the formula like , the specific expansion can be represented by formula (12).
[0142]
[0143] Since in the data-driven model predictive control (DDMPC), the model is completely unknown, instead of the system state such as the cost function, the past trajectory is used to predict the future trajectory (composed of and ), and it is optimized.
[0144] Through the input-output trajectory in Theorem 1, the DDMPC prediction framework based on the past N+n input-output sequences at time t can be represented by formula (13) and formula (14).
[0145]
[0146] Therefore, the cost function in DDMPC can be represented by formula (15) and formula (16).
[0147]
[0148] Here, the optimization problem of DDMPC is to minimize the cost function above, so that the actual input and the actual output are closest to the reference trajectory. For open-loop MPC without terminal constraints, a very long prediction horizon is needed to guarantee the stability of the control system while satisfying the constraint conditions. Therefore, terminal constraints need to be made for DDMPC, which can be represented by formula (17).
[0149]
[0150] In some embodiments, the output of an unknown linear time-invariant system (LTIS) is usually not exactly available and can be affected by measurement noise, so the Hankel matrix in formula (7) does not completely cover the trajectory space of the system, and the output trajectory cannot be accurately predicted. In addition, the noise output measurement will affect the initial conditions of the controller, thereby further reducing the prediction accuracy. Directly using the DDMPC scheme in formula (15) and formula (16) may cause feasibility problems or lead to closed-loop instability. Therefore, a robust data-driven MPC scheme with terminal constraints is used to solve the noise measurement problem.
[0151] First, consider the initial available data with bounded additive noise output measurement, defined as and the noise in online measurement where no assumption is made on the nature of the noise, but it is required to be bounded, i.e. formula (18) is satisfied.
[0152]
[0153] The current setting includes two types of noise. On the one hand, the data used for prediction by the Hankel matrix is disturbed by ε d , which can be interpreted as the uncertainty of the multiplicative model; on the other hand, the ε disturbance is in the online measurement, so the overall control objective is a noise output feedback problem. The key idea to solve the noise measurement problem is to relax the equality constraint and appropriately penalize the relaxed parameter in the cost function. For a given length n of the noise initial input-output trajectory and noise data a robust modification scheme of the cost function is proposed as shown in formula (19).
[0154]
[0155] where, represents the square of the 2-norm of the vector, i.e. the sum of the squares of each element,‖*‖∞ represents the infinity norm of vector *, i.e., the maximum of the absolute values of the individual elements, and ||*||1represents the 1-norm of vector *, i.e., the sum of the absolute values of the individual elements.
[0156] When the data-driven MPC problem is solved, the optimized input at the current time t can be applied to the actual control system. Compared with the traditional MPC problem, the output data trajectory and the initial output obtained by online measurement are replaced by their noise counterparts. In addition, the following components are added:
[0157] (1) A slack variable σ(t) is used to cope with the noise online measurement and the noise history data for prediction This can be interpreted as the uncertainty of the multiplicative model
[0158] (2) Quadratic regularization with weights of α(t) and σ(t), i.e., the regularization of α(t) depends on the noise level.
[0159] In the structural diagram of the robot force control standing system in Figure 6 , the humanoid robot only has a neck motor that needs to be adjusted, and the remaining motors are fixed at an initial position using position control. Ideally, the robot will always maintain a standing state, but in order to consider the impact of extreme cases such as the robot's neck motor exerting a large torque or the mass of the operating ball being too large on the stability of the robot, the application also adds the Zero Moment Point (ZMP) constraint to the force control standing.
[0160] In some embodiments, assuming the mass of the robot is m, the gravitational acceleration is g, the center of mass position is (x c ,y c ,z c ), the center of mass acceleration is , and the ground reaction force is F z , then the position of the ZMP (x zmp ,y zmp ) can be calculated by formula (20) and formula (21).
[0161]
[0162] The full-size humanoid robot Walker X used in this application has a total mass of 70 kg, and the material of its foot sole is rubber, which can meet the zero moment point constraint in most cases. When the robot moves to a state that does not meet the zero moment point constraint, the robot's center of mass position is adjusted through simple robot joint position control, so that the robot returns to a posture that meets the zero moment point constraint.
[0163] In some embodiments, the robot also needs to meet the friction cone constraint to prevent the robot foot from slipping, and the friction cone constraint condition can be represented by formula (22).
[0164]
[0165] Wherein, F x , F y , F z are the forces in the x, y and z directions of the robot foot, and μ is the friction coefficient.
[0166] Referring to Figure 7 , Figure 7 is a schematic diagram of the data-driven robot control method provided by the embodiments of the application, which will be combined Figure 7 to describe the specific process of the data-driven robot control method of the application.
[0167] In some embodiments, first, a simple initial controller is selected for the robot to control the robot by using a corresponding control algorithm (for example, a position control method); then, the robot is controlled by using the position control method to stand, and the corresponding historical input-output sequence is recorded, here, the input of the position control method is the position of the joint motor, and the historical input to be recorded is the six-dimensional force on the foot obtained by converting the joint torque measured by the sensor at the joint motor during standing through dynamics; then, the parameters N (the length of the input-output data sequence), n (the dimension of the state variable), L (the time delay of the system), (the adjustable parameter of the control system), (the upper bound of the output data) are determined to construct a cost function based on the parameters; subsequently, the target reference trajectory Then, the time t corresponding to the target reference trajectory is determined, and the Hankel matrix at time t is constructed; then, the corresponding α(t) after optimization is determined according to the above formula (19); then, the input data at time t, i.e., the six-dimensional force currently required to be applied to the foot of the robot, is determined according to the above formula (10), and it is determined whether the six-dimensional force currently required to be applied meets the friction cone constraint, and then the final six-dimensional force currently required to be applied to the foot of the robot is determined; subsequently, the real-time data is updated into the historical input-output sequence to dynamically adjust the control strategy, so as to adapt to the uncertain environmental changes.
[0168] The following continues to describe an exemplary structure of the data-driven robot control device 543 provided by the embodiments of the application as a software module, in some embodiments, as shown in Figure 2 the software module stored in the data-driven robot control device 543 in the memory 540 can include an acquisition module 5431, a construction module 5432 and a determination module 5433.
[0169] The acquisition module 5431 is configured to acquire a historical input-output sequence of the robot, where the historical input-output sequence includes historical input data of historical six-dimensional forces applied to the sole of the robot and historical output data of a historical movement trajectory of the robot.
[0170] In some embodiments, the acquisition module 5431 is further configured to acquire historical torques applied to leg motors of the robot when the robot is in a standing state, convert the historical torques into historical six-dimensional forces applied to the sole of the robot by a virtual force principle, acquire a historical movement trajectory of the robot corresponding to the historical six-dimensional forces, and construct the historical input-output sequence of the robot based on the historical six-dimensional forces and the historical movement trajectory.
[0171] In some embodiments, the construction module 5432 is further configured to determine a sequence length of the historical input-output sequence, create a zero matrix based on the sequence length, where the number of rows and the number of columns of the zero matrix are less than or equal to half of the sequence length, fill elements included in the historical input-output sequence into the zero matrix to obtain a Hankel matrix, where each element includes a historical six-dimensional force and a historical movement trajectory corresponding to the historical six-dimensional force, and construct the control strategy for the robot based on the Hankel matrix.
[0172] In some embodiments, the construction module 5432 is further configured to construct an initial model predictive controller for the robot based on the Hankel matrix, determine a predicted time cost at each time point in a prediction interval corresponding to the historical input-output sequence based on the initial model predictive controller, add the predicted time costs corresponding to the plurality of time points respectively, and take the addition result as a cost function, and construct the control strategy for the robot based on the cost function.
[0173] In some embodiments, the construction module 5432 is further configured to take the cost function as a first control condition, update parameters of the initial model predictive controller based on the first control condition to obtain an updated model predictive controller, and take the updated model predictive controller as the control strategy for the robot.
[0174] In some embodiments, the construction module 5432 is further configured to acquire a terminal constraint condition set for the robot, and construct the control strategy for the robot based on the terminal constraint condition and the cost function.
[0175] In some embodiments, the constructing module 5432 is further configured to combine the terminal constraint condition and the cost function to obtain a second control condition; update the parameters of the initialized model predictive controller based on the second control condition to obtain an updated model predictive controller; and use the updated model predictive controller as the control strategy for the robot.
[0176] In some embodiments, the data-driven robot control apparatus 543 further includes an updating module 5434 configured to add the six-dimensional force currently applied to the foot of the robot and the target movement trajectory to the historical input-output sequence to obtain an updated historical input-output sequence; and update the control strategy based on the updated historical input-output sequence.
[0177] In some embodiments, the data-driven robot control apparatus 543 further includes an adjusting module 5435 configured to, when the robot moves to a posture that does not satisfy the zero moment point constraint, adjust the center of mass position of the robot to make the robot return to a posture that satisfies the zero moment point constraint.
[0178] It should be noted that the description of the apparatus of the embodiments of the present application is similar to the description of the method embodiments described above, and has the same beneficial effects as the method embodiments, and thus will not be described again. For technical details of the data-driven robot control apparatus provided in the embodiments of the present application, they can be understood according to the description of any one of the accompanying drawings. Figure 3 , or Figure 4 the description of any one of the accompanying drawings.
[0179] The embodiments of the present application provide a computer program product, which includes a computer program or computer executable instructions stored in a computer readable storage medium. The processor of the electronic device reads the computer executable instructions from the computer readable storage medium, and the processor executes the computer executable instructions, so that the electronic device executes the data-driven robot control method provided in the embodiments of the present application.
[0180] The embodiments of the present application provide a computer readable storage medium, which stores computer executable instructions or computer programs. When the computer executable instructions or computer programs are executed by the processor, the processor will execute the data-driven robot control method provided in the embodiments of the present application, for example, the data-driven robot control method shown in Figure 3 , or Figure 4 .
[0181] In some embodiments, the computer-readable storage medium can be a Ferroelectric Random Access Memory (FRAM), a ROM, a Programmable Read-Only Memory (PROM), an Erasable Programmable Read-Only Memory (EPROM), an Electrically Erasable Programmable Read-Only Memory (EEPROM), a flash memory, a magnetic surface storage, an optical disc, or a Compact Disc Read-Only Memory (CD-ROM), and the like. It can also be various devices including one or any combination of the above memories.
[0182] In some embodiments, the computer-executable instructions can be in the form of programs, software, software modules, scripts, or code, written in any form of programming language, including compiled or interpreted languages, or declarative or procedural languages; and can be deployed in any form, including as a stand-alone program or as a module, component, subroutine, or other unit suitable for use in a computing environment.
[0183] By way of example, the computer-executable instructions can, but need not, reside in a file system's files, can be stored in documents, for example, Hyper Text Markup Language (HTML) documents, in one or more scripts stored in a file or files dedicated to the program in question, or in multiple cooperating files (e.g., files that store one or more modules, sub programs, or code portions).
[0184] By way of example, the computer-executable instructions can be deployed to be executed on one electronic device or on multiple electronic devices that are located at one site or that are distributed across multiple sites and that are interconnected through a communication network.
[0185] In summary, the embodiments of the present application have the following beneficial effects:
[0186] (1) DD-MPC is a data-driven method that can adapt to environmental changes in real-time and quickly adjust control strategies, thereby enhancing the stability and adaptability of the system. In practical applications, the environment in which the robot operates is often dynamic and unpredictable. Traditional control methods usually rely on fixed models and parameters, making it difficult to respond to rapid changes in the environment. The DD-MPC method, by continuously collecting and analyzing new data, can identify changes in the environment and quickly adjust control strategies to ensure that the robot remains balanced and operates normally in various complex and dynamic environments. This dynamic adaptive capability enables the robot to cope with more uncertainties and external disturbances, improving its practicality and robustness in real-world environments;
[0187] (2) The DD-MPC method uses historical data for in-depth analysis and prediction, enabling it to more accurately predict the future state of the system. This data-based prediction method can identify small changes in system behavior, allowing for more precise control. In traditional methods, control accuracy is often limited by the accuracy of the physical model, while DD-MPC does not rely on an accurate physical model but rather on actual operational data. This allows it to more accurately capture the dynamic characteristics of the system, improving control accuracy. At the same time, since DD-MPC can continuously update and optimize control strategies during operation, it can more reliably handle various nonlinearities and uncertainties, improving the overall reliability of the system;
[0188] (3) Traditional control systems often require the construction of complex dynamic models and state estimation, which not only increases the complexity of system design and implementation, but also requires high computational resources. The DD-MPC method directly uses historical input-output data for learning and optimization, completely bypassing the need for complex dynamic models, simplifying the design and implementation process of the system. Since there is no need for detailed physical models and state estimation steps, developers can focus more on data collection and analysis, greatly reducing the implementation difficulty and computational burden. This simplification not only speeds up the development cycle, but also makes the system more flexible and easy to maintain, adapting to the needs of different application scenarios. By reducing dependence on computational resources, DD-MPC also makes it possible to achieve efficient control in low-power and resource-constrained environments.
[0189] The above is only an embodiment of the present application and is not intended to limit the scope of protection of the present application. Any modifications, equivalent replacements, and improvements made within the spirit and scope of the present application are included within the scope of protection of the present application.
Claims
1. A data-driven based robot control method, characterized by, The method comprises: obtaining a historical input-output sequence of a robot, wherein the historical input-output sequence comprises historical input data of a historical six-dimensional force applied to a sole of the robot and historical output data of a historical movement trajectory of the robot; constructing a control strategy for the robot based on the historical input-output sequence, wherein the control strategy is used to represent a mapping relationship between the six-dimensional force applied to the sole of the robot and the movement trajectory of the robot; obtaining a target movement trajectory set for the robot; determining a six-dimensional force currently required to be applied to the sole of the robot based on the target movement trajectory and the control strategy.
2. The method of claim 1, wherein, The control strategy for the robot is constructed based on the historical input-output sequence, comprising: determining a sequence length of the historical input-output sequence; creating a zero matrix based on the sequence length, wherein the number of rows and the number of columns of the zero matrix are less than or equal to half of the sequence length; filling elements included in the historical input-output sequence into the zero matrix to obtain a Hankel matrix, wherein each of the elements comprises a historical six-dimensional force and a historical movement trajectory corresponding to the historical six-dimensional force; constructing the control strategy for the robot based on the Hankel matrix.
3. The method of claim 2, wherein, The control strategy for the robot is constructed based on the Hankel matrix, comprising: constructing an initial model predictive controller for the robot based on the Hankel matrix; determining a predicted time cost at each time point within a prediction interval corresponding to the historical input-output sequence based on the initial model predictive controller; adding the predicted time costs corresponding to the plurality of time points respectively, and taking the addition result as a cost function; constructing the control strategy for the robot based on the cost function.
4. The method of claim 3, wherein, The control strategy for the robot is constructed based on the cost function, comprising: taking the cost function as a first control condition; updating parameters of the initial model predictive controller based on the first control condition to obtain an updated model predictive controller; taking the updated model predictive controller as the control strategy for the robot.
5. The method of claim 3, wherein, The control strategy for the robot is constructed based on the cost function, comprising: obtaining a terminal constraint condition set for the robot; constructing the control strategy for the robot based on the terminal constraint condition and the cost function.
6. The method of claim 5, wherein, The control strategy for the robot is constructed based on the terminal constraint condition and the cost function, comprising: combining the terminal constraint condition and the cost function to obtain a second control condition; updating parameters of the initial model predictive controller based on the second control condition to obtain an updated model predictive controller; taking the updated model predictive controller as the control strategy for the robot.
7. The method according to any one of claims 1 to 6, characterized in that, The method further comprises: adding a six-dimensional force currently applied to a sole of the robot and the target movement trajectory to the historical input-output sequence to obtain an updated historical input-output sequence; updating the control strategy based on the updated historical input-output sequence.
8. The method according to any one of claims 1 to 6, characterized in that, The method further includes: adjusting a center of mass position of the robot when the robot moves to a posture that does not satisfy the zero moment point constraint, so as to make the robot return to a posture that satisfies the zero moment point constraint.
9. A data-driven based robot control apparatus characterized by comprising: The device includes: an acquisition module, configured to acquire a historical input-output sequence of a robot, wherein historical input data included in the historical input-output sequence is a historical six-dimensional force applied to a sole of the robot, and historical output data is a historical movement trajectory of the robot; a construction module, configured to construct a control strategy for the robot based on the historical input-output sequence, wherein the control strategy is used to represent a mapping relationship between a six-dimensional force applied to a sole of the robot and a movement trajectory of the robot; the acquisition module is further configured to acquire a target movement trajectory set for the robot; a determination module, configured to determine a six-dimensional force currently required to be applied to a sole of the robot based on the target movement trajectory and the control strategy.
10. An electronic device, comprising: include: a memory, configured to store computer executable instructions or computer programs; a processor, configured to execute the computer executable instructions or computer programs stored in the memory to implement the data-driven robot control method in any one of claims 1 to 8.
11. A computer readable storage medium storing computer-executable instructions or a computer program, characterized in that, The computer executable instructions or computer programs are executed by the processor to implement the data-driven robot control method in any one of claims 1 to 8.
12. A computer program product comprising computer-executable instructions or a computer program, characterized in that, The computer executable instructions or computer programs are executed by the processor to implement the data-driven robot control method in any one of claims 1 to 8. The computer executable instructions or computer programs are executed by the processor to implement the data-driven robot control method in any one of claims 1 to 8.
Citation Information
Patent Citations
Collaborative robot basic experiment platform
CN213025062U
Travel path planning method and apparatus, self-moving robot, and storage medium
WO2024140553A1