diff --git a/data/Fall_Simulation_Data/annotations_test.csv b/data/Fall_Simulation_Data/annotations_test.csv
new file mode 100644
index 0000000..7ad633f
--- /dev/null
+++ b/data/Fall_Simulation_Data/annotations_test.csv
@@ -0,0 +1,73 @@
+video_path,video_name,category,camera_id,scenario_id,fall_start,fall_end,lying_start,lying_end,length,fall_visible,lying_visible,ranking
+data/Fall_Simulation_Data/videos/Fall3_Cam2.avi,Fall3_Cam2,Fall,2,3,128.0,131.0,131.0,224.0,235,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall13_Cam3.avi,Fall13_Cam3,Fall,3,13,24.0,27.0,27.0,94.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall1_Cam1.avi,Fall1_Cam1,Fall,1,1,47.0,50.0,50.0,125.0,138,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall45_Cam2.avi,Fall45_Cam2,Fall,2,45,20.0,22.0,22.0,28.0,50,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL10_Cam3.avi,ADL10_Cam3,ADL,3,10,,,,,1170,,,
+data/Fall_Simulation_Data/videos/ADL13_Cam4.avi,ADL13_Cam4,ADL,4,13,,,,,860,,,
+data/Fall_Simulation_Data/videos/Fall22_Cam5.avi,Fall22_Cam5,Fall,5,22,19.0,22.0,22.0,127.0,145,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall29_Cam4.avi,Fall29_Cam4,Fall,4,29,23.0,25.0,25.0,37.0,120,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall27_Cam4.avi,Fall27_Cam4,Fall,4,27,67.0,70.0,70.0,121.0,140,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall28_Cam2.avi,Fall28_Cam2,Fall,2,28,68.0,70.0,70.0,134.0,150,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall10_Cam5.avi,Fall10_Cam5,Fall,5,10,23.0,25.0,25.0,168.0,180,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall31_Cam1.avi,Fall31_Cam1,Fall,1,31,65.0,67.0,67.0,158.0,180,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall1_Cam5.avi,Fall1_Cam5,Fall,5,1,47.0,50.0,50.0,125.0,138,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall46_Cam5.avi,Fall46_Cam5,Fall,5,46,26.0,28.0,28.0,39.0,60,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall30_Cam1.avi,Fall30_Cam1,Fall,1,30,24.0,27.0,27.0,88.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL1_Cam2.avi,ADL1_Cam2,ADL,2,1,,,,,1800,,,
+data/Fall_Simulation_Data/videos/Fall49_Cam2.avi,Fall49_Cam2,Fall,2,49,24.0,26.0,26.0,123.0,145,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL13_Cam3.avi,ADL13_Cam3,ADL,3,13,,,,,860,,,
+data/Fall_Simulation_Data/videos/Fall35_Cam4.avi,Fall35_Cam4,Fall,4,35,29.0,32.0,32.0,230.0,245,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL15_Cam4.avi,ADL15_Cam4,ADL,4,15,,,,,1165,,,
+data/Fall_Simulation_Data/videos/ADL12_Cam3.avi,ADL12_Cam3,ADL,3,12,,,,,1420,,,
+data/Fall_Simulation_Data/videos/Fall15_Cam5.avi,Fall15_Cam5,Fall,5,15,10.0,12.0,12.0,103.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall35_Cam2.avi,Fall35_Cam2,Fall,2,35,29.0,32.0,32.0,230.0,245,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall51_Cam4.avi,Fall51_Cam4,Fall,4,51,28.0,31.0,31.0,140.0,150,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall6_Cam4.avi,Fall6_Cam4,Fall,4,6,44.0,47.0,47.0,238.0,255,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall27_Cam3.avi,Fall27_Cam3,Fall,3,27,67.0,70.0,70.0,121.0,140,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL3_Cam4.avi,ADL3_Cam4,ADL,4,3,,,,,740,,,
+data/Fall_Simulation_Data/videos/Fall33_Cam5.avi,Fall33_Cam5,Fall,5,33,28.0,30.0,30.0,200.0,225,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall41_Cam3.avi,Fall41_Cam3,Fall,3,41,39.0,42.0,42.0,95.0,140,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall43_Cam5.avi,Fall43_Cam5,Fall,5,43,64.0,66.0,66.0,106.0,145,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall3_Cam3.avi,Fall3_Cam3,Fall,3,3,128.0,131.0,131.0,224.0,235,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall26_Cam1.avi,Fall26_Cam1,Fall,1,26,15.0,18.0,18.0,106.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall30_Cam4.avi,Fall30_Cam4,Fall,4,30,24.0,27.0,27.0,88.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL10_Cam2.avi,ADL10_Cam2,ADL,2,10,,,,,1170,,,
+data/Fall_Simulation_Data/videos/Fall50_Cam5.avi,Fall50_Cam5,Fall,5,50,15.0,18.0,18.0,131.0,140,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall37_Cam2.avi,Fall37_Cam2,Fall,2,37,30.0,33.0,33.0,88.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL15_Cam5.avi,ADL15_Cam5,ADL,5,15,,,,,1165,,,
+data/Fall_Simulation_Data/videos/Fall28_Cam4.avi,Fall28_Cam4,Fall,4,28,68.0,70.0,70.0,134.0,150,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall26_Cam4.avi,Fall26_Cam4,Fall,4,26,15.0,18.0,18.0,106.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL12_Cam5.avi,ADL12_Cam5,ADL,5,12,,,,,1420,,,
+data/Fall_Simulation_Data/videos/ADL3_Cam5.avi,ADL3_Cam5,ADL,5,3,,,,,740,,,
+data/Fall_Simulation_Data/videos/Fall46_Cam4.avi,Fall46_Cam4,Fall,4,46,26.0,28.0,28.0,39.0,60,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall52_Cam2.avi,Fall52_Cam2,Fall,2,52,43.0,45.0,45.0,164.0,180,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall14_Cam1.avi,Fall14_Cam1,Fall,1,14,11.0,13.0,13.0,220.0,255,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall24_Cam2.avi,Fall24_Cam2,Fall,2,24,30.0,33.0,33.0,97.0,130,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall10_cam4.avi,Fall10_cam4,Fall,4,10,23.0,25.0,25.0,168.0,180,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall5_Cam3.avi,Fall5_Cam3,Fall,3,5,32.0,34.0,34.0,216.0,235,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL7_Cam5.avi,ADL7_Cam5,ADL,5,7,,,,,1528,,,
+data/Fall_Simulation_Data/videos/ADL12_Cam4.avi,ADL12_Cam4,ADL,4,12,,,,,1420,,,
+data/Fall_Simulation_Data/videos/Fall33_Cam3.avi,Fall33_Cam3,Fall,3,33,28.0,30.0,30.0,200.0,225,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall35_Cam3.avi,Fall35_Cam3,Fall,3,35,29.0,32.0,32.0,230.0,245,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall14_Cam2.avi,Fall14_Cam2,Fall,2,14,11.0,13.0,13.0,220.0,255,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL14_Cam2.avi,ADL14_Cam2,ADL,2,14,,,,,1450,,,
+data/Fall_Simulation_Data/videos/Fall23_Cam5.avi,Fall23_Cam5,Fall,5,23,16.0,19.0,19.0,110.0,126,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall12_Cam1.avi,Fall12_Cam1,Fall,1,12,16.0,18.0,18.0,71.0,72,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall33_Cam2.avi,Fall33_Cam2,Fall,2,33,28.0,30.0,30.0,200.0,225,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall39_Cam2.avi,Fall39_Cam2,Fall,2,39,30.0,32.0,32.0,86.0,110,True,False,5.0
+data/Fall_Simulation_Data/videos/Fall44_Cam4.avi,Fall44_Cam4,Fall,4,44,26.0,28.0,28.0,31.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall27_Cam2.avi,Fall27_Cam2,Fall,2,27,67.0,70.0,70.0,121.0,140,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall4_Cam5.avi,Fall4_Cam5,Fall,5,4,95.0,96.0,96.0,195.0,235,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall30_Cam3.avi,Fall30_Cam3,Fall,3,30,24.0,27.0,27.0,88.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall46_Cam2.avi,Fall46_Cam2,Fall,2,46,26.0,28.0,28.0,39.0,60,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall42_Cam4.avi,Fall42_Cam4,Fall,4,42,79.0,81.0,81.0,92.0,140,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall29_Cam2.avi,Fall29_Cam2,Fall,2,29,23.0,25.0,25.0,37.0,120,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall7_Cam5.avi,Fall7_Cam5,Fall,5,7,28.0,31.0,31.0,219.0,230,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall6_Cam5.avi,Fall6_Cam5,Fall,5,6,44.0,47.0,47.0,238.0,255,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL9_Cam5.avi,ADL9_Cam5,ADL,5,9,,,,,1140,,,
+data/Fall_Simulation_Data/videos/ADL5_Cam2.avi,ADL5_Cam2,ADL,2,5,,,,,698,,,
+data/Fall_Simulation_Data/videos/Fall47_Cam4.avi,Fall47_Cam4,Fall,4,47,25.0,28.0,28.0,39.0,55,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall38_Cam4.avi,Fall38_Cam4,Fall,4,38,24.0,26.0,26.0,78.0,90,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL16_Cam1.avi,ADL16_Cam1,ADL,1,16,,,,,840,,,
+data/Fall_Simulation_Data/videos/Fall48_Cam3.avi,Fall48_Cam3,Fall,3,48,32.0,34.0,34.0,47.0,70,True,True,2.0
diff --git a/data/Fall_Simulation_Data/annotations_train.csv b/data/Fall_Simulation_Data/annotations_train.csv
new file mode 100644
index 0000000..a4ca83c
--- /dev/null
+++ b/data/Fall_Simulation_Data/annotations_train.csv
@@ -0,0 +1,250 @@
+video_path,video_name,category,camera_id,scenario_id,fall_start,fall_end,lying_start,lying_end,length,fall_visible,lying_visible,ranking
+data/Fall_Simulation_Data/videos/Fall7_Cam4.avi,Fall7_Cam4,Fall,4,7,28.0,31.0,31.0,219.0,230,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall23_Cam3.avi,Fall23_Cam3,Fall,3,23,16.0,19.0,19.0,110.0,126,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall7_Cam2.avi,Fall7_Cam2,Fall,2,7,28.0,31.0,31.0,219.0,230,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall50_Cam4.avi,Fall50_Cam4,Fall,4,50,15.0,18.0,18.0,131.0,140,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall34_Cam4.avi,Fall34_Cam4,Fall,4,34,25.0,28.0,28.0,241.0,265,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall23_Cam1.avi,Fall23_Cam1,Fall,1,23,16.0,19.0,19.0,110.0,126,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall12_Cam2.avi,Fall12_Cam2,Fall,2,12,16.0,18.0,18.0,71.0,72,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall50_Cam1.avi,Fall50_Cam1,Fall,1,50,15.0,18.0,18.0,131.0,140,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL17_Cam5.avi,ADL17_Cam5,ADL,5,17,,,,,1875,,,
+data/Fall_Simulation_Data/videos/Fall48_Cam1.avi,Fall48_Cam1,Fall,1,48,32.0,34.0,34.0,47.0,70,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL5_Cam3.avi,ADL5_Cam3,ADL,3,5,,,,,698,,,
+data/Fall_Simulation_Data/videos/Fall19_Cam5.avi,Fall19_Cam5,Fall,5,19,55.0,58.0,58.0,225.0,240,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall39_Cam5.avi,Fall39_Cam5,Fall,5,39,30.0,32.0,32.0,86.0,110,True,False,3.0
+data/Fall_Simulation_Data/videos/Fall7_Cam1.avi,Fall7_Cam1,Fall,1,7,28.0,31.0,31.0,219.0,230,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall19_Cam1.avi,Fall19_Cam1,Fall,1,19,55.0,58.0,58.0,225.0,240,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall9_Cam3.avi,Fall9_Cam3,Fall,3,9,78.0,80.0,80.0,203.0,224,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall10_Cam1.avi,Fall10_Cam1,Fall,1,10,23.0,25.0,25.0,168.0,180,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall36_Cam2.avi,Fall36_Cam2,Fall,2,36,32.0,34.0,34.0,175.0,245,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall37_Cam5.avi,Fall37_Cam5,Fall,5,37,30.0,33.0,33.0,88.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall18_Cam3.avi,Fall18_Cam3,Fall,3,18,88.0,91.0,91.0,243.0,255,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall11_cam4.avi,Fall11_cam4,Fall,4,11,52.0,54.0,54.0,60.0,145,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall26_Cam5.avi,Fall26_Cam5,Fall,5,26,15.0,18.0,18.0,106.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall53_Cam3.avi,Fall53_Cam3,Fall,3,53,71.0,73.0,73.0,214.0,220,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall42_Cam1.avi,Fall42_Cam1,Fall,1,42,79.0,81.0,81.0,92.0,140,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall39_Cam4.avi,Fall39_Cam4,Fall,4,39,30.0,32.0,32.0,86.0,110,False,False,4.0
+data/Fall_Simulation_Data/videos/ADL12_Cam1.avi,ADL12_Cam1,ADL,1,12,,,,,1420,,,
+data/Fall_Simulation_Data/videos/Fall47_Cam1.avi,Fall47_Cam1,Fall,1,47,25.0,28.0,28.0,39.0,55,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL3_Cam1.avi,ADL3_Cam1,ADL,1,3,,,,,740,,,
+data/Fall_Simulation_Data/videos/Fall41_Cam4.avi,Fall41_Cam4,Fall,4,41,39.0,42.0,42.0,95.0,140,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL7_Cam3.avi,ADL7_Cam3,ADL,3,7,,,,,1528,,,
+data/Fall_Simulation_Data/videos/ADL5_Cam4.avi,ADL5_Cam4,ADL,4,5,,,,,698,,,
+data/Fall_Simulation_Data/videos/Fall16_Cam2.avi,Fall16_Cam2,Fall,2,16,12.0,15.0,15.0,177.0,190,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL16_Cam4.avi,ADL16_Cam4,ADL,4,16,,,,,840,,,
+data/Fall_Simulation_Data/videos/Fall15_Cam3.avi,Fall15_Cam3,Fall,3,15,10.0,12.0,12.0,103.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall54_Cam4.avi,Fall54_Cam4,Fall,4,54,43.0,46.0,46.0,184.0,205,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall35_Cam5.avi,Fall35_Cam5,Fall,5,35,29.0,32.0,32.0,230.0,245,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall11_Cam2.avi,Fall11_Cam2,Fall,2,11,52.0,54.0,54.0,60.0,145,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall2_Cam2.avi,Fall2_Cam2,Fall,2,2,97.0,100.0,100.0,248.0,270,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL15_Cam2.avi,ADL15_Cam2,ADL,2,15,,,,,1165,,,
+data/Fall_Simulation_Data/videos/Fall18_Cam5.avi,Fall18_Cam5,Fall,5,18,88.0,91.0,91.0,243.0,255,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall22_Cam1.avi,Fall22_Cam1,Fall,1,22,19.0,22.0,22.0,127.0,145,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall21_Cam4.avi,Fall21_Cam4,Fall,4,21,49.0,51.0,51.0,160.0,160,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall42_Cam2.avi,Fall42_Cam2,Fall,2,42,79.0,81.0,81.0,92.0,140,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall28_Cam3.avi,Fall28_Cam3,Fall,3,28,68.0,70.0,70.0,134.0,150,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL8_Cam2.avi,ADL8_Cam2,ADL,2,8,,,,,880,,,
+data/Fall_Simulation_Data/videos/ADL13_Cam2.avi,ADL13_Cam2,ADL,2,13,,,,,860,,,
+data/Fall_Simulation_Data/videos/ADL9_Cam2.avi,ADL9_Cam2,ADL,2,9,,,,,1140,,,
+data/Fall_Simulation_Data/videos/Fall35_Cam1.avi,Fall35_Cam1,Fall,1,35,29.0,32.0,32.0,230.0,245,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL4_Cam3.avi,ADL4_Cam3,ADL,3,4,,,,,828,,,
+data/Fall_Simulation_Data/videos/Fall24_Cam4.avi,Fall24_Cam4,Fall,4,24,30.0,33.0,33.0,97.0,130,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL4_Cam5.avi,ADL4_Cam5,ADL,5,4,,,,,828,,,
+data/Fall_Simulation_Data/videos/ADL14_Cam5.avi,ADL14_Cam5,ADL,5,14,,,,,1450,,,
+data/Fall_Simulation_Data/videos/Fall24_Cam3.avi,Fall24_Cam3,Fall,3,24,30.0,33.0,33.0,97.0,130,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall29_Cam5.avi,Fall29_Cam5,Fall,5,29,23.0,25.0,25.0,37.0,120,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall21_Cam5.avi,Fall21_Cam5,Fall,5,21,49.0,51.0,51.0,160.0,160,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall55_Cam4.avi,Fall55_Cam4,Fall,4,55,29.0,32.0,32.0,164.0,180,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall55_Cam3.avi,Fall55_Cam3,Fall,3,55,29.0,32.0,32.0,164.0,180,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall17_Cam4.avi,Fall17_Cam4,Fall,4,17,14.0,16.0,16.0,112.0,124,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL5_Cam1.avi,ADL5_Cam1,ADL,1,5,,,,,698,,,
+data/Fall_Simulation_Data/videos/Fall41_Cam2.avi,Fall41_Cam2,Fall,2,41,39.0,42.0,42.0,95.0,140,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall8_Cam2.avi,Fall8_Cam2,Fall,2,8,79.0,82.0,82.0,188.0,200,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall54_Cam5.avi,Fall54_Cam5,Fall,5,54,43.0,46.0,46.0,184.0,205,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall18_Cam2.avi,Fall18_Cam2,Fall,2,18,88.0,91.0,91.0,243.0,255,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL3_Cam2.avi,ADL3_Cam2,ADL,2,3,,,,,740,,,
+data/Fall_Simulation_Data/videos/ADL10_Cam1.avi,ADL10_Cam1,ADL,1,10,,,,,1170,,,
+data/Fall_Simulation_Data/videos/Fall23_Cam2.avi,Fall23_Cam2,Fall,2,23,16.0,19.0,19.0,110.0,126,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall34_Cam2.avi,Fall34_Cam2,Fall,2,34,25.0,28.0,28.0,241.0,265,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall5_Cam4.avi,Fall5_Cam4,Fall,4,5,32.0,34.0,34.0,216.0,235,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall32_Cam5.avi,Fall32_Cam5,Fall,5,32,53.0,55.0,55.0,144.0,174,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL6_Cam5.avi,ADL6_Cam5,ADL,5,6,,,,,1490,,,
+data/Fall_Simulation_Data/videos/Fall6_Cam1.avi,Fall6_Cam1,Fall,1,6,44.0,47.0,47.0,238.0,255,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall16_Cam1.avi,Fall16_Cam1,Fall,1,16,12.0,15.0,15.0,177.0,190,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall2_Cam4.avi,Fall2_Cam4,Fall,4,2,97.0,100.0,100.0,248.0,270,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall39_Cam3.avi,Fall39_Cam3,Fall,3,39,30.0,32.0,32.0,86.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall24_Cam1.avi,Fall24_Cam1,Fall,1,24,30.0,33.0,33.0,97.0,130,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall25_Cam1.avi,Fall25_Cam1,Fall,1,25,23.0,25.0,25.0,96.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall31_Cam2.avi,Fall31_Cam2,Fall,2,31,65.0,67.0,67.0,158.0,180,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall42_Cam5.avi,Fall42_Cam5,Fall,5,42,79.0,81.0,81.0,92.0,140,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall51_Cam2.avi,Fall51_Cam2,Fall,2,51,28.0,31.0,31.0,140.0,150,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall3_Cam1.avi,Fall3_Cam1,Fall,1,3,128.0,131.0,131.0,224.0,235,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL16_Cam3.avi,ADL16_Cam3,ADL,3,16,,,,,840,,,
+data/Fall_Simulation_Data/videos/Fall22_Cam4.avi,Fall22_Cam4,Fall,4,22,19.0,22.0,22.0,127.0,145,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall4_Cam4.avi,Fall4_Cam4,Fall,4,4,95.0,96.0,96.0,195.0,235,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall45_Cam1.avi,Fall45_Cam1,Fall,1,45,20.0,22.0,22.0,28.0,50,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall4_Cam2.avi,Fall4_Cam2,Fall,2,4,95.0,96.0,96.0,195.0,235,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall15_Cam4.avi,Fall15_Cam4,Fall,4,15,10.0,12.0,12.0,103.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL17_Cam3.avi,ADL17_Cam3,ADL,3,17,,,,,1875,,,
+data/Fall_Simulation_Data/videos/Fall51_Cam5.avi,Fall51_Cam5,Fall,5,51,28.0,31.0,31.0,140.0,150,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall51_Cam3.avi,Fall51_Cam3,Fall,3,51,28.0,31.0,31.0,140.0,150,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall37_Cam3.avi,Fall37_Cam3,Fall,3,37,30.0,33.0,33.0,88.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall36_Cam5.avi,Fall36_Cam5,Fall,5,36,32.0,34.0,34.0,175.0,245,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall16_Cam4.avi,Fall16_Cam4,Fall,4,16,12.0,15.0,15.0,177.0,190,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall18_Cam1.avi,Fall18_Cam1,Fall,1,18,88.0,91.0,91.0,243.0,255,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall44_Cam2.avi,Fall44_Cam2,Fall,2,44,26.0,28.0,28.0,31.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall38_Cam1.avi,Fall38_Cam1,Fall,1,38,24.0,26.0,26.0,78.0,90,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall54_Cam2.avi,Fall54_Cam2,Fall,2,54,43.0,46.0,46.0,184.0,205,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL3_Cam3.avi,ADL3_Cam3,ADL,3,3,,,,,740,,,
+data/Fall_Simulation_Data/videos/Fall47_Cam2.avi,Fall47_Cam2,Fall,2,47,25.0,28.0,28.0,39.0,55,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall36_Cam3.avi,Fall36_Cam3,Fall,3,36,32.0,34.0,34.0,175.0,245,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall42_Cam3.avi,Fall42_Cam3,Fall,3,42,79.0,81.0,81.0,92.0,140,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall55_Cam1.avi,Fall55_Cam1,Fall,1,55,29.0,32.0,32.0,164.0,180,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL4_Cam2.avi,ADL4_Cam2,ADL,2,4,,,,,828,,,
+data/Fall_Simulation_Data/videos/Fall52_Cam5.avi,Fall52_Cam5,Fall,5,52,43.0,45.0,45.0,164.0,180,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall37_Cam1.avi,Fall37_Cam1,Fall,1,37,30.0,33.0,33.0,88.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL11_Cam4.avi,ADL11_Cam4,ADL,4,11,,,,,2130,,,
+data/Fall_Simulation_Data/videos/Fall27_Cam5.avi,Fall27_Cam5,Fall,5,27,67.0,70.0,70.0,121.0,140,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall19_Cam3.avi,Fall19_Cam3,Fall,3,19,55.0,58.0,58.0,225.0,240,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall39_Cam1.avi,Fall39_Cam1,Fall,1,39,30.0,32.0,32.0,86.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall43_Cam1.avi,Fall43_Cam1,Fall,1,43,64.0,66.0,66.0,106.0,145,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall27_Cam1.avi,Fall27_Cam1,Fall,1,27,67.0,70.0,70.0,121.0,140,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL6_Cam1.avi,ADL6_Cam1,ADL,1,6,,,,,1490,,,
+data/Fall_Simulation_Data/videos/Fall17_Cam2.avi,Fall17_Cam2,Fall,2,17,14.0,16.0,16.0,112.0,124,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall52_Cam1.avi,Fall52_Cam1,Fall,1,52,43.0,45.0,45.0,164.0,180,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall23_Cam4.avi,Fall23_Cam4,Fall,4,23,16.0,19.0,19.0,110.0,126,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall5_Cam5.avi,Fall5_Cam5,Fall,5,5,32.0,34.0,34.0,216.0,235,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL17_Cam2.avi,ADL17_Cam2,ADL,2,17,,,,,1875,,,
+data/Fall_Simulation_Data/videos/Fall10_Cam2.avi,Fall10_Cam2,Fall,2,10,23.0,25.0,25.0,168.0,180,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL8_Cam3.avi,ADL8_Cam3,ADL,3,8,,,,,880,,,
+data/Fall_Simulation_Data/videos/Fall40_Cam4.avi,Fall40_Cam4,Fall,4,40,53.0,55.0,55.0,115.0,140,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall45_Cam5.avi,Fall45_Cam5,Fall,5,45,20.0,22.0,22.0,28.0,50,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall13_Cam1.avi,Fall13_Cam1,Fall,1,13,24.0,27.0,27.0,94.0,110,True,False,4.0
+data/Fall_Simulation_Data/videos/Fall50_Cam2.avi,Fall50_Cam2,Fall,2,50,15.0,18.0,18.0,131.0,140,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall16_Cam3.avi,Fall16_Cam3,Fall,3,16,12.0,15.0,15.0,177.0,190,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall15_Cam2.avi,Fall15_Cam2,Fall,2,15,10.0,12.0,12.0,103.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL17_Cam1.avi,ADL17_Cam1,ADL,1,17,,,,,1875,,,
+data/Fall_Simulation_Data/videos/Fall50_Cam3.avi,Fall50_Cam3,Fall,3,50,15.0,18.0,18.0,131.0,140,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall16_Cam5.avi,Fall16_Cam5,Fall,5,16,12.0,15.0,15.0,177.0,190,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL8_Cam5.avi,ADL8_Cam5,ADL,5,8,,,,,880,,,
+data/Fall_Simulation_Data/videos/Fall8_Cam3.avi,Fall8_Cam3,Fall,3,8,79.0,82.0,82.0,188.0,200,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL2_Cam5.avi,ADL2_Cam5,ADL,5,2,,,,,1335,,,
+data/Fall_Simulation_Data/videos/Fall43_Cam2.avi,Fall43_Cam2,Fall,2,43,64.0,66.0,66.0,106.0,145,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall31_Cam5.avi,Fall31_Cam5,Fall,5,31,65.0,67.0,67.0,158.0,180,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall11_Cam1.avi,Fall11_Cam1,Fall,1,11,52.0,54.0,54.0,60.0,145,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall28_Cam1.avi,Fall28_Cam1,Fall,1,28,68.0,70.0,70.0,134.0,150,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall54_Cam1.avi,Fall54_Cam1,Fall,1,54,43.0,46.0,46.0,184.0,205,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall12_Cam4.avi,Fall12_Cam4,Fall,4,12,16.0,18.0,18.0,71.0,72,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL6_Cam2.avi,ADL6_Cam2,ADL,2,6,,,,,1490,,,
+data/Fall_Simulation_Data/videos/Fall31_Cam4.avi,Fall31_Cam4,Fall,4,31,65.0,67.0,67.0,158.0,180,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall13_Cam4.avi,Fall13_Cam4,Fall,4,13,24.0,27.0,27.0,94.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL17_Cam4.avi,ADL17_Cam4,ADL,4,17,,,,,1875,,,
+data/Fall_Simulation_Data/videos/Fall20_Cam1.avi,Fall20_Cam1,Fall,1,20,84.0,86.0,86.0,91.0,240,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall44_Cam3.avi,Fall44_Cam3,Fall,3,44,26.0,28.0,28.0,31.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall7_Cam3.avi,Fall7_Cam3,Fall,3,7,28.0,31.0,31.0,219.0,230,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall55_Cam5.avi,Fall55_Cam5,Fall,5,55,29.0,32.0,32.0,164.0,180,True,False,5.0
+data/Fall_Simulation_Data/videos/Fall21_Cam2.avi,Fall21_Cam2,Fall,2,21,49.0,51.0,51.0,160.0,160,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall11_Cam5.avi,Fall11_Cam5,Fall,5,11,52.0,54.0,54.0,60.0,145,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL10_Cam5.avi,ADL10_Cam5,ADL,5,10,,,,,1170,,,
+data/Fall_Simulation_Data/videos/Fall44_Cam5.avi,Fall44_Cam5,Fall,5,44,26.0,28.0,28.0,31.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall54_Cam3.avi,Fall54_Cam3,Fall,3,54,43.0,46.0,46.0,184.0,205,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall38_Cam5.avi,Fall38_Cam5,Fall,5,38,24.0,26.0,26.0,78.0,90,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall22_Cam3.avi,Fall22_Cam3,Fall,3,22,19.0,22.0,22.0,127.0,145,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL11_Cam5.avi,ADL11_Cam5,ADL,5,11,,,,,2130,,,
+data/Fall_Simulation_Data/videos/Fall12_Cam5.avi,Fall12_Cam5,Fall,5,12,16.0,18.0,18.0,71.0,72,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL7_Cam4.avi,ADL7_Cam4,ADL,4,7,,,,,1528,,,
+data/Fall_Simulation_Data/videos/Fall53_Cam4.avi,Fall53_Cam4,Fall,4,53,71.0,73.0,73.0,214.0,220,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall2_Cam5.avi,Fall2_Cam5,Fall,5,2,97.0,100.0,100.0,248.0,270,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall47_Cam5.avi,Fall47_Cam5,Fall,5,47,25.0,28.0,28.0,39.0,55,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL7_Cam2.avi,ADL7_Cam2,ADL,2,7,,,,,1528,,,
+data/Fall_Simulation_Data/videos/Fall45_Cam3.avi,Fall45_Cam3,Fall,3,45,20.0,22.0,22.0,28.0,50,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall20_Cam2.avi,Fall20_Cam2,Fall,2,20,84.0,86.0,86.0,91.0,240,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall5_Cam1.avi,Fall5_Cam1,Fall,1,5,32.0,34.0,34.0,216.0,235,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL15_Cam1.avi,ADL15_Cam1,ADL,1,15,,,,,1165,,,
+data/Fall_Simulation_Data/videos/ADL1_Cam3.avi,ADL1_Cam3,ADL,3,1,,,,,1800,,,
+data/Fall_Simulation_Data/videos/Fall30_Cam2.avi,Fall30_Cam2,Fall,2,30,24.0,27.0,27.0,88.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall1_Cam3.avi,Fall1_Cam3,Fall,3,1,47.0,50.0,50.0,125.0,138,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall8_Cam5.avi,Fall8_Cam5,Fall,5,8,79.0,82.0,82.0,188.0,200,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall40_Cam3.avi,Fall40_Cam3,Fall,3,40,53.0,55.0,55.0,115.0,140,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall4_Cam1.avi,Fall4_Cam1,Fall,1,4,95.0,96.0,96.0,195.0,235,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall47_Cam3.avi,Fall47_Cam3,Fall,3,47,25.0,28.0,28.0,39.0,55,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL2_Cam3.avi,ADL2_Cam3,ADL,3,2,,,,,1335,,,
+data/Fall_Simulation_Data/videos/Fall9_Cam5.avi,Fall9_Cam5,Fall,5,9,78.0,80.0,80.0,203.0,224,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall10_Cam3.avi,Fall10_Cam3,Fall,3,10,23.0,25.0,25.0,168.0,180,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall25_Cam5.avi,Fall25_Cam5,Fall,5,25,23.0,25.0,25.0,96.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall8_Cam1.avi,Fall8_Cam1,Fall,1,8,79.0,82.0,82.0,188.0,200,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall52_Cam4.avi,Fall52_Cam4,Fall,4,52,43.0,45.0,45.0,164.0,180,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL11_Cam2.avi,ADL11_Cam2,ADL,2,11,,,,,2130,,,
+data/Fall_Simulation_Data/videos/Fall38_Cam3.avi,Fall38_Cam3,Fall,3,38,24.0,26.0,26.0,78.0,90,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall5_Cam2.avi,Fall5_Cam2,Fall,2,5,32.0,34.0,34.0,216.0,235,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall46_Cam3.avi,Fall46_Cam3,Fall,3,46,26.0,28.0,28.0,39.0,60,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall32_Cam2.avi,Fall32_Cam2,Fall,2,32,53.0,55.0,55.0,144.0,174,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall40_Cam5.avi,Fall40_Cam5,Fall,5,40,53.0,55.0,55.0,115.0,140,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall14_Cam4.avi,Fall14_Cam4,Fall,4,14,11.0,13.0,13.0,220.0,255,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall2_Cam3.avi,Fall2_Cam3,Fall,3,2,97.0,100.0,100.0,248.0,270,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall12_Cam3.avi,Fall12_Cam3,Fall,3,12,16.0,18.0,18.0,71.0,72,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall53_Cam1.avi,Fall53_Cam1,Fall,1,53,71.0,73.0,73.0,214.0,220,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall44_Cam1.avi,Fall44_Cam1,Fall,1,44,26.0,28.0,28.0,31.0,110,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL14_Cam3.avi,ADL14_Cam3,ADL,3,14,,,,,1450,,,
+data/Fall_Simulation_Data/videos/Fall33_Cam4.avi,Fall33_Cam4,Fall,4,33,28.0,30.0,30.0,200.0,225,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL1_Cam4.avi,ADL1_Cam4,ADL,4,1,,,,,1800,,,
+data/Fall_Simulation_Data/videos/Fall29_Cam1.avi,Fall29_Cam1,Fall,1,29,23.0,25.0,25.0,37.0,120,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL4_Cam1.avi,ADL4_Cam1,ADL,1,4,,,,,828,,,
+data/Fall_Simulation_Data/videos/Fall41_Cam5.avi,Fall41_Cam5,Fall,5,41,39.0,42.0,42.0,95.0,140,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall51_Cam1.avi,Fall51_Cam1,Fall,1,51,28.0,31.0,31.0,140.0,150,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall19_Cam2.avi,Fall19_Cam2,Fall,2,19,55.0,58.0,58.0,225.0,240,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL13_Cam5.avi,ADL13_Cam5,ADL,5,13,,,,,860,,,
+data/Fall_Simulation_Data/videos/Fall55_Cam2.avi,Fall55_Cam2,Fall,2,55,29.0,32.0,32.0,164.0,180,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL4_Cam4.avi,ADL4_Cam4,ADL,4,4,,,,,828,,,
+data/Fall_Simulation_Data/videos/Fall21_Cam3.avi,Fall21_Cam3,Fall,3,21,49.0,51.0,51.0,160.0,160,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall18_Cam4.avi,Fall18_Cam4,Fall,4,18,88.0,91.0,91.0,243.0,255,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL14_Cam4.avi,ADL14_Cam4,ADL,4,14,,,,,1450,,,
+data/Fall_Simulation_Data/videos/Fall17_Cam3.avi,Fall17_Cam3,Fall,3,17,14.0,16.0,16.0,112.0,124,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall31_Cam3.avi,Fall31_Cam3,Fall,3,31,65.0,67.0,67.0,158.0,180,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall9_Cam2.avi,Fall9_Cam2,Fall,2,9,78.0,80.0,80.0,203.0,224,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL9_Cam3.avi,ADL9_Cam3,ADL,3,9,,,,,1140,,,
+data/Fall_Simulation_Data/videos/ADL6_Cam4.avi,ADL6_Cam4,ADL,4,6,,,,,1490,,,
+data/Fall_Simulation_Data/videos/Fall11_Cam3.avi,Fall11_Cam3,Fall,3,11,52.0,54.0,54.0,60.0,145,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall8_Cam4.avi,Fall8_Cam4,Fall,4,8,79.0,82.0,82.0,188.0,200,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall1_Cam4.avi,Fall1_Cam4,Fall,4,1,47.0,50.0,50.0,125.0,138,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL16_Cam2.avi,ADL16_Cam2,ADL,2,16,,,,,840,,,
+data/Fall_Simulation_Data/videos/Fall33_Cam1.avi,Fall33_Cam1,Fall,1,33,28.0,30.0,30.0,200.0,225,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall14_Cam3.avi,Fall14_Cam3,Fall,3,14,11.0,13.0,13.0,220.0,255,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL2_Cam1.avi,ADL2_Cam1,ADL,1,2,,,,,1335,,,
+data/Fall_Simulation_Data/videos/Fall34_Cam5.avi,Fall34_Cam5,Fall,5,34,25.0,28.0,28.0,241.0,265,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall20_Cam3.avi,Fall20_Cam3,Fall,3,20,84.0,86.0,86.0,91.0,240,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall2_Cam1.avi,Fall2_Cam1,Fall,1,2,97.0,100.0,100.0,248.0,270,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall26_Cam3.avi,Fall26_Cam3,Fall,3,26,15.0,18.0,18.0,106.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall49_Cam5.avi,Fall49_Cam5,Fall,5,49,24.0,26.0,26.0,123.0,145,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall49_Cam4.avi,Fall49_Cam4,Fall,4,49,24.0,26.0,26.0,123.0,145,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL13_Cam1.avi,ADL13_Cam1,ADL,1,13,,,,,860,,,
+data/Fall_Simulation_Data/videos/Fall14_Cam5.avi,Fall14_Cam5,Fall,5,14,11.0,13.0,13.0,220.0,255,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall32_Cam1.avi,Fall32_Cam1,Fall,1,32,53.0,55.0,55.0,144.0,174,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall4_Cam3.avi,Fall4_Cam3,Fall,3,4,95.0,96.0,96.0,195.0,235,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL1_Cam5.avi,ADL1_Cam5,ADL,5,1,,,,,1800,,,
+data/Fall_Simulation_Data/videos/Fall25_Cam4.avi,Fall25_Cam4,Fall,4,25,23.0,25.0,25.0,96.0,110,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall36_Cam1.avi,Fall36_Cam1,Fall,1,36,32.0,34.0,34.0,175.0,245,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall41_Cam1.avi,Fall41_Cam1,Fall,1,41,39.0,42.0,42.0,95.0,140,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall49_Cam3.avi,Fall49_Cam3,Fall,3,49,24.0,26.0,26.0,123.0,145,True,False,5.0
+data/Fall_Simulation_Data/videos/Fall19_Cam4.avi,Fall19_Cam4,Fall,4,19,55.0,58.0,58.0,225.0,240,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall48_Cam2.avi,Fall48_Cam2,Fall,2,48,32.0,34.0,34.0,47.0,70,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall52_Cam3.avi,Fall52_Cam3,Fall,3,52,43.0,45.0,45.0,164.0,180,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall20_Cam5.avi,Fall20_Cam5,Fall,5,20,84.0,86.0,86.0,91.0,240,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall3_Cam4.avi,Fall3_Cam4,Fall,4,3,128.0,131.0,131.0,224.0,235,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL16_Cam5.avi,ADL16_Cam5,ADL,5,16,,,,,840,,,
+data/Fall_Simulation_Data/videos/Fall34_Cam1.avi,Fall34_Cam1,Fall,1,34,25.0,28.0,28.0,241.0,265,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL11_Cam3.avi,ADL11_Cam3,ADL,3,11,,,,,2130,,,
+data/Fall_Simulation_Data/videos/Fall1_Cam2.avi,Fall1_Cam2,Fall,2,1,47.0,50.0,50.0,125.0,138,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL6_Cam3.avi,ADL6_Cam3,ADL,3,6,,,,,1490,,,
+data/Fall_Simulation_Data/videos/ADL8_Cam4.avi,ADL8_Cam4,ADL,4,8,,,,,880,,,
+data/Fall_Simulation_Data/videos/Fall36_Cam4.avi,Fall36_Cam4,Fall,4,36,32.0,34.0,34.0,175.0,245,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall48_Cam4.avi,Fall48_Cam4,Fall,4,48,32.0,34.0,34.0,47.0,70,True,True,3.0
+data/Fall_Simulation_Data/videos/ADL11_Cam1.avi,ADL11_Cam1,ADL,1,11,,,,,2130,,,
+data/Fall_Simulation_Data/videos/Fall48_Cam5.avi,Fall48_Cam5,Fall,5,48,32.0,34.0,34.0,47.0,70,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall43_Cam4.avi,Fall43_Cam4,Fall,4,43,64.0,66.0,66.0,106.0,145,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL9_Cam1.avi,ADL9_Cam1,ADL,1,9,,,,,1140,,,
+data/Fall_Simulation_Data/videos/Fall37_Cam4.avi,Fall37_Cam4,Fall,4,37,30.0,33.0,33.0,88.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL14_Cam1.avi,ADL14_Cam1,ADL,1,14,,,,,1450,,,
+data/Fall_Simulation_Data/videos/Fall13_Cam2.avi,Fall13_Cam2,Fall,2,13,24.0,27.0,27.0,94.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall29_Cam3.avi,Fall29_Cam3,Fall,3,29,23.0,25.0,25.0,37.0,120,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL1_Cam1.avi,ADL1_Cam1,ADL,1,1,,,,,1800,,,
diff --git a/data/Fall_Simulation_Data/annotations_val.csv b/data/Fall_Simulation_Data/annotations_val.csv
new file mode 100644
index 0000000..93f77e8
--- /dev/null
+++ b/data/Fall_Simulation_Data/annotations_val.csv
@@ -0,0 +1,37 @@
+video_path,video_name,category,camera_id,scenario_id,fall_start,fall_end,lying_start,lying_end,length,fall_visible,lying_visible,ranking
+data/Fall_Simulation_Data/videos/Fall30_Cam5.avi,Fall30_Cam5,Fall,5,30,24.0,27.0,27.0,88.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall40_Cam1.avi,Fall40_Cam1,Fall,1,40,53.0,55.0,55.0,115.0,140,True,True,2.0
+data/Fall_Simulation_Data/videos/ADL9_Cam4.avi,ADL9_Cam4,ADL,4,9,,,,,1140,,,
+data/Fall_Simulation_Data/videos/Fall32_Cam4.avi,Fall32_Cam4,Fall,4,32,53.0,55.0,55.0,144.0,174,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall9_Cam1.avi,Fall9_Cam1,Fall,1,9,78.0,80.0,80.0,203.0,224,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall24_Cam5.avi,Fall24_Cam5,Fall,5,24,30.0,33.0,33.0,97.0,130,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall28_Cam5.avi,Fall28_Cam5,Fall,5,28,68.0,70.0,70.0,134.0,150,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall25_Cam2.avi,Fall25_Cam2,Fall,2,25,23.0,25.0,25.0,96.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall32_Cam3.avi,Fall32_Cam3,Fall,3,32,53.0,55.0,55.0,144.0,174,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall21_Cam1.avi,Fall21_Cam1,Fall,1,21,49.0,51.0,51.0,160.0,160,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall49_Cam1.avi,Fall49_Cam1,Fall,1,49,24.0,26.0,26.0,123.0,145,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall43_Cam3.avi,Fall43_Cam3,Fall,3,43,64.0,66.0,66.0,106.0,145,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall17_Cam5.avi,Fall17_Cam5,Fall,5,17,14.0,16.0,16.0,112.0,124,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL5_Cam5.avi,ADL5_Cam5,ADL,5,5,,,,,698,,,
+data/Fall_Simulation_Data/videos/ADL15_Cam3.avi,ADL15_Cam3,ADL,3,15,,,,,1165,,,
+data/Fall_Simulation_Data/videos/Fall38_Cam2.avi,Fall38_Cam2,Fall,2,38,24.0,26.0,26.0,78.0,90,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall17_Cam1.avi,Fall17_Cam1,Fall,1,17,14.0,16.0,16.0,112.0,124,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall13_Cam5.avi,Fall13_Cam5,Fall,5,13,24.0,27.0,27.0,94.0,110,True,False,5.0
+data/Fall_Simulation_Data/videos/Fall26_Cam2.avi,Fall26_Cam2,Fall,2,26,15.0,18.0,18.0,106.0,110,True,True,5.0
+data/Fall_Simulation_Data/videos/Fall15_Cam1.avi,Fall15_Cam1,Fall,1,15,10.0,12.0,12.0,103.0,110,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall45_Cam4.avi,Fall45_Cam4,Fall,4,45,20.0,22.0,22.0,28.0,50,True,True,2.0
+data/Fall_Simulation_Data/videos/Fall6_Cam2.avi,Fall6_Cam2,Fall,2,6,44.0,47.0,47.0,238.0,255,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall20_Cam4.avi,Fall20_Cam4,Fall,4,20,84.0,86.0,86.0,91.0,240,True,True,3.0
+data/Fall_Simulation_Data/videos/Fall9_Cam4.avi,Fall9_Cam4,Fall,4,9,78.0,80.0,80.0,203.0,224,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall3_Cam5.avi,Fall3_Cam5,Fall,5,3,128.0,131.0,131.0,224.0,235,True,True,4.0
+data/Fall_Simulation_Data/videos/Fall25_Cam3.avi,Fall25_Cam3,Fall,3,25,23.0,25.0,25.0,96.0,110,True,True,1.0
+data/Fall_Simulation_Data/videos/Fall6_Cam3.avi,Fall6_Cam3,Fall,3,6,44.0,47.0,47.0,238.0,255,True,True,4.0
+data/Fall_Simulation_Data/videos/ADL8_Cam1.avi,ADL8_Cam1,ADL,1,8,,,,,880,,,
+data/Fall_Simulation_Data/videos/ADL2_Cam2.avi,ADL2_Cam2,ADL,2,2,,,,,1335,,,
+data/Fall_Simulation_Data/videos/Fall53_Cam2.avi,Fall53_Cam2,Fall,2,53,71.0,73.0,73.0,214.0,220,True,True,5.0
+data/Fall_Simulation_Data/videos/ADL12_Cam2.avi,ADL12_Cam2,ADL,2,12,,,,,1420,,,
+data/Fall_Simulation_Data/videos/Fall22_Cam2.avi,Fall22_Cam2,Fall,2,22,19.0,22.0,22.0,127.0,145,True,True,1.0
+data/Fall_Simulation_Data/videos/ADL10_Cam4.avi,ADL10_Cam4,ADL,4,10,,,,,1170,,,
+data/Fall_Simulation_Data/videos/ADL7_Cam1.avi,ADL7_Cam1,ADL,1,7,,,,,1528,,,
+data/Fall_Simulation_Data/videos/ADL2_Cam4.avi,ADL2_Cam4,ADL,4,2,,,,,1335,,,
+data/Fall_Simulation_Data/videos/Fall53_Cam5.avi,Fall53_Cam5,Fall,5,53,71.0,73.0,73.0,214.0,220,True,True,2.0
diff --git a/environment.yml b/environment.yml
index 235998a..d59cb54 100644
--- a/environment.yml
+++ b/environment.yml
@@ -15,6 +15,7 @@ dependencies:
- pytorch::torchvision>=0.16
- pandas>=2.1
- openpyxl>=3.0
+ - scikit-learn>=1.3
- pip:
# code-checks
diff --git a/notebooks/dataset_split.ipynb b/notebooks/dataset_split.ipynb
new file mode 100644
index 0000000..bfaecc7
--- /dev/null
+++ b/notebooks/dataset_split.ipynb
@@ -0,0 +1,1514 @@
+{
+ "cells": [
+ {
+ "cell_type": "code",
+ "execution_count": 1,
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "import sys\n",
+ "import os\n",
+ "\n",
+ "sys.path.append(os.getcwd() + \"/../\")\n",
+ "\n",
+ "import pandas as pd\n",
+ "import numpy as np\n",
+ "from scripts.split_dataset import split_dataset"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 2,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/html": [
+ "
\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " video_path | \n",
+ " video_name | \n",
+ " category | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " fall_visible | \n",
+ " lying_visible | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " 0 | \n",
+ " data/Fall_Simulation_Data/videos/ADL17_Cam1.avi | \n",
+ " ADL17_Cam1 | \n",
+ " ADL | \n",
+ " 1 | \n",
+ " 17 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " 1875 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ "
\n",
+ " \n",
+ " 1 | \n",
+ " data/Fall_Simulation_Data/videos/ADL16_Cam1.avi | \n",
+ " ADL16_Cam1 | \n",
+ " ADL | \n",
+ " 1 | \n",
+ " 16 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " 840 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ "
\n",
+ " \n",
+ " 2 | \n",
+ " data/Fall_Simulation_Data/videos/Fall30_Cam3.avi | \n",
+ " Fall30_Cam3 | \n",
+ " Fall | \n",
+ " 3 | \n",
+ " 30 | \n",
+ " 24.0 | \n",
+ " 27.0 | \n",
+ " 27.0 | \n",
+ " 88.0 | \n",
+ " 110 | \n",
+ " True | \n",
+ " True | \n",
+ " 3.0 | \n",
+ "
\n",
+ " \n",
+ " 3 | \n",
+ " data/Fall_Simulation_Data/videos/Fall19_Cam4.avi | \n",
+ " Fall19_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 19 | \n",
+ " 55.0 | \n",
+ " 58.0 | \n",
+ " 58.0 | \n",
+ " 225.0 | \n",
+ " 240 | \n",
+ " True | \n",
+ " True | \n",
+ " 4.0 | \n",
+ "
\n",
+ " \n",
+ " 4 | \n",
+ " data/Fall_Simulation_Data/videos/Fall18_Cam4.avi | \n",
+ " Fall18_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 18 | \n",
+ " 88.0 | \n",
+ " 91.0 | \n",
+ " 91.0 | \n",
+ " 243.0 | \n",
+ " 255 | \n",
+ " True | \n",
+ " True | \n",
+ " 5.0 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " video_path video_name category \\\n",
+ "0 data/Fall_Simulation_Data/videos/ADL17_Cam1.avi ADL17_Cam1 ADL \n",
+ "1 data/Fall_Simulation_Data/videos/ADL16_Cam1.avi ADL16_Cam1 ADL \n",
+ "2 data/Fall_Simulation_Data/videos/Fall30_Cam3.avi Fall30_Cam3 Fall \n",
+ "3 data/Fall_Simulation_Data/videos/Fall19_Cam4.avi Fall19_Cam4 Fall \n",
+ "4 data/Fall_Simulation_Data/videos/Fall18_Cam4.avi Fall18_Cam4 Fall \n",
+ "\n",
+ " camera_id scenario_id fall_start fall_end lying_start lying_end \\\n",
+ "0 1 17 NaN NaN NaN NaN \n",
+ "1 1 16 NaN NaN NaN NaN \n",
+ "2 3 30 24.0 27.0 27.0 88.0 \n",
+ "3 4 19 55.0 58.0 58.0 225.0 \n",
+ "4 4 18 88.0 91.0 91.0 243.0 \n",
+ "\n",
+ " length fall_visible lying_visible ranking \n",
+ "0 1875 NaN NaN NaN \n",
+ "1 840 NaN NaN NaN \n",
+ "2 110 True True 3.0 \n",
+ "3 240 True True 4.0 \n",
+ "4 255 True True 5.0 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " count | \n",
+ " 357.000000 | \n",
+ " 357.000000 | \n",
+ " 272.000000 | \n",
+ " 272.000000 | \n",
+ " 272.000000 | \n",
+ " 272.000000 | \n",
+ " 357.000000 | \n",
+ " 272.000000 | \n",
+ "
\n",
+ " \n",
+ " mean | \n",
+ " 3.008403 | \n",
+ " 23.375350 | \n",
+ " 41.602941 | \n",
+ " 44.040441 | \n",
+ " 44.040441 | \n",
+ " 138.400735 | \n",
+ " 424.005602 | \n",
+ " 2.992647 | \n",
+ "
\n",
+ " \n",
+ " std | \n",
+ " 1.417165 | \n",
+ " 16.239578 | \n",
+ " 26.260202 | \n",
+ " 26.227542 | \n",
+ " 26.227542 | \n",
+ " 62.439264 | \n",
+ " 510.244054 | \n",
+ " 1.408966 | \n",
+ "
\n",
+ " \n",
+ " min | \n",
+ " 1.000000 | \n",
+ " 1.000000 | \n",
+ " 10.000000 | \n",
+ " 12.000000 | \n",
+ " 12.000000 | \n",
+ " 28.000000 | \n",
+ " 50.000000 | \n",
+ " 1.000000 | \n",
+ "
\n",
+ " \n",
+ " 25% | \n",
+ " 2.000000 | \n",
+ " 9.000000 | \n",
+ " 24.000000 | \n",
+ " 26.000000 | \n",
+ " 26.000000 | \n",
+ " 92.000000 | \n",
+ " 138.000000 | \n",
+ " 2.000000 | \n",
+ "
\n",
+ " \n",
+ " 50% | \n",
+ " 3.000000 | \n",
+ " 19.000000 | \n",
+ " 30.000000 | \n",
+ " 33.000000 | \n",
+ " 33.000000 | \n",
+ " 127.000000 | \n",
+ " 190.000000 | \n",
+ " 3.000000 | \n",
+ "
\n",
+ " \n",
+ " 75% | \n",
+ " 4.000000 | \n",
+ " 37.000000 | \n",
+ " 55.000000 | \n",
+ " 58.000000 | \n",
+ " 58.000000 | \n",
+ " 195.000000 | \n",
+ " 270.000000 | \n",
+ " 4.000000 | \n",
+ "
\n",
+ " \n",
+ " max | \n",
+ " 5.000000 | \n",
+ " 55.000000 | \n",
+ " 128.000000 | \n",
+ " 131.000000 | \n",
+ " 131.000000 | \n",
+ " 248.000000 | \n",
+ " 2130.000000 | \n",
+ " 5.000000 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " camera_id scenario_id fall_start fall_end lying_start \\\n",
+ "count 357.000000 357.000000 272.000000 272.000000 272.000000 \n",
+ "mean 3.008403 23.375350 41.602941 44.040441 44.040441 \n",
+ "std 1.417165 16.239578 26.260202 26.227542 26.227542 \n",
+ "min 1.000000 1.000000 10.000000 12.000000 12.000000 \n",
+ "25% 2.000000 9.000000 24.000000 26.000000 26.000000 \n",
+ "50% 3.000000 19.000000 30.000000 33.000000 33.000000 \n",
+ "75% 4.000000 37.000000 55.000000 58.000000 58.000000 \n",
+ "max 5.000000 55.000000 128.000000 131.000000 131.000000 \n",
+ "\n",
+ " lying_end length ranking \n",
+ "count 272.000000 357.000000 272.000000 \n",
+ "mean 138.400735 424.005602 2.992647 \n",
+ "std 62.439264 510.244054 1.408966 \n",
+ "min 28.000000 50.000000 1.000000 \n",
+ "25% 92.000000 138.000000 2.000000 \n",
+ "50% 127.000000 190.000000 3.000000 \n",
+ "75% 195.000000 270.000000 4.000000 \n",
+ "max 248.000000 2130.000000 5.000000 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "RangeIndex: 357 entries, 0 to 356\n",
+ "Data columns (total 13 columns):\n",
+ " # Column Non-Null Count Dtype \n",
+ "--- ------ -------------- ----- \n",
+ " 0 video_path 357 non-null object \n",
+ " 1 video_name 357 non-null object \n",
+ " 2 category 357 non-null object \n",
+ " 3 camera_id 357 non-null int64 \n",
+ " 4 scenario_id 357 non-null int64 \n",
+ " 5 fall_start 272 non-null float64\n",
+ " 6 fall_end 272 non-null float64\n",
+ " 7 lying_start 272 non-null float64\n",
+ " 8 lying_end 272 non-null float64\n",
+ " 9 length 357 non-null int64 \n",
+ " 10 fall_visible 272 non-null object \n",
+ " 11 lying_visible 272 non-null object \n",
+ " 12 ranking 272 non-null float64\n",
+ "dtypes: float64(5), int64(3), object(5)\n",
+ "memory usage: 36.4+ KB\n"
+ ]
+ },
+ {
+ "data": {
+ "text/plain": [
+ "None"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "category\n",
+ "Fall 0.761905\n",
+ "ADL 0.238095\n",
+ "Name: count, dtype: float64"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "raw_dataset = pd.read_csv(\"../data/Fall_Simulation_Data/annotations.csv\")\n",
+ "\n",
+ "display(raw_dataset.head())\n",
+ "\n",
+ "display(raw_dataset.describe())\n",
+ "\n",
+ "display(raw_dataset.info())\n",
+ "\n",
+ "display(raw_dataset[\"category\"].value_counts() / len(raw_dataset))"
+ ]
+ },
+ {
+ "cell_type": "markdown",
+ "metadata": {},
+ "source": [
+ "# Split the data!\n",
+ "\n",
+ "We split the data into train, test, and validation csv files on a per video level.\n",
+ "Since ADL videos are much longer (and thus produce more samples in our method), we\n",
+ "want to keep the proportion of ADL videos vs. Fall videos similar among the different\n",
+ "splits. Hence, we stratify by the `category` column.\n"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 4,
+ "metadata": {},
+ "outputs": [],
+ "source": [
+ "SPLIT = (0.7, 0.2, 0.1)\n",
+ "\n",
+ "train_df, test_df, val_df = split_dataset(\n",
+ " annotations=raw_dataset,\n",
+ " output_path=\"../data/Fall_Simulation_Data/\",\n",
+ " split=SPLIT,\n",
+ " random_seed=42,\n",
+ " stratify=\"category\",\n",
+ " save_splits=True,\n",
+ ")"
+ ]
+ },
+ {
+ "cell_type": "code",
+ "execution_count": 5,
+ "metadata": {},
+ "outputs": [
+ {
+ "data": {
+ "text/plain": [
+ "'------------------- Train -------------------'"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " video_path | \n",
+ " video_name | \n",
+ " category | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " fall_visible | \n",
+ " lying_visible | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " 105 | \n",
+ " data/Fall_Simulation_Data/videos/Fall7_Cam4.avi | \n",
+ " Fall7_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 7 | \n",
+ " 28.0 | \n",
+ " 31.0 | \n",
+ " 31.0 | \n",
+ " 219.0 | \n",
+ " 230 | \n",
+ " True | \n",
+ " True | \n",
+ " 2.0 | \n",
+ "
\n",
+ " \n",
+ " 338 | \n",
+ " data/Fall_Simulation_Data/videos/Fall23_Cam3.avi | \n",
+ " Fall23_Cam3 | \n",
+ " Fall | \n",
+ " 3 | \n",
+ " 23 | \n",
+ " 16.0 | \n",
+ " 19.0 | \n",
+ " 19.0 | \n",
+ " 110.0 | \n",
+ " 126 | \n",
+ " True | \n",
+ " True | \n",
+ " 3.0 | \n",
+ "
\n",
+ " \n",
+ " 139 | \n",
+ " data/Fall_Simulation_Data/videos/Fall7_Cam2.avi | \n",
+ " Fall7_Cam2 | \n",
+ " Fall | \n",
+ " 2 | \n",
+ " 7 | \n",
+ " 28.0 | \n",
+ " 31.0 | \n",
+ " 31.0 | \n",
+ " 219.0 | \n",
+ " 230 | \n",
+ " True | \n",
+ " True | \n",
+ " 4.0 | \n",
+ "
\n",
+ " \n",
+ " 11 | \n",
+ " data/Fall_Simulation_Data/videos/Fall50_Cam4.avi | \n",
+ " Fall50_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 50 | \n",
+ " 15.0 | \n",
+ " 18.0 | \n",
+ " 18.0 | \n",
+ " 131.0 | \n",
+ " 140 | \n",
+ " True | \n",
+ " True | \n",
+ " 1.0 | \n",
+ "
\n",
+ " \n",
+ " 350 | \n",
+ " data/Fall_Simulation_Data/videos/Fall34_Cam4.avi | \n",
+ " Fall34_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 34 | \n",
+ " 25.0 | \n",
+ " 28.0 | \n",
+ " 28.0 | \n",
+ " 241.0 | \n",
+ " 265 | \n",
+ " True | \n",
+ " True | \n",
+ " 4.0 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " video_path video_name category \\\n",
+ "105 data/Fall_Simulation_Data/videos/Fall7_Cam4.avi Fall7_Cam4 Fall \n",
+ "338 data/Fall_Simulation_Data/videos/Fall23_Cam3.avi Fall23_Cam3 Fall \n",
+ "139 data/Fall_Simulation_Data/videos/Fall7_Cam2.avi Fall7_Cam2 Fall \n",
+ "11 data/Fall_Simulation_Data/videos/Fall50_Cam4.avi Fall50_Cam4 Fall \n",
+ "350 data/Fall_Simulation_Data/videos/Fall34_Cam4.avi Fall34_Cam4 Fall \n",
+ "\n",
+ " camera_id scenario_id fall_start fall_end lying_start lying_end \\\n",
+ "105 4 7 28.0 31.0 31.0 219.0 \n",
+ "338 3 23 16.0 19.0 19.0 110.0 \n",
+ "139 2 7 28.0 31.0 31.0 219.0 \n",
+ "11 4 50 15.0 18.0 18.0 131.0 \n",
+ "350 4 34 25.0 28.0 28.0 241.0 \n",
+ "\n",
+ " length fall_visible lying_visible ranking \n",
+ "105 230 True True 2.0 \n",
+ "338 126 True True 3.0 \n",
+ "139 230 True True 4.0 \n",
+ "11 140 True True 1.0 \n",
+ "350 265 True True 4.0 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " count | \n",
+ " 249.000000 | \n",
+ " 249.000000 | \n",
+ " 190.000000 | \n",
+ " 190.000000 | \n",
+ " 190.000000 | \n",
+ " 190.000000 | \n",
+ " 249.000000 | \n",
+ " 190.000000 | \n",
+ "
\n",
+ " \n",
+ " mean | \n",
+ " 2.935743 | \n",
+ " 23.594378 | \n",
+ " 42.421053 | \n",
+ " 44.868421 | \n",
+ " 44.868421 | \n",
+ " 140.952632 | \n",
+ " 435.321285 | \n",
+ " 2.963158 | \n",
+ "
\n",
+ " \n",
+ " std | \n",
+ " 1.424118 | \n",
+ " 16.672127 | \n",
+ " 26.002067 | \n",
+ " 25.958627 | \n",
+ " 25.958627 | \n",
+ " 62.717920 | \n",
+ " 531.165085 | \n",
+ " 1.434168 | \n",
+ "
\n",
+ " \n",
+ " min | \n",
+ " 1.000000 | \n",
+ " 1.000000 | \n",
+ " 10.000000 | \n",
+ " 12.000000 | \n",
+ " 12.000000 | \n",
+ " 28.000000 | \n",
+ " 50.000000 | \n",
+ " 1.000000 | \n",
+ "
\n",
+ " \n",
+ " 25% | \n",
+ " 2.000000 | \n",
+ " 9.000000 | \n",
+ " 24.000000 | \n",
+ " 26.000000 | \n",
+ " 26.000000 | \n",
+ " 92.500000 | \n",
+ " 140.000000 | \n",
+ " 2.000000 | \n",
+ "
\n",
+ " \n",
+ " 50% | \n",
+ " 3.000000 | \n",
+ " 19.000000 | \n",
+ " 32.000000 | \n",
+ " 34.000000 | \n",
+ " 34.000000 | \n",
+ " 134.000000 | \n",
+ " 200.000000 | \n",
+ " 3.000000 | \n",
+ "
\n",
+ " \n",
+ " 75% | \n",
+ " 4.000000 | \n",
+ " 38.000000 | \n",
+ " 55.000000 | \n",
+ " 58.000000 | \n",
+ " 58.000000 | \n",
+ " 188.000000 | \n",
+ " 270.000000 | \n",
+ " 4.000000 | \n",
+ "
\n",
+ " \n",
+ " max | \n",
+ " 5.000000 | \n",
+ " 55.000000 | \n",
+ " 128.000000 | \n",
+ " 131.000000 | \n",
+ " 131.000000 | \n",
+ " 248.000000 | \n",
+ " 2130.000000 | \n",
+ " 5.000000 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " camera_id scenario_id fall_start fall_end lying_start \\\n",
+ "count 249.000000 249.000000 190.000000 190.000000 190.000000 \n",
+ "mean 2.935743 23.594378 42.421053 44.868421 44.868421 \n",
+ "std 1.424118 16.672127 26.002067 25.958627 25.958627 \n",
+ "min 1.000000 1.000000 10.000000 12.000000 12.000000 \n",
+ "25% 2.000000 9.000000 24.000000 26.000000 26.000000 \n",
+ "50% 3.000000 19.000000 32.000000 34.000000 34.000000 \n",
+ "75% 4.000000 38.000000 55.000000 58.000000 58.000000 \n",
+ "max 5.000000 55.000000 128.000000 131.000000 131.000000 \n",
+ "\n",
+ " lying_end length ranking \n",
+ "count 190.000000 249.000000 190.000000 \n",
+ "mean 140.952632 435.321285 2.963158 \n",
+ "std 62.717920 531.165085 1.434168 \n",
+ "min 28.000000 50.000000 1.000000 \n",
+ "25% 92.500000 140.000000 2.000000 \n",
+ "50% 134.000000 200.000000 3.000000 \n",
+ "75% 188.000000 270.000000 4.000000 \n",
+ "max 248.000000 2130.000000 5.000000 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "Index: 249 entries, 105 to 263\n",
+ "Data columns (total 13 columns):\n",
+ " # Column Non-Null Count Dtype \n",
+ "--- ------ -------------- ----- \n",
+ " 0 video_path 249 non-null object \n",
+ " 1 video_name 249 non-null object \n",
+ " 2 category 249 non-null object \n",
+ " 3 camera_id 249 non-null int64 \n",
+ " 4 scenario_id 249 non-null int64 \n",
+ " 5 fall_start 190 non-null float64\n",
+ " 6 fall_end 190 non-null float64\n",
+ " 7 lying_start 190 non-null float64\n",
+ " 8 lying_end 190 non-null float64\n",
+ " 9 length 249 non-null int64 \n",
+ " 10 fall_visible 190 non-null object \n",
+ " 11 lying_visible 190 non-null object \n",
+ " 12 ranking 190 non-null float64\n",
+ "dtypes: float64(5), int64(3), object(5)\n",
+ "memory usage: 27.2+ KB\n"
+ ]
+ },
+ {
+ "data": {
+ "text/plain": [
+ "None"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "category\n",
+ "Fall 0.763052\n",
+ "ADL 0.236948\n",
+ "Name: count, dtype: float64"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "'------------------- Test -------------------'"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " video_path | \n",
+ " video_name | \n",
+ " category | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " fall_visible | \n",
+ " lying_visible | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " 255 | \n",
+ " data/Fall_Simulation_Data/videos/Fall3_Cam2.avi | \n",
+ " Fall3_Cam2 | \n",
+ " Fall | \n",
+ " 2 | \n",
+ " 3 | \n",
+ " 128.0 | \n",
+ " 131.0 | \n",
+ " 131.0 | \n",
+ " 224.0 | \n",
+ " 235 | \n",
+ " True | \n",
+ " True | \n",
+ " 2.0 | \n",
+ "
\n",
+ " \n",
+ " 80 | \n",
+ " data/Fall_Simulation_Data/videos/Fall13_Cam3.avi | \n",
+ " Fall13_Cam3 | \n",
+ " Fall | \n",
+ " 3 | \n",
+ " 13 | \n",
+ " 24.0 | \n",
+ " 27.0 | \n",
+ " 27.0 | \n",
+ " 94.0 | \n",
+ " 110 | \n",
+ " True | \n",
+ " True | \n",
+ " 3.0 | \n",
+ "
\n",
+ " \n",
+ " 37 | \n",
+ " data/Fall_Simulation_Data/videos/Fall1_Cam1.avi | \n",
+ " Fall1_Cam1 | \n",
+ " Fall | \n",
+ " 1 | \n",
+ " 1 | \n",
+ " 47.0 | \n",
+ " 50.0 | \n",
+ " 50.0 | \n",
+ " 125.0 | \n",
+ " 138 | \n",
+ " True | \n",
+ " True | \n",
+ " 5.0 | \n",
+ "
\n",
+ " \n",
+ " 239 | \n",
+ " data/Fall_Simulation_Data/videos/Fall45_Cam2.avi | \n",
+ " Fall45_Cam2 | \n",
+ " Fall | \n",
+ " 2 | \n",
+ " 45 | \n",
+ " 20.0 | \n",
+ " 22.0 | \n",
+ " 22.0 | \n",
+ " 28.0 | \n",
+ " 50 | \n",
+ " True | \n",
+ " True | \n",
+ " 1.0 | \n",
+ "
\n",
+ " \n",
+ " 159 | \n",
+ " data/Fall_Simulation_Data/videos/ADL10_Cam3.avi | \n",
+ " ADL10_Cam3 | \n",
+ " ADL | \n",
+ " 3 | \n",
+ " 10 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " 1170 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " video_path video_name category \\\n",
+ "255 data/Fall_Simulation_Data/videos/Fall3_Cam2.avi Fall3_Cam2 Fall \n",
+ "80 data/Fall_Simulation_Data/videos/Fall13_Cam3.avi Fall13_Cam3 Fall \n",
+ "37 data/Fall_Simulation_Data/videos/Fall1_Cam1.avi Fall1_Cam1 Fall \n",
+ "239 data/Fall_Simulation_Data/videos/Fall45_Cam2.avi Fall45_Cam2 Fall \n",
+ "159 data/Fall_Simulation_Data/videos/ADL10_Cam3.avi ADL10_Cam3 ADL \n",
+ "\n",
+ " camera_id scenario_id fall_start fall_end lying_start lying_end \\\n",
+ "255 2 3 128.0 131.0 131.0 224.0 \n",
+ "80 3 13 24.0 27.0 27.0 94.0 \n",
+ "37 1 1 47.0 50.0 50.0 125.0 \n",
+ "239 2 45 20.0 22.0 22.0 28.0 \n",
+ "159 3 10 NaN NaN NaN NaN \n",
+ "\n",
+ " length fall_visible lying_visible ranking \n",
+ "255 235 True True 2.0 \n",
+ "80 110 True True 3.0 \n",
+ "37 138 True True 5.0 \n",
+ "239 50 True True 1.0 \n",
+ "159 1170 NaN NaN NaN "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " count | \n",
+ " 72.000000 | \n",
+ " 72.000000 | \n",
+ " 55.000000 | \n",
+ " 55.000000 | \n",
+ " 55.000000 | \n",
+ " 55.000000 | \n",
+ " 72.000000 | \n",
+ " 55.000000 | \n",
+ "
\n",
+ " \n",
+ " mean | \n",
+ " 3.277778 | \n",
+ " 23.597222 | \n",
+ " 37.345455 | \n",
+ " 39.818182 | \n",
+ " 39.818182 | \n",
+ " 130.472727 | \n",
+ " 389.166667 | \n",
+ " 3.036364 | \n",
+ "
\n",
+ " \n",
+ " std | \n",
+ " 1.334507 | \n",
+ " 15.429677 | \n",
+ " 25.964519 | \n",
+ " 25.981540 | \n",
+ " 25.981540 | \n",
+ " 64.885327 | \n",
+ " 457.178826 | \n",
+ " 1.304744 | \n",
+ "
\n",
+ " \n",
+ " min | \n",
+ " 1.000000 | \n",
+ " 1.000000 | \n",
+ " 10.000000 | \n",
+ " 12.000000 | \n",
+ " 12.000000 | \n",
+ " 28.000000 | \n",
+ " 50.000000 | \n",
+ " 1.000000 | \n",
+ "
\n",
+ " \n",
+ " 25% | \n",
+ " 2.000000 | \n",
+ " 10.000000 | \n",
+ " 23.500000 | \n",
+ " 25.500000 | \n",
+ " 25.500000 | \n",
+ " 88.000000 | \n",
+ " 117.500000 | \n",
+ " 2.000000 | \n",
+ "
\n",
+ " \n",
+ " 50% | \n",
+ " 3.000000 | \n",
+ " 25.000000 | \n",
+ " 28.000000 | \n",
+ " 30.000000 | \n",
+ " 30.000000 | \n",
+ " 121.000000 | \n",
+ " 165.000000 | \n",
+ " 3.000000 | \n",
+ "
\n",
+ " \n",
+ " 75% | \n",
+ " 4.000000 | \n",
+ " 35.000000 | \n",
+ " 44.000000 | \n",
+ " 47.000000 | \n",
+ " 47.000000 | \n",
+ " 197.500000 | \n",
+ " 255.000000 | \n",
+ " 4.000000 | \n",
+ "
\n",
+ " \n",
+ " max | \n",
+ " 5.000000 | \n",
+ " 52.000000 | \n",
+ " 128.000000 | \n",
+ " 131.000000 | \n",
+ " 131.000000 | \n",
+ " 238.000000 | \n",
+ " 1800.000000 | \n",
+ " 5.000000 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " camera_id scenario_id fall_start fall_end lying_start \\\n",
+ "count 72.000000 72.000000 55.000000 55.000000 55.000000 \n",
+ "mean 3.277778 23.597222 37.345455 39.818182 39.818182 \n",
+ "std 1.334507 15.429677 25.964519 25.981540 25.981540 \n",
+ "min 1.000000 1.000000 10.000000 12.000000 12.000000 \n",
+ "25% 2.000000 10.000000 23.500000 25.500000 25.500000 \n",
+ "50% 3.000000 25.000000 28.000000 30.000000 30.000000 \n",
+ "75% 4.000000 35.000000 44.000000 47.000000 47.000000 \n",
+ "max 5.000000 52.000000 128.000000 131.000000 131.000000 \n",
+ "\n",
+ " lying_end length ranking \n",
+ "count 55.000000 72.000000 55.000000 \n",
+ "mean 130.472727 389.166667 3.036364 \n",
+ "std 64.885327 457.178826 1.304744 \n",
+ "min 28.000000 50.000000 1.000000 \n",
+ "25% 88.000000 117.500000 2.000000 \n",
+ "50% 121.000000 165.000000 3.000000 \n",
+ "75% 197.500000 255.000000 4.000000 \n",
+ "max 238.000000 1800.000000 5.000000 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "Index: 72 entries, 255 to 275\n",
+ "Data columns (total 13 columns):\n",
+ " # Column Non-Null Count Dtype \n",
+ "--- ------ -------------- ----- \n",
+ " 0 video_path 72 non-null object \n",
+ " 1 video_name 72 non-null object \n",
+ " 2 category 72 non-null object \n",
+ " 3 camera_id 72 non-null int64 \n",
+ " 4 scenario_id 72 non-null int64 \n",
+ " 5 fall_start 55 non-null float64\n",
+ " 6 fall_end 55 non-null float64\n",
+ " 7 lying_start 55 non-null float64\n",
+ " 8 lying_end 55 non-null float64\n",
+ " 9 length 72 non-null int64 \n",
+ " 10 fall_visible 55 non-null object \n",
+ " 11 lying_visible 55 non-null object \n",
+ " 12 ranking 55 non-null float64\n",
+ "dtypes: float64(5), int64(3), object(5)\n",
+ "memory usage: 7.9+ KB\n"
+ ]
+ },
+ {
+ "data": {
+ "text/plain": [
+ "None"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "category\n",
+ "Fall 0.763889\n",
+ "ADL 0.236111\n",
+ "Name: count, dtype: float64"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "'------------------- Val -------------------'"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " video_path | \n",
+ " video_name | \n",
+ " category | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " fall_visible | \n",
+ " lying_visible | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " 44 | \n",
+ " data/Fall_Simulation_Data/videos/Fall30_Cam5.avi | \n",
+ " Fall30_Cam5 | \n",
+ " Fall | \n",
+ " 5 | \n",
+ " 30 | \n",
+ " 24.0 | \n",
+ " 27.0 | \n",
+ " 27.0 | \n",
+ " 88.0 | \n",
+ " 110 | \n",
+ " True | \n",
+ " True | \n",
+ " 5.0 | \n",
+ "
\n",
+ " \n",
+ " 143 | \n",
+ " data/Fall_Simulation_Data/videos/Fall40_Cam1.avi | \n",
+ " Fall40_Cam1 | \n",
+ " Fall | \n",
+ " 1 | \n",
+ " 40 | \n",
+ " 53.0 | \n",
+ " 55.0 | \n",
+ " 55.0 | \n",
+ " 115.0 | \n",
+ " 140 | \n",
+ " True | \n",
+ " True | \n",
+ " 2.0 | \n",
+ "
\n",
+ " \n",
+ " 110 | \n",
+ " data/Fall_Simulation_Data/videos/ADL9_Cam4.avi | \n",
+ " ADL9_Cam4 | \n",
+ " ADL | \n",
+ " 4 | \n",
+ " 9 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " 1140 | \n",
+ " NaN | \n",
+ " NaN | \n",
+ " NaN | \n",
+ "
\n",
+ " \n",
+ " 208 | \n",
+ " data/Fall_Simulation_Data/videos/Fall32_Cam4.avi | \n",
+ " Fall32_Cam4 | \n",
+ " Fall | \n",
+ " 4 | \n",
+ " 32 | \n",
+ " 53.0 | \n",
+ " 55.0 | \n",
+ " 55.0 | \n",
+ " 144.0 | \n",
+ " 174 | \n",
+ " True | \n",
+ " True | \n",
+ " 4.0 | \n",
+ "
\n",
+ " \n",
+ " 254 | \n",
+ " data/Fall_Simulation_Data/videos/Fall9_Cam1.avi | \n",
+ " Fall9_Cam1 | \n",
+ " Fall | \n",
+ " 1 | \n",
+ " 9 | \n",
+ " 78.0 | \n",
+ " 80.0 | \n",
+ " 80.0 | \n",
+ " 203.0 | \n",
+ " 224 | \n",
+ " True | \n",
+ " True | \n",
+ " 2.0 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " video_path video_name category \\\n",
+ "44 data/Fall_Simulation_Data/videos/Fall30_Cam5.avi Fall30_Cam5 Fall \n",
+ "143 data/Fall_Simulation_Data/videos/Fall40_Cam1.avi Fall40_Cam1 Fall \n",
+ "110 data/Fall_Simulation_Data/videos/ADL9_Cam4.avi ADL9_Cam4 ADL \n",
+ "208 data/Fall_Simulation_Data/videos/Fall32_Cam4.avi Fall32_Cam4 Fall \n",
+ "254 data/Fall_Simulation_Data/videos/Fall9_Cam1.avi Fall9_Cam1 Fall \n",
+ "\n",
+ " camera_id scenario_id fall_start fall_end lying_start lying_end \\\n",
+ "44 5 30 24.0 27.0 27.0 88.0 \n",
+ "143 1 40 53.0 55.0 55.0 115.0 \n",
+ "110 4 9 NaN NaN NaN NaN \n",
+ "208 4 32 53.0 55.0 55.0 144.0 \n",
+ "254 1 9 78.0 80.0 80.0 203.0 \n",
+ "\n",
+ " length fall_visible lying_visible ranking \n",
+ "44 110 True True 5.0 \n",
+ "143 140 True True 2.0 \n",
+ "110 1140 NaN NaN NaN \n",
+ "208 174 True True 4.0 \n",
+ "254 224 True True 2.0 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/html": [
+ "\n",
+ "\n",
+ "
\n",
+ " \n",
+ " \n",
+ " | \n",
+ " camera_id | \n",
+ " scenario_id | \n",
+ " fall_start | \n",
+ " fall_end | \n",
+ " lying_start | \n",
+ " lying_end | \n",
+ " length | \n",
+ " ranking | \n",
+ "
\n",
+ " \n",
+ " \n",
+ " \n",
+ " count | \n",
+ " 36.000000 | \n",
+ " 36.000000 | \n",
+ " 27.000000 | \n",
+ " 27.000000 | \n",
+ " 27.000000 | \n",
+ " 27.000000 | \n",
+ " 36.000000 | \n",
+ " 27.000000 | \n",
+ "
\n",
+ " \n",
+ " mean | \n",
+ " 2.972222 | \n",
+ " 21.416667 | \n",
+ " 44.518519 | \n",
+ " 46.814815 | \n",
+ " 46.814815 | \n",
+ " 136.592593 | \n",
+ " 415.416667 | \n",
+ " 3.111111 | \n",
+ "
\n",
+ " \n",
+ " std | \n",
+ " 1.502115 | \n",
+ " 15.018798 | \n",
+ " 28.648225 | \n",
+ " 28.614194 | \n",
+ " 28.614194 | \n",
+ " 55.805472 | \n",
+ " 470.641287 | \n",
+ " 1.476309 | \n",
+ "
\n",
+ " \n",
+ " min | \n",
+ " 1.000000 | \n",
+ " 2.000000 | \n",
+ " 10.000000 | \n",
+ " 12.000000 | \n",
+ " 12.000000 | \n",
+ " 28.000000 | \n",
+ " 50.000000 | \n",
+ " 1.000000 | \n",
+ "
\n",
+ " \n",
+ " 25% | \n",
+ " 2.000000 | \n",
+ " 9.000000 | \n",
+ " 23.000000 | \n",
+ " 25.000000 | \n",
+ " 25.000000 | \n",
+ " 96.500000 | \n",
+ " 124.000000 | \n",
+ " 2.000000 | \n",
+ "
\n",
+ " \n",
+ " 50% | \n",
+ " 3.000000 | \n",
+ " 18.500000 | \n",
+ " 44.000000 | \n",
+ " 47.000000 | \n",
+ " 47.000000 | \n",
+ " 115.000000 | \n",
+ " 174.000000 | \n",
+ " 3.000000 | \n",
+ "
\n",
+ " \n",
+ " 75% | \n",
+ " 4.000000 | \n",
+ " 30.500000 | \n",
+ " 66.000000 | \n",
+ " 68.000000 | \n",
+ " 68.000000 | \n",
+ " 181.500000 | \n",
+ " 365.750000 | \n",
+ " 4.000000 | \n",
+ "
\n",
+ " \n",
+ " max | \n",
+ " 5.000000 | \n",
+ " 53.000000 | \n",
+ " 128.000000 | \n",
+ " 131.000000 | \n",
+ " 131.000000 | \n",
+ " 238.000000 | \n",
+ " 1528.000000 | \n",
+ " 5.000000 | \n",
+ "
\n",
+ " \n",
+ "
\n",
+ "
"
+ ],
+ "text/plain": [
+ " camera_id scenario_id fall_start fall_end lying_start \\\n",
+ "count 36.000000 36.000000 27.000000 27.000000 27.000000 \n",
+ "mean 2.972222 21.416667 44.518519 46.814815 46.814815 \n",
+ "std 1.502115 15.018798 28.648225 28.614194 28.614194 \n",
+ "min 1.000000 2.000000 10.000000 12.000000 12.000000 \n",
+ "25% 2.000000 9.000000 23.000000 25.000000 25.000000 \n",
+ "50% 3.000000 18.500000 44.000000 47.000000 47.000000 \n",
+ "75% 4.000000 30.500000 66.000000 68.000000 68.000000 \n",
+ "max 5.000000 53.000000 128.000000 131.000000 131.000000 \n",
+ "\n",
+ " lying_end length ranking \n",
+ "count 27.000000 36.000000 27.000000 \n",
+ "mean 136.592593 415.416667 3.111111 \n",
+ "std 55.805472 470.641287 1.476309 \n",
+ "min 28.000000 50.000000 1.000000 \n",
+ "25% 96.500000 124.000000 2.000000 \n",
+ "50% 115.000000 174.000000 3.000000 \n",
+ "75% 181.500000 365.750000 4.000000 \n",
+ "max 238.000000 1528.000000 5.000000 "
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "name": "stdout",
+ "output_type": "stream",
+ "text": [
+ "\n",
+ "Index: 36 entries, 44 to 252\n",
+ "Data columns (total 13 columns):\n",
+ " # Column Non-Null Count Dtype \n",
+ "--- ------ -------------- ----- \n",
+ " 0 video_path 36 non-null object \n",
+ " 1 video_name 36 non-null object \n",
+ " 2 category 36 non-null object \n",
+ " 3 camera_id 36 non-null int64 \n",
+ " 4 scenario_id 36 non-null int64 \n",
+ " 5 fall_start 27 non-null float64\n",
+ " 6 fall_end 27 non-null float64\n",
+ " 7 lying_start 27 non-null float64\n",
+ " 8 lying_end 27 non-null float64\n",
+ " 9 length 36 non-null int64 \n",
+ " 10 fall_visible 27 non-null object \n",
+ " 11 lying_visible 27 non-null object \n",
+ " 12 ranking 27 non-null float64\n",
+ "dtypes: float64(5), int64(3), object(5)\n",
+ "memory usage: 3.9+ KB\n"
+ ]
+ },
+ {
+ "data": {
+ "text/plain": [
+ "None"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ },
+ {
+ "data": {
+ "text/plain": [
+ "category\n",
+ "Fall 0.75\n",
+ "ADL 0.25\n",
+ "Name: count, dtype: float64"
+ ]
+ },
+ "metadata": {},
+ "output_type": "display_data"
+ }
+ ],
+ "source": [
+ "display(\"------------------- Train -------------------\")\n",
+ "display(train_df.head())\n",
+ "display(train_df.describe())\n",
+ "display(train_df.info())\n",
+ "display(train_df[\"category\"].value_counts() / len(train_df))\n",
+ "\n",
+ "display(\"------------------- Test -------------------\")\n",
+ "display(test_df.head())\n",
+ "display(test_df.describe())\n",
+ "display(test_df.info())\n",
+ "display(test_df[\"category\"].value_counts() / len(test_df))\n",
+ "\n",
+ "display(\"------------------- Val -------------------\")\n",
+ "display(val_df.head())\n",
+ "display(val_df.describe())\n",
+ "display(val_df.info())\n",
+ "display(val_df[\"category\"].value_counts() / len(val_df))"
+ ]
+ }
+ ],
+ "metadata": {
+ "kernelspec": {
+ "display_name": "human-fall-detection",
+ "language": "python",
+ "name": "python3"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 3
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython3",
+ "version": "3.10.13"
+ }
+ },
+ "nbformat": 4,
+ "nbformat_minor": 2
+}
diff --git a/pyproject.toml b/pyproject.toml
index 0643991..0eb79a8 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -56,6 +56,10 @@ skip-magic-trailing-comma = false
# Like Black, automatically detect the appropriate line ending.
line-ending = "auto"
+[tool.ruff.lint.per-file-ignores]
+# Ignore imports at the top of file error in notebooks.
+"**.ipynb" = ["E402"]
+
[[tool.mypy.overrides]]
module = ["mmaction.*", "mmengine.*"]
ignore_missing_imports = true
diff --git a/scripts/__init__.py b/scripts/__init__.py
new file mode 100644
index 0000000..e69de29
diff --git a/scripts/split_dataset.py b/scripts/split_dataset.py
new file mode 100644
index 0000000..d8b2eba
--- /dev/null
+++ b/scripts/split_dataset.py
@@ -0,0 +1,175 @@
+"""This script takes the path to our converted annotation file and
+splits it into a training, testing, and optionally validation dataset."""
+
+
+import argparse
+import logging
+from math import isclose
+from pathlib import Path
+
+import numpy as np
+import pandas as pd
+from sklearn.model_selection import train_test_split # type: ignore
+
+logger = logging.getLogger(__name__)
+logging.basicConfig(level=logging.INFO)
+
+
+def split_dataset(
+ annotations: Path | str | pd.DataFrame,
+ output_path: Path | str | None = None,
+ split: tuple[float, float, float] = (0.7, 0.2, 0.1),
+ random_seed: int = 42,
+ stratify: str | None = None,
+ save_splits: bool = False,
+) -> tuple[pd.DataFrame, pd.DataFrame, pd.DataFrame]:
+ """Splits the dataset into training, testing, and validation datasets.
+
+ Args:
+ annotations (Path | str | pd.Dataframe): Path to the (complete) annotation CSV file.
+ Or a pandas dataframe containing the annotations.
+ output_path (Path | str | None): Path to the output directory. The output
+ files will have the same name as the input file, with the suffixes _train,
+ _test, and _val. Defaults to None and uses the same folder as the
+ `annotation_path`.
+ split (tuple[float, float, float]): Tuple of three floats indicating the proportions
+ of the dataset to use for training, testing, and validation (in that order). Each
+ value should be between 0.0 and 1.0, and the sum of the three values should be 1.0.
+ Defaults to (0.7, 0.2, 0.1).
+ random_seed (int): Random seed to use for splitting the dataset. Defaults to 42.
+ stratify (str | None): Column name to use for stratification. Defaults to None.
+ save_splits (bool): Whether to save the splits as CSV files. Defaults to False.
+ """
+ annotation_path = None
+ if isinstance(annotations, (Path, str)):
+ annotation_path = Path(annotations)
+ annotations = pd.read_csv(annotations)
+
+ assert isclose(sum(split), 1), "The sum of the split values should be 1.0"
+ assert all(
+ 0.0 <= v <= 1.0 for v in split
+ ), "All split values should be between 0.0 and 1.0"
+ train_portion, test_portion, val_portion = split
+
+ # Split the dataset
+ np.random.seed(random_seed)
+ train_df, test_df = train_test_split(
+ annotations,
+ test_size=test_portion + val_portion,
+ random_state=random_seed,
+ stratify=annotations[stratify] if stratify else None,
+ )
+ if val_portion > 0.0:
+ test_df, val_df = train_test_split(
+ test_df,
+ test_size=val_portion / (test_portion + val_portion),
+ random_state=random_seed,
+ stratify=test_df[stratify] if stratify else None,
+ )
+ else:
+ val_df = pd.DataFrame()
+
+ # Save the splits
+ if save_splits or __name__ == "__main__":
+ if annotation_path is None:
+ file_stem = "annotations"
+ if output_path is None:
+ raise ValueError(
+ "If the annotations are given as a dataframe, "
+ "then the output path must be specified "
+ "to save the datasets."
+ )
+ output_path = Path(output_path)
+ else:
+ output_path = Path(output_path) if output_path else annotation_path.parent
+ file_stem = annotation_path.stem
+
+ if len(train_df) != 0:
+ train_df.to_csv(output_path / f"{file_stem}_train.csv", index=False)
+ if len(test_df) != 0:
+ test_df.to_csv(output_path / f"{file_stem}_test.csv", index=False)
+ if len(val_df) != 0:
+ val_df.to_csv(output_path / f"{file_stem}_val.csv", index=False)
+
+ return train_df, test_df, val_df
+
+
+def parse_args():
+ parser = argparse.ArgumentParser(
+ description="Splits the dataset into training, testing, and optionally validation datasets."
+ )
+ parser.add_argument(
+ "--annotation_path",
+ default="data/Fall_Simulation_Data/annotations.csv",
+ type=str,
+ help="Path to the (complete) annotation CSV file",
+ )
+ parser.add_argument(
+ "--output_path",
+ default=None,
+ type=str,
+ help="Path to the output directory. "
+ "The output files will have the same name as the input "
+ "file, with the suffixes _train, _test, and _val.",
+ )
+
+ class TupleAction(argparse.Action):
+ def __call__(self, parser, namespace, values, option_string=None):
+ try:
+ values = tuple(map(float, values.split(",")))
+ if not all(0.0 <= v <= 1.0 for v in values):
+ raise ValueError
+ if not sum(values) == 1.0:
+ raise ValueError
+ if not len(values) == 3:
+ raise ValueError
+ if not all(v > 0.0 for v in values[:-1]):
+ raise ValueError
+ except ValueError:
+ raise argparse.ArgumentError(
+ self,
+ "Invalid tuple of floats. Each value should be between 0.0 and 1.0. "
+ "And the sum of all values should be 1.0. "
+ "The tuple should have three values. "
+ "The values for training and testing should be greater than 0.0.",
+ )
+ setattr(namespace, self.dest, values)
+
+ parser.add_argument(
+ "--split",
+ default=(0.7, 0.2, 0.1),
+ type=str,
+ action=TupleAction,
+ help="Tuple of three floats indicating the proportions of the dataset "
+ "to use for training, testing, and validation (in that order). Each "
+ "value should be between 0.0 and 1.0, and the sum of the three values "
+ "should be 1.0.",
+ )
+
+ parser.add_argument(
+ "--random_seed",
+ default=42,
+ type=int,
+ help="Random seed to use for splitting the dataset",
+ )
+
+ parser.add_argument(
+ "--stratify",
+ default=None,
+ type=str,
+ help="Column name to use for stratification",
+ )
+
+ return parser.parse_args()
+
+
+if __name__ == "__main__":
+ args = parse_args()
+ logger.debug(args)
+ split_dataset(
+ annotations=args.annotation_path,
+ output_path=args.output_path,
+ split=args.split,
+ random_seed=args.random_seed,
+ stratify=args.stratify,
+ )