Package: transport-co2
Transport CO2Calculate CO2 (equivalent) emissions for a given transport trip and provide a simple interpretation of the result.Install fromPyPIviapipinstalltransport-co2Usage examplesYou can list the currently supported modes like so:fromtransport_co2importModelist(Mode)EachModeallows you to estimate the CO2 emission per passenger for a journey given its distance (in km):Mode.SMALL_CAR.estimate_co2(distance_in_km=100)# 11200.0This estimate is based on an average occupancy (in this example1.5). You can also specify the occupancy:Mode.SMALL_CAR.estimate_co2(distance_in_km=100,occupancy=3)# 5600.0If you don't want to work with theModeenum, you can instead work with theestimate_co2function:fromtransport_co2importestimate_co2estimate_co2(mode="light_rail",distance_in_km=100)# 1400.0You can also specify the occupancy like above:estimate_co2(mode="light_rail",distance_in_km=100,occupancy=250)# 873.6Running unit testsIn order to run the unit tests for this project:activate the virtual environment withpipenv shellrunpytestGoalsThis project is intended to be used to help raise awareness about the cost of transportation choices, so people can make informed decisions.Initial focusWe are initially focused on ground (road and rail) transport, as it is the most significant source on transport greenhouse gas emissions.API DesignThis library intends to provide:a statistical estimate of greenhouse gase emissions given information about a trip (origin/destination, mode, and/or distance)a simple interpretation of the statistical emissions estimate, in terms such as "high" or "low"Carbon estimatesWe try to provide a "best effort" estimate of CO2 emissions for transportation modes defined by the OpenTripPlanner project.Our baseline estimates come from an infographic published by the European Environment Agency:CO2 emissions from passenger transport.For modes not covered in the EEA infographic, we have used data from other sources (described below). In some cases, we have simply averaged values for several modes to provide estimates for more ambiguous modes, likeCARandTRANSIT.Some mode energy estimates are based onmegajoules for the petroleum consumed. For those modes, we used apetroleum average of 12g CO2 eq. per megajoule(The International Council on Clean Transportation, 2010).ForFERRYmode calculation we use the average of 6.8 MJ per passenger kilometer with an average occupancy of 91 (Schiller & Kenworthy, 2017, p. 143-144). We then estimate that each ferry passenger kilometer approximates to 81.6 g CO2, based on the above petroleum megajoule to grams CO2 conversion factor (6.8 * 12).ForSUBWAY(metro) mode calculation we use the average of 0.52 MJ per passenger kilometer with an average occupancy of 31 (Schiller & Kenworthy, 2017, pp. 143-144). We then estimate that each metro passenger kilometer approximates to 6.24 grams of CO2, based on the above petroleum megajoule to grams CO2 conversion factor (0.52 * 12).BibliographyThe International Council on Clean Transportation. (2010). Carbon Intensity of Crude Oil in Europe. Retrieved fromhttps://theicct.org/sites/default/files/ICCT_crudeoil_Eur_Dec2010_sum.pdfSchiller, P. L., & Kenworthy, J. R. (2017). An Introduction to Sustainable Transportation. Abingdon, United Kingdom: Routledge.Further readingFurther improvements to the model may come from other sources, such as the following.IPCC AR5Chapter 8 - TransportWikipedia:Environmental impact of transportAttributionInitial package structure forked fromnavdeep-G/setup.py.Friendly nod tojamiebull1/transport-carbon.