Closed florent-lamiraux closed 4 years ago
We already planned paths for scenarios with objects (like a tool) with grippers and handles. We always managed to generate the graph using rules (I think, but we may also have modified the generated graph).
Out of curiosity, what is the case that requires you to add this function ?
The use case is a forklift that is required to stack boxes on top of each other.
Then, there is a bug in the Python factory. Normally, an object that is not grasped cannot be moved so box1 should not be movable.
I would not call that a bug. Method ConstraintGraphFactory._recurse does not make any difference between objects and robots. As it is implemented now, it requests "box1/top" to grasp "box2/bottom" without realizing that "box1" is an object.
After an oral discussion, the problem is that the graph contains infeasible transition (they are truly infeasible) rather that not generating them.
https://github.com/humanoid-path-planner/hpp-manipulation-corba/blob/2f1c5592ac21218c377fd008f79adf14518569fa/src/hpp/corbaserver/manipulation/constraint_graph_factory.py#L296 I think we should add a call to a new method called "transitionIsAllowed" here to filter out transitions where an object moves without being grasps. This happens when stacking boxes equipped with grippers and handles.