Skip to main content

ppplca (parametric plant protein life cycle assessment)

This repository contains the model code and required input data files for parametric LCAs of plant protein value chains based on variable process parameters and geographical locations.

Requirements

Install

pip install ppplca

Run

In the project folder run:

import ppplca

ppplca.install()

This creates all the necessary sub-folders in the project folder, loads the config.ini file, the excel file containing the process parameters, the excel file to define the value chains that should be calculated, and asks you to locate the agrifootprint database to store it in the created Database folder.

After defining the parameters in the config.ini file, choosing the value chains, and optionally changing parameter values, run:

ppplca.setup()

This sets up a brightway2 project, loads and links the econivent and agrifootprint databases, regionalizes them, and creates necessary processes such as cultivation, electricity mixes, and heat production. The regionalization of the databases can take up to 48 hours on a regular laptop.

After the setup is finished, run:

ppplca.run()

or if you want to select your own excel file to specify the value chains:

ppplca.run('filename.xlsx', sheet=None)
# filename.xlsx must be located in working directory
# The first sheet will be loaded for analysis unless specified either by number or worksheet name.

This yields environmental impacts (see below for more details) for the defined value chains based on multiple Monte-Carlo simulations or single runs depending on the value defined in config.ini. They are stored in the folder Parametrized_LCA_results. Specifically, it provides the following files for each value chain:

  • Overall results for each Monte-Carlo iteration based on 1 kg product
  • Overall results for each Monte-Carlo iteration based on 1 kg protein
  • Contribution analysis based on 1 kg product
  • Contribution analysis based on 1 kg protein
  • First order Sobol-indices (global sensitivity analysis)
  • Total Sobol-indices
  • Parameter values for each iteration

The model

Currently, the model is designed to calculate environmental impacts for the value chains of pea protein isolate (PPI) and concentrate (PPC), soy protein isolate (SPI) and concentrate (SPC), and wheat gluten (WG).

System boundaries

They system boundaries can be chosen flexibly based on the following processes:

  • Cultivation
  • Pre-treatment
  • Milling
  • Defatting
  • Protein extraction (Various technologies)
  • Transport between processes and until point-of-use.

Geographical scope

The geographical scope includes all European countries for the processing steps. Countries for cultivation are principally limited by the coverage of the Agrifootprint database. However, there is a function implemented that creates cultivation processes based on the closest available country in the Agrifootprint database by adapting, e.g., electricity mixes but not local conditions such as the availability of peat soils. Additionally, the US is available for the cultivation and processing of soy and wheat, Brazil for the cultivation and processing of soy, and China for the cultivation and processing of pea, soy, and wheat. For processing in Brazil, China, or the US no transport between the cultivation and processing facility can be modelled currently (assumption that it is nearby or on the way to the port).

Functional units

Currently, a mass- and protein-based functional are used. Variable protein contents in the final product are considered when using a protein-based functional unit

Multi-functionality

Currently, multi-functionality of processes is dealt with by economic allocation (but any allocation type possible). The uncertainty of allocation factors can be taken into account in the models.

Impact assessment

Currently, the model calculates environmental impacts based on regional characterization factors for water stress, land use related biodiversity loss, and particulate matter related human health impacts. For climate change, the factors from IPCC are used. However, any other impact assessment can be added to the model

Model dependencies

The model is based on the Brightway 2 library and lca_algebraic.

The code for loading the agrifootprint database and regionalizing the databases is based on work of Jing et al. (2024).

The regionalization further required input data from Scherer et al. (2023), Boulay et al. (2018), and Oberschelp et al. (2020).

Possible adjustments of the model for further applications

  1. Use different cultivation activities instead of the ones provided in the Agrifootprint database to cover more countries, increase the resolution to a sub-country level, or investigate different cultivation practices deviating from the average cultivation.

  2. Expand the transport to other countries apart from Europe and the production locations in Brazil, China, and the US to model value chains outside of the European context or add more supplying countries.

This would require to update the .csv files in the folder "data" --> "transport" based on the approach described in the manuscript (...) (or any other approach). Further, the tab "Countries" in the file "Value_chains.xlsx" that is loaded with

ppplca.install()

would need to be updated to include the updated list of possible countries.

  1. Conduct LCAs for different products or update the process parameters for the available processes.

This would require different model parameters tailored to the products of interest. They can be set up as shown for pea, soy, and wheat proteins in the excel file "Processing_data.xlsx" that is loaded with

ppplca.install()

Metadata

Release files for ppplca 0.2.40

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

Source distribution (sdist)

Source distribution for ppplca 0.2.40
File Size Uploaded Provenance Actions
ppplca-0.2.40.tar.gz 2.9 MB Without provenance Details for ppplca-0.2.40.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ppplca 0.2.40
File Interpreter ABI Platform Actions
ppplca-0.2.40-py3-none-any.whl Python 3 none any Details for ppplca-0.2.40-py3-none-any.whl

Total release size: 5.8 MB

Release files / ppplca-0.2.40.tar.gz

Download URL ppplca-0.2.40.tar.gz
Size 2.9 MB
Tags Source
SHA-256 checksum
How to use checksums
7c2500e2c811a4b7a6d9bb31b1eae727ac3551c22dc5357e93a7479775c67dde
BLAKE2b-256 checksum
How to use checksums
37f082b928a923f8f1824fc291dd0e638c13edda5af91a5171c69ba29c5a3303
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.1.3 CPython/3.11.5 Windows/10

Release files / ppplca-0.2.40-py3-none-any.whl

Download URL ppplca-0.2.40-py3-none-any.whl
Size 2.9 MB
Tags Python 3
SHA-256 checksum
How to use checksums
8d7a29cfa76f41f421d504f309b0c9cd17a9fb9a031e7bfbdd1315a24dfbf58b
BLAKE2b-256 checksum
How to use checksums
8c16752dd98e33a7f4ab8ad893b5fcc028a4743a9ad4db61ae5d5b9835475e1f
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via poetry/2.1.3 CPython/3.11.5 Windows/10

Security for ppplca 0.2.40

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Release history Release notifications | RSS feed

This release

0.2.40 This release

2 release files No provenance

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