Skip to content

Repository files navigation

Cooling Loop Dashboard

A local Streamlit dashboard for exploring synthetic cooling-loop sensor data and calculating basic thermal performance. It accepts CSV files created by sensor-stream-simulator.

Why I built it

I built this project while preparing to study mechanical engineering at Case Western Reserve University. It helped me connect thermal equations and sensor measurements with data validation, interactive charts, warning logic, and a tested local interface.

Features

  • Upload a compatible CSV or select one of three included synthetic datasets
  • Current operating summary and responsive time-series charts
  • Inlet/outlet temperature, temperature difference, flow, pressure drop, pump speed, and calculated heat-removal views
  • Optional display, chart, processed-CSV column, and HTML reporting for a simulator-provided synthetic_heat_load_w value and its educational heat-balance residual
  • Configurable specific heat and warning thresholds
  • Warning table for low flow, high pressure drop, high temperature difference, missing or unreasonable values, leaks, and high pump speed with low flow
  • Data-quality summary
  • Downloadable processed CSV and standalone HTML summary
  • Clear errors for empty, malformed, or incompatible files

Technical approach

CSV validation and analysis live in a small importable package under src/. The Streamlit application calls those functions and uses Streamlit's native charts. Heat removal is calculated with the separately installed thermal-calculator package at its validated v0.1.1 tag; the equation is not copied into this repository. The optional synthetic heat-load comparison is activated by column presence. The three included datasets demonstrate it, while CSV files created before that simulator field was added remain compatible.

Installation

Python 3.11 or newer and Git are required.

git clone https://github.com/ryanmalone-0/cooling-loop-dashboard.git
cd cooling-loop-dashboard
python -m venv .venv

Activate on Windows:

.venv\Scripts\Activate.ps1

Or activate on macOS/Linux:

source .venv/bin/activate

Install the application and development tools:

python -m pip install -e ".[dev]"

Usage

python -m streamlit run app.py

Open the local URL printed by Streamlit, choose a sample dataset or upload a compatible CSV, and adjust the assumptions in the sidebar.

Compatible files may include the optional numeric column synthetic_heat_load_w. When it is present, the dashboard compares that simulator-provided value with estimated heat removal. The included sample files contain the field and were generated by sensor-stream-simulator; legacy files without it remain supported.

Example output

The dashboard displays an operating summary, six base chart sections, an optional synthetic-load comparison chart, warnings, data-quality metrics, and two downloads:

Working dashboard with synthetic sample data

Testing

python -m pytest
python -m ruff check .
python -m ruff format --check .

Tests cover calculations, legacy and optional-column inputs, validation errors, missing values, every warning type, data-quality metrics, conditional HTML generation, and headless dashboard paths.

Assumptions

  • Temperature difference is outlet temperature - inlet temperature.
  • Estimated heat removal is mass flow rate × specific heat × temperature difference.
  • When synthetic_heat_load_w is present, the educational heat-balance residual is estimated heat removal - simulator-provided synthetic heat load.
  • The synthetic heat load is an input generated by the simulator, not a measured load or an independently verified thermal result.
  • Water's approximate specific heat, 4180 J/(kg·K), is the default and can be changed in the sidebar.
  • Input rows represent sequential synthetic samples.
  • Thresholds are educational defaults and are not equipment specifications.

Limitations

  • This is an educational tool using synthetic data; it is not production-ready and is not intended for control or safety decisions in real facilities.
  • It does not perform live acquisition, unit conversion, uncertainty analysis, sensor calibration, or automatic fault diagnosis.
  • Warnings are simple threshold rules rather than validated detection models.
  • The heat calculation assumes constant specific heat and ignores other losses.
  • The optional residual is a sample-by-sample educational comparison. It does not account for thermal storage, heat exchange with the surroundings, sensor uncertainty, transport delay, or time alignment, so it is not a validated physical energy balance or fault-detection signal.

What I learned

This project helped me practice turning sensor files into useful calculations, separating analysis from interface code, handling incomplete input safely, testing a Streamlit application, and documenting physical assumptions.

Possible future work

  • Add selectable time windows and comparison between two sessions
  • Add unit conversion while keeping SI units as the internal standard
  • Export chart images in addition to tabular and HTML summaries
  • Add configurable reasonable-range profiles for different educational examples

How the repositories connect

  1. thermal-calculator provides the tested heat-removal function.
  2. sensor-stream-simulator creates reproducible synthetic measurements.
  3. cooling-loop-dashboard reads those measurements, applies the shared calculation, and presents the results.

Each repository can still be understood independently.

License

MIT

About

Streamlit dashboard for synthetic cooling-loop data, heat-removal estimates, and educational balance checks.

Topics

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages