Comments (7)
Original comment by Benjamin W. Portner (Bitbucket: pommespapst, GitHub: pommespapst).
Update: error does not occur, if I export an ecoinvent activity as ILCD, convert it to ecospold2, and try to import it into brightway2. Seems, the error occurs because I try to import a custom process with mal-defined geography?
from brightway2.
Original comment by Chris Mutel (Bitbucket: cmutel, GitHub: cmutel).
The output file is not valid ecospold2. It is not just the location data, but a lot of different of elements:
#!bash
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:12: element timePeriod: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}timePeriod': This element is not expected. Expected is one of ( {http://www.EcoInvent.org/EcoSpold02}classification, {http://www.EcoInvent.org/EcoSpold02}geography ).
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:45: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:45: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:48: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:48: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:51: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:51: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:54: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:54: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:57: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:57: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:60: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:60: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:63: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:63: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:66: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:66: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:69: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:69: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:72: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:72: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:75: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:75: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:78: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:78: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:81: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:81: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:84: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:84: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:87: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter', attribute 'id': The attribute 'id' is not allowed.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:87: element parameter: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}parameter': The attribute 'parameterId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:97: element dataEntryBy: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataEntryBy': The attribute 'personId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:97: element dataEntryBy: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataEntryBy': The attribute 'personName' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:97: element dataEntryBy: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataEntryBy': The attribute 'personEmail' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:98: element dataGeneratorAndPublication: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataGeneratorAndPublication': The attribute 'personId' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:98: element dataGeneratorAndPublication: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataGeneratorAndPublication': The attribute 'personName' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:98: element dataGeneratorAndPublication: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}dataGeneratorAndPublication': The attribute 'personEmail' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:99: element fileAttributes: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}fileAttributes': The attribute 'majorRevision' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold:99: element fileAttributes: Schemas validity error : Element '{http://www.EcoInvent.org/EcoSpold02}fileAttributes': The attribute 'minorRevision' is required but missing.
8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold fails to validate
Unfortunately, there is not much that Brightway can do here. If you expect this to be a major problem, the only real solution would be to write a more lenient extractor that provides default values for missing attributes (e.g. GLO
for location).
from brightway2.
Original comment by Benjamin W. Portner (Bitbucket: pommespapst, GitHub: pommespapst).
Could you let me know how you created the log file?
from brightway2.
Original comment by Chris Mutel (Bitbucket: cmutel, GitHub: cmutel).
#!bash
xmllint --schema "path/to/EcoSpold02.xsd" --noout 8eb88a18-9ad1-4382-a1d1-99cec36e6a58.spold
You can download the schema from ecoinvent.
from brightway2.
Original comment by Benjamin W. Portner (Bitbucket: pommespapst, GitHub: pommespapst).
Thanks a lot for the hint to xmllint!
Concerning my problem: I found a work around. I will describe it here. Maybe you can make it a section in your documentation or something.
Aim: Export a model from GaBi into Brightway2.
Things I've tried:
Export as tsx -> import in Brightway2 : import of tsx not supported in Brightway2
Export as ecospold1 -> import in Brightway2: not an option because ecospold1 does not support parameters
Export as ILCD -> import in Brightway2: import of ILCD not supported in Brightway2
Export as ILCD -> convert to ecospold2 using OpenLCA conversion tool -> import in brightway2: import crashes with above errors (only for custom activities, ecoinvent activities work)
Export as ILCD -> import into OpenLCA -> export as ecospold2 -> import in brightway2: works!
Looks like OpenLCA import adds the missing attributes. Also export from OpenLCA seems to get the attribute naming right (parameterId instead of id), contrary to the conversion tool. Unfortunately there is no possibility in GaBi to export ecospold2. Would make things a lot easier...
from brightway2.
Original comment by Benjamin W. Portner (Bitbucket: pommespapst, GitHub: pommespapst).
Just realized that the import worked but the mathematical relations in the parameters were not imported. Is there a way to keep the mathematical relations?
from brightway2.
Original comment by Chris Mutel (Bitbucket: cmutel, GitHub: cmutel).
It's on the roadmap, and needed for current projects, so it is coming - but is not there yet. Shouldn't be too much of a change, you are welcome to look at the parameter extraction already in bw2io and extend it :)
from brightway2.
Related Issues (20)
- Biosphere3 version made clear
- bw2io.errors.MultiprocessingError HOT 1
- Ecospold2 importer issue with versions 2.1, 2.2, 2.4 (ecoinvent 3.6 and ecoinvent 3.8) HOT 1
- Unable to clone repository due to invalid path (possibly forbidden character (?) in file name)
- Brightway tutorial not working on fresh install HOT 3
- Unable to create new project. "IntegrityError: NOT NULL constraint failed: projectdataset.full_hash" HOT 6
- numpy.bool is deprecated and is removed from numpy-1.24.x HOT 1
- Trying to create activity parameters through imports of databases
- Biosphere exchange in- and outputs wrong way around with ecoinvent 3.9.1? HOT 1
- Importing ILCD-EPDs from Ökobaudat
- Export inventory results from uncertainty analysis
- Top activities not working for upstream exploration of hotspots HOT 1
- LeastSquaresLCA throwing NonsquareTechnoSphere
- Wrong units for ReCiPe endpoint categories
- I cannot install brightway 2 with anaconda HOT 3
- how to use brightway 2 to import lcia file. {http://www.EcoInvent.org/EcoSpold02}impactIndicator raise ValueError ValueError
- cannot install the brightway 2 in anaconda
- Cannot import brightway2 in Jupyter notebook HOT 3
- ExcelImporter write_database issue
- Trace back error
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from brightway2.