From d08130e516acf4dc16ea0fb1237afb466e05f319 Mon Sep 17 00:00:00 2001 From: Bhargav Kowshik Date: Mon, 16 Jul 2018 14:16:54 +0530 Subject: [PATCH] Compare tool works with just images and labels --- robosat/tools/compare.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/robosat/tools/compare.py b/robosat/tools/compare.py index 956fc969..c41cd9be 100644 --- a/robosat/tools/compare.py +++ b/robosat/tools/compare.py @@ -17,7 +17,7 @@ def add_parser(subparser): parser.add_argument("out", type=str, help="directory to save visualizations to") parser.add_argument("images", type=str, help="directory to read slippy map images from") parser.add_argument("labels", type=str, help="directory to read slippy map labels from") - parser.add_argument("masks", type=str, nargs="+", help="slippy map directories to read masks from") + parser.add_argument("masks", type=str, nargs="*", help="slippy map directories to read masks from") parser.add_argument("--minimum", type=float, default=0.0, help="minimum percentage of mask not background") parser.add_argument("--maximum", type=float, default=1.0, help="maximum percentage of mask not background") @@ -48,7 +48,7 @@ def main(args): if percentage >= args.minimum and percentage <= args.maximum: keep = True - if not keep: + if args.masks and not keep: continue width, height = image.size