robosuite.controllers.composite package#

Submodules#

robosuite.controllers.composite.composite_controller module#

class robosuite.controllers.composite.composite_controller.CompositeController(sim: MjSim, robot_model: RobotModel, grippers: Dict[str, GripperModel])#

Bases: object

This is the parent class for all composite controllers. If you want to develop an advanced version of your controller, you should subclass from this composite controller.

property action_limits#
get_control_dim(part_name)#
get_controller(part_name)#
get_controller_base_pose(controller_name)#
load_controller_config(part_controller_config, composite_controller_specific_config: Dict | None = None)#
name = 'BASIC'#
reset()#
run_controller(enabled_parts)#
set_goal(all_action)#
setup_action_split_idx()#
update_state()#
class robosuite.controllers.composite.composite_controller.HybridMobileBase(sim: MjSim, robot_model: RobotModel, grippers: Dict[str, GripperModel])#

Bases: CompositeController

property action_limits#
create_action_vector(action_dict)#

A helper function that creates the action vector given a dictionary

name = 'HYBRID_MOBILE_BASE'#
set_goal(all_action)#
class robosuite.controllers.composite.composite_controller.WholeBody(sim: MjSim, robot_model: RobotModel, grippers: Dict[str, GripperModel])#

Bases: CompositeController

property action_limits#

Returns the action limits for the whole body controller. Corresponds to each term in the action vector passed to env.step().

create_action_vector(action_dict: Dict[str, ndarray]) ndarray#
name = 'WHOLE_BODY_COMPOSITE'#
print_action_info()#
print_action_info_dict(name: str = '')#
set_goal(all_action)#
setup_action_split_idx()#

Action split indices for the underlying factorized controllers.

WholeBody controller takes in a different action space from the underlying factorized controllers for individual body parts.

setup_whole_body_controller_action_split_idx()#

Action split indices for the composite controller’s input action space.

WholeBodyIK composite controller takes in a different action space from the underlying factorized controllers.

update_state()#
class robosuite.controllers.composite.composite_controller.WholeBodyIK(sim: MjSim, robot_model: RobotModel, grippers: Dict[str, GripperModel])#

Bases: WholeBody

name = 'WHOLE_BODY_IK'#
robosuite.controllers.composite.composite_controller.register_composite_controller(target_class)#

robosuite.controllers.composite.composite_controller_factory module#

robosuite.controllers.composite.composite_controller_factory.is_part_controller_config(config: Dict)#

Checks if a controller config is a part config as a opposed to a composite controller config.

Parameters:

config (dict) – Controller configuration

Returns:

True if the config is in the for the arm-only, False otherwise

Return type:

bool

robosuite.controllers.composite.composite_controller_factory.load_composite_controller_config(controller: str | None = None, robot: str | None = None) Dict | None#

Utility function that loads the desired composite controller and returns the loaded configuration as a dict

Parameters:
  • controller – Name or path of the controller to load. If None, robot must be specified and we load the robot’s default controller in controllers/config/robots/. If specified, must be a valid controller name or path to a controller config file.

  • robot – Name of the robot to load the controller for.

Returns:

Controller configuration

Return type:

dict

Raises:

FileNotFoundError – If the controller file is not found

robosuite.controllers.composite.composite_controller_factory.refactor_composite_controller_config(controller_config, robot_type, arms)#

Checks if a controller config is in the format from robosuite versions <= 1.4.1. If this is the case, converts the controller config to the new composite controller config format in robosuite versions >= 1.5. If the robot has a default controller config use that and override the arms with the old controller config. If not just use the old controller config for arms.

Parameters:

old_controller_config (dict) – Old controller config

Returns:

New controller config

Return type:

dict

robosuite.controllers.composite.composite_controller_factory.validate_composite_controller_config(config: dict)#

Module contents#