reab5555 commited on
Commit
6ec4314
·
verified ·
1 Parent(s): 7f3ac2a

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +7 -2
app.py CHANGED
@@ -32,8 +32,13 @@ def process_and_show_completion(video_input_path, anomaly_threshold_input, fps,
32
  face_samples_frequent = [Image.open(path) for path in face_samples_frequent]
33
  face_samples_other = [Image.open(path) for path in face_samples_other]
34
 
35
- kde_plot = create_kdeplot(df, mse_embeddings, mse_posture)
36
- joint_plot = create_jointplot(df, mse_embeddings, mse_posture)
 
 
 
 
 
37
 
38
  output = [
39
  exec_time, results_summary,
 
32
  face_samples_frequent = [Image.open(path) for path in face_samples_frequent]
33
  face_samples_other = [Image.open(path) for path in face_samples_other]
34
 
35
+ # Convert timecodes to seconds for plotting
36
+ df['Timecode_Seconds'] = df['Timecode'].apply(lambda x: sum(float(t) * 60 ** i for i, t in enumerate(reversed(x.split(':')))))
37
+ # Combine MSE values (you might want to adjust this based on your specific needs)
38
+ df['MSE_Combined'] = (df['MSE_Embeddings'] + df['MSE_Posture']) / 2
39
+
40
+ kde_plot = create_kdeplot(df)
41
+ joint_plot = create_jointplot(df)
42
 
43
  output = [
44
  exec_time, results_summary,