concepts.dm.crowhat.impl.pybullet.pybullet_sim_interfaces.PyBulletSimulationControllerInterface#

class PyBulletSimulationControllerInterface[source]#

Bases: CrowSimulationControllerInterface

Methods

get_action_counter()

get_crow_state()

Get the state of the simulation interface.

increment_action_counter()

reflex(controller_name[, reflex_name])

register_controller(name, function)

register_reflex(controller_name, ...[, priority])

register_state_getter(state_getter)

reset()

reset_action_counter()

restore_context([verbose])

restore_state(state_identifier, **kwargs)

restore_state_keep(state_identifier[, ...])

save_state(**kwargs)

step(action, **kwargs)

step_internal(name, *args, **kwargs)

step_with_saved_state(action, **kwargs)

Step with saved state.

step_without_error(action, **kwargs)

Attributes

__init__(bullet_client, mplib_client=None)[source]#
Parameters:
__new__(**kwargs)#
get_action_counter()#
Return type:

int

get_crow_state()[source]#

Get the state of the simulation interface.

Return type:

CrowState

increment_action_counter()#
reflex(controller_name, reflex_name=None)#
Parameters:
register_controller(name, function)[source]#
Parameters:
register_reflex(controller_name, reflex_name, function, priority=10)#
Parameters:
register_state_getter(state_getter)[source]#
Parameters:

state_getter (Callable[[PyBulletSimulationControllerInterface], CrowState])

reset()[source]#
reset_action_counter()#
restore_context(verbose=False, **kwargs)#
Parameters:

verbose (bool)

restore_state(state_identifier, **kwargs)[source]#
Parameters:

state_identifier (int)

restore_state_keep(state_identifier, action_counter=None, **kwargs)[source]#
Parameters:
  • state_identifier (int)

  • action_counter (int | None)

save_state(**kwargs)[source]#
Return type:

int

step(action, **kwargs)#
Parameters:

action (CrowControllerApplier)

Return type:

None

step_internal(name, *args, **kwargs)#
Parameters:

name (str)

Return type:

bool | None

step_with_saved_state(action, **kwargs)#

Step with saved state. If the execution fails, return False and the state identifier.

Parameters:

action (CrowControllerApplier) – the action to take.

Returns:

whether the execution is successful. int: the state identifier.

Return type:

bool

step_without_error(action, **kwargs)#
Parameters:

action (CrowControllerApplier)

Return type:

bool

property bullet_client#
property controller_reflexes: Dict[Tuple[str, str], CrowControllerReflex]#
property controllers: Dict[str, Callable]#
property executor: CrowExecutor | None#
property mplib_client#
property saved_states#