YAML Metadata Warning:empty or missing yaml metadata in repo card

Check out the documentation for more information.

Smart Environment Monitor — ML Models

These are the trained ML models for the smart-env-monitor project — a Raspberry Pi based indoor environment monitoring system that measures temperature, humidity, and air quality (CO₂) and predicts air quality labels in real-time.


Models

File Type Purpose
models/rf_model.pkl Random Forest Predicts air quality label (Good / Moderate / Poor / Hazardous)
models/kmeans_model.pkl K-Means (k=4) Clusters readings into 4 groups for borderline detection
models/isoforest_model.pkl Isolation Forest Detects anomalous sensor readings
models/label_encoder.pkl Label Encoder Encodes/decodes air quality labels
models/scaler.pkl Standard Scaler Scales features for K-Means input

Input Features

Feature Description
temp_c Temperature in °C
humidity Relative humidity in %
co2_ppm COâ‚‚ in ppm (derived from MQ135 raw ADC reading)

Labels

Label Meaning
Good Clean air
Moderate Acceptable air quality
Poor Ventilation recommended
Hazardous Immediate action required

K-Means Cluster Mapping

Cluster Label
0 Good
1 Poor
2 Hazardous
3 Moderate

Usage

from huggingface_hub import hf_hub_download
import joblib
import os

REPO = "satwikshreshth1/smart-env-monitor-models"
FILES = [
    "models/rf_model.pkl",
    "models/kmeans_model.pkl",
    "models/isoforest_model.pkl",
    "models/label_encoder.pkl",
    "models/scaler.pkl",
]

os.makedirs("models", exist_ok=True)
for f in FILES:
    hf_hub_download(repo_id=REPO, filename=f, local_dir=".")

rf     = joblib.load("models/rf_model.pkl")
scaler = joblib.load("models/scaler.pkl")

Hardware

  • Microcontroller: Arduino (serial output)
  • Sensors: DHT11/DHT22 (temp & humidity), MQ135 (air quality)
  • Host: Raspberry Pi (runs inference)

License

MIT

Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. 🙋 Ask for provider support