-
Notifications
You must be signed in to change notification settings - Fork 1
/
benchmark.py
51 lines (36 loc) · 1.6 KB
/
benchmark.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
43
44
45
46
47
48
49
50
51
from estaty.experiment.explore import CaseExploration
import warnings
warnings.filterwarnings('ignore')
def calculate_green_area_for_several_objects_using_bbox():
"""
Launch experiments to calculate possible values of green index for different
locations.
Set location for experiments using bbox coordinates
"""
# Define coordinates (WGS84) for experiments
locations = {'min_x': 13.0, 'max_x': 13.7, 'min_y': 52.3, 'max_y': 52.7}
exploration = CaseExploration(400, locations, 'simple_green_scale_bbox.gpkg', True)
exploration.launch_green_experiment()
def calculate_green_area_for_several_objects_using_name():
"""
Launch experiments to calculate possible values of green index for different
locations
Set location for experiments using city name and administrative borders
"""
locations = 'Berlin'
exploration = CaseExploration(400, locations,
f'simple_green_scale_{locations}.gpkg', True)
exploration.launch_green_experiment()
def calculate_green_area_for_several_objects_using_buildings():
"""
Launch experiments to calculate possible values of green index for different
locations
Set location for experiments using city name and administrative borders and
use only buildings extend for calculation
"""
locations = 'Berlin_buildings'
exploration = CaseExploration(500, locations,
f'simple_green_scale_{locations}.gpkg', True)
exploration.launch_green_experiment()
if __name__ == '__main__':
calculate_green_area_for_several_objects_using_buildings()