diff --git a/src/twomartens/masterthesis/cli.py b/src/twomartens/masterthesis/cli.py index e99847f..5d9278f 100644 --- a/src/twomartens/masterthesis/cli.py +++ b/src/twomartens/masterthesis/cli.py @@ -45,13 +45,19 @@ def prepare(args: argparse.Namespace) -> None: from twomartens.masterthesis import data - file_names_photos, file_names_instances, instances = data.prepare_scenenet_data(args.scenenet_path, - args.protobuf_path) - with open(f"{args.ground_truth_path}/photo_paths.bin", "wb") as file: + file_names_photos, file_names_instances, \ + instances = data.prepare_scenenet_data(conf.get_property("Paths.scenenet"), + args.protobuf_path) + with open(f"{conf.get_property('Paths.scenenet_gt')}/" + f"{args.ground_truth_path}/photo_paths.bin", "wb") as file: pickle.dump(file_names_photos, file) - with open(f"{args.ground_truth_path}/instance_paths.bin", "wb") as file: + + with open(f"{conf.get_property('Paths.scenenet_gt')}/" + f"{args.ground_truth_path}/instance_paths.bin", "wb") as file: pickle.dump(file_names_instances, file) - with open(f"{args.ground_truth_path}/instances.bin", "wb") as file: + + with open(f"{conf.get_property('Paths.scenenet_gt')}/" + f"{args.ground_truth_path}/instances.bin", "wb") as file: pickle.dump(instances, file) diff --git a/src/twomartens/masterthesis/config.py b/src/twomartens/masterthesis/config.py index 5c922d3..c793ee3 100644 --- a/src/twomartens/masterthesis/config.py +++ b/src/twomartens/masterthesis/config.py @@ -36,6 +36,7 @@ _CONFIG_PROPS = { "Paths": { "coco": (str, ""), "scenenet": (str, ""), + "scenenet_gt": (str, ""), "scenenet_gt_train": (str, ""), "scenenet_gt_val": (str, ""), "scenenet_gt_test": (str, ""),