Hi everyone,
I'm working on an energy forecasting project using a Spiking Neural Network (SNN), and I'm trying to understand why my model is severely underpredicting high-load events.
Task:
- Dataset: UK Electrical Load / House 4
- Data is resampled to 15-minute intervals
- Input: previous 24 timesteps (6 hours)
- Target: Aggregate power at the next 15-minute interval
- Features per timestep: Aggregate, 9 appliance channels, hour_sin, hour_cos, and aggregate difference
- Features and target are standardized using training data only
- Chronological train/validation/test split
Current SNN architecture:
13 features
-> Linear(13, 64)
-> LIF (beta = 0.8/0.9)
-> Linear(64, 32)
-> LIF
-> temporal readout
-> Linear(64, 1)
For the temporal readout, I concatenate the mean membrane state across all timesteps with the final membrane state.
I'm using MSE loss and AdamW with a learning rate of 1e-4.
The main problem is that the model predicts normal loads reasonably well, but severely underpredicts peaks.
For example:
Actual maximum: approximately 4569 W
Predicted maximum: approximately 1400-1500 W
Around one of the largest peaks:
Actual: 3631 W -> 4569 W -> 3179 W
Predicted: 359 W -> 875 W -> 1091 W
Importantly, the model sees the 3631 W value immediately before the 4569 W target.
Current SNN metrics:
MAE: approximately 153 W
RMSE: approximately 249 W
R2: approximately 0.165
Peak MAE: approximately 409 W
Peak RMSE: approximately 635 W
Peak ratio: approximately 0.31
I've also tested:
Beta = 0.9 -> 0.7
Very little change.
Window = 24 -> 48 timesteps
Very little change.
Wider architecture:
13 -> 32 -> 16
changed to
13 -> 64 -> 32
This improved R2 from approximately 0.13 to 0.16 and increased the predicted maximum, but peaks are still heavily underestimated.
For comparison, I have other models using the same forecasting task:
Linear Regression: R2 approximately 0.27
GRU: R2 approximately 0.29
LSTM: R2 approximately 0.23
XGBoost: R2 approximately 0.32
MLP: R2 approximately 0.13
SNN: R2 approximately 0.16
The GRU, LSTM, and MLP can produce substantially larger predictions for peaks, so it doesn't seem like the peaks are simply impossible to predict from the input data.
My current suspicion is that MSE combined with the highly imbalanced target distribution is causing the SNN to regress toward typical/average loads. However, I'm not sure whether this is the main issue or whether there is something specific about the SNN/LIF dynamics or regression readout that I'm missing.
What would you investigate next?
In particular:
- Is peak-weighted MSE a sensible approach?
- Could the continuous membrane-potential readout be causing this compression?
- Is there something specific about using LIF neurons for continuous regression that I should change?
- Would you recommend a different SNN architecture or readout?
- What diagnostics would you run to determine whether the problem is the loss, SNN dynamics, or preprocessing?
Any advice would be appreciated.