New parameters approach doesn't work with SimaPro importer

Create issue
Issue #45 new
Chris Mutel repo owner created an issue

See email from Giuseppe. We already have the code to parse these values, just need to adapt it. Need to:

  1. Distinguish between project and database parameters
  2. Use his file to create a test fixture

We also probably need to close #14.

Comments (1)

  1. giuseppe cardellini

    The csv file test_parameters_no_subprod.xlsx can be used as test.

    It contains activity, project and db parameters both as input (i.e. amount) and calculated (i.e. formula). Parameters (and formulas) are in technosphere, substitution, production and biosphere exchanges and the file contains also a duplicate parameter (i.e. the 2 activity has parameters with same name) and each of the 2 datasets has the other as input. Dunno if all the possible cases are covered but the sima db can be updated. Be aware that is linked to ecoinvent and need to :

    match_database("ecoinvent 3.2 cutoff",  fields=['name', 'unit', 'location','reference product']) 
    match_database("biosphere3",  fields=['name', 'unit', 'categories']) 

    The xslx file test_parameters.xlsx reproduce the same database in a format to be imported with the ExcelImporter.

    From what I could see so far the importing has two problems that are independent from the way they are imported (i.e. occurs also in the xls file)

    1. when production amount is not explicitly set (no amount) but is based on a formula the importing fails when trying to assign_only_product_as_production
    2. also when point 1 is solved (e.g. just setting an amount to the production exchange in the xlsx file) this database is not imported due to Undefined or circular references error.

    P.S: disregard or better delete the file test_parameters.CSV, it was the first that I changed and improved.

  2. Log in to comment