utils.plotting
Utility methods for generating diagnostic plots from loggable variables.
- utils.plotting.spike_raster(data: Tensor, line_size: float = 0.25, events: _Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes] | Tensor = None, event_colors: _Buffer | _SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes] | Tensor = None) eventplot
- Generates a spike raster event plot from data. - Parameters:
- data (Tensor) – 2D binary integer tensor containing spike time series in the format units X steps. 
- line_size (float) – Controls spike event line size. 
- events (ArrayLike or Tensor) – Event timestamps w.r.t. X-axis. The raster will contain semi-transparent vertical bars at those locations. 
- event_colors (ArrayLike or Tensor) – Colors to use with vertical lines corresponding to event timestamps, given as a list where the i-th element is the color of the i-th vertical line.