pycram.robot_plans.actions.core.container#

Attributes#

Classes#

OpenAction

Opens a container like object

CloseAction

Closes a container like object.

Functions#

validate_close_open(object_designator, arm, action_type)

Validates if the container is opened or closed by checking the joint position of the container.

check_opened(joint_obj, obj_part, arm, upper_limit)

check_closed(joint_obj, obj_part, arm, lower_limit)

Module Contents#

class pycram.robot_plans.actions.core.container.OpenAction#

Bases: pycram.robot_plans.actions.base.ActionDescription

Opens a container like object

object_designator: semantic_digital_twin.world_description.world_entity.Body#

Object designator_description describing the object that should be opened

arm: pycram.datastructures.enums.Arms#

Arm that should be used for opening the container

grasping_prepose_distance: float#

The distance in meters the gripper should be at in the x-axis away from the handle.

plan() None#

Symbolic plan. Should only call motions or sub-actions.

validate(result: typing_extensions.Optional[typing_extensions.Any] = None, max_wait_time: typing_extensions.Optional[datetime.timedelta] = None)#

Check if the container is opened, this assumes that the container state can be read accurately from the real world.

classmethod description(object_designator_description: typing_extensions.Union[typing_extensions.Iterable[semantic_digital_twin.world_description.world_entity.Body], semantic_digital_twin.world_description.world_entity.Body], arm: typing_extensions.Union[typing_extensions.Iterable[pycram.datastructures.enums.Arms], pycram.datastructures.enums.Arms] = None, grasping_prepose_distance: typing_extensions.Union[typing_extensions.Iterable[float], float] = ActionConfig.grasping_prepose_distance) pycram.datastructures.partial_designator.PartialDesignator[typing_extensions.Type[OpenAction]]#
class pycram.robot_plans.actions.core.container.CloseAction#

Bases: pycram.robot_plans.actions.base.ActionDescription

Closes a container like object.

object_designator: semantic_digital_twin.world_description.world_entity.Body#

Object designator_description describing the object that should be closed

arm: pycram.datastructures.enums.Arms#

Arm that should be used for closing

grasping_prepose_distance: float#

The distance in meters between the gripper and the handle before approaching to grasp.

plan() None#

Symbolic plan. Should only call motions or sub-actions.

validate(result: typing_extensions.Optional[typing_extensions.Any] = None, max_wait_time: typing_extensions.Optional[datetime.timedelta] = None)#

Check if the container is closed, this assumes that the container state can be read accurately from the real world.

classmethod description(object_designator_description: typing_extensions.Union[typing_extensions.Iterable[semantic_digital_twin.world_description.world_entity.Body], semantic_digital_twin.world_description.world_entity.Body], arm: typing_extensions.Union[typing_extensions.Iterable[pycram.datastructures.enums.Arms], pycram.datastructures.enums.Arms] = None, grasping_prepose_distance: typing_extensions.Union[typing_extensions.Iterable[float], float] = ActionConfig.grasping_prepose_distance) pycram.datastructures.partial_designator.PartialDesignator[typing_extensions.Type[CloseAction]]#
pycram.robot_plans.actions.core.container.validate_close_open(object_designator: semantic_digital_twin.world_description.world_entity.Body, arm: pycram.datastructures.enums.Arms, action_type: typing_extensions.Union[typing_extensions.Type[OpenAction], typing_extensions.Type[CloseAction]])#

Validates if the container is opened or closed by checking the joint position of the container.

Parameters:
  • object_designator – The object designator_description describing the object that should be opened or closed.

  • arm – The arm that should be used for opening or closing the container.

  • action_type – The type of the action that should be validated.

pycram.robot_plans.actions.core.container.check_opened(joint_obj: semantic_digital_twin.world_description.world_entity.Connection, obj_part: semantic_digital_twin.world_description.world_entity.Body, arm: pycram.datastructures.enums.Arms, upper_limit: float)#
pycram.robot_plans.actions.core.container.check_closed(joint_obj: semantic_digital_twin.world_description.world_entity.Connection, obj_part: semantic_digital_twin.world_description.world_entity.Body, arm: pycram.datastructures.enums.Arms, lower_limit: float)#
pycram.robot_plans.actions.core.container.OpenActionDescription#
pycram.robot_plans.actions.core.container.CloseActionDescription#