robokudo.object_knowledge_base¶
Object knowledge base for RoboKudo.
This module provides classes for storing and managing knowledge about objects in RoboKudo. It includes support for object components, features, and their spatial relationships.
Classes¶
Knowledge representation for a single object. |
|
Base class for managing object knowledge. |
Module Contents¶
- class robokudo.object_knowledge_base.ObjectKnowledge¶
-
Bases:
robokudo.defs.Region3DWithNameKnowledge representation for a single object.
This class extends Region3DWithName to add support for object components and features. Each object can have multiple components (physical parts) and features (characteristics).
- Variables:
-
components – List of component objects that make up this object
features – List of features associated with this object
- components: List[Any] = []¶
- features: List[Any] = []¶
- is_frame_in_camera_coordinates()¶
- class robokudo.object_knowledge_base.BaseObjectKnowledgeBase¶
-
Base class for managing object knowledge.
This class provides functionality to store and manage knowledge about different objects. Each object is stored as an ObjectKnowledge instance and can be accessed by its name.
- entries: Dict[str, ObjectKnowledge]¶
- add_entry(entry)¶
-
Add a single object knowledge entry.
- Parameters:
-
entry (ObjectKnowledge) – The object knowledge entry to add
- Raises:
-
Exception – If the entry has no name attribute
- add_entries(entries: list)¶
-
Add multiple object knowledge entries.
- Parameters:
-
entries (list[ObjectKnowledge]) – List of object knowledge entries to add
- static has_parthood_childs(object_knowledge: ObjectKnowledge) bool¶
-
Check if an object has any components or features.
- Parameters:
-
object_knowledge (ObjectKnowledge) – The object knowledge to check
- Returns:
-
True if the object has components or features
- Return type:
-
bool