Initialize YamlArgparse class and parse CLI arguments for COMPASS.
Source code in src/compass/utils/yaml_argparse.py
4
5
6
7
8
9
10
11
12
13
14
15
16 | def __init__(self, add_grid_type=False):
'''Initialize YamlArgparse class and parse CLI arguments for COMPASS.'''
parser = argparse.ArgumentParser(description='', formatter_class=argparse.ArgumentDefaultsHelpFormatter)
parser.add_argument('run_config_path', type=str, nargs='?', default=None, help='Path to run config file')
# additional arguments for s1_cslc.py
if add_grid_type:
parser.add_argument('-g','--grid','--grid-type', dest='grid_type', type=str,
default='geo', choices=['geo', 'radar'],
help='Grid (coordinates) type of the output CSLC')
# parse arguments
self.args = parser.parse_args()
|