danesherbs / carbon-emissions-exporter

Calculate physical quantities and metrics for CPU, GPU and DRAM. Expose them via HTTP for Prometheus consumption.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Carbon emissions exporter

A simple Python package that:

  • Calculates physical quantities of your device meters.py
  • Calculates useful metrics metrics.py

Also includes a server that exports these via HTTP for Prometheus consumption export.py

Features

Physical quantities

  • Power (kW)
  • Energy (kWh)
  • CO2e emissions (kg)

Metrics

  • Donation to offset carbon emissions (USD)
  • Number of one-way flights from London to New York

Devices monitored

  • CPU
  • DRAM
  • GPU

Setup

Use as a library

import meters
import metrics

Start server for Prometheus

python export.py

About

Calculate physical quantities and metrics for CPU, GPU and DRAM. Expose them via HTTP for Prometheus consumption.

License:MIT License


Languages

Language:Python 100.0%