Open bauerfe opened 2 years ago
@bauerfe this is now fixed right?
No. Looks like this one got overlooked. Would you like me to take care of it?
Perhaps not now. Since this is not a feature that exists on speck, I would say this is low priority.
After discussion among sinabs developers: The current behavior is good as it is now. However, it should be described properly in the docstrings (and documentation).
Currently the shape of time constant parameters (
alpha_xxx
ortau_xxx
) in theLIF
layer is determined by what has been provided during class instantiation.If a user wants individual time constants (one per neuron), they have to provide a tensor with corresponding shape.
I suggest introducing an additional option,
individual_time_constants
. When it is set toTrue
, the time constants of the layer will be expanded to the number of neurons (without batch size). when callingforward
. This makes it possible to train time constants on a per-neuron base, while still having the comfort of just passing a scalar initial value at instantiation.When the new parameter is
False
(default), the behavior is the same as now.