Skip to main content

iomb is an open source Python library for creating environmentally extended input-output models (EEIO models) from CSV files in a simple data format. It includes functions to calculate different result types (e.g. life cycle assessment results, direct and upstream contributions, etc.) from such models and convert them into JSON-LD data packages that can be imported into openLCA.

Installation

iomb is tested with Python 3.5 but should also work with older versions of Python 3. The easiest way to install the package is to do so using pip, which is generally packaged with a Python installation. Open up the command line and enter:

pip install IO-Model-Builder

This will also install the dependencies of the IO-Model-Builder (NumPy, pandas, and matplotlib) if required. After this you should be able to use the iomb package in your Python code. To uninstall the package, you can again use pip from the command line:

pip uninstall IO-Model-Builder

Usage

You can find a more detailed example here in form of a Jupyter notebook which is a convenient way to use iomb. The following script shows the basic usage of iomb. For detailed information about the data format see the data format specification

import iomb

# optionally show all logging information of iomb
iomb.log_all()

# create a direct requirements coefficients matrix from a supply and use table
# and save it to a CSV file
drc = iomb.coefficients_from_sut('supply_table.csv', 'use_table.csv')
drc.to_csv('drc.csv')

# create an EEIO model from a coefficients matrix, satellite tables, and a
# LCIA method
model = iomb.make_model('drc.csv',
                        ['satellite_table1.csv', 'satellite_table2.csv'],
                        "sector_meta_data.csv",
                        ['LCIA_factors1.csv', 'LCIA_factors1.csv'])

# validate the model
import iomb.validation as val
vr = validation.validate(model)
print(vr)

# calculate results for a given demand
result = iomb.calculate(model, {'1111a0/oilseed farming/us': 1})
print(result.total_result)

# export the model to a JSON-LD package
import iomb.olca as olca
olca.Export(model).to('model_as_json-ld.zip')

License

This project is in the worldwide public domain, released under the CC0 1.0 Universal Public Domain Dedication.

Public Domain Dedication

Public Domain Dedication

Citation

Please cite as: Srocka, M. and W. Ingwersen (2017). IO Model Builder, v1.1 (or current version). US Environmental Protection Agency. https://www.github.com/usepa/io-model-builder

A brief description of the iomb is also included in: Yang, Y., Ingwersen, W.W., Hawkins, T.R., Srocka, M., Meyer, D.E., 2017. USEEIO: A New and Transparent United States Environmentally-Extended Input-Output Model. Journal of Cleaner Production 158, 308-318. DOI: 10.1016/j.jclepro.2017.04.150

Release files for IO-Model-Builder 1.1.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distribution (wheel)

Table of built distributions (wheels) for IO-Model-Builder 1.1.2
File Interpreter ABI Platform
IO_Model_Builder-1.1.2-py3-none-any.whl Python 3 none any Details

Release files / IO_Model_Builder-1.1.2-py3-none-any.whl

Download URL IO_Model_Builder-1.1.2-py3-none-any.whl
Size 52.1 kB
Tags Python 3
SHA-256 checksum
How to use checksums
0b84821b99bdf0537c663bc41661ace9b1afa620d4bc6ee3b9b39ef003209ee2
BLAKE2b-256 checksum
How to use checksums
d1ec32e65910e5bb4a59d9a966dd9aeedf1a515ce5c35e81984ba771f7775016
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No

Release history Release notifications | RSS feed

This release

1.1.2 This release

1 release file

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page