children¶
Sub-tasks that serve as children to other tasks.
Note
The Child agent will be formalized in an upcoming release, until then these classes remain relatively undocumented as their design will likely change.
Classes:
|
Just a placeholder class for now to work with |
|
|
|
|
|
|
- class Wheel_Child(stage_block=None, fs=10, thresh=100, **kwargs)[source]¶
Bases:
autopilot.tasks.children.Child
Attributes:
STAGE_NAMES
PARAMS
HARDWARE
Methods:
noop
()end
()- STAGE_NAMES = ['collect']¶
- PARAMS = OrderedDict([ ('fs', {'tag': 'Velocity Reporting Rate (Hz)', 'type': 'int'}), ('thresh', {'tag': 'Distance Threshold', 'type': 'int'})])¶
- HARDWARE = { 'OUTPUT': <class 'autopilot.hardware.gpio.Digital_Out'>, 'WHEEL': <class 'autopilot.hardware.usb.Wheel'>}¶
- class Video_Child(cams=None, stage_block=None, start_now=True, **kwargs)[source]¶
Bases:
autopilot.tasks.children.Child
- Parameters
cams (dict, list) –
Should be a dictionary of camera parameters or a list of dicts. Dicts should have, at least:
{ 'type': 'string_of_camera_class', 'name': 'name_of_camera_in_task', 'param1': 'first_param' }
Attributes:
PARAMS
Methods:
start
()stop
()noop
()- PARAMS = OrderedDict([ ( 'cams', { 'tag': 'Dictionary of camera params, or list of dicts', 'type': ('dict', 'list')})])¶
- class Transformer(transform, operation: str = 'trigger', node_id=None, return_id='T', return_ip=None, return_port=None, return_key=None, router_port=None, stage_block=None, value_subset=None, forward_id=None, forward_ip=None, forward_port=None, forward_key=None, forward_what='both', **kwargs)[source]¶
Bases:
autopilot.tasks.children.Child
- Parameters
transform
operation (str) – either
“trigger”, where the last transform is a
Condition
and a trigger is returned to sender only when the return value of the transformation changes, or * “stream”, where each result of the transformation is returned to sender
return_id
return_ip
return_port
return_key
router_port (None, int) – If not
None
(default), spawn the node with a route port to receievestage_block
value_subset (str) – Optional - subset a value from from a dict/list sent to
l_process()
forward_what (str) – one of ‘input’, ‘output’, or ‘both’ (default) that determines what is forwarded
**kwargs
Methods:
noop
()l_process
(value)forward
([input, output])