Skip to main content

State

The State object is the response back after calling solve. It contains the state of the robot in terms of joint and frames, as well as some diagnostic information regarding proximity of various shapes and the center_of_mass of the robot.

note

For Solver initialization, only origin and joints parameters have to be defined if user decided to provide a Stateobject to the initial_state parameter.

ParameterTypeOptionalDescription
originisometry consisted of translation and rotationnoThe transform of the root of the robot. This data is also included in frames
jointslookup table of float indexed by a string keynoA lookup table of the joint values for each movable joint
frameslookup table of TransformInfo indexed by string keycan be ignored for Solver initializationA lookup table of each link’s position in both world and local coordinates
proximitylist of ProximityInfocan be ignored for Solver initializationA vector of data representing pairwise proximity between the robot’s parts and other robot parts and the environment. Each entry contains distance, as well as the closest points between the pair of colliders
center_of_masslist of floatcan be ignored for Solver initializationA 3-vector representing the center of mass of the robot in the world frame

Import

note

There is no need to import for Javascript.

  from lively import State

Declaration Example

  let state = {origin:{translation:[0,0,0],rotation:[1,0,0,0]},joints:{"panda_joint1":0.0,"panda_joint2":0.0}}