pycram.designator#
Exceptions#
Implementation of designator_description errors. |
|
Common base class for all non-exit exceptions. |
Classes#
Parent class of location designator_description descriptions. |
|
Class for object designator_description descriptions. |
|
Description for objects found via an EQL query. |
|
Description for objects with a specific name. |
Module Contents#
- exception pycram.designator.DesignatorError(*args, **kwargs)#
Bases:
ExceptionImplementation of designator_description errors.
- exception pycram.designator.ResolutionError(missing_properties: typing_extensions.List[str], wrong_type: typing_extensions.Dict, current_type: typing_extensions.Any, designator: DesignatorDescription)#
Bases:
ExceptionCommon base class for all non-exit exceptions.
- error = Multiline-String#
Show Value
""" Some required properties where missing or had the wrong type when grounding the Designator: Uninferable. """
- missing = Multiline-String#
Show Value
"""The missing properties where: Uninferable """
- wrong = Multiline-String#
Show Value
"""The properties with the wrong type along with the current -and right type : """
- head = Multiline-String#
Show Value
"""Property | Current Type | Right Type ------------------------------------------------------------- """
- tab = ''#
- message = Multiline-String#
Show Value
""" Some required properties where missing or had the wrong type when grounding the Designator: Uninferable. """
- class pycram.designator.DesignatorDescription#
- plan_node: pycram.plan.PlanNode = None#
The plan node to which this designator_description belongs.
- property plan: pycram.plan.Plan#
Returns the plan that this designator_description is part of.
- property robot_view: semantic_digital_twin.robots.abstract_robot.AbstractRobot#
Returns the robot that this designator_description is part of.
- property world: semantic_digital_twin.world.World#
Returns the world that this designator_description is part of.
- resolve()#
- ground() typing_extensions.Any#
Should be overwritten with an actual grounding function which infers missing properties.
- copy() DesignatorDescription#
- get_optional_parameter() typing_extensions.List[str]#
Returns a list of optional parameter names of this designator_description description.
- get_all_parameter() typing_extensions.List[str]#
Returns a list of all parameter names of this designator_description description.
- classmethod get_type_hints() typing_extensions.Dict[str, typing_extensions.Any]#
Returns the type hints of the __init__ method of this designator_description description.
- Returns:
- class pycram.designator.LocationDesignatorDescription#
Bases:
DesignatorDescription,pycram.datastructures.partial_designator.PartialDesignatorParent class of location designator_description descriptions.
- abstract ground() pycram.datastructures.pose.PoseStamped#
Find a location that satisfies all constrains.
- class pycram.designator.ObjectDesignatorDescription(names: typing_extensions.Optional[typing_extensions.List[str]] = None)#
Bases:
DesignatorDescription,pycram.datastructures.partial_designator.PartialDesignatorClass for object designator_description descriptions. Descriptions hold possible parameter ranges for object designators.
- names: typing_extensions.Optional[typing_extensions.List[str]] = None#
- ground() semantic_digital_twin.world_description.world_entity.Body#
Return the first object from the world that fits the description.
- Returns:
A executed object designator_description
- __iter__() typing_extensions.Iterator[semantic_digital_twin.world_description.world_entity.Body]#
Iterate through all possible objects fitting this description
- Yield:
A executed object designator_description
- flatten() typing_extensions.List#
- class pycram.designator.EQLObjectDesignator(eql_query)#
Bases:
DesignatorDescriptionDescription for objects found via an EQL query.
- eql_query#
- __iter__() typing_extensions.Iterator[semantic_digital_twin.world_description.world_entity.Body]#
- class pycram.designator.NamedObject(name: typing_extensions.Union[typing_extensions.Iterable[str], str])#
Bases:
ObjectDesignatorDescription,pycram.datastructures.partial_designator.PartialDesignatorDescription for objects with a specific name.
- __iter__() typing_extensions.Iterator[semantic_digital_twin.world_description.world_entity.Body]#
Iterate through all possible objects fitting this description
- Yield:
A executed object designator_description