Created
October 19, 2020 10:23
-
-
Save mebibou/923e76198fb6d89437c289ec53112840 to your computer and use it in GitHub Desktop.
HESTIA Calculation Engine sample
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
from hestia_earth.calculation import Engine | |
engine = Engine() | |
# cycle: {"@context": "https://hestia.earth/Cycle.jsonld", "@id": "id", "@type": "Cycle", "site": {"@type": "Site"}, ...} | |
engine.import_data(cycle) | |
# run the calculations | |
engine.calculate_all() | |
# read the data | |
engine.export_data() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment