01 - Measuring Your Code\
Using CodeCarbon to measure code CO2 emissions: setup, tracking, dashboard and optimization.
Using CodeCarbon to measure code CO2 emissions: setup, tracking, dashboard and optimization.
What you'll learn
- Basic Installation
- First Use: The Context Manager
- Explicit Usage with Start/Stop
- Basic Decorator
- Decorator with Offline Mode
This article is part of the Green Software series on federicocalo.dev.
Read the full article
The complete article (20 min read) with code examples, diagrams, and practical exercises is available here:
https://federicocalo.dev/en/blog/measuring-code-carbon-footprint-codecarbon
By Federico Calò — Software Developer & Technical Writer