imblearn_protein_homo.log 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726
  1. ///////////////////////////////////////////
  2. // Running CTAB-GAN on imblearn_protein_homo
  3. ///////////////////////////////////////////
  4. Load 'data_input/imblearn_protein_homo'
  5. from imblearn
  6. Data loaded.
  7. -> Shuffling data
  8. ### Start exercise for synthetic point generator
  9. ====== Step 1/5 =======
  10. -> Shuffling data
  11. -> Spliting data to slices
  12. ------ Step 1/5: Slice 1/5 -------
  13. -> Reset the GAN
  14. -> Train generator for synthetic samples
  15. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:42, 11.43s/it] 20%|██ | 2/10 [00:22<01:31, 11.49s/it] 30%|███ | 3/10 [00:34<01:21, 11.62s/it] 40%|████ | 4/10 [00:46<01:09, 11.67s/it] 50%|█████ | 5/10 [00:57<00:56, 11.38s/it] 60%|██████ | 6/10 [01:08<00:44, 11.18s/it] 70%|███████ | 7/10 [01:18<00:32, 10.95s/it] 80%|████████ | 8/10 [01:29<00:22, 11.02s/it] 90%|█████████ | 9/10 [01:41<00:11, 11.36s/it] 100%|██████████| 10/10 [01:53<00:00, 11.35s/it] 100%|██████████| 10/10 [01:53<00:00, 11.32s/it]
  16. -> create 114528 synthetic samples
  17. -> test with 'LR'
  18. LR tn, fp: 28867, 24
  19. LR fn, tp: 60, 200
  20. LR f1 score: 0.826
  21. LR cohens kappa score: 0.825
  22. LR average precision score: 0.853
  23. -> test with 'GB'
  24. GB tn, fp: 28861, 30
  25. GB fn, tp: 58, 202
  26. GB f1 score: 0.821
  27. GB cohens kappa score: 0.820
  28. -> test with 'KNN'
  29. KNN tn, fp: 28883, 8
  30. KNN fn, tp: 161, 99
  31. KNN f1 score: 0.540
  32. KNN cohens kappa score: 0.537
  33. ------ Step 1/5: Slice 2/5 -------
  34. -> Reset the GAN
  35. -> Train generator for synthetic samples
  36. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:47, 12.00s/it] 20%|██ | 2/10 [00:23<01:33, 11.70s/it] 30%|███ | 3/10 [00:34<01:18, 11.21s/it] 40%|████ | 4/10 [00:44<01:05, 10.90s/it] 50%|█████ | 5/10 [00:55<00:54, 10.96s/it] 60%|██████ | 6/10 [01:06<00:43, 10.94s/it] 70%|███████ | 7/10 [01:18<00:33, 11.12s/it] 80%|████████ | 8/10 [01:28<00:21, 10.93s/it] 90%|█████████ | 9/10 [01:40<00:11, 11.21s/it] 100%|██████████| 10/10 [01:51<00:00, 11.32s/it] 100%|██████████| 10/10 [01:51<00:00, 11.19s/it]
  37. -> create 114528 synthetic samples
  38. -> test with 'LR'
  39. LR tn, fp: 28879, 12
  40. LR fn, tp: 57, 203
  41. LR f1 score: 0.855
  42. LR cohens kappa score: 0.854
  43. LR average precision score: 0.888
  44. -> test with 'GB'
  45. GB tn, fp: 28876, 15
  46. GB fn, tp: 60, 200
  47. GB f1 score: 0.842
  48. GB cohens kappa score: 0.841
  49. -> test with 'KNN'
  50. KNN tn, fp: 28874, 17
  51. KNN fn, tp: 144, 116
  52. KNN f1 score: 0.590
  53. KNN cohens kappa score: 0.588
  54. ------ Step 1/5: Slice 3/5 -------
  55. -> Reset the GAN
  56. -> Train generator for synthetic samples
  57. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:42, 11.40s/it] 20%|██ | 2/10 [00:23<01:32, 11.58s/it] 30%|███ | 3/10 [00:34<01:21, 11.65s/it] 40%|████ | 4/10 [00:46<01:08, 11.48s/it] 50%|█████ | 5/10 [00:57<00:57, 11.41s/it] 60%|██████ | 6/10 [01:08<00:45, 11.40s/it] 70%|███████ | 7/10 [01:20<00:34, 11.39s/it] 80%|████████ | 8/10 [01:30<00:22, 11.21s/it] 90%|█████████ | 9/10 [01:41<00:11, 11.14s/it] 100%|██████████| 10/10 [01:52<00:00, 11.11s/it] 100%|██████████| 10/10 [01:52<00:00, 11.29s/it]
  58. -> create 114528 synthetic samples
  59. -> test with 'LR'
  60. LR tn, fp: 28870, 21
  61. LR fn, tp: 62, 198
  62. LR f1 score: 0.827
  63. LR cohens kappa score: 0.825
  64. LR average precision score: 0.886
  65. -> test with 'GB'
  66. GB tn, fp: 28867, 24
  67. GB fn, tp: 73, 187
  68. GB f1 score: 0.794
  69. GB cohens kappa score: 0.792
  70. -> test with 'KNN'
  71. KNN tn, fp: 28881, 10
  72. KNN fn, tp: 170, 90
  73. KNN f1 score: 0.500
  74. KNN cohens kappa score: 0.498
  75. ------ Step 1/5: Slice 4/5 -------
  76. -> Reset the GAN
  77. -> Train generator for synthetic samples
  78. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:52, 12.45s/it] 20%|██ | 2/10 [00:24<01:37, 12.20s/it] 30%|███ | 3/10 [00:36<01:25, 12.25s/it] 40%|████ | 4/10 [00:47<01:10, 11.78s/it] 50%|█████ | 5/10 [00:59<00:58, 11.76s/it] 60%|██████ | 6/10 [01:11<00:47, 11.89s/it] 70%|███████ | 7/10 [01:23<00:35, 11.92s/it] 80%|████████ | 8/10 [01:35<00:23, 11.93s/it] 90%|█████████ | 9/10 [01:48<00:12, 12.13s/it] 100%|██████████| 10/10 [02:00<00:00, 12.09s/it] 100%|██████████| 10/10 [02:00<00:00, 12.02s/it]
  79. -> create 114528 synthetic samples
  80. -> test with 'LR'
  81. LR tn, fp: 28877, 14
  82. LR fn, tp: 68, 192
  83. LR f1 score: 0.824
  84. LR cohens kappa score: 0.823
  85. LR average precision score: 0.852
  86. -> test with 'GB'
  87. GB tn, fp: 28871, 20
  88. GB fn, tp: 70, 190
  89. GB f1 score: 0.809
  90. GB cohens kappa score: 0.807
  91. -> test with 'KNN'
  92. KNN tn, fp: 28884, 7
  93. KNN fn, tp: 160, 100
  94. KNN f1 score: 0.545
  95. KNN cohens kappa score: 0.543
  96. ------ Step 1/5: Slice 5/5 -------
  97. -> Reset the GAN
  98. -> Train generator for synthetic samples
  99. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:44, 11.62s/it] 20%|██ | 2/10 [00:22<01:29, 11.23s/it] 30%|███ | 3/10 [00:35<01:23, 11.89s/it] 40%|████ | 4/10 [00:46<01:09, 11.55s/it] 50%|█████ | 5/10 [00:58<00:59, 11.96s/it] 60%|██████ | 6/10 [01:10<00:46, 11.71s/it] 70%|███████ | 7/10 [01:23<00:36, 12.13s/it] 80%|████████ | 8/10 [01:35<00:24, 12.11s/it] 90%|█████████ | 9/10 [01:46<00:11, 11.81s/it] 100%|██████████| 10/10 [01:57<00:00, 11.53s/it] 100%|██████████| 10/10 [01:57<00:00, 11.73s/it]
  100. -> create 114524 synthetic samples
  101. -> test with 'LR'
  102. LR tn, fp: 28880, 11
  103. LR fn, tp: 84, 172
  104. LR f1 score: 0.784
  105. LR cohens kappa score: 0.782
  106. LR average precision score: 0.827
  107. -> test with 'GB'
  108. GB tn, fp: 28865, 26
  109. GB fn, tp: 74, 182
  110. GB f1 score: 0.784
  111. GB cohens kappa score: 0.783
  112. -> test with 'KNN'
  113. KNN tn, fp: 28886, 5
  114. KNN fn, tp: 173, 83
  115. KNN f1 score: 0.483
  116. KNN cohens kappa score: 0.480
  117. ====== Step 2/5 =======
  118. -> Shuffling data
  119. -> Spliting data to slices
  120. ------ Step 2/5: Slice 1/5 -------
  121. -> Reset the GAN
  122. -> Train generator for synthetic samples
  123. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:15<02:23, 15.89s/it] 20%|██ | 2/10 [00:28<01:50, 13.77s/it] 30%|███ | 3/10 [00:41<01:33, 13.39s/it] 40%|████ | 4/10 [00:56<01:24, 14.05s/it] 50%|█████ | 5/10 [01:07<01:05, 13.19s/it] 60%|██████ | 6/10 [01:20<00:52, 13.15s/it] 70%|███████ | 7/10 [01:32<00:37, 12.65s/it] 80%|████████ | 8/10 [01:45<00:25, 12.85s/it] 90%|█████████ | 9/10 [01:58<00:12, 12.80s/it] 100%|██████████| 10/10 [02:11<00:00, 12.82s/it] 100%|██████████| 10/10 [02:11<00:00, 13.14s/it]
  124. -> create 114528 synthetic samples
  125. -> test with 'LR'
  126. LR tn, fp: 28881, 10
  127. LR fn, tp: 75, 185
  128. LR f1 score: 0.813
  129. LR cohens kappa score: 0.812
  130. LR average precision score: 0.874
  131. -> test with 'GB'
  132. GB tn, fp: 28868, 23
  133. GB fn, tp: 74, 186
  134. GB f1 score: 0.793
  135. GB cohens kappa score: 0.792
  136. -> test with 'KNN'
  137. KNN tn, fp: 28882, 9
  138. KNN fn, tp: 163, 97
  139. KNN f1 score: 0.530
  140. KNN cohens kappa score: 0.528
  141. ------ Step 2/5: Slice 2/5 -------
  142. -> Reset the GAN
  143. -> Train generator for synthetic samples
  144. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:13<01:58, 13.22s/it] 20%|██ | 2/10 [00:25<01:41, 12.72s/it] 30%|███ | 3/10 [00:37<01:26, 12.29s/it] 40%|████ | 4/10 [00:49<01:14, 12.33s/it] 50%|█████ | 5/10 [01:01<01:00, 12.10s/it] 60%|██████ | 6/10 [01:13<00:48, 12.09s/it] 70%|███████ | 7/10 [01:25<00:36, 12.18s/it] 80%|████████ | 8/10 [01:38<00:24, 12.23s/it] 90%|█████████ | 9/10 [01:51<00:12, 12.41s/it] 100%|██████████| 10/10 [02:02<00:00, 12.15s/it] 100%|██████████| 10/10 [02:02<00:00, 12.26s/it]
  145. -> create 114528 synthetic samples
  146. -> test with 'LR'
  147. LR tn, fp: 28876, 15
  148. LR fn, tp: 59, 201
  149. LR f1 score: 0.845
  150. LR cohens kappa score: 0.843
  151. LR average precision score: 0.892
  152. -> test with 'GB'
  153. GB tn, fp: 28868, 23
  154. GB fn, tp: 61, 199
  155. GB f1 score: 0.826
  156. GB cohens kappa score: 0.824
  157. -> test with 'KNN'
  158. KNN tn, fp: 28890, 1
  159. KNN fn, tp: 162, 98
  160. KNN f1 score: 0.546
  161. KNN cohens kappa score: 0.544
  162. ------ Step 2/5: Slice 3/5 -------
  163. -> Reset the GAN
  164. -> Train generator for synthetic samples
  165. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:52, 12.49s/it] 20%|██ | 2/10 [00:24<01:37, 12.24s/it] 30%|███ | 3/10 [00:36<01:25, 12.28s/it] 40%|████ | 4/10 [00:48<01:12, 12.09s/it] 50%|█████ | 5/10 [01:00<00:59, 11.98s/it] 60%|██████ | 6/10 [01:12<00:47, 11.99s/it] 70%|███████ | 7/10 [01:24<00:35, 11.94s/it] 80%|████████ | 8/10 [01:35<00:23, 11.73s/it] 90%|█████████ | 9/10 [01:47<00:11, 11.73s/it] 100%|██████████| 10/10 [01:59<00:00, 11.97s/it] 100%|██████████| 10/10 [01:59<00:00, 11.98s/it]
  166. -> create 114528 synthetic samples
  167. -> test with 'LR'
  168. LR tn, fp: 28872, 19
  169. LR fn, tp: 63, 197
  170. LR f1 score: 0.828
  171. LR cohens kappa score: 0.826
  172. LR average precision score: 0.844
  173. -> test with 'GB'
  174. GB tn, fp: 28862, 29
  175. GB fn, tp: 67, 193
  176. GB f1 score: 0.801
  177. GB cohens kappa score: 0.799
  178. -> test with 'KNN'
  179. KNN tn, fp: 28882, 9
  180. KNN fn, tp: 152, 108
  181. KNN f1 score: 0.573
  182. KNN cohens kappa score: 0.571
  183. ------ Step 2/5: Slice 4/5 -------
  184. -> Reset the GAN
  185. -> Train generator for synthetic samples
  186. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:45, 11.75s/it] 20%|██ | 2/10 [00:23<01:35, 11.92s/it] 30%|███ | 3/10 [00:35<01:23, 11.92s/it] 40%|████ | 4/10 [00:47<01:11, 11.99s/it] 50%|█████ | 5/10 [00:59<00:59, 11.89s/it] 60%|██████ | 6/10 [01:10<00:46, 11.72s/it] 70%|███████ | 7/10 [01:22<00:35, 11.81s/it] 80%|████████ | 8/10 [01:35<00:23, 11.94s/it] 90%|█████████ | 9/10 [01:46<00:11, 11.90s/it] 100%|██████████| 10/10 [01:59<00:00, 12.26s/it] 100%|██████████| 10/10 [01:59<00:00, 12.00s/it]
  187. -> create 114528 synthetic samples
  188. -> test with 'LR'
  189. LR tn, fp: 28867, 24
  190. LR fn, tp: 65, 195
  191. LR f1 score: 0.814
  192. LR cohens kappa score: 0.813
  193. LR average precision score: 0.860
  194. -> test with 'GB'
  195. GB tn, fp: 28861, 30
  196. GB fn, tp: 67, 193
  197. GB f1 score: 0.799
  198. GB cohens kappa score: 0.798
  199. -> test with 'KNN'
  200. KNN tn, fp: 28883, 8
  201. KNN fn, tp: 155, 105
  202. KNN f1 score: 0.563
  203. KNN cohens kappa score: 0.561
  204. ------ Step 2/5: Slice 5/5 -------
  205. -> Reset the GAN
  206. -> Train generator for synthetic samples
  207. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:44, 11.63s/it] 20%|██ | 2/10 [00:24<01:39, 12.38s/it] 30%|███ | 3/10 [00:37<01:28, 12.67s/it] 40%|████ | 4/10 [00:49<01:14, 12.34s/it] 50%|█████ | 5/10 [01:02<01:02, 12.47s/it] 60%|██████ | 6/10 [01:14<00:49, 12.42s/it] 70%|███████ | 7/10 [01:27<00:38, 12.69s/it] 80%|████████ | 8/10 [01:39<00:24, 12.47s/it] 90%|█████████ | 9/10 [01:50<00:11, 11.96s/it] 100%|██████████| 10/10 [02:02<00:00, 12.03s/it] 100%|██████████| 10/10 [02:02<00:00, 12.27s/it]
  208. -> create 114524 synthetic samples
  209. -> test with 'LR'
  210. LR tn, fp: 28876, 15
  211. LR fn, tp: 67, 189
  212. LR f1 score: 0.822
  213. LR cohens kappa score: 0.820
  214. LR average precision score: 0.854
  215. -> test with 'GB'
  216. GB tn, fp: 28860, 31
  217. GB fn, tp: 74, 182
  218. GB f1 score: 0.776
  219. GB cohens kappa score: 0.774
  220. -> test with 'KNN'
  221. KNN tn, fp: 28884, 7
  222. KNN fn, tp: 166, 90
  223. KNN f1 score: 0.510
  224. KNN cohens kappa score: 0.508
  225. ====== Step 3/5 =======
  226. -> Shuffling data
  227. -> Spliting data to slices
  228. ------ Step 3/5: Slice 1/5 -------
  229. -> Reset the GAN
  230. -> Train generator for synthetic samples
  231. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:40, 11.20s/it] 20%|██ | 2/10 [00:23<01:36, 12.04s/it] 30%|███ | 3/10 [00:36<01:25, 12.15s/it] 40%|████ | 4/10 [00:46<01:09, 11.60s/it] 50%|█████ | 5/10 [00:58<00:58, 11.66s/it] 60%|██████ | 6/10 [01:11<00:47, 11.92s/it] 70%|███████ | 7/10 [01:23<00:36, 12.12s/it] 80%|████████ | 8/10 [01:35<00:23, 11.90s/it] 90%|█████████ | 9/10 [01:46<00:11, 11.85s/it] 100%|██████████| 10/10 [01:58<00:00, 11.78s/it] 100%|██████████| 10/10 [01:58<00:00, 11.84s/it]
  232. -> create 114528 synthetic samples
  233. -> test with 'LR'
  234. LR tn, fp: 28875, 16
  235. LR fn, tp: 59, 201
  236. LR f1 score: 0.843
  237. LR cohens kappa score: 0.841
  238. LR average precision score: 0.875
  239. -> test with 'GB'
  240. GB tn, fp: 28869, 22
  241. GB fn, tp: 66, 194
  242. GB f1 score: 0.815
  243. GB cohens kappa score: 0.814
  244. -> test with 'KNN'
  245. KNN tn, fp: 28886, 5
  246. KNN fn, tp: 168, 92
  247. KNN f1 score: 0.515
  248. KNN cohens kappa score: 0.513
  249. ------ Step 3/5: Slice 2/5 -------
  250. -> Reset the GAN
  251. -> Train generator for synthetic samples
  252. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:51, 12.37s/it] 20%|██ | 2/10 [00:24<01:37, 12.14s/it] 30%|███ | 3/10 [00:36<01:24, 12.07s/it] 40%|████ | 4/10 [00:48<01:12, 12.13s/it] 50%|█████ | 5/10 [01:00<00:59, 11.99s/it] 60%|██████ | 6/10 [01:12<00:48, 12.06s/it] 70%|███████ | 7/10 [01:24<00:36, 12.15s/it] 80%|████████ | 8/10 [01:37<00:24, 12.24s/it] 90%|█████████ | 9/10 [01:50<00:12, 12.47s/it] 100%|██████████| 10/10 [02:02<00:00, 12.35s/it] 100%|██████████| 10/10 [02:02<00:00, 12.23s/it]
  253. -> create 114528 synthetic samples
  254. -> test with 'LR'
  255. LR tn, fp: 28874, 17
  256. LR fn, tp: 67, 193
  257. LR f1 score: 0.821
  258. LR cohens kappa score: 0.820
  259. LR average precision score: 0.858
  260. -> test with 'GB'
  261. GB tn, fp: 28874, 17
  262. GB fn, tp: 70, 190
  263. GB f1 score: 0.814
  264. GB cohens kappa score: 0.812
  265. -> test with 'KNN'
  266. KNN tn, fp: 28886, 5
  267. KNN fn, tp: 172, 88
  268. KNN f1 score: 0.499
  269. KNN cohens kappa score: 0.496
  270. ------ Step 3/5: Slice 3/5 -------
  271. -> Reset the GAN
  272. -> Train generator for synthetic samples
  273. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:51, 12.37s/it] 20%|██ | 2/10 [00:24<01:39, 12.44s/it] 30%|███ | 3/10 [00:37<01:26, 12.42s/it] 40%|████ | 4/10 [00:48<01:12, 12.11s/it] 50%|█████ | 5/10 [01:01<01:00, 12.14s/it] 60%|██████ | 6/10 [01:13<00:49, 12.37s/it] 70%|███████ | 7/10 [01:27<00:37, 12.66s/it] 80%|████████ | 8/10 [01:41<00:26, 13.17s/it] 90%|█████████ | 9/10 [01:54<00:13, 13.05s/it] 100%|██████████| 10/10 [02:07<00:00, 13.15s/it] 100%|██████████| 10/10 [02:07<00:00, 12.76s/it]
  274. -> create 114528 synthetic samples
  275. -> test with 'LR'
  276. LR tn, fp: 28868, 23
  277. LR fn, tp: 72, 188
  278. LR f1 score: 0.798
  279. LR cohens kappa score: 0.797
  280. LR average precision score: 0.838
  281. -> test with 'GB'
  282. GB tn, fp: 28865, 26
  283. GB fn, tp: 70, 190
  284. GB f1 score: 0.798
  285. GB cohens kappa score: 0.797
  286. -> test with 'KNN'
  287. KNN tn, fp: 28878, 13
  288. KNN fn, tp: 158, 102
  289. KNN f1 score: 0.544
  290. KNN cohens kappa score: 0.541
  291. ------ Step 3/5: Slice 4/5 -------
  292. -> Reset the GAN
  293. -> Train generator for synthetic samples
  294. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:48, 12.04s/it] 20%|██ | 2/10 [00:24<01:39, 12.44s/it] 30%|███ | 3/10 [00:36<01:23, 11.93s/it] 40%|████ | 4/10 [00:47<01:11, 11.89s/it] 50%|█████ | 5/10 [00:59<00:58, 11.60s/it] 60%|██████ | 6/10 [01:10<00:46, 11.73s/it] 70%|███████ | 7/10 [01:23<00:35, 11.84s/it] 80%|████████ | 8/10 [01:34<00:23, 11.78s/it] 90%|█████████ | 9/10 [01:46<00:11, 11.63s/it] 100%|██████████| 10/10 [01:56<00:00, 11.35s/it] 100%|██████████| 10/10 [01:56<00:00, 11.67s/it]
  295. -> create 114528 synthetic samples
  296. -> test with 'LR'
  297. LR tn, fp: 28873, 18
  298. LR fn, tp: 73, 187
  299. LR f1 score: 0.804
  300. LR cohens kappa score: 0.803
  301. LR average precision score: 0.857
  302. -> test with 'GB'
  303. GB tn, fp: 28864, 27
  304. GB fn, tp: 68, 192
  305. GB f1 score: 0.802
  306. GB cohens kappa score: 0.800
  307. -> test with 'KNN'
  308. KNN tn, fp: 28886, 5
  309. KNN fn, tp: 165, 95
  310. KNN f1 score: 0.528
  311. KNN cohens kappa score: 0.525
  312. ------ Step 3/5: Slice 5/5 -------
  313. -> Reset the GAN
  314. -> Train generator for synthetic samples
  315. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:54, 12.74s/it] 20%|██ | 2/10 [00:25<01:43, 12.99s/it] 30%|███ | 3/10 [00:41<01:40, 14.36s/it] 40%|████ | 4/10 [00:54<01:23, 13.85s/it] 50%|█████ | 5/10 [01:07<01:07, 13.50s/it] 60%|██████ | 6/10 [01:20<00:52, 13.08s/it] 70%|███████ | 7/10 [01:32<00:38, 12.92s/it] 80%|████████ | 8/10 [01:44<00:25, 12.68s/it] 90%|█████████ | 9/10 [01:56<00:12, 12.39s/it] 100%|██████████| 10/10 [02:09<00:00, 12.46s/it] 100%|██████████| 10/10 [02:09<00:00, 12.93s/it]
  316. -> create 114524 synthetic samples
  317. -> test with 'LR'
  318. LR tn, fp: 28880, 11
  319. LR fn, tp: 62, 194
  320. LR f1 score: 0.842
  321. LR cohens kappa score: 0.840
  322. LR average precision score: 0.882
  323. -> test with 'GB'
  324. GB tn, fp: 28872, 19
  325. GB fn, tp: 62, 194
  326. GB f1 score: 0.827
  327. GB cohens kappa score: 0.826
  328. -> test with 'KNN'
  329. KNN tn, fp: 28880, 11
  330. KNN fn, tp: 146, 110
  331. KNN f1 score: 0.584
  332. KNN cohens kappa score: 0.581
  333. ====== Step 4/5 =======
  334. -> Shuffling data
  335. -> Spliting data to slices
  336. ------ Step 4/5: Slice 1/5 -------
  337. -> Reset the GAN
  338. -> Train generator for synthetic samples
  339. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:10<01:38, 10.94s/it] 20%|██ | 2/10 [00:22<01:30, 11.37s/it] 30%|███ | 3/10 [00:34<01:21, 11.60s/it] 40%|████ | 4/10 [00:46<01:11, 11.89s/it] 50%|█████ | 5/10 [00:59<01:00, 12.04s/it] 60%|██████ | 6/10 [01:12<00:49, 12.50s/it] 70%|███████ | 7/10 [01:25<00:37, 12.57s/it] 80%|████████ | 8/10 [01:36<00:24, 12.18s/it] 90%|█████████ | 9/10 [01:47<00:11, 11.66s/it] 100%|██████████| 10/10 [01:58<00:00, 11.73s/it] 100%|██████████| 10/10 [01:58<00:00, 11.90s/it]
  340. -> create 114528 synthetic samples
  341. -> test with 'LR'
  342. LR tn, fp: 28875, 16
  343. LR fn, tp: 62, 198
  344. LR f1 score: 0.835
  345. LR cohens kappa score: 0.834
  346. LR average precision score: 0.884
  347. -> test with 'GB'
  348. GB tn, fp: 28859, 32
  349. GB fn, tp: 61, 199
  350. GB f1 score: 0.811
  351. GB cohens kappa score: 0.809
  352. -> test with 'KNN'
  353. KNN tn, fp: 28888, 3
  354. KNN fn, tp: 160, 100
  355. KNN f1 score: 0.551
  356. KNN cohens kappa score: 0.549
  357. ------ Step 4/5: Slice 2/5 -------
  358. -> Reset the GAN
  359. -> Train generator for synthetic samples
  360. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:44, 11.66s/it] 20%|██ | 2/10 [00:22<01:29, 11.13s/it] 30%|███ | 3/10 [00:35<01:23, 11.92s/it] 40%|████ | 4/10 [00:46<01:10, 11.67s/it] 50%|█████ | 5/10 [00:57<00:57, 11.46s/it] 60%|██████ | 6/10 [01:09<00:46, 11.69s/it] 70%|███████ | 7/10 [01:21<00:34, 11.67s/it] 80%|████████ | 8/10 [01:33<00:23, 11.66s/it] 90%|█████████ | 9/10 [01:45<00:11, 11.78s/it] 100%|██████████| 10/10 [01:56<00:00, 11.63s/it] 100%|██████████| 10/10 [01:56<00:00, 11.64s/it]
  361. -> create 114528 synthetic samples
  362. -> test with 'LR'
  363. LR tn, fp: 28870, 21
  364. LR fn, tp: 75, 185
  365. LR f1 score: 0.794
  366. LR cohens kappa score: 0.792
  367. LR average precision score: 0.841
  368. -> test with 'GB'
  369. GB tn, fp: 28856, 35
  370. GB fn, tp: 72, 188
  371. GB f1 score: 0.778
  372. GB cohens kappa score: 0.777
  373. -> test with 'KNN'
  374. KNN tn, fp: 28880, 11
  375. KNN fn, tp: 162, 98
  376. KNN f1 score: 0.531
  377. KNN cohens kappa score: 0.529
  378. ------ Step 4/5: Slice 3/5 -------
  379. -> Reset the GAN
  380. -> Train generator for synthetic samples
  381. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:11<01:47, 11.95s/it] 20%|██ | 2/10 [00:24<01:36, 12.09s/it] 30%|███ | 3/10 [00:35<01:23, 11.95s/it] 40%|████ | 4/10 [00:47<01:11, 11.92s/it] 50%|█████ | 5/10 [00:59<00:59, 11.85s/it] 60%|██████ | 6/10 [01:11<00:47, 11.91s/it] 70%|███████ | 7/10 [01:23<00:35, 11.98s/it] 80%|████████ | 8/10 [01:35<00:23, 11.81s/it] 90%|█████████ | 9/10 [01:47<00:11, 11.93s/it] 100%|██████████| 10/10 [01:58<00:00, 11.70s/it] 100%|██████████| 10/10 [01:58<00:00, 11.85s/it]
  382. -> create 114528 synthetic samples
  383. -> test with 'LR'
  384. LR tn, fp: 28876, 15
  385. LR fn, tp: 60, 200
  386. LR f1 score: 0.842
  387. LR cohens kappa score: 0.841
  388. LR average precision score: 0.855
  389. -> test with 'GB'
  390. GB tn, fp: 28866, 25
  391. GB fn, tp: 61, 199
  392. GB f1 score: 0.822
  393. GB cohens kappa score: 0.821
  394. -> test with 'KNN'
  395. KNN tn, fp: 28883, 8
  396. KNN fn, tp: 168, 92
  397. KNN f1 score: 0.511
  398. KNN cohens kappa score: 0.509
  399. ------ Step 4/5: Slice 4/5 -------
  400. -> Reset the GAN
  401. -> Train generator for synthetic samples
  402. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:16<02:26, 16.24s/it] 20%|██ | 2/10 [00:28<01:49, 13.69s/it] 30%|███ | 3/10 [00:40<01:30, 12.89s/it] 40%|████ | 4/10 [00:52<01:15, 12.61s/it] 50%|█████ | 5/10 [01:04<01:02, 12.46s/it] 60%|██████ | 6/10 [01:16<00:49, 12.41s/it] 70%|███████ | 7/10 [01:28<00:36, 12.31s/it] 80%|████████ | 8/10 [01:41<00:24, 12.30s/it] 90%|█████████ | 9/10 [01:53<00:12, 12.41s/it] 100%|██████████| 10/10 [02:04<00:00, 12.03s/it] 100%|██████████| 10/10 [02:04<00:00, 12.50s/it]
  403. -> create 114528 synthetic samples
  404. -> test with 'LR'
  405. LR tn, fp: 28875, 16
  406. LR fn, tp: 67, 193
  407. LR f1 score: 0.823
  408. LR cohens kappa score: 0.822
  409. LR average precision score: 0.877
  410. -> test with 'GB'
  411. GB tn, fp: 28868, 23
  412. GB fn, tp: 75, 185
  413. GB f1 score: 0.791
  414. GB cohens kappa score: 0.789
  415. -> test with 'KNN'
  416. KNN tn, fp: 28886, 5
  417. KNN fn, tp: 159, 101
  418. KNN f1 score: 0.552
  419. KNN cohens kappa score: 0.550
  420. ------ Step 4/5: Slice 5/5 -------
  421. -> Reset the GAN
  422. -> Train generator for synthetic samples
  423. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [07:09<1:04:22, 429.14s/it] 20%|██ | 2/10 [10:09<37:41, 282.65s/it] 30%|███ | 3/10 [10:20<18:30, 158.60s/it] 40%|████ | 4/10 [10:31<10:03, 100.51s/it] 50%|█████ | 5/10 [10:43<05:43, 68.67s/it] 60%|██████ | 6/10 [10:55<03:16, 49.16s/it] 70%|███████ | 7/10 [11:06<01:50, 36.88s/it] 80%|████████ | 8/10 [11:18<00:57, 28.94s/it] 90%|█████████ | 9/10 [11:29<00:23, 23.42s/it] 100%|██████████| 10/10 [11:42<00:00, 19.95s/it] 100%|██████████| 10/10 [11:42<00:00, 70.22s/it]
  424. -> create 114524 synthetic samples
  425. -> test with 'LR'
  426. LR tn, fp: 28875, 16
  427. LR fn, tp: 67, 189
  428. LR f1 score: 0.820
  429. LR cohens kappa score: 0.819
  430. LR average precision score: 0.854
  431. -> test with 'GB'
  432. GB tn, fp: 28861, 30
  433. GB fn, tp: 68, 188
  434. GB f1 score: 0.793
  435. GB cohens kappa score: 0.792
  436. -> test with 'KNN'
  437. KNN tn, fp: 28882, 9
  438. KNN fn, tp: 156, 100
  439. KNN f1 score: 0.548
  440. KNN cohens kappa score: 0.546
  441. ====== Step 5/5 =======
  442. -> Shuffling data
  443. -> Spliting data to slices
  444. ------ Step 5/5: Slice 1/5 -------
  445. -> Reset the GAN
  446. -> Train generator for synthetic samples
  447. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:13<01:59, 13.24s/it] 20%|██ | 2/10 [00:26<01:44, 13.06s/it] 30%|███ | 3/10 [00:38<01:28, 12.58s/it] 40%|████ | 4/10 [00:50<01:15, 12.57s/it] 50%|█████ | 5/10 [01:02<01:01, 12.38s/it] 60%|██████ | 6/10 [01:15<00:49, 12.45s/it] 70%|███████ | 7/10 [01:26<00:36, 12.11s/it] 80%|████████ | 8/10 [01:38<00:24, 12.08s/it] 90%|█████████ | 9/10 [01:50<00:12, 12.11s/it] 100%|██████████| 10/10 [02:02<00:00, 12.03s/it] 100%|██████████| 10/10 [02:02<00:00, 12.28s/it]
  448. -> create 114528 synthetic samples
  449. -> test with 'LR'
  450. LR tn, fp: 28868, 23
  451. LR fn, tp: 61, 199
  452. LR f1 score: 0.826
  453. LR cohens kappa score: 0.824
  454. LR average precision score: 0.867
  455. -> test with 'GB'
  456. GB tn, fp: 28864, 27
  457. GB fn, tp: 62, 198
  458. GB f1 score: 0.816
  459. GB cohens kappa score: 0.815
  460. -> test with 'KNN'
  461. KNN tn, fp: 28883, 8
  462. KNN fn, tp: 164, 96
  463. KNN f1 score: 0.527
  464. KNN cohens kappa score: 0.525
  465. ------ Step 5/5: Slice 2/5 -------
  466. -> Reset the GAN
  467. -> Train generator for synthetic samples
  468. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [05:15<47:16, 315.15s/it] 20%|██ | 2/10 [05:29<18:26, 138.27s/it] 30%|███ | 3/10 [05:43<09:28, 81.28s/it] 40%|████ | 4/10 [05:56<05:26, 54.45s/it] 50%|█████ | 5/10 [06:09<03:17, 39.54s/it] 60%|██████ | 6/10 [06:22<02:02, 30.55s/it] 70%|███████ | 7/10 [06:34<01:13, 24.57s/it] 80%|████████ | 8/10 [06:48<00:42, 21.18s/it] 90%|█████████ | 9/10 [07:02<00:18, 18.71s/it] 100%|██████████| 10/10 [07:14<00:00, 16.81s/it] 100%|██████████| 10/10 [07:14<00:00, 43.46s/it]
  469. -> create 114528 synthetic samples
  470. -> test with 'LR'
  471. LR tn, fp: 28880, 11
  472. LR fn, tp: 66, 194
  473. LR f1 score: 0.834
  474. LR cohens kappa score: 0.833
  475. LR average precision score: 0.866
  476. -> test with 'GB'
  477. GB tn, fp: 28861, 30
  478. GB fn, tp: 71, 189
  479. GB f1 score: 0.789
  480. GB cohens kappa score: 0.787
  481. -> test with 'KNN'
  482. KNN tn, fp: 28888, 3
  483. KNN fn, tp: 160, 100
  484. KNN f1 score: 0.551
  485. KNN cohens kappa score: 0.549
  486. ------ Step 5/5: Slice 3/5 -------
  487. -> Reset the GAN
  488. -> Train generator for synthetic samples
  489. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:55, 12.82s/it] 20%|██ | 2/10 [00:27<01:49, 13.74s/it] 30%|███ | 3/10 [00:39<01:30, 12.96s/it] 40%|████ | 4/10 [00:51<01:15, 12.58s/it] 50%|█████ | 5/10 [01:03<01:02, 12.48s/it] 60%|██████ | 6/10 [01:16<00:51, 12.80s/it] 70%|███████ | 7/10 [01:29<00:38, 12.76s/it] 80%|████████ | 8/10 [01:41<00:24, 12.49s/it] 90%|█████████ | 9/10 [01:53<00:12, 12.23s/it] 100%|██████████| 10/10 [02:05<00:00, 12.33s/it] 100%|██████████| 10/10 [02:05<00:00, 12.57s/it]
  490. -> create 114528 synthetic samples
  491. -> test with 'LR'
  492. LR tn, fp: 28874, 17
  493. LR fn, tp: 74, 186
  494. LR f1 score: 0.803
  495. LR cohens kappa score: 0.802
  496. LR average precision score: 0.860
  497. -> test with 'GB'
  498. GB tn, fp: 28871, 20
  499. GB fn, tp: 76, 184
  500. GB f1 score: 0.793
  501. GB cohens kappa score: 0.791
  502. -> test with 'KNN'
  503. KNN tn, fp: 28883, 8
  504. KNN fn, tp: 165, 95
  505. KNN f1 score: 0.523
  506. KNN cohens kappa score: 0.521
  507. ------ Step 5/5: Slice 4/5 -------
  508. -> Reset the GAN
  509. -> Train generator for synthetic samples
  510. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:49, 12.17s/it] 20%|██ | 2/10 [00:24<01:38, 12.28s/it] 30%|███ | 3/10 [00:37<01:29, 12.77s/it] 40%|████ | 4/10 [00:50<01:17, 12.86s/it] 50%|█████ | 5/10 [01:03<01:03, 12.72s/it] 60%|██████ | 6/10 [01:15<00:50, 12.62s/it] 70%|███████ | 7/10 [01:30<00:39, 13.30s/it] 80%|████████ | 8/10 [01:42<00:26, 13.00s/it] 90%|█████████ | 9/10 [01:56<00:13, 13.06s/it] 100%|██████████| 10/10 [02:08<00:00, 12.98s/it] 100%|██████████| 10/10 [02:08<00:00, 12.88s/it]
  511. -> create 114528 synthetic samples
  512. -> test with 'LR'
  513. LR tn, fp: 28877, 14
  514. LR fn, tp: 65, 195
  515. LR f1 score: 0.832
  516. LR cohens kappa score: 0.830
  517. LR average precision score: 0.857
  518. -> test with 'GB'
  519. GB tn, fp: 28863, 28
  520. GB fn, tp: 67, 193
  521. GB f1 score: 0.802
  522. GB cohens kappa score: 0.801
  523. -> test with 'KNN'
  524. KNN tn, fp: 28884, 7
  525. KNN fn, tp: 165, 95
  526. KNN f1 score: 0.525
  527. KNN cohens kappa score: 0.522
  528. ------ Step 5/5: Slice 5/5 -------
  529. -> Reset the GAN
  530. -> Train generator for synthetic samples
  531. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:12<01:52, 12.52s/it] 20%|██ | 2/10 [00:25<01:42, 12.86s/it] 30%|███ | 3/10 [00:38<01:29, 12.81s/it] 40%|████ | 4/10 [00:51<01:16, 12.83s/it] 50%|█████ | 5/10 [01:03<01:02, 12.53s/it] 60%|██████ | 6/10 [01:15<00:50, 12.58s/it] 70%|███████ | 7/10 [01:28<00:37, 12.51s/it] 80%|████████ | 8/10 [01:40<00:24, 12.41s/it] 90%|█████████ | 9/10 [01:53<00:12, 12.58s/it] 100%|██████████| 10/10 [02:05<00:00, 12.42s/it] 100%|██████████| 10/10 [02:05<00:00, 12.55s/it]
  532. -> create 114524 synthetic samples
  533. -> test with 'LR'
  534. LR tn, fp: 28872, 19
  535. LR fn, tp: 63, 193
  536. LR f1 score: 0.825
  537. LR cohens kappa score: 0.823
  538. LR average precision score: 0.861
  539. -> test with 'GB'
  540. GB tn, fp: 28866, 25
  541. GB fn, tp: 66, 190
  542. GB f1 score: 0.807
  543. GB cohens kappa score: 0.805
  544. -> test with 'KNN'
  545. KNN tn, fp: 28880, 11
  546. KNN fn, tp: 147, 109
  547. KNN f1 score: 0.580
  548. KNN cohens kappa score: 0.577
  549. ### Exercise is done.
  550. -----[ LR ]-----
  551. maximum:
  552. LR tn, fp: 28881, 24
  553. LR fn, tp: 84, 203
  554. LR f1 score: 0.855
  555. LR cohens kappa score: 0.854
  556. LR average precision score: 0.892
  557. average:
  558. LR tn, fp: 28874.28, 16.72
  559. LR fn, tp: 66.12, 193.08
  560. LR f1 score: 0.823
  561. LR cohens kappa score: 0.822
  562. LR average precision score: 0.862
  563. minimum:
  564. LR tn, fp: 28867, 10
  565. LR fn, tp: 57, 172
  566. LR f1 score: 0.784
  567. LR cohens kappa score: 0.782
  568. LR average precision score: 0.827
  569. -----[ GB ]-----
  570. maximum:
  571. GB tn, fp: 28876, 35
  572. GB fn, tp: 76, 202
  573. GB f1 score: 0.842
  574. GB cohens kappa score: 0.841
  575. average:
  576. GB tn, fp: 28865.52, 25.48
  577. GB fn, tp: 67.72, 191.48
  578. GB f1 score: 0.804
  579. GB cohens kappa score: 0.803
  580. minimum:
  581. GB tn, fp: 28856, 15
  582. GB fn, tp: 58, 182
  583. GB f1 score: 0.776
  584. GB cohens kappa score: 0.774
  585. -----[ KNN ]-----
  586. maximum:
  587. KNN tn, fp: 28890, 17
  588. KNN fn, tp: 173, 116
  589. KNN f1 score: 0.590
  590. KNN cohens kappa score: 0.588
  591. average:
  592. KNN tn, fp: 28883.28, 7.72
  593. KNN fn, tp: 160.84, 98.36
  594. KNN f1 score: 0.538
  595. KNN cohens kappa score: 0.536
  596. minimum:
  597. KNN tn, fp: 28874, 1
  598. KNN fn, tp: 144, 83
  599. KNN f1 score: 0.483
  600. KNN cohens kappa score: 0.480