Commit 148178b6 authored by 翟艳秋(20软)'s avatar 翟艳秋(20软)

chore: modified the ocr in judge_subtitle

parent 9671a120
......@@ -2,5 +2,6 @@
/build
/missing_packages
/aborted_icons
/docx
/无障碍电影制作工具(无黑窗口).zip
/无障碍电影制作工具(有黑窗口).zip
......@@ -5,8 +5,6 @@ import cv2
import numpy as np
from paddleocr import PaddleOCR
import difflib
# from openpyxl.styles import PatternFill, Alignment
# from openpyxl import Workbook
import re
from detect_with_asr import create_sheet, write_to_sheet
......
......@@ -6,7 +6,7 @@ import numpy as np
from paddleocr import PaddleOCR
from collections import Counter
ocr = PaddleOCR(use_angle_cls=True, lang="ch", show_log=False)
ocr = PaddleOCR(use_angle_cls=True, lang="ch", show_log=False, use_gpu=False)
def random_int_list(start, stop, length):
......@@ -93,5 +93,5 @@ def detect_movie(video_path, start, end, interval):
return Counter(ans).most_common(1)[0][0]
if __name__ == '__main__':
pass
# if __name__ == '__main__':
# pass
......@@ -295,7 +295,9 @@ def start_detect():
progressbar_1.stop()
progressbar_1['value'] = 100.0
progress_1['text'] = "100.0%"
# 检测完成后,将“停止检测”按钮设置为不可点击状态,”开始检测“按钮设置为可点击状态
progressbar_1.grid_forget()
progress_1.grid_forget()
# 检测完成后,将“停止检测”按钮设置为不可点击状态,“开始检测”按钮设置为可点击状态
stopDetection.config(state=tk.DISABLED)
startDetection.config(state=tk.ACTIVE)
......@@ -488,6 +490,8 @@ def start_synthesis():
progressbar_2.stop()
progressbar_2['value'] = 100.0
progress_2['text'] = "100.00%"
progressbar_2.grid_forget()
progress_2.grid_forget()
startSynthesis.config(state=tk.ACTIVE)
stopSynthesis.config(state=tk.DISABLED)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment