This release is a pre-release and may not be stable for production use.
lca_disclosures
Python based tools for working with LCA foreground model disclosures
Disclosure framework based on "Disclosure of product system models in life cycle assessment: achieving Transparency and Privacy" by Brandon Kuczenski in J Ind Ecol. (doi: 10.1111/jiec12810)
This package was originally authored by James Joyce. Code and testing related to Brightway 2 have been branched into the lca_disclosures_bw2 repository so as to remove dependencies from the core program. The original repository lca_disclosures is still operational.
Supported software frameworks
The lca_disclosures repository supports the generation of a disclosure specification from the following software:
Support (and testing) for Brightway2 is available in the original repository lca_disclosures.
Usage
To use the disclosure framework, instantiate the appropriate Disclosure subclass and supply it with the software-specific input data. The disclosure object can be used to answer questions about the model:
- listing foreground flows, background flows, and emissions;
- identifying cutoff flows (flows that exit the model boundary with no impacts);
- performing an aggregation of the model into a unit process
The disclosure object can also be serialized to JSON or saved as an Excel spreadsheet.
Requirements
pandas, to write to excelscipy, to perform matrix operations
Contents of an LCA Disclosure
A disclosure has six parts, including three lists of flows:
- i An ordered list of foreground flows, beginning with the functional unit of the system (length = p);
- ii An ordered list of flows from background processes or activities (length = n);
- iii An ordered list of environmental or social "emissions" (length = m).
And three sparse matrix specifications:
- iv A list of nonzero entries in the p x p sparse matrix defining the foreground;
- v A list of nonzero entries in the n x p sparse matrix defining the foreground's dependency on the background;
- vi A list of nonzero entries in the m x p sparse matrix defining the foreground's direct emissions.
A visual representation of the disclosure is found in Figure 3 of the above paper:
Development
The base Disclosure class is abstract, and a subclass must be created for each supported software type. A subclass must populate the following methods:
_prepare_efn()returns the evaluated filename used to store disclosure serializations._prepare_disclosure()returns a 6-tuple corresponding to the 6 disclosure elements, in the order listed above.__init__()must be written to handle input data and then call the superclass__init__, which computes_prepare_disclosure()and stores the output.
Release files for lca-disclosures 0.2.0rc2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| lca_disclosures-0.2.0rc2.tar.gz | 21.0 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| lca_disclosures-0.2.0rc2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size:44.7 kB
Release files / lca_disclosures-0.2.0rc2.tar.gz
| Download URL | lca_disclosures-0.2.0rc2.tar.gz |
|---|---|
| Size | 21.0 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
9955d5afef99fe9a7cc56627ae4c2623c473b4d28f42d811101dd1180971dd98
|
|
BLAKE2b-256 checksum How to use checksums |
55541e8d7a5e0b34d39e659706c9d062ccad42c6ec7756cd18ddc20385cefd2e
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.6
|
Release files / lca_disclosures-0.2.0rc2-py3-none-any.whl
| Download URL | lca_disclosures-0.2.0rc2-py3-none-any.whl |
|---|---|
| Size | 23.6 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
78ddf6d915c826ead735913ad27ee918d50d03a2f95e0cd24335749d234b2893
|
|
BLAKE2b-256 checksum How to use checksums |
7a528a33a488e75946ae6476987cfac8480adf7551316b098f662f2d7265a3f2
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.3.0 pkginfo/1.5.0.1 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.9.1 tqdm/4.46.0 CPython/3.8.6
|