Institutional buildings consume large amounts of electricity, but energy data is often difficult to monitor continuously. Abnormal consumption may go unnoticed, and daily energy planning is usually based on manual observation or fixed assumptions.

We were inspired to build a system that could continuously monitor real energy usage from an institutional electricity meter and turn that data into useful decisions. The goal was not only to display energy consumption, but also to identify unusual patterns, forecast future demand, and help reduce avoidable energy waste.

What the project does

Iot Based Energy Monetring is an AI-powered energy-monitoring and forecasting system for institutional buildings.

The system collects live energy data for Device 153, stores both predicted and actual consumption, detects abnormal daily profiles, and generates daily-total and 24-hour hourly forecasts.

The dashboard displays:

  • Current and historical energy consumption
  • Daily and hourly predictions
  • Actual-versus-predicted values
  • Prediction errors
  • Anomaly scores and explanations
  • Collector health and data quality
  • Model performance metrics
  • Automatic energy-use suggestions

The system uses completed hourly measurements and deliberately ignores future placeholder zeros so that incomplete days do not corrupt the anomaly-detection model.

How we built it

The system has four main parts:

  1. Live data collection
    Energy data is retrieved from the institutional HTTP APIs every 15 minutes.

  2. Data validation and storage The collector validates hourly and daily responses, identifies incomplete data, and stores the results in persistent CSV and JSON files.

  3. AI analysis and forecasting
    The system uses clustering for anomaly detection, Ridge regression and profile-based forecasting for daily predictions, and adaptive hourly profiles with feedback corrections.

  4. Cloud dashboard
    GitHub Actions runs the collector in the cloud, while GitHub Pages hosts a public dashboard. The laptop does not need to remain switched on.

The forecast error is calculated as:

$$ \text{Prediction Error} = \text{Actual Consumption} - \text{Predicted Consumption} $$

These errors are stored and used to make bounded corrections to future forecasts.

What we learned

During development, we learned how to:

  • Work with real-world HTTP APIs
  • Handle incomplete and inconsistent sensor data
  • Process timestamps in India Standard Time
  • Avoid treating future-hour placeholder zeros as real measurements
  • Build time-series forecasting features
  • Evaluate predictions using MAE, RMSE, bias, and confidence coverage
  • Deploy an automated Python data pipeline using GitHub Actions
  • Build a public frontend using JavaScript and GitHub Pages
  • Separate live production data from source code using a dedicated data branch

Challenges we faced

The biggest challenge was that the meter dashboard provided partial-day data while the anomaly model required complete 24-hour profiles. We solved this by waiting for completed cycles and marking incomplete days separately.

Another challenge was ensuring that predicted values and actual values were matched correctly after the forecast period ended. We implemented a feedback loop that compares both values, records the error, and applies only bounded corrections to future forecasts.

We also had to solve data-publication and synchronization issues between the cloud collector and dashboard. The final architecture publishes validated snapshots to a dedicated live-data branch, which the dashboard reads automatically.

Real-world impact

Iot Based Energy Monetring can help institutions:

  • Detect unusual energy consumption earlier
  • Identify hours with excessive usage
  • Plan electricity demand more effectively
  • Reduce avoidable energy waste
  • Monitor whether energy-saving actions are working
  • Build a data-driven sustainability culture

The system is designed to be low-cost and does not require a continuously running laptop or local server.

Share this project:

Updates

Submission history