Skip to content

Commit

Permalink
added more info in paper
Browse files Browse the repository at this point in the history
  • Loading branch information
sumn2u committed Nov 25, 2023
1 parent c059fea commit 1a8741f
Show file tree
Hide file tree
Showing 2 changed files with 87 additions and 5 deletions.
66 changes: 66 additions & 0 deletions paper/paper.bib
Original file line number Diff line number Diff line change
Expand Up @@ -32,3 +32,69 @@ @misc{greenwood_why_2020
year = {2020},
}

@misc{swd_2022,
title = {Calculating digital emissions},
url = {https://sustainablewebdesign.org/calculating-digital-emissions/},
abstract = {Learn why calculating digital emissions is so challenging and how we arrived at a formula for estimating emissions from digital products.},
language = {en-US},
urldate = {2023-11-25},
journal = {Sustainable Web Design},
month = apr,
year = {2022},
}

@misc{one_byte_2022,
title = {Co2. {Js}: an open library for digital carbon reporting},
shorttitle = {{CO2}.js},
url = {https://branch.climateaction.tech/issues/issue-4/co2js/},
abstract = {Uploading and downloading the bits and bytes that make up the internet uses a lot of electricity. Breaking the internet down to a systems level, data transfer over networks accounts for an estimated 14\% of the web’s total electricity consumption. Networks are also globally distributed, meaning that the bytes you downloaded to render this web page in your browser are probably passed through several different electricity grids. Those grids are made up of different mixes of green and fossil fuel energy.},
language = {en-GB},
urldate = {2023-11-25},
journal = {Branch},
author = {Irani, Fershad},
month = aug,
year = {2022},
}


@misc{carbonbetter_carbon_2023,
title = {Carbon emissions intensity explained},
url = {https://carbonbetter.com/story/carbon-emissions-intensity/},
abstract = {The metric that will give context to your total emissions as your business and carbon footprint both expand.},
language = {en},
urldate = {2023-11-25},
journal = {CarbonBetter},
author = {{CarbonBetter}},
month = feb,
year = {2023},
}



@misc{website_carbon_2019,
title = {How does it work?},
url = {https://www.websitecarbon.com/how-does-it-work/},
abstract = {Calculating the carbon emissions of website is somewhat of a challenge, but we have been working for many years to develop and refine a methodology for this purpose. Our hope is that this will help raise awareness and encourage more eco-friendly approaches to be adopted throughout the web design industry. Having developed the original website […]},
language = {en-US},
urldate = {2023-11-25},
journal = {Website Carbon Calculator},
year = {2019},
}
@misc{ecoping_measure_2020,
title = {Frequently asked questions about {EcoPing} and website carbon emissions},
url = {https://ecoping.earth},
abstract = {Tracking website carbon emissions over time and, the worlds first renewable image CDN hosting on hydroelectric data centers},
language = {en},
urldate = {2023-11-25},
year = {2020},
}

@misc{ram_power_usage_2019,
title = {How much power does memory use?},
url = {https://www.crucial.com/support/articles-faq-memory/how-much-power-does-memory-use},
abstract = {As a rule of thumb, you want to allocate around 3 watts of power for every 8GB of DDR3 or DDR4 memory. High-performance memory such as Ballistix® parts can draw more power, especially if you overclock the voltage beyond XMP settings.},
language = {en-us},
urldate = {2023-11-25},
journal = {Crucial},
year = {2019},
}
26 changes: 21 additions & 5 deletions paper/paper.md
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,34 @@ Node.js is a popular JavaScript runtime environment that is widely used for web
The increasing popularity of Node.js [@w3techs_usage_2022] for web development and server-side applications has raised concerns about the environmental impact of computational processes [@szczesny_reduce_2021]. While existing tools like [CO2.js](https://developers.thegreenwebfoundation.org/co2js/overview/), [EcoPing](https://ecoping.earth), and [Website Carbon Calculator](https://www.websitecarbon.com/) provide valuable insights into the carbon footprint of web applications, they primarily focus on factors like grid energy mix, process execution time, system boundaries [@greenwood_why_2020] and data transfer, lacking a comprehensive approach that incorporates hardware power usage. This limitation can lead to inaccurate carbon footprint assessments and hinder developers' efforts to minimize their environmental impact.


To address this gap, there is a need for a more comprehensive tool like Node Carbon that directly measures hardware power consumption (RAM + CPU) and incorporates it into its carbon footprint calculations.

![Carbon emission calculation process\label{fig:Carbon emission calculation process}](carbon_emission.png){width="100%"}

Figure 1 describes the general process of calculating carbon emission. This enhanced approach would provide developers with more accurate and actionable insights, enabling them to:
To address this gap, there is a need for a more comprehensive tool like Node Carbon that directly measures hardware power consumption (RAM + CPU) and incorporates it into its carbon footprint calculations. This enhanced approach would provide developers with more accurate and actionable insights, enabling them to:

- Optimize their code to reduce energy consumption
- Select more efficient hardware components
- Choose hosting providers that utilize renewable energy sources

By accurately quantifying the carbon footprint of Node.js applications, Node Carbon empowers developers to make informed decisions that contribute to a more sustainable digital ecosystem.

# Related software

There are several libraries available for developers to assess the carbon emissions of their web applications. Among them, [Website Carbon](https://www.websitecarbon.com/), [CO2.js](https://www.thegreenwebfoundation.org/) and [EcoPing](https://ecoping.earth/) and are noteworthy. Website Carbon measures website energy consumption by analyzing data transfer and usage patterns, repeat visitors, and energy sources[@website_carbon_2019]. It uses [The Green Web Foundation (TGWF)](https://www.thegreenwebfoundation.org/) database to check if data centers use green energy and estimates carbon emissions using grid and renewable energy factors. Whereas Ecoping calculates website carbon emissions using live grid data from around the world to reflect energy consumption of data centers and websites, along with green hosting practices based on the location of website resources and energy production [@ecoping_measure_2020].

On the other hand, CO2.js, an open-source JavaScript library, estimates carbon emissions through models like SWD [@swd_2022] and OneByte [@one_byte_2022]. It takes into account variables such as data size, type, and network efficiency. Here, Grid intensity data is obtained from sources such as [Ember](https://ember-climate.org/) and [UNFCCC](https://unfccc.int/). The data reflects the amount of carbon dioxide emissions per unit of electricity generated in a specific location. One can use open-source tools like [Scaphandre](https://github.com/hubblo-org/scaphandre), [Greenframe CLI](https://github.com/marmelab/greenframe-cli), and [DIMPACT](https://dimpact.org) to calculate customized carbon emissions. For cloud-based workloads, [Cloud Carbon Footprint](https://www.cloudcarbonfootprint.org/) can also be used.



Similarly to these, Node Carbon estimates the amount of carbon dioxide (CO2) produced by personal computing resources used to execute the code. It estimates the electricity consumption of the hardware used to run the processes and applies the carbon intensity of the region where the processes are being executed. This helps in measuring the environmental impact of running code on personal computing devices.

# Overview

Node Carbon calculates CO₂ emissions using Carbon Intensity (C) and Energy Consumed (E). C is the CO₂ emitted per kilowatt-hour of electricity consumed while E is the amount of electricity consumed by the computational infrastructure. Figure 1 describes the general process of calculating carbon emission.

![Carbon emission calculation process\label{fig:Carbon emission calculation process}](carbon_emission.png){width="100%"}

Carbon Intensity of electricity is based on emissions from energy sources used to generate it [@carbonbetter_carbon_2023]. Fossil fuels have high carbon intensities, while low-carbon fuels include solar, hydro, biomass, and geothermal power. Node carbon calculates the carbon intensity of consumed electricity based on the mix of sources used. Providers like [Electricity Maps](https://www.electricitymaps.com/) and [WattTime](https://www.watttime.org/) can be used for real-time grid intensity data. Here, we rely on carbon intensity electricity data from [Our World in Data](https://ourworldindata.org/grapher/carbon-intensity-electricity) and process it. If data is missing, we use [code carbon data](https://mlco2.github.io/codecarbon/methodology.html#id5).


We track the power supply to the underlying hardware based on computational usage. To ensure security and stability, the power usage of RAM used here is 3 watts for an 8 GB ratio [@ram_power_usage_2019]. We measure CPU usage by correlating current usage with TDPs from the data source, then multiplying by the CPU usage. If a global constant is unavailable, a standard value is used.


# References

0 comments on commit 1a8741f

Please sign in to comment.