From cae11201ef26eadc3d98d4861b15ef6f561de3e4 Mon Sep 17 00:00:00 2001 From: Jay Xu Date: Mon, 4 Aug 2025 16:08:24 +0800 Subject: [PATCH] fix "out of memory" if slide.get_thumbnail() to a huge image (#9211) ### What problem does this PR solve? fix "out of memory" if slide.get_thumbnail() to a huge image ### Type of change - [x] Bug Fix (non-breaking change which fixes an issue) --- rag/app/presentation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/rag/app/presentation.py b/rag/app/presentation.py index d924f49b1..d451deb8d 100644 --- a/rag/app/presentation.py +++ b/rag/app/presentation.py @@ -42,7 +42,7 @@ class Ppt(PptParser): try: with BytesIO() as buffered: slide.get_thumbnail( - 0.5, 0.5).save( + 0.1, 0.1).save( buffered, drawing.imaging.ImageFormat.jpeg) buffered.seek(0) imgs.append(Image.open(buffered).copy())