Skip to content

Horizontal

HorizontalLayer

Bases: LayerBase

plot_activations(xtitle='Neuron', ytitle='Activation', width=1000)

Return a scatter plot of the activations of this layer's neurons.

Parameters:

Name Type Description Default
xtitle str

Title for the x axis.

'Neuron'
ytitle str

Title for the y axis.

'Activation'
width int

Plot width.

1000

Returns:

Type Description
figure

A Bokeh figure.

record_activations(fpath, vl=None)

Record the neuron activations.

Parameters:

Name Type Description Default
fpath Path

The file to save the recording to.

required
vl VideoLoader | None

An optional VideoLoader instance.

None

Returns:

Type Description
VideoRecorder

A VideoRecorder instance.

record_feedback(fpath, vl=None)

Record the feedback signal from the neurons.

Parameters:

Name Type Description Default
fpath Path

The file to save the recording to.

required
vl VideoLoader | None

An optional VideoLoader instance.

None

Returns:

Type Description
VideoRecorder

A VideoRecorder instance.

visualise_norm_input(signal)

Visualise the input normalised by the feedback of the horizontal cells.

Parameters:

Name Type Description Default
signal ndarray

The input signal.

required

Returns:

Type Description
CommsHandle | None

The normalised input.