YAML Metadata Warning:empty or missing yaml metadata in repo card
Check out the documentation for more information.
Transformer / LSTM Load Forecast
Short-term electrical load forecasting using a sequence model (LSTM or Transformer). Predicts the next time steps from a window of past load (and optionally other features).
Problem
Utilities need short-term load forecasts for unit commitment and balancing. This project trains a PyTorch model on historical load series to predict future values (e.g. next 24 hours from the last 168 hours).
Data
- Use public load datasets (e.g. UCI Electricity Load, ISO New England, or similar) or the provided synthetic CSV in
data/for a quick run. - Expected format: one column for load (and optionally date/time); script normalizes and builds sliding windows.
Model
- LSTM (default) consumes a fixed-length history and outputs a forecast horizon. Script args:
--seq_len,--horizon,--epochs,--data_path.
Files
model.pyโ LSTM;train.pyโ training and validation (synthetic series if no CSV);data/load_sample.csvโ sample data.
Usage
pip install -r requirements.txt
python train.py
For custom data, place a CSV with a load column and set --data_path. A small sample is in data/load_sample.csv; if the path is missing, the script falls back to synthetic data.
Metrics
- Mean Absolute Error (MAE) and Root Mean Squared Error (RMSE) on the test set.
- Optional: MAPE if values are strictly positive.
Limitations / future work
- Single series / single region; multi-region or multivariate inputs would require a different setup.
- No exogenous variables (temperature, holidays) in the minimal version; these can be added for better accuracy.
Author
Alireza Aminzadeh
- Email: alireza.aminzadeh@hotmail.com
- Hugging Face: syeedalireza
- LinkedIn: alirezaaminzadeh
Inference Providers NEW
This model isn't deployed by any Inference Provider. ๐ Ask for provider support