Update video_processing.py
Browse files- video_processing.py +1 -3
video_processing.py
CHANGED
@@ -6,7 +6,7 @@ import tempfile
|
|
6 |
import time
|
7 |
from PIL import Image, ImageDraw, ImageFont
|
8 |
import math
|
9 |
-
from face_analysis import get_face_embedding, cluster_faces, organize_faces_by_person
|
10 |
from pose_analysis import pose, calculate_posture_score, draw_pose_landmarks
|
11 |
from voice_analysis import get_speaker_embeddings, align_voice_embeddings, extract_audio_from_video, diarize_speakers
|
12 |
from anomaly_detection import anomaly_detection
|
@@ -231,8 +231,6 @@ def process_video(video_path, anomaly_threshold, desired_fps, progress=None):
|
|
231 |
face_img = cv2.imread(face_path)
|
232 |
if face_img is not None:
|
233 |
face_img = cv2.cvtColor(face_img, cv2.COLOR_BGR2RGB)
|
234 |
-
if frame in facial_landmarks_by_frame:
|
235 |
-
face_img = draw_facial_landmarks(face_img, facial_landmarks_by_frame[frame])
|
236 |
timecode = df[df['Frame'] == frame]['Timecode'].iloc[0]
|
237 |
face_img_with_timecode = add_timecode_to_image(face_img, timecode)
|
238 |
anomaly_faces_embeddings.append(face_img_with_timecode)
|
|
|
6 |
import time
|
7 |
from PIL import Image, ImageDraw, ImageFont
|
8 |
import math
|
9 |
+
from face_analysis import get_face_embedding, cluster_faces, organize_faces_by_person
|
10 |
from pose_analysis import pose, calculate_posture_score, draw_pose_landmarks
|
11 |
from voice_analysis import get_speaker_embeddings, align_voice_embeddings, extract_audio_from_video, diarize_speakers
|
12 |
from anomaly_detection import anomaly_detection
|
|
|
231 |
face_img = cv2.imread(face_path)
|
232 |
if face_img is not None:
|
233 |
face_img = cv2.cvtColor(face_img, cv2.COLOR_BGR2RGB)
|
|
|
|
|
234 |
timecode = df[df['Frame'] == frame]['Timecode'].iloc[0]
|
235 |
face_img_with_timecode = add_timecode_to_image(face_img, timecode)
|
236 |
anomaly_faces_embeddings.append(face_img_with_timecode)
|