pycram.world_concepts.world_object
==================================

.. py:module:: pycram.world_concepts.world_object


Attributes
----------

.. autoapisummary::

   pycram.world_concepts.world_object.MJCF
   pycram.world_concepts.world_object.Link


Classes
-------

.. autoapisummary::

   pycram.world_concepts.world_object.Object


Module Contents
---------------

.. py:data:: MJCF
   :value: None


.. py:data:: Link

.. py:class:: Object(name: str, concept: typing_extensions.Type[pycrap.ontologies.PhysicalObject], path: typing_extensions.Optional[str] = None, description: typing_extensions.Optional[pycram.description.ObjectDescription] = None, pose: typing_extensions.Optional[pycram.datastructures.pose.PoseStamped] = None, world: typing_extensions.Optional[pycram.datastructures.world.World] = None, color: typing_extensions.Optional[pycram.datastructures.dataclasses.Color] = None, size: typing_extensions.Optional[typing_extensions.List[float]] = None, ignore_cached_files: bool = False, scale_mesh: typing_extensions.Optional[float] = None, mesh_transform: typing_extensions.Optional[pycram.datastructures.pose.TransformStamped] = None)

   Bases: :py:obj:`pycram.datastructures.world_entity.PhysicalBody`, :py:obj:`pycram.has_parameters.HasParameters`


   Represents a spawned Object in the World.


   .. py:attribute:: tf_prospection_world_prefix
      :type:  str
      :value: 'prospection/'


      The prefix for the tf frame of objects in the prospection world.



   .. py:attribute:: extension_to_description_type
      :type:  typing_extensions.Dict[str, typing_extensions.Type[pycram.description.ObjectDescription]]

      A dictionary that maps the file extension to the corresponding ObjectDescription type.



   .. py:attribute:: ontology_concept
      :type:  typing_extensions.Type[pycrap.ontologies.PhysicalObject]


   .. py:attribute:: world
      :value: None



   .. py:property:: name

      The name of the object.



   .. py:attribute:: path
      :type:  typing_extensions.Optional[str]
      :value: None



   .. py:attribute:: cache_manager


   .. py:attribute:: local_transformer


   .. py:attribute:: original_pose


   .. py:attribute:: _current_pose


   .. py:attribute:: scale_mesh
      :value: None



   .. py:attribute:: id


   .. py:attribute:: size_
      :value: None



   .. py:attribute:: attachments
      :type:  typing_extensions.Dict[Object, pycram.world_concepts.constraints.Attachment]


   .. py:property:: parts
      :type: typing_extensions.Dict[str, pycram.datastructures.world_entity.PhysicalBody]



   .. py:property:: tf_frame
      :type: str


      The tf frame of the object.



   .. py:property:: color
      :type: typing_extensions.Union[pycram.datastructures.dataclasses.Color, typing_extensions.Dict[str, pycram.datastructures.dataclasses.Color]]


      Return the rgba_color of this object. The return is either:

          1. A Color object with RGBA values, this is the case if the object only has one link (this
              happens for example if the object is spawned from a .obj or .stl file)
          2. A dict with the link name as key and the rgba_color as value. The rgba_color is given as a Color Object.
              Please keep in mind that not every link may have a rgba_color. This is dependent on the URDF from which
               the object is spawned.

      :return: The rgba_color as Color object with RGBA values between 0 and 1 or a dict with the link name as key and
       the rgba_color as value.



   .. py:property:: size
      :type: typing_extensions.List[float]



   .. py:method:: get_mesh_path() -> typing_extensions.List[str]

      Get the path to the mesh file of the object.

      :return: The path(s) to the mesh file(s).



   .. py:method:: _resolve_description(path: typing_extensions.Optional[str] = None, description: typing_extensions.Optional[pycram.description.ObjectDescription] = None) -> None

      Find the correct description type of the object and initialize it and set the description of this object to it.

      :param path: The path to the source file.
      :param description: The ObjectDescription of the object.



   .. py:method:: set_mobile_robot_pose(pose: pycram.datastructures.pose.PoseStamped) -> None

      Set the goal for the mobile base joints of a mobile robot to reach a target pose. This is used for example when
      the simulator does not support setting the pose of the robot directly (e.g. MuJoCo).

      :param pose: The target pose.



   .. py:method:: get_mobile_base_joint_goal(pose: pycram.datastructures.pose.PoseStamped) -> typing_extensions.Dict[pycram.datastructures.dataclasses.VirtualJoint, float]

      Get the goal for the mobile base joints of a mobile robot to reach a target pose.

      :param pose: The target pose.
      :return: The goal for the mobile base joints.



   .. py:method:: get_mobile_base_pose_difference(pose: pycram.datastructures.pose.PoseStamped) -> typing_extensions.Tuple[pycram.datastructures.pose.Point, float]

      Get the difference between the current and the target pose of the mobile base.

      :param pose: The target pose.
      :return: The difference between the current and the target pose of the mobile base.



   .. py:property:: joint_actuators
      :type: typing_extensions.Optional[typing_extensions.Dict[str, str]]


      The joint actuators of the robot.



   .. py:property:: has_actuators
      :type: bool


      True if the object has actuators, otherwise False.



   .. py:property:: robot_description
      :type: pycram.robot_description.RobotDescription


      The current robot description.



   .. py:method:: get_actuator_for_joint(joint: pycrap.ontologies.Joint) -> typing_extensions.Optional[str]

      Get the actuator name for a joint.

      :param joint: The joint object for which to get the actuator.
      :return: The name of the actuator.



   .. py:method:: get_multiple_link_positions(links: typing_extensions.List[Link]) -> typing_extensions.Dict[str, typing_extensions.List[float]]

      Get the positions of multiple links of the object.

      :param links: The link objects of which to get the positions.
      :return: The positions of the links.



   .. py:method:: get_multiple_link_orientations(links: typing_extensions.List[Link]) -> typing_extensions.Dict[str, typing_extensions.List[float]]

      Get the orientations of multiple links of the object.

      :param links: The link objects of which to get the orientations.
      :return: The orientations of the links.



   .. py:method:: get_multiple_link_poses(links: typing_extensions.List[Link]) -> typing_extensions.Dict[str, pycram.datastructures.pose.PoseStamped]

      Get the poses of multiple links of the object.

      :param links: The link objects of which to get the poses.
      :return: The poses of the links.



   .. py:method:: get_poses_of_attached_objects() -> typing_extensions.Dict[Object, pycram.datastructures.pose.PoseStamped]

      Get the poses of the attached objects.

      :return: The poses of the attached objects



   .. py:method:: get_target_poses_of_attached_objects_given_parent(pose: pycram.datastructures.pose.PoseStamped) -> typing_extensions.Dict[Object, pycram.datastructures.pose.PoseStamped]

      Get the target poses of the attached objects of an object. Given the pose of the parent object. (i.e. the poses
       to which the attached objects will move when the parent object is at the given pose)

      :param pose: The pose of the parent object.
      :return: The target poses of the attached objects



   .. py:property:: pose

      The current pose of the object.



   .. py:property:: transform

      The current transform of the object.



   .. py:property:: obj_type
      :type: typing_extensions.Type[pycrap.ontologies.PhysicalObject]



   .. py:method:: _spawn_object_and_get_id() -> int

      Loads an object to the given World with the given position and orientation. The rgba_color will only be
      used when an .obj or .stl file is given.
      If a .obj or .stl file is given, before spawning, an urdf file with the .obj or .stl as mesh will be created
      and this URDf file will be loaded instead.
      When spawning a URDf file a new file will be created in the cache directory, if there exists none.
      This new file will have resolved mesh file paths, meaning there will be no references
      to ROS packages instead there will be absolute file paths.

      :return: The unique id of the object and the path of the file that was loaded.



   .. py:method:: _update_world_robot_and_description()

      Initialize the robot description of the object, load the description from the RobotDescriptionManager and set
      the robot as the current robot in the World. Also add the virtual mobile base joints to the robot.



   .. py:method:: _update_world_environment_object()

      Initialize the environment as the current environment in the World.



   .. py:method:: _add_virtual_move_base_joints()

      Add the virtual mobile base joints to the robot description.



   .. py:method:: _init_joint_name_and_id_map() -> None

      Create a dictionary which maps the joint names to their unique ids and vice versa.



   .. py:method:: _init_link_name_and_id_map() -> None

      Create a dictionary which maps the link names to their unique ids and vice versa.



   .. py:method:: _init_links_and_update_transforms() -> None

      Initialize the link objects from the URDF file and creates a dictionary which maps the link names to the
      corresponding link objects.



   .. py:method:: _init_joints()

      Initialize the joint objects from the URDF file and creates a dictionary which mas the joint names to the
      corresponding joint objects



   .. py:method:: is_joint_virtual(name: str)

      Check if a joint is virtual.



   .. py:property:: virtual_joint_names

      The names of the virtual joints.



   .. py:property:: virtual_joints

      The virtual joints as a list.



   .. py:property:: has_one_link
      :type: bool


      True if the object has only one link, otherwise False.



   .. py:property:: link_names
      :type: typing_extensions.List[str]


      The names of the links as a list.



   .. py:property:: joint_names
      :type: typing_extensions.List[str]


      The names of the joints as a list.



   .. py:method:: get_link(link_name: str) -> pycram.description.ObjectDescription.Link

      Return the link object with the given name.

      :param link_name: The name of the link.
      :return: The link object.



   .. py:method:: get_link_pose(link_name: str) -> pycram.datastructures.pose.PoseStamped

      Return the pose of the link with the given name.

      :param link_name: The name of the link.
      :return: The pose of the link.



   .. py:method:: get_link_position(link_name: str) -> pycram.datastructures.pose.Point

      Return the position of the link with the given name.

      :param link_name: The name of the link.
      :return: The position of the link.



   .. py:method:: get_link_position_as_list(link_name: str) -> typing_extensions.List[float]

      Return the position of the link with the given name.

      :param link_name: The name of the link.
      :return: The position of the link.



   .. py:method:: get_link_orientation(link_name: str) -> pycram.datastructures.pose.Quaternion

      Return the orientation of the link with the given name.

      :param link_name: The name of the link.
      :return: The orientation of the link.



   .. py:method:: get_link_orientation_as_list(link_name: str) -> typing_extensions.List[float]

      Return the orientation of the link with the given name.

      :param link_name: The name of the link.
      :return: The orientation of the link.



   .. py:method:: get_link_tf_frame(link_name: str) -> str

      Return the tf frame of the link with the given name.

      :param link_name: The name of the link.
      :return: The tf frame of the link.



   .. py:method:: get_link_axis_aligned_bounding_box(link_name: str, transform_to_link_pose: bool = True) -> pycram.datastructures.dataclasses.AxisAlignedBoundingBox

      Return the axis aligned bounding box of the link with the given name.

      :param link_name: The name of the link.
      :param transform_to_link_pose: If True, the bounding box will be transformed to fit link pose.
      :return: The axis aligned bounding box of the link.



   .. py:method:: get_transform_between_links(from_link: str, to_link: str) -> pycram.datastructures.pose.TransformStamped

      Return the transform between two links.

      :param from_link: The name of the link from which the transform should be calculated.
      :param to_link: The name of the link to which the transform should be calculated.



   .. py:method:: get_link_color(link_name: str) -> pycram.datastructures.dataclasses.Color

      Return the color of the link with the given name.

      :param link_name: The name of the link.
      :return: The color of the link.



   .. py:method:: set_link_color(link_name: str, color: typing_extensions.List[float]) -> None

      Set the color of the link with the given name.

      :param link_name: The name of the link.
      :param color: The new color of the link.



   .. py:method:: get_link_geometry(link_name: str) -> typing_extensions.List[pycram.datastructures.dataclasses.VisualShape]

      Return the collision geometry of the link with the given name.

      :param link_name: The name of the link.
      :return: List of the collision geometry of the link.



   .. py:method:: get_link_visual_geometry(link_name: str) -> typing_extensions.List[pycram.datastructures.dataclasses.VisualShape]

      Return the visual geometry of the link with the given name.

      :param link_name: The name of the link.
      :return: The visual geometry of the link.



   .. py:method:: get_link_transform(link_name: str) -> pycram.datastructures.pose.TransformStamped

      Return the transform of the link with the given name.

      :param link_name: The name of the link.
      :return: The transform of the link.



   .. py:method:: get_link_origin(link_name: str) -> pycram.datastructures.pose.PoseStamped

      Return the origin of the link with the given name.

      :param link_name: The name of the link.
      :return: The origin of the link as a 'Pose'.



   .. py:method:: get_link_origin_transform(link_name: str) -> pycram.datastructures.pose.TransformStamped

      Return the origin transform of the link with the given name.

      :param link_name: The name of the link.
      :return: The origin transform of the link.



   .. py:property:: base_origin_shift
      :type: numpy.ndarray


      The shift between the base of the object and the origin of the object.

      :return: A numpy array with the shift between the base of the object and the origin of the object.



   .. py:method:: __repr__()


   .. py:method:: remove() -> None

      Remove this object from the World it currently resides in.
      For the object to be removed it has to be detached from all objects it
      is currently attached to. Then remove this Object from the simulation/world.



   .. py:method:: reset(remove_saved_states=False) -> None

      Reset the Object to the state it was first spawned in.
      All attached objects will be detached, all joints will be set to the
      default position of 0 and the object will be set to the position and
      orientation in which it was spawned.

      :param remove_saved_states: If True the saved states will be removed.



   .. py:method:: reset_all_joints() -> None

      Reset all joints of the object.



   .. py:method:: reset_all_links() -> None

      Reset all links of the object.



   .. py:property:: is_an_environment
      :type: bool


      Check if the object is of type environment.

      :return: True if the object is of type environment, False otherwise.



   .. py:property:: is_an_object
      :type: bool


      Check if the object is of type Physical Object or Generic Object.

      :return: True if the object is of type PhysicalObject , False otherwise.



   .. py:property:: is_a_robot
      :type: bool


      Check if the object is a robot.
      TODO: Check if this is a the correct filter
      :return: True if the object is a robot, False otherwise.



   .. py:method:: merge(other: Object, name: typing_extensions.Optional[str] = None, pose: typing_extensions.Optional[pycram.datastructures.pose.PoseStamped] = None, new_description_file: typing_extensions.Optional[str] = None) -> Object

      Merge the object with another object. This is done by merging the descriptions of the objects,
      removing the original objects creating a new merged object.

      :param other: The object to merge with.
      :param name: The name of the merged object.
      :param pose: The pose of the merged object.
      :param new_description_file: The new description file of the merged object.
      :return: The merged object.



   .. py:method:: attach(child_object: Object, parent_link: typing_extensions.Optional[str] = None, child_link: typing_extensions.Optional[str] = None, bidirectional: bool = True, coincide_the_objects: bool = False, parent_to_child_transform: typing_extensions.Optional[pycram.datastructures.pose.TransformStamped] = None) -> None

      Attach another object to this object. This is done by
      saving the transformation between the given link, if there is one, and
      the base pose of the other object. Additionally, the name of the link, to
      which the object is attached, will be saved.
      Furthermore, a simulator constraint will be created so the attachment
      also works while simulation.
      Loose attachments means that the attachment will only be one-directional. For example, if this object moves the
      other, attached, object will also move but not the other way around.

      :param child_object: The other object that should be attached.
      :param parent_link: The link name of this object.
      :param child_link: The link name of the other object.
      :param bidirectional: If the attachment should be a loose attachment.
      :param coincide_the_objects: If True the object frames will be coincided.
      :param parent_to_child_transform: The transform from the parent to the child object.



   .. py:method:: detach(child_object: Object) -> None

      Detache another object from this object. This is done by
      deleting the attachment from the attachments dictionary of both objects
      and deleting the constraint of the simulator.
      Afterward the detachment event of the corresponding World will be fired.

      :param child_object: The object which should be detached



   .. py:method:: detach_all() -> None

      Detach all objects attached to this object.



   .. py:method:: update_attachment_with_object(child_object: Object)


   .. py:method:: get_position() -> pycram.datastructures.pose.Point

      Return the position of this Object as a list of xyz.

      :return: The current position of this object



   .. py:method:: get_orientation() -> pycram.datastructures.pose.PoseStamped.orientation

      Return the orientation of this object as a list of xyzw, representing a quaternion.

      :return: A list of xyzw



   .. py:method:: get_position_as_list() -> typing_extensions.List[float]

      Return the position of this Object as a list of xyz.

      :return: The current position of this object



   .. py:method:: get_base_position_as_list() -> typing_extensions.List[float]

      Return the position of this Object as a list of xyz.

      :return: The current position of this object



   .. py:method:: get_orientation_as_list() -> typing_extensions.List[float]

      Return the orientation of this object as a list of xyzw, representing a quaternion.

      :return: A list of xyzw



   .. py:method:: get_pose() -> pycram.datastructures.pose.PoseStamped

      Return the position of this object as a list of xyz. Alias for :func:`~Object.get_position`.

      :return: The current pose of this object



   .. py:method:: set_pose(pose: pycram.datastructures.pose.PoseStamped, base: bool = False, set_attachments: bool = True) -> None

      Set the Pose of the object.

      :param pose: New Pose for the object
      :param base: If True places the object base instead of origin at the specified position and orientation
      :param set_attachments: Whether to set the poses of the attached objects to this object or not.



   .. py:method:: reset_base_pose(pose: pycram.datastructures.pose.PoseStamped) -> bool


   .. py:method:: move_base_to_origin_pose() -> None

      Move the object such that its base will be at the current origin position.
      This is useful when placing objects on surfaces where you want the object base in contact with the surface.



   .. py:method:: save_state(state_id: int, save_dir: typing_extensions.Optional[str] = None) -> None

      Save the state of this object by saving the state of all links and attachments.

      :param state_id: The unique id of the state.
      :param save_dir: The directory in which to save the state.



   .. py:method:: save_links_states(state_id: int) -> None

      Save the state of all links of this object.

      :param state_id: The unique id of the state.



   .. py:method:: save_joints_states(state_id: int) -> None

      Save the state of all joints of this object.

      :param state_id: The unique id of the state.



   .. py:property:: current_state
      :type: pycram.datastructures.dataclasses.ObjectState


      The current state of this object as an ObjectState.



   .. py:method:: set_attachments(attachments: typing_extensions.Dict[Object, pycram.world_concepts.constraints.Attachment]) -> None

      Set the attachments of this object to the given attachments.

      :param attachments: A dictionary with the object as key and the attachment as value.



   .. py:method:: detach_objects_not_in_attachments(attachments: typing_extensions.Dict[Object, pycram.world_concepts.constraints.Attachment]) -> None

      Detach objects that are not in the attachments list and are in the current attachments list.

      :param attachments: A dictionary with the object as key and the attachment as value.



   .. py:method:: attach_objects_in_attachments(attachments: typing_extensions.Dict[Object, pycram.world_concepts.constraints.Attachment]) -> None

      Attach objects that are in the given attachments list but not in the current attachments list.

      :param attachments: A dictionary with the object as key and the attachment as value.



   .. py:method:: mimic_attachment_with_object(attachment: pycram.world_concepts.constraints.Attachment, child_object: Object) -> None

      Mimic the given attachment for this and the given child objects.

      :param attachment: The attachment to mimic.
      :param child_object: The child object.



   .. py:method:: get_attachment_transform_with_object(attachment: pycram.world_concepts.constraints.Attachment, child_object: Object) -> pycram.datastructures.pose.TransformStamped

      Return the attachment transform for the given parent and child objects, taking into account the prospection
      world.

      :param attachment: The attachment.
      :param child_object: The child object.
      :return: The attachment transform.



   .. py:property:: link_states
      :type: typing_extensions.Dict[int, pycram.datastructures.dataclasses.LinkState]


      The current state of all links of this object.

      :return: A dictionary with the link id as key and the current state of the link as value.



   .. py:property:: joint_states
      :type: typing_extensions.Dict[int, pycram.datastructures.dataclasses.JointState]


      The current state of all joints of this object.

      :return: A dictionary with the joint id as key and the current state of the joint as value.



   .. py:method:: robot_virtual_move_base_joints_names()


   .. py:method:: remove_saved_states() -> None

      Remove all saved states of this object.



   .. py:method:: remove_links_saved_states() -> None

      Remove all saved states of the links of this object.



   .. py:method:: remove_joints_saved_states() -> None

      Remove all saved states of the joints of this object.



   .. py:method:: _set_attached_objects_poses(already_moved_objects: typing_extensions.Optional[typing_extensions.List[Object]] = None) -> None

      Update the positions of all attached objects. This is done
      by calculating the new pose in world coordinate frame and setting the
      base pose of the attached objects to this new pose.
      After this call _set_attached_objects method for all attached objects.

      :param already_moved_objects: A list of Objects that were already moved, these will be excluded to prevent loops
       in the update.



   .. py:method:: set_position(position: typing_extensions.Union[pycram.datastructures.pose.PoseStamped, pycram.datastructures.pose.Point, typing_extensions.List], base=False) -> None

      Set this Object to the given position, if base is true, place the bottom of the Object at the position
      instead of the origin in the center of the Object. The given position can either be a Pose,
      in this case only the position is used or a geometry_msgs.msg/Point which is the position part of a Pose.

      :param position: Target position as xyz.
      :param base: If the bottom of the Object should be placed or the origin in the center.



   .. py:method:: set_orientation(orientation: typing_extensions.Union[pycram.datastructures.pose.PoseStamped, pycram.datastructures.pose.Quaternion, typing_extensions.List, typing_extensions.Tuple, numpy.ndarray]) -> None

      Set the orientation of the Object to the given orientation. Orientation can either be a Pose, in this case only
      the orientation of this pose is used or a geometry_msgs.msg/Quaternion which is the orientation of a Pose.

      :param orientation: Target orientation given as a list of xyzw.



   .. py:method:: get_joint_id(name: str) -> int

      Return the unique id for a joint name. As used by the world/simulator.

      :param name: The joint name
      :return: The unique id



   .. py:method:: get_root_link_description() -> pycram.description.LinkDescription

      Return the root link of the URDF of this object.

      :return: The root link as defined in the URDF of this object.



   .. py:property:: root_link
      :type: pycram.description.ObjectDescription.Link


      The root link of this object.

      :return: The root link of this object.



   .. py:property:: tip_link
      :type: pycram.description.ObjectDescription.Link


      The tip link of this object.

      :return: The tip link of this object.



   .. py:method:: get_root_link_id() -> int

      Return the unique id of the root link of this object.

      :return: The unique id of the root link of this object.



   .. py:method:: get_link_id(link_name: str) -> int

      Return a unique id for a link name.

      :param link_name: The name of the link.
      :return: The unique id of the link.



   .. py:method:: get_link_by_id(link_id: int) -> pycram.description.ObjectDescription.Link

      Return the link for a given unique link id

      :param link_id: The unique id of the link.
      :return: The link object.



   .. py:method:: reset_all_joints_positions() -> None

      Set the current position of all joints to 0. This is useful if the joints should be reset to their default



   .. py:method:: set_joint_position(joint_name: str, joint_position: float) -> None

      Set the position of the given joint to the given joint pose and updates the poses of all attached objects.

      :param joint_name: The name of the joint
      :param joint_position: The target pose for this joint



   .. py:method:: set_joint_positions(joint_positions: typing_extensions.Dict[str, float]) -> None


   .. py:method:: set_multiple_joint_positions(joint_positions: typing_extensions.Dict[str, float]) -> None

      Set the current position of multiple joints at once, this method should be preferred when setting
      multiple joints at once instead of running :func:`~Object.set_joint_position` in a loop.

      :param joint_positions: A dictionary with the joint names as keys and the target positions as values.



   .. py:method:: clip_joint_positions_to_limits(joint_positions: typing_extensions.Dict[str, float]) -> typing_extensions.Dict[str, float]

      Clip the given joint positions to the joint limits.

      :param joint_positions: A dictionary with the joint names as keys and the target positions as values.
      :return: A dictionary with the joint names as keys and the clipped positions as values.



   .. py:method:: get_joint_position(joint_name: str) -> float

      Return the current position of the given joint.

      :param joint_name: The name of the joint
      :return: The current position of the given joint



   .. py:method:: get_joint_damping(joint_name: str) -> float

      Return the damping of the given joint (friction).

      :param joint_name: The name of the joint
      :return: The damping of the given joint



   .. py:method:: get_joint_upper_limit(joint_name: str) -> float

      Return the upper limit of the given joint.

      :param joint_name: The name of the joint
      :return: The upper limit of the given joint



   .. py:method:: get_joint_lower_limit(joint_name: str) -> float

      Return the lower limit of the given joint.

      :param joint_name: The name of the joint
      :return: The lower limit of the given joint



   .. py:method:: get_joint_axis(joint_name: str) -> pycram.datastructures.pose.Point

      Return the axis of the given joint.

      :param joint_name: The name of the joint
      :return: The axis of the given joint



   .. py:method:: get_joint_type(joint_name: str) -> pycram.datastructures.enums.JointType

      Return the type of the given joint.

      :param joint_name: The name of the joint
      :return: The type of the given joint



   .. py:method:: get_joint_limits(joint_name: str) -> typing_extensions.Tuple[float, float]

      Return the lower and upper limits of the given joint.

      :param joint_name: The name of the joint
      :return: The lower and upper limits of the given joint



   .. py:method:: get_joint_child_link(joint_name: str) -> pycram.description.ObjectDescription.Link

      Return the child link of the given joint.

      :param joint_name: The name of the joint
      :return: The child link of the given joint



   .. py:method:: get_joint_parent_link(joint_name: str) -> pycram.description.ObjectDescription.Link

      Return the parent link of the given joint.

      :param joint_name: The name of the joint
      :return: The parent link of the given joint



   .. py:method:: find_joint_above_link(link_name: str, joint_type: typing_extensions.Optional[pycram.datastructures.enums.JointType] = None) -> typing_extensions.Optional[str]

      Traverses the chain from 'link' to the URDF origin and returns the first joint that is of type 'joint_type'.
      If no joint type is given, the first joint that is not FIXED is returned.

      :param link_name: AbstractLink name above which the joint should be found
      :param joint_type: Joint type that should be searched for
      :return: Name of the first joint which has the given type



   .. py:method:: get_multiple_joint_positions(joint_names: typing_extensions.List[str]) -> typing_extensions.Dict[str, float]

      Return the positions of multiple joints at once.

      :param joint_names: A list of joint names.
      :return: A dictionary with the joint names as keys and the joint positions as values.



   .. py:method:: get_positions_of_controllable_joints() -> typing_extensions.Dict[str, float]

      Return a list of all controllable joints of this object.

      :return: A list of all controllable joints.



   .. py:method:: get_positions_of_all_joints() -> typing_extensions.Dict[str, float]

      Return the positions of all joints of the object as a dictionary of joint names and joint positions.

      :return: A dictionary with all joints positions'.



   .. py:method:: update_link_transforms(transform_time: typing_extensions.Optional[pycram.ros.Time] = None) -> None

      Update the transforms of all links of this object using time 'transform_time' or the current ros time.

      :param transform_time: The time to use for the transform update.



   .. py:property:: contact_points
      :type: pycram.datastructures.dataclasses.ContactPointsList


      Return a list of contact points of this Object with other Objects.

      :return: A list of all contact points with other objects



   .. py:method:: contact_points_simulated() -> pycram.datastructures.dataclasses.ContactPointsList

      Return a list of all contact points between this Object and other Objects after stepping the simulation once.

      :return: A list of contact points between this Object and other Objects



   .. py:method:: closest_points(max_distance: float) -> pycram.datastructures.dataclasses.ClosestPointsList

      Return a list of closest points between this Object and other Objects.

      :param max_distance: The maximum distance between the closest points
      :return: A list of closest points between this Object and other Objects



   .. py:method:: closest_points_with_obj(other_object: Object, max_distance: float) -> pycram.datastructures.dataclasses.ClosestPointsList

      Return a list of closest points between this Object and another Object.

      :param other_object: The other object
      :param max_distance: The maximum distance between the closest points
      :return: A list of closest points between this Object and the other Object



   .. py:method:: set_color(rgba_color: pycram.datastructures.dataclasses.Color) -> None


   .. py:method:: get_color() -> typing_extensions.Union[pycram.datastructures.dataclasses.Color, typing_extensions.Dict[str, pycram.datastructures.dataclasses.Color]]


   .. py:property:: links_colors
      :type: typing_extensions.Dict[str, pycram.datastructures.dataclasses.Color]


      The color of each link as a dictionary with link names as keys and RGBA colors as values.



   .. py:method:: get_axis_aligned_bounding_box(shift_to_object_position: bool = True) -> pycram.datastructures.dataclasses.AxisAlignedBoundingBox

      Return the axis aligned bounding box of this object.

      :param shift_to_object_position: If True, the bounding box will be shifted to the object position.
      :return: The axis aligned bounding box of this object.



   .. py:method:: get_rotated_bounding_box() -> pycram.datastructures.dataclasses.RotatedBoundingBox

      Return the rotated bounding box of this object.

      :return: The rotated bounding box of this object.



   .. py:method:: get_convex_hull() -> trimesh.parent.Geometry3D

      Return the convex hull of this object.

      :return: The convex hull of this object.



   .. py:method:: get_base_origin() -> pycram.datastructures.pose.PoseStamped

      Return the origin of the base/bottom of this object.

      :return: the origin of the base/bottom of this object.



   .. py:method:: get_joint_by_id(joint_id: int) -> pycrap.ontologies.Joint

      Return the joint object with the given id.

      :param joint_id: The unique id of the joint.
      :return: The joint object.



   .. py:method:: get_link_for_attached_objects() -> typing_extensions.Dict[Object, pycram.description.ObjectDescription.Link]

      Return a dictionary which maps attached object to the link of this object to which the given object is attached.

      :return: The link of this object to which the given object is attached.



   .. py:method:: copy_to_prospection() -> Object

      Copy this object to the prospection world.

      :return: The copied object in the prospection world.



   .. py:method:: copy_to_world(world: pycram.datastructures.world.World) -> Object

      Copy this object to the given world.

      :param world: The world to which the object should be copied.
      :return: The copied object in the given world.



   .. py:method:: parent_entity() -> pycram.datastructures.world.World

      :return: The parent of this object which is the world.



   .. py:method:: frozen_copy() -> pycram.datastructures.dataclasses.FrozenObject

      Creates a copied version of this object which contains the information of this object but can not be interacted
      with.

      :return FrozenObject: The copied forzen object.



   .. py:method:: define_parameters() -> typing_extensions.Dict[str, typing_extensions.Any]
      :classmethod:


      Defines the parameters of Object for the HasParameter flattener. Relevant parameters for objects are only the
      Pose and Type.

      :return: A dictionary with the parameters of the object



