pub struct SpikeNetFixedConfig {Show 15 fields
pub n_input: usize,
pub n_hidden: usize,
pub n_output: usize,
pub alpha: i16,
pub kappa: i16,
pub kappa_out: i16,
pub eta: i16,
pub v_thr: i16,
pub gamma: i16,
pub spike_threshold: i16,
pub seed: u64,
pub weight_init_range: i16,
pub use_astrocyte: bool,
pub astrocyte_tau: f64,
pub astrocyte_mode: AstrocyteMode,
}alloc only.Expand description
Configuration for a SpikeNetFixed network.
All Q1.14 parameters should be in the range [-2.0, +2.0) when converted
from f64 via f64_to_q14(). Typical defaults:
| Parameter | f64 | Q1.14 |
|---|---|---|
| alpha | 0.95 | 15565 |
| kappa | 0.99 | 16220 |
| kappa_out | 0.90 | 14746 |
| eta | 0.001 | 16 |
| v_thr | 0.50 | 8192 |
| gamma | 0.30 | 4915 |
| spike_threshold | 0.05 | 819 |
Fields§
§n_input: usizeNumber of raw input features (encoded to 2x for spike channels).
Number of hidden LIF neurons.
n_output: usizeNumber of output readout neurons.
alpha: i16Membrane decay factor in Q1.14.
kappa: i16Eligibility trace decay factor in Q1.14.
kappa_out: i16Readout membrane decay factor in Q1.14.
eta: i16Learning rate in Q1.14.
v_thr: i16Firing threshold in Q1.14.
gamma: i16Surrogate gradient dampening factor in Q1.14.
spike_threshold: i16Delta encoding threshold in Q1.14.
seed: u64PRNG seed for reproducible weight initialization.
weight_init_range: i16Weight initialization range: weights sampled from [-range, +range] in Q1.14.
use_astrocyte: boolEnable astrocyte-gated modulation of input weights.
astrocyte_tau: f64Astrocyte EWMA time constant (higher = slower adaptation). Default: 1000.
astrocyte_mode: AstrocyteModeAstrocyte gating mode (only used when use_astrocyte is true).
WeightMod (default): scales forward-pass input weights.
LearningRateGate: scales the per-neuron learning rate during updates
(Dong & He 2025, Frontiers Neurosci, Eq. 4 – AGMP proper).
Trait Implementations§
Source§impl Clone for SpikeNetFixedConfig
impl Clone for SpikeNetFixedConfig
Source§fn clone(&self) -> SpikeNetFixedConfig
fn clone(&self) -> SpikeNetFixedConfig
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for SpikeNetFixedConfig
impl Debug for SpikeNetFixedConfig
Auto Trait Implementations§
impl Freeze for SpikeNetFixedConfig
impl RefUnwindSafe for SpikeNetFixedConfig
impl Send for SpikeNetFixedConfig
impl Sync for SpikeNetFixedConfig
impl Unpin for SpikeNetFixedConfig
impl UnsafeUnpin for SpikeNetFixedConfig
impl UnwindSafe for SpikeNetFixedConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more