diff --git a/python/mujinplanningclient/binpickingplanningclient.py b/python/mujinplanningclient/binpickingplanningclient.py index e6affbd..cd0ec82 100644 --- a/python/mujinplanningclient/binpickingplanningclient.py +++ b/python/mujinplanningclient/binpickingplanningclient.py @@ -69,7 +69,7 @@ def PickAndPlace( worksteplength=None, densowavearmgroup=5, regionname=None, - cameranames=None, + sensorSelectionInfos=None, envclearance=None, toolname=None, robotspeed=None, @@ -92,7 +92,7 @@ def PickAndPlace( worksteplength (float, optional): planning parameter densowavearmgroup (int, optional): planning parameter (Default: 5) regionname (str, optional): name of the region of the objects - cameranames (list[str], optional): The names of the cameras to avoid occlusions with the robot + sensorSelectionInfos (list[dict[str, str]], optional): The sensorSelectionInfo configs of the cameras to avoid occlusions with the robot. envclearance (float, optional): Environment clearance in millimeters. toolname (str, optional): Name of the manipulator. Defaults to currently selected tool robotspeed (float, optional): Value in (0,1] defining the percentage of speed the robot should move at. @@ -165,7 +165,7 @@ def StartPickAndPlaceThread( robotspeed (float, optional): Value in (0,1] defining the percentage of speed the robot should move at. timeout (float, optional): Time in seconds after which the command is assumed to have failed. (Default: 10) densowavearmgroup (int, optional): robot parameters (Default: 5) - cameranames (list[str], optional): the names of the cameras to avoid occlusions with the robot + sensorSelectionInfos (list[dict[str, str]], optional): The sensorSelectionInfo configs of the cameras to avoid occlusions with the robot. cycledests (int, optional): When finished cycling through all destikparamnames, will delete all the targets and start from the first index again doing this for cycledests times. By default it is 1. desttargetname (str, optional): The destination target name where the destination goal ikparams come from destikparamnames (list[list[str]], optional): A list of lists of ikparam names for the ordered destinations of the target. destikparamnames[0] is where the first picked up part goes, desttargetname[1] is where the second picked up target goes. @@ -348,12 +348,15 @@ def MoveToDropOff(self, dropOffInfo, robotname=None, robotspeed=None, robotaccel taskparameters.update(kwargs) return self.ExecuteCommand(taskparameters, robotname=robotname, robotspeed=robotspeed, robotaccelmult=robotaccelmult, timeout=timeout) - def IsRobotOccludingBody(self, bodyname, cameraname, timeout=10, **kwargs): + def IsRobotOccludingBody(self, bodyname, sensorSelectionInfo, timeout=10, **kwargs): """returns if the robot is occluding body in the view of the specified camera Args: bodyname: Name of the object - cameraname: Name of the camera + sensorSelectionInfo (dict[str, str]): A dictionary with the structure: + + - sensorName (str): Name of the sensor body + - sensorLinkName (str): Name of the sensor link timeout (float, optional): Time in seconds after which the command is assumed to have failed. (Default: 10) Returns: @@ -364,7 +367,7 @@ def IsRobotOccludingBody(self, bodyname, cameraname, timeout=10, **kwargs): taskparameters = { 'command': 'IsRobotOccludingBody', 'bodyname': bodyname, - 'cameraname': cameraname, + 'sensorSelectionInfo': sensorSelectionInfo, } taskparameters.update(kwargs) return self.ExecuteCommand(taskparameters, timeout=timeout) @@ -428,7 +431,7 @@ def MoveRobotOutOfCameraOcclusion(self, regionname=None, robotspeed=None, toolna robotspeed (float, optional): Value in (0,1] defining the percentage of speed the robot should move at. toolname (str, optional): Name of the manipulator. Defaults to currently selected tool timeout (float, optional): Time in seconds after which the command is assumed to have failed. (Default: 10) - cameranames (list[str], optional): The names of the cameras to avoid occlusions with the robot + sensorSelectionInfos (list[dict[str, str]], optional): The sensorSelectionInfo configs of the cameras to avoid occlusions with the robot. """ if regionname is None: regionname = self.regionname diff --git a/python/mujinplanningclient/realtimerobotplanningclient.py b/python/mujinplanningclient/realtimerobotplanningclient.py index 571f0d6..e8e9b1e 100644 --- a/python/mujinplanningclient/realtimerobotplanningclient.py +++ b/python/mujinplanningclient/realtimerobotplanningclient.py @@ -327,7 +327,7 @@ def UpdateObjects( object_uri (str, optional): Same as objectname, but in a Mujin URI format, e.g.: mujin:/OBJECTNAME.mujin.dae detectionResultState (dict, optional): Information about the detected objects (received from detectors) targetUpdateNamePrefix (str, optional): - cameranames (list[str], optional): + sensorSelectionInfos (list[dict[str, str]], optional): The sensorSelectionInfo configs of the cameras to avoid occlusions with the robot. countOverlappingPoints (bool, optional): overlapUpAxis (list[float], optional): Values of ['x', 'y', 'z'] correspondingly. zthresholdmult (float, optional):