From 9972a4c432800f222c2cade6f7951efb6cbc82bf Mon Sep 17 00:00:00 2001 From: Harsh Devmurari Date: Sun, 16 Jun 2024 16:58:36 +0530 Subject: [PATCH] converts img considering format provided --- DocumentUnderstanding/VGT/object_detection/pdf2img.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/DocumentUnderstanding/VGT/object_detection/pdf2img.py b/DocumentUnderstanding/VGT/object_detection/pdf2img.py index b73ad27..c16704e 100644 --- a/DocumentUnderstanding/VGT/object_detection/pdf2img.py +++ b/DocumentUnderstanding/VGT/object_detection/pdf2img.py @@ -34,6 +34,6 @@ for i, image in enumerate(images): image.save( os.path.join( - args.output, f"page_{i}.png")) + args.output, f"page_{i}.{args.format}")) logging.info(f"PDF converted to images and saved at {args.output}")