An open API service indexing awesome lists of open source software.

https://github.com/GreenScheduler/cats

CATS: the Climate-Aware Task Scheduler 🐈 🐈‍⬛
https://github.com/GreenScheduler/cats

carbon carbon-footprint climate computing electricity electricity-consumption energy energy-consumption job-scheduler scheduling

Last synced: about 2 months ago
JSON representation

CATS: the Climate-Aware Task Scheduler 🐈 🐈‍⬛

Awesome Lists containing this project

README

          

![CATS logo](docs/source/_static/cats_dalle_img_200x200px_for_logo.png)

# CATS: **C**limate-**A**ware **T**ask **S**cheduler

CATS is a **C**limate-**A**ware **T**ask **S**cheduler. It schedules cluster jobs to minimize predicted carbon intensity of running the process. It was created as part of the [2023 Collaborations Workshop](https://software.ac.uk/cw23).

The Climate-Aware Task Scheduler is a lightweight Python package designed to schedule tasks based on the estimated carbon intensity of the electricity grid at any given moment. This tool uses real-time carbon intensity data from the National Grid ESO via their API to estimate the carbon intensity of the electricity grid, and schedules tasks at times when the estimated carbon intensity is lowest. This helps to reduce the carbon emissions associated with running computationally intensive tasks, making it an ideal solution for environmentally conscious developers.

*Demo showing CATS scheduling a 30 minute job using the `at` scheduler*
![CATS animated usage example](cats.gif)

> [!NOTE]
> Currently CATS only works in the UK. If you are aware of APIs for realtime grid carbon intensity data in other countries please open an issue and let us know.

[![DOI](https://joss.theoj.org/papers/10.21105/joss.08251/status.svg)](https://doi.org/10.21105/joss.08251)

## Features

- Estimates the carbon intensity of the electricity grid in real-time
- Schedules tasks based on the estimated carbon intensity, minimizing carbon emissions
- Provides a simple and intuitive API for developers
- Lightweight and easy to integrate into existing workflows
- Supports Python 3.9+

## Installation

Install via `pip` as follows:

```bash
pip install climate-aware-task-scheduler
```

To install the development version:

```bash
pip install git+https://github.com/GreenScheduler/cats
```

## Documentation

Documentation is available at https://cats.readthedocs.io

We recommend the
[quickstart](https://greenscheduler.github.io/cats/quickstart.html#basic-usage)
if you are new to CATS. CATS can optionally [display carbon footprint
savings](https://greenscheduler.github.io/cats/quickstart.html#displaying-carbon-footprint-estimates)
using a [configuration file](cats/config.yml).

## Contributing

We welcome contributions from the community! If you find a bug or have an idea for a new feature, please open an issue on our GitHub repository or submit a pull request.

## License

[MIT License](https://github.com/GreenScheduler/cats/blob/main/LICENSE)