Skip to content
Snippets Groups Projects
Commit fc7df764 authored by Michel Spils's avatar Michel Spils
Browse files

params bsh_extractor

parent 16095bc3
Branches
No related tags found
No related merge requests found
......@@ -15,8 +15,9 @@ def parse_arguments() -> Path:
"""
parser = argparse.ArgumentParser(description='Process root folder.')
parser.add_argument('base_dir', type=Path, help='Path to the root folder')
parser.add_argument('dest_dir', type=Path, help='Path to the root folder')
args = parser.parse_args()
return args.base_dir
return [args.base_dir, args.dest_dir]
def get_offset(hour:int) -> int:
""" Calculates how many values to skip from the input hour to get to an hour divisible by 3
......@@ -146,10 +147,15 @@ def make_target_file_name(base_dir:Path,tsVorh) -> Path:
def main():
"""Main function of the script. Reads the data from the MOS.zip file, extracts the relevant data and writes it .zrx files."""
base_dir = parse_arguments()
#base_dir = parse_arguments()
#mos_file_name = base_dir / "MOS.zip"
#dat_file,tsVorh = get_dat_file_name(mos_file_name)
#target_file = make_target_file_name(base_dir,tsVorh)
base_dir,dest_dir = parse_arguments()
mos_file_name = base_dir / "MOS.zip"
dat_file,tsVorh = get_dat_file_name(mos_file_name)
target_file = make_target_file_name(base_dir,tsVorh)
target_file = make_target_file_name(base_dir / '4WISKI',tsVorh)
df = read_dat_file(mos_file_name,dat_file,tsVorh)
writeZrxp(target_file,df)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment