bw2io.strategies.simapro
#
Module Contents#
Functions#
Change datasets with the string |
|
Change |
|
Drop all inputs from allocated products which had zero allocation factors. |
|
|
Link technosphere exchanges based on name, unit, and location. Can't use categories because we can't reliably extract categories from SimaPro exports, only exchanges. |
Normalize biosphere categories to ecoinvent standard. |
|
Normalize biosphere flow names to ecoinvent standard |
|
|
Convert SimaPro formulae to Python |
Make sure |
|
Create a dataset from each product in a raw SimaPro dataset |
|
Split a name like 'foo/CH U' into name and geo components. |
Attributes#
- bw2io.strategies.simapro.change_electricity_unit_mj_to_kwh(db)[source]#
Change datasets with the string
electricity
in their name from units of MJ to kilowatt hour.
- bw2io.strategies.simapro.fix_localized_water_flows(db)[source]#
Change
Water, BR
toWater
.Biosphere flows canāt have locations - locations are defined by the activity dataset.
- bw2io.strategies.simapro.fix_zero_allocation_products(db)[source]#
Drop all inputs from allocated products which had zero allocation factors.
The final production amount is the initial amount times the allocation factor. If this is zero, a singular technosphere matrix is created. We fix this by setting the production amount to one, and deleting all inputs.
Does not modify datasets with more than one production exchange.
- bw2io.strategies.simapro.link_technosphere_based_on_name_unit_location(db, external_db_name=None)[source]#
Link technosphere exchanges based on name, unit, and location. Canāt use categories because we canāt reliably extract categories from SimaPro exports, only exchanges.
If
external_db_name
, link against a different database; otherwise link internally.
- bw2io.strategies.simapro.normalize_simapro_biosphere_categories(db)[source]#
Normalize biosphere categories to ecoinvent standard.
- bw2io.strategies.simapro.normalize_simapro_biosphere_names(db)[source]#
Normalize biosphere flow names to ecoinvent standard
- bw2io.strategies.simapro.normalize_simapro_formulae(formula, settings)[source]#
Convert SimaPro formulae to Python
- bw2io.strategies.simapro.set_lognormal_loc_value_uncertainty_safe(db)[source]#
Make sure
loc
value is correct for lognormal uncertainty distributions
- bw2io.strategies.simapro.sp_allocate_products(db)[source]#
Create a dataset from each product in a raw SimaPro dataset
- bw2io.strategies.simapro.split_simapro_name_geo(db)[source]#
Split a name like āfoo/CH Uā into name and geo components.
Sets original name to
simapro name
.