process_GC_AC.py 1.34 KB
Newer Older
luroth's avatar
luroth committed
1
2
3
4
5
from GroundAerialCoverage import GroundAerialCoverageSegmentation
from pathlib import Path

if __name__ == "__main__":

luroth's avatar
luroth committed
6
    dates = ['20180322',
luroth's avatar
luroth committed
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
        '20180325',
        '20180402',
        '20180404',
        '20180406',
        '20180409',
        '20180411',
        '20180413',
        '20180417',
        '20180419',
        '20180420',
        '20180423',
        '20180426',
        '20180427',
        '20180501',
        '20180507',
        '20180509'
    ]

    for date in dates:

luroth's avatar
luroth committed
27
28
        print("Process", date)

luroth's avatar
luroth committed
29
30
31
        # Paths
        path_processed = Path(r'O:\UAV\_Processed_\ETHZ_eschikon_FPWW022_lot1') / date / '28m_M600P'

luroth's avatar
luroth committed
32
33
34
35
36
        design_labels = ['FPWW022_lot1', 'FPWW023_lot1', 'FPWWE02_lot1']

        rmdest = True
        for design_label in design_labels:

37
38
39
40
41
42
            # input GSD and buffer
            GSD = 0.003  # m
            buffer = round(-0.3 / GSD) # 0.3 m buffer
            # output image size
            GSD_output = 0.001 # m
            ny, nx = (round( (2 - (2 * 0.3) ) / GSD_output), round( ( 1.5 - (2 * 0.3) ) / GSD_output) )
luroth's avatar
luroth committed
43

luroth's avatar
luroth committed
44
45
46
            GroundAerialCoverageSegmentation.process_multiview_images_generation(path_processed, design_label, nx=nx, ny=ny , subplots=None, buffer=buffer, rmdest=rmdest)
            rmdest = False
            GroundAerialCoverageSegmentation.process_CC_AC_calc(path_processed, design_label)
luroth's avatar
luroth committed
47