Main

Main

The main functions to use if importing metaDMG as a package.


Functions:

compute_config([config_file, force])

Run the LCA and fit on the config file.

load_results([config_file, results_dir])

Load the results from either a config file or a results-directory

run_dashboard([config_file, results, debug, ...])

Visualise the results in an interactive dashboard

metaDMG.main.compute_config(config_file=PosixPath('config.yaml'), force=False)[source]

Run the LCA and fit on the config file.

Parameters
  • config_file (Path) – The config file to run the computations on, by default Path(“config.yaml”)

  • force (bool) – Force the computation, i.e. do not load (intermediate) results, by default False

Return type

None

metaDMG.main.load_results(config_file=None, results_dir=None)[source]

Load the results from either a config file or a results-directory

Parameters
  • config_file (Optional[Path]) – The the config file to use to locate the results directory, by default None

  • results_dir (Optional[Path]) – The results directory, by default None

Return type

A dataframe of all the results

metaDMG.main.run_dashboard(config_file=PosixPath('config.yaml'), results=None, debug=False, server=False, port=8050, host='0.0.0.0')[source]

Visualise the results in an interactive dashboard

Parameters
  • config_file (Path) – The the config file to use to locate the results directory, by default Path(“config.yaml”)

  • results (Optional[Path]) – The results directory, by default None

  • debug (bool) – Whether or not the debug-button should be displayed, by default False

  • server (bool) – Whether or not it should behave as running on a server, by default False

  • port (int) – Dashboard port, by default 8050

  • host (str) – Dashboard host address, by default “0.0.0.0”

Return type

None