Pytest plugin for measuring carbon emissions.
This plugin is installed via pip using:
pip3 install pytest-codecarbon
To use, simply run pytest with the --carbon
option. When the tests have run, you will find an emissions.csv
file containing each test, and the carbon, time and energy statistics for each test. You can also use --carbon-dir
to specify a different directory for the emissions.csv
file.