Spaces:
Running
Running
Update app.py
Browse files
app.py
CHANGED
@@ -154,10 +154,11 @@ def get_information_from_video_using_OCR(video_path, interval=2):
|
|
154 |
text = pytesseract.image_to_string(preprocessed_frame, lang='eng', config='--psm 6 --oem 3')
|
155 |
cleaned_text = clean_ocr_text(text)
|
156 |
|
157 |
-
if cleaned_text:
|
158 |
-
|
159 |
-
|
160 |
-
|
|
|
161 |
|
162 |
frame_count += 1
|
163 |
|
|
|
154 |
text = pytesseract.image_to_string(preprocessed_frame, lang='eng', config='--psm 6 --oem 3')
|
155 |
cleaned_text = clean_ocr_text(text)
|
156 |
|
157 |
+
if cleaned_text:
|
158 |
+
extracted_text += cleaned_text + "\n\n"
|
159 |
+
# print(f"Text found at frame {frame_count}: {cleaned_text[:50]}...")
|
160 |
+
|
161 |
+
|
162 |
|
163 |
frame_count += 1
|
164 |
|