spinn_front_end_common.utilities.scp package¶
Module contents¶
- class spinn_front_end_common.utilities.scp.ClearIOBUFProcess(next_connection_selector: ConnectionSelector, n_retries: int = 10, timeout: float = 1.0, n_channels: int = 8, intermediate_channel_waits: int = 7, non_fail_retry_codes: Set[SCPResult] | None = None)¶
Bases:
AbstractMultiConnectionProcess
[CheckOKResponse
]How to clear the IOBUF buffers of a set of cores.
Note
The cores must be using the simulation interface.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.
- clear_iobuf(core_subsets: CoreSubsets, n_cores: int | None = None) None [source]¶
- Parameters:
core_subsets (CoreSubsets)
n_cores (int) – Defaults to the number of cores in core_subsets.
- class spinn_front_end_common.utilities.scp.GetCurrentTimeProcess(connection_selector: MostDirectConnectionSelector)¶
Bases:
AbstractMultiConnectionProcess
[_GetCurrentTimeResponse
]How to update the target running time of a set of cores.
Note
The cores must be using the simulation interface.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.
- get_latest_runtime(n_cores: int, core_subsets: CoreSubsets) int | None [source]¶
- Parameters:
core_subsets (CoreSubsets)
n_cores (int) – Number of cores being updated
- class spinn_front_end_common.utilities.scp.LoadMCRoutesProcess(next_connection_selector: ConnectionSelector, n_retries: int = 10, timeout: float = 1.0, n_channels: int = 8, intermediate_channel_waits: int = 7, non_fail_retry_codes: Set[SCPResult] | None = None)¶
Bases:
AbstractMultiConnectionProcess
[CheckOKResponse
]How to send messages to load the saved multicast routing tables.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.
- load_application_mc_routes(core_subsets: CoreSubsets) None [source]¶
Load the saved application multicast routes.
- Parameters:
core_subsets (CoreSubsets) – sets of cores to send command to
- load_system_mc_routes(core_subsets: CoreSubsets) None [source]¶
Load the saved system multicast routes.
- Parameters:
core_subsets (CoreSubsets) – sets of cores to send command to
- class spinn_front_end_common.utilities.scp.ReinjectorControlProcess(next_connection_selector: ConnectionSelector, n_retries: int = 10, timeout: float = 1.0, n_channels: int = 8, intermediate_channel_waits: int = 7, non_fail_retry_codes: Set[SCPResult] | None = None)¶
Bases:
AbstractMultiConnectionProcess
How to send messages to the packet reinjection system.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.
- clear_queue(core_subsets: CoreSubsets) None [source]¶
Clear the reinjection queue.
- Parameters:
core_subsets (CoreSubsets)
- get_reinjection_status(x: int, y: int, p: int) ReInjectionStatus [source]¶
Get the reinjection status of a particular monitor.
- Parameters:
- Return type:
- get_reinjection_status_for_core_subsets(core_subsets: CoreSubsets) Dict[Chip, ReInjectionStatus] [source]¶
Get the reinjection status of a collection of monitors.
- Parameters:
core_subsets (CoreSubsets)
- Return type:
- reset_counters(core_subsets: CoreSubsets) None [source]¶
Reset the packet counters.
- Parameters:
core_subsets (CoreSubsets)
- set_packet_types(core_subsets: CoreSubsets, point_to_point: bool, multicast: bool, nearest_neighbour: bool, fixed_route: bool) None [source]¶
Set what types of packets should be reinjected.
- Parameters:
core_subsets (CoreSubsets) – sets of cores to send command to
point_to_point (bool) – If point-to-point should be set
multicast (bool) – If multicast should be set
nearest_neighbour (bool) – If nearest neighbour should be set
fixed_route (bool) – If fixed route should be set
- set_wait1_timeout(mantissa: int, exponent: int, core_subsets: CoreSubsets) None [source]¶
The wait1 timeout is the time from when a packet is received to when emergency routing becomes enabled.
- Parameters:
mantissa (int) – Timeout mantissa (0 to 15)
exponent (int) – Timeout exponent (0 to 15)
core_subsets (CoreSubsets) – Where the extra monitors that manage the routers are located.
- set_wait2_timeout(mantissa: int, exponent: int, core_subsets: CoreSubsets) None [source]¶
The wait2 timeout is the time from when a packet has emergency routing enabled for it to when it is dropped.
- Parameters:
mantissa (int) – Timeout mantissa (0 to 15)
exponent (int) – Timeout exponent (0 to 15)
core_subsets (CoreSubsets) – Where the extra monitors that manage the routers are located.
- class spinn_front_end_common.utilities.scp.SendPauseProcess(next_connection_selector: ConnectionSelector, n_retries: int = 10, timeout: float = 1.0, n_channels: int = 8, intermediate_channel_waits: int = 7, non_fail_retry_codes: Set[SCPResult] | None = None)¶
Bases:
AbstractMultiConnectionProcess
[CheckOKResponse
]Send pause to a set of cores
Note
The cores must be using the simulation interface.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.
- send_pause(core_subsets: CoreSubsets, n_cores: int) None [source]¶
- Parameters:
core_subsets (CoreSubsets)
n_cores (int) – Number of cores being updated
- class spinn_front_end_common.utilities.scp.UpdateRuntimeProcess(next_connection_selector: ConnectionSelector, n_retries: int = 10, timeout: float = 1.0, n_channels: int = 8, intermediate_channel_waits: int = 7, non_fail_retry_codes: Set[SCPResult] | None = None)¶
Bases:
AbstractMultiConnectionProcess
[CheckOKResponse
]How to update the target running time of a set of cores.
Note
The cores must be using the simulation interface.
- Parameters:
next_connection_selector (ConnectionSelector) – How to choose the connection.
n_retries (int) – The number of retries of a message to use. Passed to
SCPRequestPipeLine
timeout (float) – The timeout, in seconds. Passed to
SCPRequestPipeLine
n_channels (int) – The maximum number of channels to use when talking to a particular SCAMP instance. Passed to
SCPRequestPipeLine
intermediate_channel_waits (int) – The maximum number of outstanding message/reply pairs to have on a particular connection. Passed to
SCPRequestPipeLine
non_fail_retry_codes (Optional[Set[SCPResult]]) – Optional set of responses that result in retry but after retrying don’t then result in failure even if returned on the last call.