onstove.Biomass#

class onstove.Biomass(name: str | None = None, carbon_intensity: float | None = None, co2_intensity: float = 112, ch4_intensity: float = 0.864, n2o_intensity: float = 0.0039, co_intensity: float = 0, bc_intensity: float = 0.1075, oc_intensity: float = 0.308, energy_content: float = 16, tech_life: int = 2, inv_cost: float = 0, fuel_cost: float = 0, time_of_cooking: float = 2.9, om_cost: float = 0, efficiency: float = 0.12, pm25: float = 844, forest_path: str | None = None, friction_path: str | None = None, travel_time: Series | None = None, collection_capacity: float = 25, collected_fuel: bool = True, time_of_collection: float = 2, draft_type: str = 'natural', forest_condition: Callable[[ndarray], ndarray] | None = None)[source]#

Biomass technology class used to model traditional and improved stoves.

This class inherits the standard Technology class and is used to model traditional and Improved Cook Stoves (ICS) using biomass as fuel. The biomass can be either collected or purchased, which is indicated with the attribute collected_fuel. Depending on the biomass type (e.g. fuelwood or pellets), the parameters passed to the class such as efficiency, energy content, pm25 and emissions need to be representative of the fuel-stove. Moreover, the ICS can be modelled as natural draft or forced draft options by specifying it with the draft_type attribute. If forced draft is used, then the class will consider and extra capital cost for a standard 6 watt solar panel in order to run the fan in unelectrified areas.

Parameters:
name: str, optional.

Name of the technology to model.

carbon_intensity: float, optional

The CO2 equivalent emissions in kg/GJ of burned fuel. If this attribute is used, then none of the gas-specific intensities will be used (e.g. ch4_intensity).

co2_intensity: float, default 112

The CO2 emissions in kg/GJ of burned fuel.

ch4_intensity: float, default 0.864

The CH4 emissions in kg/GJ of burned fuel.

n2o_intensity: float, default 0.0039

The N2O emissions in kg/GJ of burned fuel.

co_intensity: float, default 0

The CO emissions in kg/GJ of burned fuel.

bc_intensity: float, default 0.1075

The black carbon emissions in kg/GJ of burned fuel.

oc_intensity: float, default 0.308

The organic carbon emissions in kg/GJ of burned fuel.

energy_content: float, default 16

Energy content of the fuel in MJ/kg.

tech_life: int, default 2

Stove life in years.

inv_cost: float, default 0

Investment cost of the stove in USD.

fuel_cost: float, default 0

Fuel cost in USD/kg if any.

time_of_cooking: float, default 2.9

Daily average time spent for cooking with this stove in hours.

om_cost: float, default 0

Operation and maintenance cost in USD/year.

efficiency: float, default 0.12

Efficiency of the stove.

pm25: float, default 844

Particulate Matter emissions (PM25) in mg/kg of fuel.

forest_path: str, optional

Path to the forest cover raster file.

friction_path: str, optional

Path to the friction raster file describing the time needed (in minutes) to travel one meter within each cell.

travel_time: Pandas Series, optional

Pandas Series describing the time needed (in hours) to reach the closest forest cover point from each population point. It is calculated using the forest cover, friction layer and population density layer.

collection_capacity: float, default 25

Average wood collection capacity per person in kg/trip.

collected_fuel: bool, default True

Boolean indicating if the fuel is collected or purchased. If True, then the travel_time will be calculated. If False, the fuel_cost will be used and a travel and collection time disregarded.

time_of_collection: float, default 2

Time spent collecting biomass on a single trip (excluding travel time) in hours.

draft_type: str, default ‘natural’

Whether the ICS uses a natural draft or a forced draft.

forest_condition: Callable object (function or lambda function) with a numpy array as input, optional

Function or lambda function describing which forest canopy cover to consider when assessing the potential points for biomass collection.

Example: lambda function for canopy cover equal or over 30%#
>>> forest_condition = lambda  x: x >= 0.3

Examples

An OnStove Biomass class can be created by providing the technology input data on an csv file and calling the read_tech_data method of the onstove.OnStove> class, or by passing all technology information in the script.

Creating the technologies from a csv configuration file (see link to examples or mendeley for a example of the configuration file):

>>> from onstove import OnStove
... model = OnStove(output_directory='output_directory')
... mode.read_tech_data(path_to_config='path_to_csv_file', delimiter=',')
... model.techs
{'Biomass': {'Biomass': <onstove.Biomass at 0x2478e85ee80>}}

Creating a Biomass technology in the script:

>>> from onstove import OnStove
... from onstove import Biomass
... model = OnStove(output_directory='output_directory')
... biomass = Biomass(name='Biomass')  # we define the name and leave all other parameters with the default values
... model.techs['Biomass'] = biomass
... model.techs
{'Biomass': {'Biomass': <onstove.Biomass at 0x2478e85ee80>}}
Attributes:
forest: object of type RasterLayer, optional

This is the forest cover raster dataset read from the forest_path parameter. See the onstove.RasterLayer class for more information.

friction: str, optional

This is the forest cover raster dataset read from the friction_path.

trips_per_yr: float

The trips that a person needs to do to the nearest forest point, in order to collect the amount of biomass required for cooking in one year (per households).

Methods

adjusted_pm25()

Adjusts the PM25 value of each stove based on the adjusment factor.

carb(model)

Checks if carbon_emission is given in the socio-economic specification file.

carbon_emissions(model)

Calculates the reduced emissions and the costs avoided by reducing these emissions.

discount_factor(specs)

Calculates and returns the discount factor used for benefits and costs in the net-benefit equation.

discount_fuel_cost(model[, relative])

Calls discount_factor function and calculates discounted fuel costs.

discounted_inv(model[, relative])

This method expands Technology.discounted_inv() by adding the solar panel cost in unlectrified areas.

discounted_om(model)

Calls discount_factor function and calculates discounted operation and maintenance cost for each stove.

get_carbon_intensity(model)

This method expands Technology.get_carbon_intensity().

health_parameters(model)

Calculates the population attributable fraction for ALRI, COPD, IHD, lung cancer or stroke for urban and rural settlements of the area of interest.

morbidity(model)

Calculates the morbidity across the study area per stove by calling the mort_morb function.

mort_morb(model[, parameter, dr])

Calculates mortality or morbidity rate per fuel.

mortality(model)

Calculates the mortality across the study area per stove by calling the mort_morb function.

net_benefit(model[, w_health, w_spillovers, ...])

This method combines all costs and benefits as specified by the user using the weights parameters.

normalize(column[, inverse])

Uses the MinMax method to normalize the data from a column of the gdf GeoDataFrame.

paf(rr, sfu)

Calculates the Population Attributable Fraction for (PAF) ALRI, COPD, IHD, lung cancer or stroke based on the percentage of population using non-clean stoves and the relative risk.

relative_risk()

Calculates the relative risk of contracting ALRI, COPD, IHD, lung cancer or stroke based on the adjusted

required_energy(model)

Calculates the annual energy needed for cooking in MJ/yr.

salvage(model)

Calls discount_factor function and calculates discounted salvage cost for each stove assuming a straight-line depreciation of the stove value.

solar_panel_investment(model)

This method adds the cost of a solar panel to unelectrified areas.

time_saved(model)

Calculates time saved per year by adopting a new stove.

total_costs()

Calculates total costs (fuel, investment, operation and maintenance as well as salvage costs).

total_time(model)

This method expands Technology.total_time() when biomass is collected.

transportation_time(friction_path, ...)

This method calculates the travel time needed to gather biomass.