tsa_project / README.md
cloud450's picture
Update README.md
1eda1cf verified

A newer version of the Gradio SDK is available: 6.15.2

Upgrade
metadata
title: Transformer Oil Temperature Forecaster
emoji: 
colorFrom: red
colorTo: blue
sdk: gradio
sdk_version: 6.12.0
app_file: app.py
pinned: false

⚡ Transformer Oil Temperature Forecaster

ARIMAX · Anomaly Detection · Time Series Analysis

Upload ETT-style transformer CSV data and get:

Feature Details
Model ARIMAX — auto-selects best (p, d, q) via AIC grid search
Endog OT — oil temperature
Exog HUFL, HULL, MUFL, MULL, LUFL, LULL — load features
Stationarity ADF test; auto-applies 1st differencing if needed
Anomaly Detection Residual-based, threshold = mean ± 2.5σ
Evaluation MAE + RMSE on 20% hold-out set

📂 Expected CSV Format

date,HUFL,HULL,MUFL,MULL,LUFL,LULL,OT
2016-07-01 00:00:00,5.827,2.009,1.599,0.462,4.203,1.340,30.531
...

The ETT (Electricity Transformer Temperature) dataset works out of the box.
Download it from: https://github.com/zhouhaoyi/ETDataset


🚀 Running Locally

pip install -r requirements.txt
python app.py

📐 Architecture

CSV Upload
    │
    ▼
load_data()          ← parse datetime index, ffill missing
    │
    ▼
check_stationarity() ← ADF test → d value
    │
    ▼
train_arimax()       ← grid search (p,q) on 80% train split
    │
    ├──► forecast()          ← out-of-sample N steps
    │
    └──► detect_anomalies()  ← residual threshold flagging