+2 votes
I would like to introduce an impact method to my database that relates to biotic inputs. As ecoinvent has no elementary flows for biomass other than wood, i would like to add an artifical flow to each other biotic product, which could then be used to be multiplied with a characterisation factor that includes biotic losses (at e.g. farm gate).

We did this manually in the past using OpenLCA, but i am wondering if I could speed up the process at least for future updates. Therefore, i would like to write a Python Script that

- creates elementary flows

- and adds/copies them to defined processes (input)

I have found a script snipped that "adds flows" (in GitHub), but so far i was not able to make it work. I expect that I need certain libraries at the beginning of the code? Do I also have to re-direct to the path of the database or does the Addon automatically target the database i have currently opened?

PS: If anyone already wrote a similar script, i could certainly adapt it to my needs.
in openLCA by (140 points)

2 Answers

0 votes
by (240 points)
Hi Jens,

We have a similar issue : we want to copy certains flows from one method to another.

Have you had any feedback/update on your problem outside this forum ?


0 votes
by (1.8k points)
There are probably a number of ways you could try to implement this. I'll point you to EPA's repository which creates flows and saves them as JSON-ld files which you can import into a database. That might give you some insight into how you could adapt for your own use.

I think the second step, of adding them to existing inputs, might be better done in SQL.

This is not a full answer but may get you moving in the right direction