stemp_abw.results package¶
Submodules¶
stemp_abw.results.io module¶
-
stemp_abw.results.io.
oemof_json_to_results
(results_json)[source]¶ Convert stored oemof results json back to result dicts
Parameters: results_json (JSON formatted str
) – Format seestemp_abw.results.tools.oemof_results_to_json()
Returns: dict
– Results from optimization as returned byoemof.outputlib.processing.results()
(sequences only without timestamps, no scalars)dict
– Parameters of optimization as returned byoemof.outputlib.processing.parameter_as_dict()
(scalars only, no sequences)
-
stemp_abw.results.io.
oemof_results_to_json
(results, param_results)[source]¶ Convert oemof raw results to json
Parameters: - results (
dict
) – Results from optimization as returned byoemof.outputlib.processing.results()
- param_results (
dict
) – Parameters of optimization as returned byoemof.outputlib.processing.parameter_as_dict()
Returns: Serialized results, format: {‘param_results’:
- {‘node_from_1’:
- {‘node_to_1’: {‘scalars’: {‘param_1’: val_1,
’param_2’: val_2}
}
}
},
- ’results’:
- {‘node_from_1’:
- {‘node_to_1’: {‘sequences’: [n values]
}
}
}
}
Return type: JSON formatted
str
Notes
- Node keys in results and para_results must be provided as strings using
oemof.outputlib.processing.convert_keys_to_strings()
- In the sequences, timestamps are not preserved (values only)
- results (