Skip to content
Sasi Sundar
ProjectsComplete

NYC Energy Star Score Predictor

A regression pipeline over the NYC 2016 Energy Benchmarking dataset. Five model families compared under cross-validation, the winner tuned by randomised search, then interpreted with LIME and a surrogate tree.

Records
9,535 raw / 9,253 cleaned
Train / holdout
6,477 / 2,776
Input features
43
Holdout MAE
8.6064
Holdout R²
0.824

Why I built it

Most student ML projects stop at model.fit() and a printed accuracy score. I wanted to build the second half properly: comparison, tuning, held-out evaluation, and interpretation. The interpretation is what found a bug the metrics never surfaced.

Architecture

  • Cleaning stage reducing 9,535 raw records to 9,253 usable rows across 43 input features.
  • A 70/30 train and holdout split with a fixed random seed.
  • Five regression families compared under 5-fold shuffled K-fold cross-validation.
  • A 40-trial randomised hyperparameter search over the winning family.
  • Interpretation layer: cumulative feature importance, a depth-3 surrogate decision tree, and three LIME case studies.
  • Metrics and tuned parameters persisted to a `model_meta.json` artifact rather than printed to a notebook cell.

Engineering decisions

Persist metrics to an artifact, not a notebook cell

A number that exists only in notebook output is a number you cannot cite later. Writing the final metrics and best parameters to `model_meta.json` meant every figure quoted anywhere else about this project can be checked against a file in the repository.

Interpretation as debugging, not decoration

The feature list revealed two columns for one borough, differing only by a trailing space in the source data. One-hot encoding an unstripped categorical had split that borough across two features. The cross-validation score never flinched. The interpretability layer is the only reason I found it.

What I learned

  • Interpretability tools earn their place as debugging instruments long before they become an ethics requirement.
  • A metric with no stored baseline is a metric you cannot defend in a conversation.
  • Comparing five model families costs an afternoon and removes all argument about the choice.

Stack

Pythonscikit-learnpandasLIMEmatplotlib