Skip to main content

Contains all the python boilerplate you need to create a Brightway ecosystem package.

Project description

Brightway2 parameters

Library for storing, validating, and calculating with parameters. Designed to work with the Brightway2 life cycle assessment framework, but is generic enough to work in other use cases.

In [1]: from bw2parameters import ParameterSet

In [2]: parameters = {
   ...:        'Deep_Thought': {'amount': 42},
   ...:        'East_River_Creature': {'formula': '2 * Deep_Thought + 16'},
   ...:        'Elders_of_Krikkit': {'formula': 'sqrt(East_River_Creature)'},
   ...: }

In [3]: ParameterSet(parameters).evaluate()
Out[3]: {'Deep_Thought': 42, 'East_River_Creature': 100, 'Elders_of_Krikkit': 10.0}

Compatible with Python 2.7 and 3.3+. 100% test coverage. Source code on Github, documentation on Read the Docs.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

bw2parameters-1.1.0.tar.gz (26.9 kB view hashes)

Uploaded source

Built Distribution

bw2parameters-1.1.0-py3-none-any.whl (15.2 kB view hashes)

Uploaded py3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page