Skip to content

Commit

Permalink
Fixed argparse error
Browse files Browse the repository at this point in the history
  • Loading branch information
SWHL committed Oct 24, 2023
1 parent 7ba5b6b commit ad6caf0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 2 deletions.
2 changes: 1 addition & 1 deletion label_convert/labelImg_to_publaynet.py
Original file line number Diff line number Diff line change
Expand Up @@ -192,7 +192,7 @@ def main():
"--data_dir", type=str, required=True, help="The directory from labelImg."
)
parser.add_argument("--val_ratio", type=float, default=0.2)
parser.add_argument("--have_test", type=bool, default=True)
parser.add_argument("--have_test", action="store_true", default=False)
parser.add_argument("--test_ratio", type=float, default=0.2)
args = parser.parse_args()

Expand Down
2 changes: 1 addition & 1 deletion label_convert/labelImg_to_yolov5.py
Original file line number Diff line number Diff line change
Expand Up @@ -135,7 +135,7 @@ def main():
parser.add_argument("--src_dir", type=str)
parser.add_argument("--out_dir", type=str)
parser.add_argument("--val_ratio", type=float, default=0.2)
parser.add_argument("--have_test", type=bool, default=True)
parser.add_argument("--have_test", action="store_true", default=False)
parser.add_argument("--test_ratio", type=float, default=0.2)
args = parser.parse_args()

Expand Down

0 comments on commit ad6caf0

Please sign in to comment.