ElectricityLCI icon indicating copy to clipboard operation
ElectricityLCI copied to clipboard

Updating mains of sub-modules to implement model configuration

Open m-jamieson opened this issue 4 years ago • 0 comments

Many of the sub-modules contain mains (in the form of if name=="main") that need to be updated to reflect the new way of specifying the model configuration. When these were originally written, importing electricitylci would always result in a prompt for the configuration. That is no longer the case - electricitylci.model_config.model_specs must be generated largely before importing any of the sub-modules - either:

import electricitylci.model_config as config
config.model_specs = config.build_model_class()

or config._model_specs=config.build_model_class("<model_configuration_name>") (e.g., "ELCI_1")

m-jamieson avatar Jul 30 '20 17:07 m-jamieson