mirror of
https://github.com/opendatalab/MinerU.git
synced 2026-09-24 23:10:23 +08:00
fix(magic_pdf): disable PaddlePaddle signal handler
- Import paddle module and disable its signal handler to prevent interference with other components - This change addresses potential conflicts between PaddlePaddle and other libraries or system signals
This commit is contained in:
@@ -5,6 +5,10 @@ import fitz
|
||||
import numpy as np
|
||||
from loguru import logger
|
||||
|
||||
# 关闭paddle的信号处理
|
||||
import paddle
|
||||
paddle.disable_signal_handler()
|
||||
|
||||
os.environ['NO_ALBUMENTATIONS_UPDATE'] = '1' # 禁止albumentations检查更新
|
||||
os.environ['YOLO_VERBOSE'] = 'False' # disable yolo logger
|
||||
|
||||
|
||||
Reference in New Issue
Block a user