Skip to content
Jossue Sarango
All projects

DataCool: Data Center Optimization

I built a machine learning system that predicts which data center racks will overheat and plans workload moves to cool them, winning 1st place at the Claude NJIT Hackathon.

1st Place · Claude NJIT Hackathon · Newark, NJ

  • Python
  • scikit-learn
  • SHAP
  • Streamlit
  • Three.js

The Challenge

Data center cooling is mostly reactive. Static temperature thresholds and manual intervention mean a thermal spike usually shows up as hardware failure, or as cooling capacity that was over-provisioned just to be safe. The question we set out to answer at the Claude NJIT Hackathon in Newark was twofold: (1) can we predict which racks will overheat before they do, and (2) once we know, can we automatically generate a workload-migration plan that respects thermal physics, migration cost, and capacity limits?

We had 4 hours, and I worked on a team of four with Yahil, Guru, and Sergio. In that time we built the whole loop end to end: predict, optimize, and show the result.

The team brainstorming at the hackathon

The Data and the Model

We did not have access to a real data center, so the system simulates one. It generates 20 to 30 racks with correlated features (CPU load, temperature, network usage, and power draw), places them in hot and cold aisle zones, and gives each rack a position so adjacency can be calculated. A rack counts as a hotspot when CPU is above 80% and temperature is above 70°C. That also means the 94% accuracy is measured on synthetic data with correlations we wrote ourselves, and I would not claim it carries over to a real facility untouched.

For the classifier we used scikit-learn's Histogram Gradient Boosting model. The project README lists XGBoost, LightGBM, and a small neural network (an MLP classifier) as drop-in swaps, so the model is easy to replace. Each rack gets a risk score, and the optimizer works from that ranking.

We also added SHAP, which attributes each prediction to the features that drove it. It kept the model out of black-box territory, and on a critical path an explainable 94% beats an opaque 96%.

The thermal visualizer
The data center during optimization

The Optimizer

A risk score alone does not cool anything, so the second half of the system turns predictions into a plan. It is a constraint-satisfaction approach that balances three things pulling against each other: thermal physics, migration cost, and capacity limits. The steps run in order. First, sort the racks by predicted risk. Next, find candidate receivers, meaning racks with low CPU and low temperature. Then calculate the workload transfers that minimize cost times distance. Finally, simulate the thermal result and check it against the constraints.

Moving load is not free, so we priced it. A transfer costs 0.5 units per percentage point of CPU moved, with a distance penalty of 1.0 plus 0.2 times the Manhattan distance between racks. The thermal model also includes coupling between adjacent racks, because heat does not stay inside one cabinet. The coefficients (temperature per percent CPU, adjacency coupling, cost per percent) are constants at the top of the main file so they can be tuned.

The Build

Everything is Python. scikit-learn provides the model, SHAP the explanations, and scipy.optimize and numpy the optimization and simulation. The interface is a Streamlit dashboard, which let us get a working UI without writing a front end, with Three.js and Plotly behind interactive 3D and 2D temperature heatmaps. The dashboard shows the racks before optimization, during it, and after, plus the migration plan itself, so a judge can watch the heat map change instead of taking a number on faith.

The code is split into a main application file, datacenter_ai_enhanced.py, and sim.py, which is the original prototype. Since SHAP can be slow, the dashboard lets you switch it off or reduce the rack count.

The data center after optimization

The Results

On a typical run the model reached 94% prediction accuracy, and the optimizer cut hotspots from 4 to 1, a 75% reduction. Peak rack temperature dropped from 78.3°C to 71.2°C, power from 125.4 kW to 123.8 kW, and the plan cost 47.3 units, within budget. These are simulation results, not a measurement on live hardware.

We won 1st place at the Claude NJIT Hackathon 2025. The code is on GitHub, and the next steps we wrote down were time-series forecasting with LSTM or GRU models, real-time monitoring over WebSockets, multi-objective optimization across temperature, power, and latency, and network topology constraints.

What I Learned

  • Constraint satisfaction is a balancing act — thermal physics pulls against migration cost and capacity, and the optimizer is only as good as how you price the tradeoff.
  • SHAP kept the model out of black-box territory; on a critical path, an explainable 94% beats an opaque 96%.

Let's make something amazing.