folding_hypothyroid.log 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727
  1. ///////////////////////////////////////////
  2. // Running CTAB-GAN on folding_hypothyroid
  3. ///////////////////////////////////////////
  4. Load 'data_input/folding_hypothyroid'
  5. from pickle file
  6. non empty cut in data_input/folding_hypothyroid! (1 points)
  7. Data loaded.
  8. -> Shuffling data
  9. ### Start exercise for synthetic point generator
  10. ====== Step 1/5 =======
  11. -> Shuffling data
  12. -> Spliting data to slices
  13. ------ Step 1/5: Slice 1/5 -------
  14. -> Reset the GAN
  15. -> Train generator for synthetic samples
  16. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.17s/it] 20%|██ | 2/10 [00:04<00:16, 2.06s/it] 30%|███ | 3/10 [00:06<00:15, 2.16s/it] 40%|████ | 4/10 [00:08<00:12, 2.07s/it] 50%|█████ | 5/10 [00:10<00:10, 2.00s/it] 60%|██████ | 6/10 [00:12<00:08, 2.10s/it] 70%|███████ | 7/10 [00:14<00:06, 2.11s/it] 80%|████████ | 8/10 [00:16<00:04, 2.14s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.10s/it] 100%|██████████| 10/10 [00:20<00:00, 2.09s/it] 100%|██████████| 10/10 [00:20<00:00, 2.10s/it]
  17. -> create 2289 synthetic samples
  18. -> test with 'LR'
  19. LR tn, fp: 571, 32
  20. LR fn, tp: 20, 11
  21. LR f1 score: 0.297
  22. LR cohens kappa score: 0.255
  23. LR average precision score: 0.234
  24. -> test with 'GB'
  25. GB tn, fp: 599, 4
  26. GB fn, tp: 7, 24
  27. GB f1 score: 0.814
  28. GB cohens kappa score: 0.804
  29. -> test with 'KNN'
  30. KNN tn, fp: 589, 14
  31. KNN fn, tp: 9, 22
  32. KNN f1 score: 0.657
  33. KNN cohens kappa score: 0.638
  34. ------ Step 1/5: Slice 2/5 -------
  35. -> Reset the GAN
  36. -> Train generator for synthetic samples
  37. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.06s/it] 20%|██ | 2/10 [00:04<00:17, 2.20s/it] 30%|███ | 3/10 [00:06<00:14, 2.10s/it] 40%|████ | 4/10 [00:08<00:12, 2.06s/it] 50%|█████ | 5/10 [00:10<00:10, 2.11s/it] 60%|██████ | 6/10 [00:12<00:08, 2.07s/it] 70%|███████ | 7/10 [00:14<00:06, 2.07s/it] 80%|████████ | 8/10 [00:16<00:04, 2.09s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.00s/it] 100%|██████████| 10/10 [00:20<00:00, 1.99s/it] 100%|██████████| 10/10 [00:20<00:00, 2.05s/it]
  38. -> create 2289 synthetic samples
  39. -> test with 'LR'
  40. LR tn, fp: 557, 46
  41. LR fn, tp: 24, 7
  42. LR f1 score: 0.167
  43. LR cohens kappa score: 0.112
  44. LR average precision score: 0.126
  45. -> test with 'GB'
  46. GB tn, fp: 595, 8
  47. GB fn, tp: 8, 23
  48. GB f1 score: 0.742
  49. GB cohens kappa score: 0.729
  50. -> test with 'KNN'
  51. KNN tn, fp: 587, 16
  52. KNN fn, tp: 6, 25
  53. KNN f1 score: 0.694
  54. KNN cohens kappa score: 0.676
  55. ------ Step 1/5: Slice 3/5 -------
  56. -> Reset the GAN
  57. -> Train generator for synthetic samples
  58. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.06s/it] 20%|██ | 2/10 [00:04<00:16, 2.02s/it] 30%|███ | 3/10 [00:05<00:13, 1.92s/it] 40%|████ | 4/10 [00:07<00:11, 1.89s/it] 50%|█████ | 5/10 [00:09<00:09, 1.94s/it] 60%|██████ | 6/10 [00:12<00:08, 2.06s/it] 70%|███████ | 7/10 [00:14<00:06, 2.05s/it] 80%|████████ | 8/10 [00:16<00:04, 2.06s/it] 90%|█████████ | 9/10 [00:17<00:01, 1.99s/it] 100%|██████████| 10/10 [00:20<00:00, 2.06s/it] 100%|██████████| 10/10 [00:20<00:00, 2.02s/it]
  59. -> create 2289 synthetic samples
  60. -> test with 'LR'
  61. LR tn, fp: 590, 13
  62. LR fn, tp: 26, 5
  63. LR f1 score: 0.204
  64. LR cohens kappa score: 0.174
  65. LR average precision score: 0.207
  66. -> test with 'GB'
  67. GB tn, fp: 598, 5
  68. GB fn, tp: 5, 26
  69. GB f1 score: 0.839
  70. GB cohens kappa score: 0.830
  71. -> test with 'KNN'
  72. KNN tn, fp: 592, 11
  73. KNN fn, tp: 14, 17
  74. KNN f1 score: 0.576
  75. KNN cohens kappa score: 0.556
  76. ------ Step 1/5: Slice 4/5 -------
  77. -> Reset the GAN
  78. -> Train generator for synthetic samples
  79. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.13s/it] 20%|██ | 2/10 [00:04<00:16, 2.00s/it] 30%|███ | 3/10 [00:06<00:14, 2.11s/it] 40%|████ | 4/10 [00:08<00:12, 2.08s/it] 50%|█████ | 5/10 [00:10<00:11, 2.20s/it] 60%|██████ | 6/10 [00:12<00:08, 2.12s/it] 70%|███████ | 7/10 [00:14<00:06, 2.07s/it] 80%|████████ | 8/10 [00:16<00:04, 2.08s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.02s/it] 100%|██████████| 10/10 [00:20<00:00, 1.94s/it] 100%|██████████| 10/10 [00:20<00:00, 2.04s/it]
  80. -> create 2289 synthetic samples
  81. -> test with 'LR'
  82. LR tn, fp: 596, 7
  83. LR fn, tp: 24, 7
  84. LR f1 score: 0.311
  85. LR cohens kappa score: 0.289
  86. LR average precision score: 0.328
  87. -> test with 'GB'
  88. GB tn, fp: 601, 2
  89. GB fn, tp: 11, 20
  90. GB f1 score: 0.755
  91. GB cohens kappa score: 0.744
  92. -> test with 'KNN'
  93. KNN tn, fp: 590, 13
  94. KNN fn, tp: 13, 18
  95. KNN f1 score: 0.581
  96. KNN cohens kappa score: 0.559
  97. ------ Step 1/5: Slice 5/5 -------
  98. -> Reset the GAN
  99. -> Train generator for synthetic samples
  100. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.96s/it] 20%|██ | 2/10 [00:04<00:16, 2.11s/it] 30%|███ | 3/10 [00:06<00:14, 2.08s/it] 40%|████ | 4/10 [00:08<00:12, 2.08s/it] 50%|█████ | 5/10 [00:10<00:10, 2.02s/it] 60%|██████ | 6/10 [00:12<00:08, 2.02s/it] 70%|███████ | 7/10 [00:14<00:05, 1.99s/it] 80%|████████ | 8/10 [00:16<00:04, 2.03s/it] 90%|█████████ | 9/10 [00:17<00:01, 1.93s/it] 100%|██████████| 10/10 [00:20<00:00, 2.02s/it] 100%|██████████| 10/10 [00:20<00:00, 2.02s/it]
  101. -> create 2288 synthetic samples
  102. -> test with 'LR'
  103. LR tn, fp: 542, 58
  104. LR fn, tp: 16, 11
  105. LR f1 score: 0.229
  106. LR cohens kappa score: 0.178
  107. LR average precision score: 0.155
  108. -> test with 'GB'
  109. GB tn, fp: 596, 4
  110. GB fn, tp: 6, 21
  111. GB f1 score: 0.808
  112. GB cohens kappa score: 0.799
  113. -> test with 'KNN'
  114. KNN tn, fp: 583, 17
  115. KNN fn, tp: 11, 16
  116. KNN f1 score: 0.533
  117. KNN cohens kappa score: 0.510
  118. ====== Step 2/5 =======
  119. -> Shuffling data
  120. -> Spliting data to slices
  121. ------ Step 2/5: Slice 1/5 -------
  122. -> Reset the GAN
  123. -> Train generator for synthetic samples
  124. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.00s/it] 20%|██ | 2/10 [00:03<00:15, 1.90s/it] 30%|███ | 3/10 [00:05<00:13, 1.94s/it] 40%|████ | 4/10 [00:07<00:11, 2.00s/it] 50%|█████ | 5/10 [00:10<00:10, 2.07s/it] 60%|██████ | 6/10 [00:12<00:08, 2.03s/it] 70%|███████ | 7/10 [00:14<00:06, 2.08s/it] 80%|████████ | 8/10 [00:16<00:04, 2.12s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.06s/it] 100%|██████████| 10/10 [00:20<00:00, 2.09s/it] 100%|██████████| 10/10 [00:20<00:00, 2.05s/it]
  125. -> create 2289 synthetic samples
  126. -> test with 'LR'
  127. LR tn, fp: 568, 35
  128. LR fn, tp: 24, 7
  129. LR f1 score: 0.192
  130. LR cohens kappa score: 0.144
  131. LR average precision score: 0.155
  132. -> test with 'GB'
  133. GB tn, fp: 597, 6
  134. GB fn, tp: 10, 21
  135. GB f1 score: 0.724
  136. GB cohens kappa score: 0.711
  137. -> test with 'KNN'
  138. KNN tn, fp: 594, 9
  139. KNN fn, tp: 12, 19
  140. KNN f1 score: 0.644
  141. KNN cohens kappa score: 0.627
  142. ------ Step 2/5: Slice 2/5 -------
  143. -> Reset the GAN
  144. -> Train generator for synthetic samples
  145. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.98s/it] 20%|██ | 2/10 [00:03<00:15, 1.95s/it] 30%|███ | 3/10 [00:06<00:14, 2.02s/it] 40%|████ | 4/10 [00:08<00:12, 2.10s/it] 50%|█████ | 5/10 [00:10<00:10, 2.16s/it] 60%|██████ | 6/10 [00:12<00:08, 2.14s/it] 70%|███████ | 7/10 [00:14<00:06, 2.12s/it] 80%|████████ | 8/10 [00:16<00:04, 2.03s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.00s/it] 100%|██████████| 10/10 [00:20<00:00, 1.96s/it] 100%|██████████| 10/10 [00:20<00:00, 2.03s/it]
  146. -> create 2289 synthetic samples
  147. -> test with 'LR'
  148. LR tn, fp: 557, 46
  149. LR fn, tp: 20, 11
  150. LR f1 score: 0.250
  151. LR cohens kappa score: 0.199
  152. LR average precision score: 0.167
  153. -> test with 'GB'
  154. GB tn, fp: 597, 6
  155. GB fn, tp: 5, 26
  156. GB f1 score: 0.825
  157. GB cohens kappa score: 0.816
  158. -> test with 'KNN'
  159. KNN tn, fp: 592, 11
  160. KNN fn, tp: 9, 22
  161. KNN f1 score: 0.688
  162. KNN cohens kappa score: 0.671
  163. ------ Step 2/5: Slice 3/5 -------
  164. -> Reset the GAN
  165. -> Train generator for synthetic samples
  166. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.08s/it] 20%|██ | 2/10 [00:04<00:16, 2.08s/it] 30%|███ | 3/10 [00:06<00:14, 2.08s/it] 40%|████ | 4/10 [00:08<00:12, 2.03s/it] 50%|█████ | 5/10 [00:10<00:10, 2.03s/it] 60%|██████ | 6/10 [00:12<00:08, 2.04s/it] 70%|███████ | 7/10 [00:14<00:06, 2.02s/it] 80%|████████ | 8/10 [00:16<00:03, 1.95s/it] 90%|█████████ | 9/10 [00:17<00:01, 1.91s/it] 100%|██████████| 10/10 [00:19<00:00, 1.94s/it] 100%|██████████| 10/10 [00:19<00:00, 1.99s/it]
  167. -> create 2289 synthetic samples
  168. -> test with 'LR'
  169. LR tn, fp: 576, 27
  170. LR fn, tp: 22, 9
  171. LR f1 score: 0.269
  172. LR cohens kappa score: 0.228
  173. LR average precision score: 0.257
  174. -> test with 'GB'
  175. GB tn, fp: 600, 3
  176. GB fn, tp: 10, 21
  177. GB f1 score: 0.764
  178. GB cohens kappa score: 0.753
  179. -> test with 'KNN'
  180. KNN tn, fp: 593, 10
  181. KNN fn, tp: 12, 19
  182. KNN f1 score: 0.633
  183. KNN cohens kappa score: 0.615
  184. ------ Step 2/5: Slice 4/5 -------
  185. -> Reset the GAN
  186. -> Train generator for synthetic samples
  187. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.94s/it] 20%|██ | 2/10 [00:04<00:16, 2.07s/it] 30%|███ | 3/10 [00:06<00:14, 2.13s/it] 40%|████ | 4/10 [00:08<00:12, 2.06s/it] 50%|█████ | 5/10 [00:10<00:10, 2.05s/it] 60%|██████ | 6/10 [00:12<00:08, 2.01s/it] 70%|███████ | 7/10 [00:13<00:05, 1.92s/it] 80%|████████ | 8/10 [00:16<00:04, 2.00s/it] 90%|█████████ | 9/10 [00:18<00:01, 2.00s/it] 100%|██████████| 10/10 [00:20<00:00, 2.02s/it] 100%|██████████| 10/10 [00:20<00:00, 2.02s/it]
  188. -> create 2289 synthetic samples
  189. -> test with 'LR'
  190. LR tn, fp: 574, 29
  191. LR fn, tp: 19, 12
  192. LR f1 score: 0.333
  193. LR cohens kappa score: 0.294
  194. LR average precision score: 0.208
  195. -> test with 'GB'
  196. GB tn, fp: 599, 4
  197. GB fn, tp: 9, 22
  198. GB f1 score: 0.772
  199. GB cohens kappa score: 0.761
  200. -> test with 'KNN'
  201. KNN tn, fp: 585, 18
  202. KNN fn, tp: 14, 17
  203. KNN f1 score: 0.515
  204. KNN cohens kappa score: 0.489
  205. ------ Step 2/5: Slice 5/5 -------
  206. -> Reset the GAN
  207. -> Train generator for synthetic samples
  208. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.22s/it] 20%|██ | 2/10 [00:04<00:17, 2.23s/it] 30%|███ | 3/10 [00:06<00:15, 2.15s/it] 40%|████ | 4/10 [00:08<00:12, 2.05s/it] 50%|█████ | 5/10 [00:10<00:10, 2.07s/it] 60%|██████ | 6/10 [00:12<00:08, 2.04s/it] 70%|███████ | 7/10 [00:14<00:06, 2.05s/it] 80%|████████ | 8/10 [00:16<00:04, 2.02s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.02s/it] 100%|██████████| 10/10 [00:20<00:00, 1.98s/it] 100%|██████████| 10/10 [00:20<00:00, 2.04s/it]
  209. -> create 2288 synthetic samples
  210. -> test with 'LR'
  211. LR tn, fp: 562, 38
  212. LR fn, tp: 22, 5
  213. LR f1 score: 0.143
  214. LR cohens kappa score: 0.095
  215. LR average precision score: 0.149
  216. -> test with 'GB'
  217. GB tn, fp: 597, 3
  218. GB fn, tp: 5, 22
  219. GB f1 score: 0.846
  220. GB cohens kappa score: 0.840
  221. -> test with 'KNN'
  222. KNN tn, fp: 585, 15
  223. KNN fn, tp: 9, 18
  224. KNN f1 score: 0.600
  225. KNN cohens kappa score: 0.580
  226. ====== Step 3/5 =======
  227. -> Shuffling data
  228. -> Spliting data to slices
  229. ------ Step 3/5: Slice 1/5 -------
  230. -> Reset the GAN
  231. -> Train generator for synthetic samples
  232. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.26s/it] 20%|██ | 2/10 [00:04<00:17, 2.19s/it] 30%|███ | 3/10 [00:06<00:15, 2.23s/it] 40%|████ | 4/10 [00:08<00:13, 2.24s/it] 50%|█████ | 5/10 [00:10<00:10, 2.11s/it] 60%|██████ | 6/10 [00:13<00:08, 2.14s/it] 70%|███████ | 7/10 [00:14<00:06, 2.05s/it] 80%|████████ | 8/10 [00:16<00:04, 2.07s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.01s/it] 100%|██████████| 10/10 [00:20<00:00, 2.00s/it] 100%|██████████| 10/10 [00:20<00:00, 2.08s/it]
  233. -> create 2289 synthetic samples
  234. -> test with 'LR'
  235. LR tn, fp: 571, 32
  236. LR fn, tp: 21, 10
  237. LR f1 score: 0.274
  238. LR cohens kappa score: 0.231
  239. LR average precision score: 0.258
  240. -> test with 'GB'
  241. GB tn, fp: 602, 1
  242. GB fn, tp: 8, 23
  243. GB f1 score: 0.836
  244. GB cohens kappa score: 0.829
  245. -> test with 'KNN'
  246. KNN tn, fp: 597, 6
  247. KNN fn, tp: 14, 17
  248. KNN f1 score: 0.630
  249. KNN cohens kappa score: 0.614
  250. ------ Step 3/5: Slice 2/5 -------
  251. -> Reset the GAN
  252. -> Train generator for synthetic samples
  253. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.99s/it] 20%|██ | 2/10 [00:03<00:15, 1.97s/it] 30%|███ | 3/10 [00:05<00:13, 1.94s/it] 40%|████ | 4/10 [00:07<00:11, 1.90s/it] 50%|█████ | 5/10 [00:09<00:09, 1.94s/it] 60%|██████ | 6/10 [00:11<00:07, 1.94s/it] 70%|███████ | 7/10 [00:13<00:06, 2.01s/it] 80%|████████ | 8/10 [00:15<00:04, 2.01s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.10s/it] 100%|██████████| 10/10 [00:19<00:00, 2.02s/it] 100%|██████████| 10/10 [00:19<00:00, 1.99s/it]
  254. -> create 2289 synthetic samples
  255. -> test with 'LR'
  256. LR tn, fp: 594, 9
  257. LR fn, tp: 25, 6
  258. LR f1 score: 0.261
  259. LR cohens kappa score: 0.237
  260. LR average precision score: 0.327
  261. -> test with 'GB'
  262. GB tn, fp: 594, 9
  263. GB fn, tp: 5, 26
  264. GB f1 score: 0.788
  265. GB cohens kappa score: 0.776
  266. -> test with 'KNN'
  267. KNN tn, fp: 587, 16
  268. KNN fn, tp: 10, 21
  269. KNN f1 score: 0.618
  270. KNN cohens kappa score: 0.596
  271. ------ Step 3/5: Slice 3/5 -------
  272. -> Reset the GAN
  273. -> Train generator for synthetic samples
  274. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.14s/it] 20%|██ | 2/10 [00:04<00:18, 2.32s/it] 30%|███ | 3/10 [00:06<00:15, 2.20s/it] 40%|████ | 4/10 [00:08<00:12, 2.07s/it] 50%|█████ | 5/10 [00:10<00:10, 2.03s/it] 60%|██████ | 6/10 [00:12<00:08, 2.06s/it] 70%|███████ | 7/10 [00:14<00:06, 2.03s/it] 80%|████████ | 8/10 [00:16<00:03, 1.96s/it] 90%|█████████ | 9/10 [00:18<00:01, 1.98s/it] 100%|██████████| 10/10 [00:20<00:00, 1.99s/it] 100%|██████████| 10/10 [00:20<00:00, 2.04s/it]
  275. -> create 2289 synthetic samples
  276. -> test with 'LR'
  277. LR tn, fp: 592, 11
  278. LR fn, tp: 26, 5
  279. LR f1 score: 0.213
  280. LR cohens kappa score: 0.186
  281. LR average precision score: 0.218
  282. -> test with 'GB'
  283. GB tn, fp: 599, 4
  284. GB fn, tp: 5, 26
  285. GB f1 score: 0.852
  286. GB cohens kappa score: 0.845
  287. -> test with 'KNN'
  288. KNN tn, fp: 588, 15
  289. KNN fn, tp: 9, 22
  290. KNN f1 score: 0.647
  291. KNN cohens kappa score: 0.627
  292. ------ Step 3/5: Slice 4/5 -------
  293. -> Reset the GAN
  294. -> Train generator for synthetic samples
  295. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.10s/it] 20%|██ | 2/10 [00:04<00:17, 2.22s/it] 30%|███ | 3/10 [00:06<00:15, 2.21s/it] 40%|████ | 4/10 [00:08<00:12, 2.12s/it] 50%|█████ | 5/10 [00:10<00:10, 2.11s/it] 60%|██████ | 6/10 [00:12<00:08, 2.10s/it] 70%|███████ | 7/10 [00:14<00:06, 2.04s/it] 80%|████████ | 8/10 [00:16<00:04, 2.08s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.12s/it] 100%|██████████| 10/10 [00:21<00:00, 2.18s/it] 100%|██████████| 10/10 [00:21<00:00, 2.14s/it]
  296. -> create 2289 synthetic samples
  297. -> test with 'LR'
  298. LR tn, fp: 565, 38
  299. LR fn, tp: 17, 14
  300. LR f1 score: 0.337
  301. LR cohens kappa score: 0.294
  302. LR average precision score: 0.252
  303. -> test with 'GB'
  304. GB tn, fp: 595, 8
  305. GB fn, tp: 6, 25
  306. GB f1 score: 0.781
  307. GB cohens kappa score: 0.770
  308. -> test with 'KNN'
  309. KNN tn, fp: 590, 13
  310. KNN fn, tp: 10, 21
  311. KNN f1 score: 0.646
  312. KNN cohens kappa score: 0.627
  313. ------ Step 3/5: Slice 5/5 -------
  314. -> Reset the GAN
  315. -> Train generator for synthetic samples
  316. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.21s/it] 20%|██ | 2/10 [00:04<00:17, 2.16s/it] 30%|███ | 3/10 [00:06<00:14, 2.07s/it] 40%|████ | 4/10 [00:08<00:12, 2.07s/it] 50%|█████ | 5/10 [00:10<00:10, 2.01s/it] 60%|██████ | 6/10 [00:12<00:07, 1.95s/it] 70%|███████ | 7/10 [00:13<00:05, 1.92s/it] 80%|████████ | 8/10 [00:16<00:03, 1.99s/it] 90%|█████████ | 9/10 [00:17<00:01, 1.96s/it] 100%|██████████| 10/10 [00:20<00:00, 1.98s/it] 100%|██████████| 10/10 [00:20<00:00, 2.00s/it]
  317. -> create 2288 synthetic samples
  318. -> test with 'LR'
  319. LR tn, fp: 571, 29
  320. LR fn, tp: 19, 8
  321. LR f1 score: 0.250
  322. LR cohens kappa score: 0.211
  323. LR average precision score: 0.186
  324. -> test with 'GB'
  325. GB tn, fp: 598, 2
  326. GB fn, tp: 5, 22
  327. GB f1 score: 0.863
  328. GB cohens kappa score: 0.857
  329. -> test with 'KNN'
  330. KNN tn, fp: 582, 18
  331. KNN fn, tp: 7, 20
  332. KNN f1 score: 0.615
  333. KNN cohens kappa score: 0.595
  334. ====== Step 4/5 =======
  335. -> Shuffling data
  336. -> Spliting data to slices
  337. ------ Step 4/5: Slice 1/5 -------
  338. -> Reset the GAN
  339. -> Train generator for synthetic samples
  340. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.15s/it] 20%|██ | 2/10 [00:04<00:16, 2.01s/it] 30%|███ | 3/10 [00:05<00:13, 1.95s/it] 40%|████ | 4/10 [00:07<00:11, 1.98s/it] 50%|█████ | 5/10 [00:09<00:09, 1.92s/it] 60%|██████ | 6/10 [00:12<00:08, 2.03s/it] 70%|███████ | 7/10 [00:14<00:06, 2.11s/it] 80%|████████ | 8/10 [00:16<00:04, 2.01s/it] 90%|█████████ | 9/10 [00:18<00:01, 1.98s/it] 100%|██████████| 10/10 [00:19<00:00, 1.96s/it] 100%|██████████| 10/10 [00:19<00:00, 1.99s/it]
  341. -> create 2289 synthetic samples
  342. -> test with 'LR'
  343. LR tn, fp: 592, 11
  344. LR fn, tp: 29, 2
  345. LR f1 score: 0.091
  346. LR cohens kappa score: 0.064
  347. LR average precision score: 0.203
  348. -> test with 'GB'
  349. GB tn, fp: 596, 7
  350. GB fn, tp: 6, 25
  351. GB f1 score: 0.794
  352. GB cohens kappa score: 0.783
  353. -> test with 'KNN'
  354. KNN tn, fp: 593, 10
  355. KNN fn, tp: 16, 15
  356. KNN f1 score: 0.536
  357. KNN cohens kappa score: 0.515
  358. ------ Step 4/5: Slice 2/5 -------
  359. -> Reset the GAN
  360. -> Train generator for synthetic samples
  361. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.02s/it] 20%|██ | 2/10 [00:04<00:16, 2.03s/it] 30%|███ | 3/10 [00:05<00:13, 1.94s/it] 40%|████ | 4/10 [00:07<00:11, 1.85s/it] 50%|█████ | 5/10 [00:09<00:09, 1.87s/it] 60%|██████ | 6/10 [00:11<00:07, 1.88s/it] 70%|███████ | 7/10 [00:13<00:05, 1.92s/it] 80%|████████ | 8/10 [00:15<00:03, 1.86s/it] 90%|█████████ | 9/10 [00:17<00:01, 1.90s/it] 100%|██████████| 10/10 [00:19<00:00, 1.91s/it] 100%|██████████| 10/10 [00:19<00:00, 1.90s/it]
  362. -> create 2289 synthetic samples
  363. -> test with 'LR'
  364. LR tn, fp: 577, 26
  365. LR fn, tp: 24, 7
  366. LR f1 score: 0.219
  367. LR cohens kappa score: 0.177
  368. LR average precision score: 0.162
  369. -> test with 'GB'
  370. GB tn, fp: 600, 3
  371. GB fn, tp: 7, 24
  372. GB f1 score: 0.828
  373. GB cohens kappa score: 0.819
  374. -> test with 'KNN'
  375. KNN tn, fp: 589, 14
  376. KNN fn, tp: 13, 18
  377. KNN f1 score: 0.571
  378. KNN cohens kappa score: 0.549
  379. ------ Step 4/5: Slice 3/5 -------
  380. -> Reset the GAN
  381. -> Train generator for synthetic samples
  382. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:16, 1.85s/it] 20%|██ | 2/10 [00:03<00:14, 1.80s/it] 30%|███ | 3/10 [00:05<00:12, 1.77s/it] 40%|████ | 4/10 [00:07<00:10, 1.75s/it] 50%|█████ | 5/10 [00:08<00:08, 1.79s/it] 60%|██████ | 6/10 [00:10<00:07, 1.79s/it] 70%|███████ | 7/10 [00:12<00:05, 1.84s/it] 80%|████████ | 8/10 [00:14<00:03, 1.90s/it] 90%|█████████ | 9/10 [00:16<00:01, 1.91s/it] 100%|██████████| 10/10 [00:18<00:00, 1.91s/it] 100%|██████████| 10/10 [00:18<00:00, 1.85s/it]
  383. -> create 2289 synthetic samples
  384. -> test with 'LR'
  385. LR tn, fp: 575, 28
  386. LR fn, tp: 18, 13
  387. LR f1 score: 0.361
  388. LR cohens kappa score: 0.323
  389. LR average precision score: 0.280
  390. -> test with 'GB'
  391. GB tn, fp: 601, 2
  392. GB fn, tp: 6, 25
  393. GB f1 score: 0.862
  394. GB cohens kappa score: 0.855
  395. -> test with 'KNN'
  396. KNN tn, fp: 593, 10
  397. KNN fn, tp: 10, 21
  398. KNN f1 score: 0.677
  399. KNN cohens kappa score: 0.661
  400. ------ Step 4/5: Slice 4/5 -------
  401. -> Reset the GAN
  402. -> Train generator for synthetic samples
  403. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.98s/it] 20%|██ | 2/10 [00:03<00:14, 1.86s/it] 30%|███ | 3/10 [00:05<00:13, 1.87s/it] 40%|████ | 4/10 [00:07<00:11, 2.00s/it] 50%|█████ | 5/10 [00:10<00:10, 2.06s/it] 60%|██████ | 6/10 [00:12<00:08, 2.08s/it] 70%|███████ | 7/10 [00:14<00:06, 2.03s/it] 80%|████████ | 8/10 [00:16<00:04, 2.01s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.03s/it] 100%|██████████| 10/10 [00:20<00:00, 2.01s/it] 100%|██████████| 10/10 [00:20<00:00, 2.00s/it]
  404. -> create 2289 synthetic samples
  405. -> test with 'LR'
  406. LR tn, fp: 562, 41
  407. LR fn, tp: 20, 11
  408. LR f1 score: 0.265
  409. LR cohens kappa score: 0.217
  410. LR average precision score: 0.197
  411. -> test with 'GB'
  412. GB tn, fp: 601, 2
  413. GB fn, tp: 5, 26
  414. GB f1 score: 0.881
  415. GB cohens kappa score: 0.876
  416. -> test with 'KNN'
  417. KNN tn, fp: 584, 19
  418. KNN fn, tp: 15, 16
  419. KNN f1 score: 0.485
  420. KNN cohens kappa score: 0.457
  421. ------ Step 4/5: Slice 5/5 -------
  422. -> Reset the GAN
  423. -> Train generator for synthetic samples
  424. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.03s/it] 20%|██ | 2/10 [00:04<00:15, 2.00s/it] 30%|███ | 3/10 [00:05<00:13, 1.90s/it] 40%|████ | 4/10 [00:07<00:11, 1.89s/it] 50%|█████ | 5/10 [00:09<00:09, 1.94s/it] 60%|██████ | 6/10 [00:11<00:07, 1.92s/it] 70%|███████ | 7/10 [00:14<00:06, 2.09s/it] 80%|████████ | 8/10 [00:16<00:04, 2.13s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.12s/it] 100%|██████████| 10/10 [00:20<00:00, 2.06s/it] 100%|██████████| 10/10 [00:20<00:00, 2.03s/it]
  425. -> create 2288 synthetic samples
  426. -> test with 'LR'
  427. LR tn, fp: 549, 51
  428. LR fn, tp: 15, 12
  429. LR f1 score: 0.267
  430. LR cohens kappa score: 0.220
  431. LR average precision score: 0.197
  432. -> test with 'GB'
  433. GB tn, fp: 597, 3
  434. GB fn, tp: 8, 19
  435. GB f1 score: 0.776
  436. GB cohens kappa score: 0.766
  437. -> test with 'KNN'
  438. KNN tn, fp: 584, 16
  439. KNN fn, tp: 10, 17
  440. KNN f1 score: 0.567
  441. KNN cohens kappa score: 0.545
  442. ====== Step 5/5 =======
  443. -> Shuffling data
  444. -> Spliting data to slices
  445. ------ Step 5/5: Slice 1/5 -------
  446. -> Reset the GAN
  447. -> Train generator for synthetic samples
  448. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.30s/it] 20%|██ | 2/10 [00:04<00:17, 2.20s/it] 30%|███ | 3/10 [00:06<00:14, 2.05s/it] 40%|████ | 4/10 [00:08<00:12, 2.07s/it] 50%|█████ | 5/10 [00:10<00:10, 2.12s/it] 60%|██████ | 6/10 [00:12<00:08, 2.09s/it] 70%|███████ | 7/10 [00:14<00:06, 2.02s/it] 80%|████████ | 8/10 [00:16<00:04, 2.06s/it] 90%|█████████ | 9/10 [00:18<00:02, 2.02s/it] 100%|██████████| 10/10 [00:20<00:00, 1.98s/it] 100%|██████████| 10/10 [00:20<00:00, 2.05s/it]
  449. -> create 2289 synthetic samples
  450. -> test with 'LR'
  451. LR tn, fp: 560, 43
  452. LR fn, tp: 16, 15
  453. LR f1 score: 0.337
  454. LR cohens kappa score: 0.292
  455. LR average precision score: 0.205
  456. -> test with 'GB'
  457. GB tn, fp: 599, 4
  458. GB fn, tp: 8, 23
  459. GB f1 score: 0.793
  460. GB cohens kappa score: 0.783
  461. -> test with 'KNN'
  462. KNN tn, fp: 586, 17
  463. KNN fn, tp: 9, 22
  464. KNN f1 score: 0.629
  465. KNN cohens kappa score: 0.607
  466. ------ Step 5/5: Slice 2/5 -------
  467. -> Reset the GAN
  468. -> Train generator for synthetic samples
  469. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:16, 1.89s/it] 20%|██ | 2/10 [00:03<00:16, 2.01s/it] 30%|███ | 3/10 [00:06<00:14, 2.01s/it] 40%|████ | 4/10 [00:08<00:12, 2.09s/it] 50%|█████ | 5/10 [00:10<00:10, 2.15s/it] 60%|██████ | 6/10 [00:12<00:08, 2.07s/it] 70%|███████ | 7/10 [00:14<00:06, 2.08s/it] 80%|████████ | 8/10 [00:16<00:04, 2.06s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.83s/it] 100%|██████████| 10/10 [00:23<00:00, 2.57s/it] 100%|██████████| 10/10 [00:23<00:00, 2.30s/it]
  470. -> create 2289 synthetic samples
  471. -> test with 'LR'
  472. LR tn, fp: 575, 28
  473. LR fn, tp: 27, 4
  474. LR f1 score: 0.127
  475. LR cohens kappa score: 0.081
  476. LR average precision score: 0.152
  477. -> test with 'GB'
  478. GB tn, fp: 603, 0
  479. GB fn, tp: 6, 25
  480. GB f1 score: 0.893
  481. GB cohens kappa score: 0.888
  482. -> test with 'KNN'
  483. KNN tn, fp: 591, 12
  484. KNN fn, tp: 14, 17
  485. KNN f1 score: 0.567
  486. KNN cohens kappa score: 0.545
  487. ------ Step 5/5: Slice 3/5 -------
  488. -> Reset the GAN
  489. -> Train generator for synthetic samples
  490. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.32s/it] 20%|██ | 2/10 [00:04<00:16, 2.09s/it] 30%|███ | 3/10 [00:06<00:15, 2.18s/it] 40%|████ | 4/10 [00:08<00:13, 2.26s/it] 50%|█████ | 5/10 [00:11<00:11, 2.28s/it] 60%|██████ | 6/10 [00:13<00:09, 2.31s/it] 70%|███████ | 7/10 [00:15<00:06, 2.28s/it] 80%|████████ | 8/10 [00:18<00:04, 2.25s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.17s/it] 100%|██████████| 10/10 [00:22<00:00, 2.15s/it] 100%|██████████| 10/10 [00:22<00:00, 2.21s/it]
  491. -> create 2289 synthetic samples
  492. -> test with 'LR'
  493. LR tn, fp: 544, 59
  494. LR fn, tp: 20, 11
  495. LR f1 score: 0.218
  496. LR cohens kappa score: 0.161
  497. LR average precision score: 0.159
  498. -> test with 'GB'
  499. GB tn, fp: 598, 5
  500. GB fn, tp: 11, 20
  501. GB f1 score: 0.714
  502. GB cohens kappa score: 0.701
  503. -> test with 'KNN'
  504. KNN tn, fp: 590, 13
  505. KNN fn, tp: 14, 17
  506. KNN f1 score: 0.557
  507. KNN cohens kappa score: 0.535
  508. ------ Step 5/5: Slice 4/5 -------
  509. -> Reset the GAN
  510. -> Train generator for synthetic samples
  511. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.10s/it] 20%|██ | 2/10 [00:04<00:16, 2.07s/it] 30%|███ | 3/10 [00:08<00:21, 3.06s/it] 40%|████ | 4/10 [00:10<00:16, 2.69s/it] 50%|█████ | 5/10 [00:12<00:12, 2.52s/it] 60%|██████ | 6/10 [00:14<00:09, 2.31s/it] 70%|███████ | 7/10 [00:16<00:06, 2.20s/it] 80%|████████ | 8/10 [00:18<00:04, 2.12s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.09s/it] 100%|██████████| 10/10 [00:22<00:00, 2.06s/it] 100%|██████████| 10/10 [00:22<00:00, 2.26s/it]
  512. -> create 2289 synthetic samples
  513. -> test with 'LR'
  514. LR tn, fp: 573, 30
  515. LR fn, tp: 20, 11
  516. LR f1 score: 0.306
  517. LR cohens kappa score: 0.265
  518. LR average precision score: 0.190
  519. -> test with 'GB'
  520. GB tn, fp: 598, 5
  521. GB fn, tp: 4, 27
  522. GB f1 score: 0.857
  523. GB cohens kappa score: 0.850
  524. -> test with 'KNN'
  525. KNN tn, fp: 593, 10
  526. KNN fn, tp: 10, 21
  527. KNN f1 score: 0.677
  528. KNN cohens kappa score: 0.661
  529. ------ Step 5/5: Slice 5/5 -------
  530. -> Reset the GAN
  531. -> Train generator for synthetic samples
  532. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.06s/it] 20%|██ | 2/10 [00:03<00:15, 1.97s/it] 30%|███ | 3/10 [00:06<00:14, 2.02s/it] 40%|████ | 4/10 [00:08<00:12, 2.04s/it] 50%|█████ | 5/10 [00:10<00:09, 2.00s/it] 60%|██████ | 6/10 [00:12<00:07, 1.99s/it] 70%|███████ | 7/10 [00:14<00:06, 2.03s/it] 80%|████████ | 8/10 [00:16<00:03, 1.99s/it] 90%|█████████ | 9/10 [00:18<00:01, 1.99s/it] 100%|██████████| 10/10 [00:19<00:00, 1.95s/it] 100%|██████████| 10/10 [00:19<00:00, 1.99s/it]
  533. -> create 2288 synthetic samples
  534. -> test with 'LR'
  535. LR tn, fp: 556, 44
  536. LR fn, tp: 15, 12
  537. LR f1 score: 0.289
  538. LR cohens kappa score: 0.245
  539. LR average precision score: 0.168
  540. -> test with 'GB'
  541. GB tn, fp: 594, 6
  542. GB fn, tp: 10, 17
  543. GB f1 score: 0.680
  544. GB cohens kappa score: 0.667
  545. -> test with 'KNN'
  546. KNN tn, fp: 587, 13
  547. KNN fn, tp: 7, 20
  548. KNN f1 score: 0.667
  549. KNN cohens kappa score: 0.650
  550. ### Exercise is done.
  551. -----[ LR ]-----
  552. maximum:
  553. LR tn, fp: 596, 59
  554. LR fn, tp: 29, 15
  555. LR f1 score: 0.361
  556. LR cohens kappa score: 0.323
  557. LR average precision score: 0.328
  558. average:
  559. LR tn, fp: 569.96, 32.44
  560. LR fn, tp: 21.16, 9.04
  561. LR f1 score: 0.248
  562. LR cohens kappa score: 0.207
  563. LR average precision score: 0.206
  564. minimum:
  565. LR tn, fp: 542, 7
  566. LR fn, tp: 15, 2
  567. LR f1 score: 0.091
  568. LR cohens kappa score: 0.064
  569. LR average precision score: 0.126
  570. -----[ GB ]-----
  571. maximum:
  572. GB tn, fp: 603, 9
  573. GB fn, tp: 11, 27
  574. GB f1 score: 0.893
  575. GB cohens kappa score: 0.888
  576. average:
  577. GB tn, fp: 598.16, 4.24
  578. GB fn, tp: 7.04, 23.16
  579. GB f1 score: 0.803
  580. GB cohens kappa score: 0.794
  581. minimum:
  582. GB tn, fp: 594, 0
  583. GB fn, tp: 4, 17
  584. GB f1 score: 0.680
  585. GB cohens kappa score: 0.667
  586. -----[ KNN ]-----
  587. maximum:
  588. KNN tn, fp: 597, 19
  589. KNN fn, tp: 16, 25
  590. KNN f1 score: 0.694
  591. KNN cohens kappa score: 0.676
  592. average:
  593. KNN tn, fp: 588.96, 13.44
  594. KNN fn, tp: 11.08, 19.12
  595. KNN f1 score: 0.608
  596. KNN cohens kappa score: 0.588
  597. minimum:
  598. KNN tn, fp: 582, 6
  599. KNN fn, tp: 6, 15
  600. KNN f1 score: 0.485
  601. KNN cohens kappa score: 0.457