-
Notifications
You must be signed in to change notification settings - Fork 0
/
run_full_analysis.py
42 lines (35 loc) · 1.23 KB
/
run_full_analysis.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import asyncio
import logging
import logging.config
import yaml
import download_worldcover_data
import compare_rasters
import download_osm_data
import calculate_oqapi
import calculate_correlation
from config import LOGGCONFIG
async def main():
"""Run the full analysis consisting of 5 scripts."""
logging.info("Running Script 1: Downloading WC Data")
download_worldcover_data.main()
logging.info("Finished Script 1")
logging.info("Running Script 2: Downloading OSM Data")
await download_osm_data.main()
logging.info("Finished Script 2")
logging.info("Running Script 3: Comparing Data")
compare_rasters.main(
compare_change=True, compare_wc=True, compare_wc_osm=True, compare_osm=True
)
logging.info("Finished Script 3")
logging.info("Running Script 4: Calculation Ohsome Quality API")
calculate_oqapi.main()
logging.info("Finished Script 4")
logging.info("Running Script 5: Calculating Correlations")
calculate_correlation.main()
logging.info("Finished Script 5")
logging.info("Analysis Finished!")
if __name__ == "__main__":
with open(LOGGCONFIG, "r") as f:
config = yaml.safe_load(f.read())
logging.config.dictConfig(config)
asyncio.run(main())