devices.xylo.syns63300.cycles_model

devices.xylo.syns63300.cycles_model(config: XyloConfiguration, input_sp: float | ndarray | Tensor | array = 1.0, hidden_sp: float | ndarray | Tensor | array = 1.0, output_sp: float | ndarray | Tensor | array = 1.0) float[source]

Calculate the average number of cycles required for a given network architecture

This function contains a model which estimates the number of master clock cycles required for the Xylo SNN SYNS61202 inference core to compute one time-step for a given chip configuration in config. Use devices.xylo.syns61201.config_from_specification() to obtain a chip configuration, along with Module.as_graph() and devices.xylo.syns61201.mapper(), as described in the deployment tutorials for Xylo.

By default the model provides a β€œworst-case” estimation, assuming that every neuron and every input channel fire on each time-step. If desired, real input rasters and real hidden and output spike rasters can be provided for analysis. Alternative spiking probabilities can also be provided as floats 0..1.

Note that when estimating spiking probablility, only boolean values are relevant β€” either a spike or no spike per time step per channel. Multiple events per bin cost the same as a single event.

Parameters:
  • config (XyloIMUConfig) – A Xylo IMU configuration for which to calculate the cycle requirements

  • input_sp (FloatVector) – Either a floating-point number 0..1, specifying the average input firing rate, or an actual input spike raster to use in evaluation. Default: 1.0; estimate a worst-case scenario

  • hidden_sp (FloatVector) – Either a floating-point number 0..1, specifying the average hidden neuron firing rate, or an actual hidden spike raster to use in evaluation. Default: 1.0; estimate a worst-case scenario

  • output_sp (FloatVector) – Either a floating-point number 0..1, specifying the average output neuron firing rate, or an actual output spike raster to use in evaluation. Default: 1.0; estimate a worst-case scenario

Returns:

The average number of master clock cycles required for this configuration, for the Xylo SNN core to compute one network dt

Return type:

float