kaggle_creditcard.log 30 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725
  1. ///////////////////////////////////////////
  2. // Running CTAB-GAN on kaggle_creditcard
  3. ///////////////////////////////////////////
  4. Load 'data_input/kaggle_creditcard'
  5. Data loaded.
  6. -> Shuffling data
  7. ### Start exercise for synthetic point generator
  8. ====== Step 1/5 =======
  9. -> Shuffling data
  10. -> Spliting data to slices
  11. ------ Step 1/5: Slice 1/5 -------
  12. -> Reset the GAN
  13. -> Train generator for synthetic samples
  14. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:22, 2.54s/it] 20%|██ | 2/10 [00:05<00:20, 2.55s/it] 30%|███ | 3/10 [00:07<00:17, 2.48s/it] 40%|████ | 4/10 [00:09<00:14, 2.46s/it] 50%|█████ | 5/10 [00:12<00:11, 2.39s/it] 60%|██████ | 6/10 [00:14<00:09, 2.32s/it] 70%|███████ | 7/10 [00:16<00:06, 2.29s/it] 80%|████████ | 8/10 [00:18<00:04, 2.32s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.30s/it] 100%|██████████| 10/10 [00:23<00:00, 2.29s/it] 100%|██████████| 10/10 [00:23<00:00, 2.35s/it]
  15. -> create 227059 synthetic samples
  16. -> test with 'LR'
  17. LR tn, fp: 56837, 26
  18. LR fn, tp: 30, 69
  19. LR f1 score: 0.711
  20. LR cohens kappa score: 0.711
  21. LR average precision score: 0.560
  22. -> test with 'GB'
  23. GB tn, fp: 56848, 15
  24. GB fn, tp: 27, 72
  25. GB f1 score: 0.774
  26. GB cohens kappa score: 0.774
  27. -> test with 'KNN'
  28. KNN tn, fp: 56509, 354
  29. KNN fn, tp: 92, 7
  30. KNN f1 score: 0.030
  31. KNN cohens kappa score: 0.028
  32. ------ Step 1/5: Slice 2/5 -------
  33. -> Reset the GAN
  34. -> Train generator for synthetic samples
  35. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.16s/it] 20%|██ | 2/10 [00:04<00:17, 2.17s/it] 30%|███ | 3/10 [00:06<00:14, 2.10s/it] 40%|████ | 4/10 [00:08<00:12, 2.11s/it] 50%|█████ | 5/10 [00:10<00:10, 2.06s/it] 60%|██████ | 6/10 [00:12<00:08, 2.13s/it] 70%|███████ | 7/10 [00:14<00:06, 2.15s/it] 80%|████████ | 8/10 [00:17<00:04, 2.16s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.20s/it] 100%|██████████| 10/10 [00:21<00:00, 2.24s/it] 100%|██████████| 10/10 [00:21<00:00, 2.17s/it]
  36. -> create 227059 synthetic samples
  37. -> test with 'LR'
  38. LR tn, fp: 56847, 16
  39. LR fn, tp: 20, 79
  40. LR f1 score: 0.814
  41. LR cohens kappa score: 0.814
  42. LR average precision score: 0.744
  43. -> test with 'GB'
  44. GB tn, fp: 56856, 7
  45. GB fn, tp: 26, 73
  46. GB f1 score: 0.816
  47. GB cohens kappa score: 0.815
  48. -> test with 'KNN'
  49. KNN tn, fp: 56523, 340
  50. KNN fn, tp: 93, 6
  51. KNN f1 score: 0.027
  52. KNN cohens kappa score: 0.024
  53. ------ Step 1/5: Slice 3/5 -------
  54. -> Reset the GAN
  55. -> Train generator for synthetic samples
  56. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:01<00:17, 1.92s/it] 20%|██ | 2/10 [00:03<00:15, 1.92s/it] 30%|███ | 3/10 [00:05<00:13, 1.97s/it] 40%|████ | 4/10 [00:09<00:16, 2.81s/it] 50%|█████ | 5/10 [00:12<00:12, 2.55s/it] 60%|██████ | 6/10 [00:13<00:09, 2.34s/it] 70%|███████ | 7/10 [00:15<00:06, 2.23s/it] 80%|████████ | 8/10 [00:18<00:04, 2.34s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.18s/it] 100%|██████████| 10/10 [00:22<00:00, 2.12s/it] 100%|██████████| 10/10 [00:22<00:00, 2.24s/it]
  57. -> create 227059 synthetic samples
  58. -> test with 'LR'
  59. LR tn, fp: 56838, 25
  60. LR fn, tp: 20, 79
  61. LR f1 score: 0.778
  62. LR cohens kappa score: 0.778
  63. LR average precision score: 0.657
  64. -> test with 'GB'
  65. GB tn, fp: 56851, 12
  66. GB fn, tp: 20, 79
  67. GB f1 score: 0.832
  68. GB cohens kappa score: 0.831
  69. -> test with 'KNN'
  70. KNN tn, fp: 56600, 263
  71. KNN fn, tp: 97, 2
  72. KNN f1 score: 0.011
  73. KNN cohens kappa score: 0.008
  74. ------ Step 1/5: Slice 4/5 -------
  75. -> Reset the GAN
  76. -> Train generator for synthetic samples
  77. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.41s/it] 20%|██ | 2/10 [00:04<00:18, 2.33s/it] 30%|███ | 3/10 [00:06<00:15, 2.22s/it] 40%|████ | 4/10 [00:08<00:13, 2.20s/it] 50%|█████ | 5/10 [00:10<00:10, 2.12s/it] 60%|██████ | 6/10 [00:13<00:08, 2.11s/it] 70%|███████ | 7/10 [00:15<00:06, 2.18s/it] 80%|████████ | 8/10 [00:17<00:04, 2.14s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.09s/it] 100%|██████████| 10/10 [00:21<00:00, 2.12s/it] 100%|██████████| 10/10 [00:21<00:00, 2.16s/it]
  78. -> create 227059 synthetic samples
  79. -> test with 'LR'
  80. LR tn, fp: 56829, 34
  81. LR fn, tp: 15, 84
  82. LR f1 score: 0.774
  83. LR cohens kappa score: 0.774
  84. LR average precision score: 0.757
  85. -> test with 'GB'
  86. GB tn, fp: 56851, 12
  87. GB fn, tp: 17, 82
  88. GB f1 score: 0.850
  89. GB cohens kappa score: 0.849
  90. -> test with 'KNN'
  91. KNN tn, fp: 56548, 315
  92. KNN fn, tp: 98, 1
  93. KNN f1 score: 0.005
  94. KNN cohens kappa score: 0.002
  95. ------ Step 1/5: Slice 5/5 -------
  96. -> Reset the GAN
  97. -> Train generator for synthetic samples
  98. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:22, 2.48s/it] 20%|██ | 2/10 [00:04<00:19, 2.42s/it] 30%|███ | 3/10 [00:06<00:15, 2.18s/it] 40%|████ | 4/10 [00:08<00:13, 2.20s/it] 50%|█████ | 5/10 [00:11<00:10, 2.16s/it] 60%|██████ | 6/10 [00:13<00:08, 2.19s/it] 70%|███████ | 7/10 [00:15<00:06, 2.08s/it] 80%|████████ | 8/10 [00:17<00:04, 2.07s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.12s/it] 100%|██████████| 10/10 [00:21<00:00, 2.11s/it] 100%|██████████| 10/10 [00:21<00:00, 2.15s/it]
  99. -> create 227056 synthetic samples
  100. -> test with 'LR'
  101. LR tn, fp: 56850, 13
  102. LR fn, tp: 19, 77
  103. LR f1 score: 0.828
  104. LR cohens kappa score: 0.828
  105. LR average precision score: 0.812
  106. -> test with 'GB'
  107. GB tn, fp: 56856, 7
  108. GB fn, tp: 18, 78
  109. GB f1 score: 0.862
  110. GB cohens kappa score: 0.862
  111. -> test with 'KNN'
  112. KNN tn, fp: 56543, 320
  113. KNN fn, tp: 94, 2
  114. KNN f1 score: 0.010
  115. KNN cohens kappa score: 0.007
  116. ====== Step 2/5 =======
  117. -> Shuffling data
  118. -> Spliting data to slices
  119. ------ Step 2/5: Slice 1/5 -------
  120. -> Reset the GAN
  121. -> Train generator for synthetic samples
  122. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.28s/it] 20%|██ | 2/10 [00:04<00:19, 2.38s/it] 30%|███ | 3/10 [00:06<00:16, 2.30s/it] 40%|████ | 4/10 [00:09<00:13, 2.24s/it] 50%|█████ | 5/10 [00:10<00:10, 2.11s/it] 60%|██████ | 6/10 [00:13<00:08, 2.15s/it] 70%|███████ | 7/10 [00:15<00:06, 2.12s/it] 80%|████████ | 8/10 [00:17<00:04, 2.13s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.15s/it] 100%|██████████| 10/10 [00:21<00:00, 2.20s/it] 100%|██████████| 10/10 [00:21<00:00, 2.19s/it]
  123. -> create 227059 synthetic samples
  124. -> test with 'LR'
  125. LR tn, fp: 56810, 53
  126. LR fn, tp: 15, 84
  127. LR f1 score: 0.712
  128. LR cohens kappa score: 0.711
  129. LR average precision score: 0.694
  130. -> test with 'GB'
  131. GB tn, fp: 56847, 16
  132. GB fn, tp: 19, 80
  133. GB f1 score: 0.821
  134. GB cohens kappa score: 0.820
  135. -> test with 'KNN'
  136. KNN tn, fp: 56522, 341
  137. KNN fn, tp: 96, 3
  138. KNN f1 score: 0.014
  139. KNN cohens kappa score: 0.011
  140. ------ Step 2/5: Slice 2/5 -------
  141. -> Reset the GAN
  142. -> Train generator for synthetic samples
  143. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:18, 2.04s/it] 20%|██ | 2/10 [00:04<00:19, 2.38s/it] 30%|███ | 3/10 [00:07<00:16, 2.43s/it] 40%|████ | 4/10 [00:09<00:14, 2.36s/it] 50%|█████ | 5/10 [00:13<00:14, 2.87s/it] 60%|██████ | 6/10 [00:15<00:10, 2.60s/it] 70%|███████ | 7/10 [00:17<00:07, 2.37s/it] 80%|████████ | 8/10 [00:19<00:04, 2.27s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.25s/it] 100%|██████████| 10/10 [00:23<00:00, 2.20s/it] 100%|██████████| 10/10 [00:23<00:00, 2.35s/it]
  144. -> create 227059 synthetic samples
  145. -> test with 'LR'
  146. LR tn, fp: 56835, 28
  147. LR fn, tp: 17, 82
  148. LR f1 score: 0.785
  149. LR cohens kappa score: 0.784
  150. LR average precision score: 0.619
  151. -> test with 'GB'
  152. GB tn, fp: 56850, 13
  153. GB fn, tp: 19, 80
  154. GB f1 score: 0.833
  155. GB cohens kappa score: 0.833
  156. -> test with 'KNN'
  157. KNN tn, fp: 56508, 355
  158. KNN fn, tp: 98, 1
  159. KNN f1 score: 0.004
  160. KNN cohens kappa score: 0.002
  161. ------ Step 2/5: Slice 3/5 -------
  162. -> Reset the GAN
  163. -> Train generator for synthetic samples
  164. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.12s/it] 20%|██ | 2/10 [00:04<00:17, 2.17s/it] 30%|███ | 3/10 [00:06<00:16, 2.29s/it] 40%|████ | 4/10 [00:08<00:13, 2.27s/it] 50%|█████ | 5/10 [00:11<00:11, 2.22s/it] 60%|██████ | 6/10 [00:13<00:08, 2.23s/it] 70%|███████ | 7/10 [00:15<00:06, 2.20s/it] 80%|████████ | 8/10 [00:17<00:04, 2.17s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.14s/it] 100%|██████████| 10/10 [00:21<00:00, 2.12s/it] 100%|██████████| 10/10 [00:21<00:00, 2.18s/it]
  165. -> create 227059 synthetic samples
  166. -> test with 'LR'
  167. LR tn, fp: 56840, 23
  168. LR fn, tp: 23, 76
  169. LR f1 score: 0.768
  170. LR cohens kappa score: 0.767
  171. LR average precision score: 0.646
  172. -> test with 'GB'
  173. GB tn, fp: 56850, 13
  174. GB fn, tp: 23, 76
  175. GB f1 score: 0.809
  176. GB cohens kappa score: 0.808
  177. -> test with 'KNN'
  178. KNN tn, fp: 56557, 306
  179. KNN fn, tp: 94, 5
  180. KNN f1 score: 0.024
  181. KNN cohens kappa score: 0.022
  182. ------ Step 2/5: Slice 4/5 -------
  183. -> Reset the GAN
  184. -> Train generator for synthetic samples
  185. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:24, 2.69s/it] 20%|██ | 2/10 [00:05<00:21, 2.73s/it] 30%|███ | 3/10 [00:07<00:18, 2.64s/it] 40%|████ | 4/10 [00:10<00:14, 2.50s/it] 50%|█████ | 5/10 [00:12<00:12, 2.42s/it] 60%|██████ | 6/10 [00:15<00:10, 2.51s/it] 70%|███████ | 7/10 [00:17<00:07, 2.46s/it] 80%|████████ | 8/10 [00:19<00:04, 2.35s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.23s/it] 100%|██████████| 10/10 [00:23<00:00, 2.23s/it] 100%|██████████| 10/10 [00:23<00:00, 2.39s/it]
  186. -> create 227059 synthetic samples
  187. -> test with 'LR'
  188. LR tn, fp: 56836, 27
  189. LR fn, tp: 21, 78
  190. LR f1 score: 0.765
  191. LR cohens kappa score: 0.764
  192. LR average precision score: 0.713
  193. -> test with 'GB'
  194. GB tn, fp: 56856, 7
  195. GB fn, tp: 21, 78
  196. GB f1 score: 0.848
  197. GB cohens kappa score: 0.848
  198. -> test with 'KNN'
  199. KNN tn, fp: 56433, 430
  200. KNN fn, tp: 95, 4
  201. KNN f1 score: 0.015
  202. KNN cohens kappa score: 0.012
  203. ------ Step 2/5: Slice 5/5 -------
  204. -> Reset the GAN
  205. -> Train generator for synthetic samples
  206. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.24s/it] 20%|██ | 2/10 [00:04<00:17, 2.23s/it] 30%|███ | 3/10 [00:06<00:15, 2.26s/it] 40%|████ | 4/10 [00:08<00:13, 2.23s/it] 50%|█████ | 5/10 [00:11<00:11, 2.29s/it] 60%|██████ | 6/10 [00:13<00:09, 2.28s/it] 70%|███████ | 7/10 [00:15<00:06, 2.27s/it] 80%|████████ | 8/10 [00:17<00:04, 2.22s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.24s/it] 100%|██████████| 10/10 [00:22<00:00, 2.35s/it] 100%|██████████| 10/10 [00:22<00:00, 2.28s/it]
  207. -> create 227056 synthetic samples
  208. -> test with 'LR'
  209. LR tn, fp: 56850, 13
  210. LR fn, tp: 23, 73
  211. LR f1 score: 0.802
  212. LR cohens kappa score: 0.802
  213. LR average precision score: 0.750
  214. -> test with 'GB'
  215. GB tn, fp: 56852, 11
  216. GB fn, tp: 23, 73
  217. GB f1 score: 0.811
  218. GB cohens kappa score: 0.811
  219. -> test with 'KNN'
  220. KNN tn, fp: 56594, 269
  221. KNN fn, tp: 93, 3
  222. KNN f1 score: 0.016
  223. KNN cohens kappa score: 0.014
  224. ====== Step 3/5 =======
  225. -> Shuffling data
  226. -> Spliting data to slices
  227. ------ Step 3/5: Slice 1/5 -------
  228. -> Reset the GAN
  229. -> Train generator for synthetic samples
  230. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.13s/it] 20%|██ | 2/10 [00:04<00:20, 2.54s/it] 30%|███ | 3/10 [00:07<00:17, 2.47s/it] 40%|████ | 4/10 [00:09<00:14, 2.35s/it] 50%|█████ | 5/10 [00:11<00:11, 2.23s/it] 60%|██████ | 6/10 [00:13<00:08, 2.17s/it] 70%|███████ | 7/10 [00:15<00:06, 2.17s/it] 80%|████████ | 8/10 [00:17<00:04, 2.15s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.21s/it] 100%|██████████| 10/10 [00:22<00:00, 2.19s/it] 100%|██████████| 10/10 [00:22<00:00, 2.24s/it]
  231. -> create 227059 synthetic samples
  232. -> test with 'LR'
  233. LR tn, fp: 56838, 25
  234. LR fn, tp: 21, 78
  235. LR f1 score: 0.772
  236. LR cohens kappa score: 0.772
  237. LR average precision score: 0.703
  238. -> test with 'GB'
  239. GB tn, fp: 56852, 11
  240. GB fn, tp: 25, 74
  241. GB f1 score: 0.804
  242. GB cohens kappa score: 0.804
  243. -> test with 'KNN'
  244. KNN tn, fp: 56349, 514
  245. KNN fn, tp: 95, 4
  246. KNN f1 score: 0.013
  247. KNN cohens kappa score: 0.010
  248. ------ Step 3/5: Slice 2/5 -------
  249. -> Reset the GAN
  250. -> Train generator for synthetic samples
  251. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:19, 2.18s/it] 20%|██ | 2/10 [00:04<00:18, 2.32s/it] 30%|███ | 3/10 [00:06<00:16, 2.32s/it] 40%|████ | 4/10 [00:09<00:14, 2.38s/it] 50%|█████ | 5/10 [00:11<00:11, 2.30s/it] 60%|██████ | 6/10 [00:13<00:08, 2.24s/it] 70%|███████ | 7/10 [00:15<00:06, 2.24s/it] 80%|████████ | 8/10 [00:18<00:04, 2.20s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.25s/it] 100%|██████████| 10/10 [00:22<00:00, 2.23s/it] 100%|██████████| 10/10 [00:22<00:00, 2.26s/it]
  252. -> create 227059 synthetic samples
  253. -> test with 'LR'
  254. LR tn, fp: 56836, 27
  255. LR fn, tp: 22, 77
  256. LR f1 score: 0.759
  257. LR cohens kappa score: 0.758
  258. LR average precision score: 0.666
  259. -> test with 'GB'
  260. GB tn, fp: 56851, 12
  261. GB fn, tp: 21, 78
  262. GB f1 score: 0.825
  263. GB cohens kappa score: 0.825
  264. -> test with 'KNN'
  265. KNN tn, fp: 56501, 362
  266. KNN fn, tp: 95, 4
  267. KNN f1 score: 0.017
  268. KNN cohens kappa score: 0.015
  269. ------ Step 3/5: Slice 3/5 -------
  270. -> Reset the GAN
  271. -> Train generator for synthetic samples
  272. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.28s/it] 20%|██ | 2/10 [00:04<00:20, 2.52s/it] 30%|███ | 3/10 [00:07<00:17, 2.51s/it] 40%|████ | 4/10 [00:10<00:15, 2.66s/it] 50%|█████ | 5/10 [00:12<00:12, 2.51s/it] 60%|██████ | 6/10 [00:14<00:09, 2.44s/it] 70%|███████ | 7/10 [00:17<00:07, 2.41s/it] 80%|████████ | 8/10 [00:19<00:04, 2.33s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.32s/it] 100%|██████████| 10/10 [00:24<00:00, 2.31s/it] 100%|██████████| 10/10 [00:24<00:00, 2.40s/it]
  273. -> create 227059 synthetic samples
  274. -> test with 'LR'
  275. LR tn, fp: 56844, 19
  276. LR fn, tp: 25, 74
  277. LR f1 score: 0.771
  278. LR cohens kappa score: 0.770
  279. LR average precision score: 0.733
  280. -> test with 'GB'
  281. GB tn, fp: 56858, 5
  282. GB fn, tp: 18, 81
  283. GB f1 score: 0.876
  284. GB cohens kappa score: 0.875
  285. -> test with 'KNN'
  286. KNN tn, fp: 56504, 359
  287. KNN fn, tp: 95, 4
  288. KNN f1 score: 0.017
  289. KNN cohens kappa score: 0.015
  290. ------ Step 3/5: Slice 4/5 -------
  291. -> Reset the GAN
  292. -> Train generator for synthetic samples
  293. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.41s/it] 20%|██ | 2/10 [00:04<00:18, 2.35s/it] 30%|███ | 3/10 [00:06<00:15, 2.18s/it] 40%|████ | 4/10 [00:08<00:13, 2.22s/it] 50%|█████ | 5/10 [00:11<00:10, 2.17s/it] 60%|██████ | 6/10 [00:13<00:08, 2.21s/it] 70%|███████ | 7/10 [00:15<00:06, 2.22s/it] 80%|████████ | 8/10 [00:17<00:04, 2.20s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.24s/it] 100%|██████████| 10/10 [00:22<00:00, 2.27s/it] 100%|██████████| 10/10 [00:22<00:00, 2.24s/it]
  294. -> create 227059 synthetic samples
  295. -> test with 'LR'
  296. LR tn, fp: 56839, 24
  297. LR fn, tp: 20, 79
  298. LR f1 score: 0.782
  299. LR cohens kappa score: 0.782
  300. LR average precision score: 0.747
  301. -> test with 'GB'
  302. GB tn, fp: 56853, 10
  303. GB fn, tp: 16, 83
  304. GB f1 score: 0.865
  305. GB cohens kappa score: 0.864
  306. -> test with 'KNN'
  307. KNN tn, fp: 56447, 416
  308. KNN fn, tp: 92, 7
  309. KNN f1 score: 0.027
  310. KNN cohens kappa score: 0.024
  311. ------ Step 3/5: Slice 5/5 -------
  312. -> Reset the GAN
  313. -> Train generator for synthetic samples
  314. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.42s/it] 20%|██ | 2/10 [00:04<00:19, 2.39s/it] 30%|███ | 3/10 [00:07<00:16, 2.37s/it] 40%|████ | 4/10 [00:09<00:13, 2.26s/it] 50%|█████ | 5/10 [00:11<00:11, 2.24s/it] 60%|██████ | 6/10 [00:13<00:08, 2.21s/it] 70%|███████ | 7/10 [00:15<00:06, 2.22s/it] 80%|████████ | 8/10 [00:17<00:04, 2.19s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.17s/it] 100%|██████████| 10/10 [00:22<00:00, 2.31s/it] 100%|██████████| 10/10 [00:22<00:00, 2.27s/it]
  315. -> create 227056 synthetic samples
  316. -> test with 'LR'
  317. LR tn, fp: 56844, 19
  318. LR fn, tp: 21, 75
  319. LR f1 score: 0.789
  320. LR cohens kappa score: 0.789
  321. LR average precision score: 0.757
  322. -> test with 'GB'
  323. GB tn, fp: 56853, 10
  324. GB fn, tp: 24, 72
  325. GB f1 score: 0.809
  326. GB cohens kappa score: 0.809
  327. -> test with 'KNN'
  328. KNN tn, fp: 56518, 345
  329. KNN fn, tp: 94, 2
  330. KNN f1 score: 0.009
  331. KNN cohens kappa score: 0.006
  332. ====== Step 4/5 =======
  333. -> Shuffling data
  334. -> Spliting data to slices
  335. ------ Step 4/5: Slice 1/5 -------
  336. -> Reset the GAN
  337. -> Train generator for synthetic samples
  338. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.23s/it] 20%|██ | 2/10 [00:04<00:17, 2.19s/it] 30%|███ | 3/10 [00:06<00:15, 2.22s/it] 40%|████ | 4/10 [00:08<00:13, 2.20s/it] 50%|█████ | 5/10 [00:11<00:12, 2.44s/it] 60%|██████ | 6/10 [00:14<00:09, 2.47s/it] 70%|███████ | 7/10 [00:16<00:07, 2.51s/it] 80%|████████ | 8/10 [00:18<00:04, 2.34s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.34s/it] 100%|██████████| 10/10 [00:23<00:00, 2.38s/it] 100%|██████████| 10/10 [00:23<00:00, 2.36s/it]
  339. -> create 227059 synthetic samples
  340. -> test with 'LR'
  341. LR tn, fp: 56837, 26
  342. LR fn, tp: 16, 83
  343. LR f1 score: 0.798
  344. LR cohens kappa score: 0.798
  345. LR average precision score: 0.680
  346. -> test with 'GB'
  347. GB tn, fp: 56849, 14
  348. GB fn, tp: 17, 82
  349. GB f1 score: 0.841
  350. GB cohens kappa score: 0.841
  351. -> test with 'KNN'
  352. KNN tn, fp: 56571, 292
  353. KNN fn, tp: 97, 2
  354. KNN f1 score: 0.010
  355. KNN cohens kappa score: 0.008
  356. ------ Step 4/5: Slice 2/5 -------
  357. -> Reset the GAN
  358. -> Train generator for synthetic samples
  359. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.42s/it] 20%|██ | 2/10 [00:04<00:18, 2.30s/it] 30%|███ | 3/10 [00:07<00:16, 2.43s/it] 40%|████ | 4/10 [00:09<00:14, 2.39s/it] 50%|█████ | 5/10 [00:11<00:11, 2.34s/it] 60%|██████ | 6/10 [00:14<00:09, 2.38s/it] 70%|███████ | 7/10 [00:16<00:07, 2.42s/it] 80%|████████ | 8/10 [00:19<00:04, 2.44s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.36s/it] 100%|██████████| 10/10 [00:23<00:00, 2.34s/it] 100%|██████████| 10/10 [00:23<00:00, 2.37s/it]
  360. -> create 227059 synthetic samples
  361. -> test with 'LR'
  362. LR tn, fp: 56844, 19
  363. LR fn, tp: 32, 67
  364. LR f1 score: 0.724
  365. LR cohens kappa score: 0.724
  366. LR average precision score: 0.646
  367. -> test with 'GB'
  368. GB tn, fp: 56851, 12
  369. GB fn, tp: 21, 78
  370. GB f1 score: 0.825
  371. GB cohens kappa score: 0.825
  372. -> test with 'KNN'
  373. KNN tn, fp: 56551, 312
  374. KNN fn, tp: 96, 3
  375. KNN f1 score: 0.014
  376. KNN cohens kappa score: 0.012
  377. ------ Step 4/5: Slice 3/5 -------
  378. -> Reset the GAN
  379. -> Train generator for synthetic samples
  380. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.38s/it] 20%|██ | 2/10 [00:04<00:18, 2.30s/it] 30%|███ | 3/10 [00:06<00:16, 2.30s/it] 40%|████ | 4/10 [00:09<00:13, 2.24s/it] 50%|█████ | 5/10 [00:11<00:11, 2.28s/it] 60%|██████ | 6/10 [00:13<00:08, 2.23s/it] 70%|███████ | 7/10 [00:15<00:06, 2.19s/it] 80%|████████ | 8/10 [00:17<00:04, 2.22s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.20s/it] 100%|██████████| 10/10 [00:22<00:00, 2.17s/it] 100%|██████████| 10/10 [00:22<00:00, 2.22s/it]
  381. -> create 227059 synthetic samples
  382. -> test with 'LR'
  383. LR tn, fp: 56837, 26
  384. LR fn, tp: 22, 77
  385. LR f1 score: 0.762
  386. LR cohens kappa score: 0.762
  387. LR average precision score: 0.680
  388. -> test with 'GB'
  389. GB tn, fp: 56854, 9
  390. GB fn, tp: 25, 74
  391. GB f1 score: 0.813
  392. GB cohens kappa score: 0.813
  393. -> test with 'KNN'
  394. KNN tn, fp: 56591, 272
  395. KNN fn, tp: 94, 5
  396. KNN f1 score: 0.027
  397. KNN cohens kappa score: 0.024
  398. ------ Step 4/5: Slice 4/5 -------
  399. -> Reset the GAN
  400. -> Train generator for synthetic samples
  401. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:21, 2.42s/it] 20%|██ | 2/10 [00:05<00:21, 2.73s/it] 30%|███ | 3/10 [00:07<00:17, 2.49s/it] 40%|████ | 4/10 [00:09<00:13, 2.30s/it] 50%|█████ | 5/10 [00:11<00:11, 2.26s/it] 60%|██████ | 6/10 [00:14<00:09, 2.27s/it] 70%|███████ | 7/10 [00:16<00:07, 2.34s/it] 80%|████████ | 8/10 [00:18<00:04, 2.24s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.27s/it] 100%|██████████| 10/10 [00:23<00:00, 2.27s/it] 100%|██████████| 10/10 [00:23<00:00, 2.32s/it]
  402. -> create 227059 synthetic samples
  403. -> test with 'LR'
  404. LR tn, fp: 56851, 12
  405. LR fn, tp: 19, 80
  406. LR f1 score: 0.838
  407. LR cohens kappa score: 0.837
  408. LR average precision score: 0.775
  409. -> test with 'GB'
  410. GB tn, fp: 56852, 11
  411. GB fn, tp: 17, 82
  412. GB f1 score: 0.854
  413. GB cohens kappa score: 0.854
  414. -> test with 'KNN'
  415. KNN tn, fp: 56552, 311
  416. KNN fn, tp: 96, 3
  417. KNN f1 score: 0.015
  418. KNN cohens kappa score: 0.012
  419. ------ Step 4/5: Slice 5/5 -------
  420. -> Reset the GAN
  421. -> Train generator for synthetic samples
  422. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.33s/it] 20%|██ | 2/10 [00:04<00:16, 2.11s/it] 30%|███ | 3/10 [00:06<00:14, 2.03s/it] 40%|████ | 4/10 [00:08<00:13, 2.26s/it] 50%|█████ | 5/10 [00:11<00:11, 2.24s/it] 60%|██████ | 6/10 [00:13<00:08, 2.22s/it] 70%|███████ | 7/10 [00:15<00:06, 2.23s/it] 80%|████████ | 8/10 [00:17<00:04, 2.22s/it] 90%|█████████ | 9/10 [00:19<00:02, 2.21s/it] 100%|██████████| 10/10 [00:22<00:00, 2.24s/it] 100%|██████████| 10/10 [00:22<00:00, 2.22s/it]
  423. -> create 227056 synthetic samples
  424. -> test with 'LR'
  425. LR tn, fp: 56847, 16
  426. LR fn, tp: 25, 71
  427. LR f1 score: 0.776
  428. LR cohens kappa score: 0.776
  429. LR average precision score: 0.710
  430. -> test with 'GB'
  431. GB tn, fp: 56845, 18
  432. GB fn, tp: 21, 75
  433. GB f1 score: 0.794
  434. GB cohens kappa score: 0.793
  435. -> test with 'KNN'
  436. KNN tn, fp: 56541, 322
  437. KNN fn, tp: 88, 8
  438. KNN f1 score: 0.038
  439. KNN cohens kappa score: 0.035
  440. ====== Step 5/5 =======
  441. -> Shuffling data
  442. -> Spliting data to slices
  443. ------ Step 5/5: Slice 1/5 -------
  444. -> Reset the GAN
  445. -> Train generator for synthetic samples
  446. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:22, 2.53s/it] 20%|██ | 2/10 [00:04<00:18, 2.36s/it] 30%|███ | 3/10 [00:07<00:16, 2.32s/it] 40%|████ | 4/10 [00:09<00:14, 2.35s/it] 50%|█████ | 5/10 [00:11<00:11, 2.34s/it] 60%|██████ | 6/10 [00:13<00:08, 2.25s/it] 70%|███████ | 7/10 [00:15<00:06, 2.15s/it] 80%|████████ | 8/10 [00:18<00:04, 2.26s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.27s/it] 100%|██████████| 10/10 [00:22<00:00, 2.24s/it] 100%|██████████| 10/10 [00:22<00:00, 2.27s/it]
  447. -> create 227059 synthetic samples
  448. -> test with 'LR'
  449. LR tn, fp: 56841, 22
  450. LR fn, tp: 24, 75
  451. LR f1 score: 0.765
  452. LR cohens kappa score: 0.765
  453. LR average precision score: 0.677
  454. -> test with 'GB'
  455. GB tn, fp: 56857, 6
  456. GB fn, tp: 25, 74
  457. GB f1 score: 0.827
  458. GB cohens kappa score: 0.827
  459. -> test with 'KNN'
  460. KNN tn, fp: 56487, 376
  461. KNN fn, tp: 96, 3
  462. KNN f1 score: 0.013
  463. KNN cohens kappa score: 0.010
  464. ------ Step 5/5: Slice 2/5 -------
  465. -> Reset the GAN
  466. -> Train generator for synthetic samples
  467. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:20, 2.29s/it] 20%|██ | 2/10 [00:04<00:17, 2.15s/it] 30%|███ | 3/10 [00:06<00:15, 2.18s/it] 40%|████ | 4/10 [00:08<00:13, 2.24s/it] 50%|█████ | 5/10 [00:11<00:11, 2.24s/it] 60%|██████ | 6/10 [00:13<00:08, 2.18s/it] 70%|███████ | 7/10 [00:15<00:06, 2.20s/it] 80%|████████ | 8/10 [00:17<00:04, 2.20s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.61s/it] 100%|██████████| 10/10 [00:23<00:00, 2.41s/it] 100%|██████████| 10/10 [00:23<00:00, 2.31s/it]
  468. -> create 227059 synthetic samples
  469. -> test with 'LR'
  470. LR tn, fp: 56799, 64
  471. LR fn, tp: 16, 83
  472. LR f1 score: 0.675
  473. LR cohens kappa score: 0.674
  474. LR average precision score: 0.733
  475. -> test with 'GB'
  476. GB tn, fp: 56854, 9
  477. GB fn, tp: 20, 79
  478. GB f1 score: 0.845
  479. GB cohens kappa score: 0.845
  480. -> test with 'KNN'
  481. KNN tn, fp: 56409, 454
  482. KNN fn, tp: 93, 6
  483. KNN f1 score: 0.021
  484. KNN cohens kappa score: 0.019
  485. ------ Step 5/5: Slice 3/5 -------
  486. -> Reset the GAN
  487. -> Train generator for synthetic samples
  488. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:22, 2.53s/it] 20%|██ | 2/10 [00:05<00:21, 2.66s/it] 30%|███ | 3/10 [00:07<00:17, 2.53s/it] 40%|████ | 4/10 [00:10<00:14, 2.50s/it] 50%|█████ | 5/10 [00:12<00:12, 2.43s/it] 60%|██████ | 6/10 [00:14<00:09, 2.41s/it] 70%|███████ | 7/10 [00:16<00:06, 2.31s/it] 80%|████████ | 8/10 [00:18<00:04, 2.23s/it] 90%|█████████ | 9/10 [00:21<00:02, 2.26s/it] 100%|██████████| 10/10 [00:23<00:00, 2.22s/it] 100%|██████████| 10/10 [00:23<00:00, 2.34s/it]
  489. -> create 227059 synthetic samples
  490. -> test with 'LR'
  491. LR tn, fp: 56841, 22
  492. LR fn, tp: 24, 75
  493. LR f1 score: 0.765
  494. LR cohens kappa score: 0.765
  495. LR average precision score: 0.677
  496. -> test with 'GB'
  497. GB tn, fp: 56852, 11
  498. GB fn, tp: 20, 79
  499. GB f1 score: 0.836
  500. GB cohens kappa score: 0.836
  501. -> test with 'KNN'
  502. KNN tn, fp: 56608, 255
  503. KNN fn, tp: 96, 3
  504. KNN f1 score: 0.017
  505. KNN cohens kappa score: 0.014
  506. ------ Step 5/5: Slice 4/5 -------
  507. -> Reset the GAN
  508. -> Train generator for synthetic samples
  509. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:04<00:36, 4.06s/it] 20%|██ | 2/10 [00:06<00:25, 3.15s/it] 30%|███ | 3/10 [00:09<00:19, 2.82s/it] 40%|████ | 4/10 [00:11<00:15, 2.60s/it] 50%|█████ | 5/10 [00:13<00:12, 2.51s/it] 60%|██████ | 6/10 [00:15<00:09, 2.41s/it] 70%|███████ | 7/10 [00:18<00:07, 2.38s/it] 80%|████████ | 8/10 [00:20<00:04, 2.41s/it] 90%|█████████ | 9/10 [00:23<00:02, 2.41s/it] 100%|██████████| 10/10 [00:25<00:00, 2.45s/it] 100%|██████████| 10/10 [00:25<00:00, 2.56s/it]
  510. -> create 227059 synthetic samples
  511. -> test with 'LR'
  512. LR tn, fp: 56841, 22
  513. LR fn, tp: 18, 81
  514. LR f1 score: 0.802
  515. LR cohens kappa score: 0.802
  516. LR average precision score: 0.734
  517. -> test with 'GB'
  518. GB tn, fp: 56856, 7
  519. GB fn, tp: 20, 79
  520. GB f1 score: 0.854
  521. GB cohens kappa score: 0.854
  522. -> test with 'KNN'
  523. KNN tn, fp: 56449, 414
  524. KNN fn, tp: 97, 2
  525. KNN f1 score: 0.008
  526. KNN cohens kappa score: 0.005
  527. ------ Step 5/5: Slice 5/5 -------
  528. -> Reset the GAN
  529. -> Train generator for synthetic samples
  530. 0%| | 0/10 [00:00<?, ?it/s] 10%|█ | 1/10 [00:02<00:24, 2.70s/it] 20%|██ | 2/10 [00:05<00:19, 2.50s/it] 30%|███ | 3/10 [00:07<00:17, 2.47s/it] 40%|████ | 4/10 [00:09<00:14, 2.40s/it] 50%|█████ | 5/10 [00:12<00:12, 2.41s/it] 60%|██████ | 6/10 [00:14<00:09, 2.33s/it] 70%|███████ | 7/10 [00:16<00:06, 2.23s/it] 80%|████████ | 8/10 [00:18<00:04, 2.30s/it] 90%|█████████ | 9/10 [00:20<00:02, 2.20s/it] 100%|██████████| 10/10 [00:23<00:00, 2.22s/it] 100%|██████████| 10/10 [00:23<00:00, 2.31s/it]
  531. -> create 227056 synthetic samples
  532. -> test with 'LR'
  533. LR tn, fp: 56843, 20
  534. LR fn, tp: 19, 77
  535. LR f1 score: 0.798
  536. LR cohens kappa score: 0.798
  537. LR average precision score: 0.661
  538. -> test with 'GB'
  539. GB tn, fp: 56846, 17
  540. GB fn, tp: 22, 74
  541. GB f1 score: 0.791
  542. GB cohens kappa score: 0.791
  543. -> test with 'KNN'
  544. KNN tn, fp: 56548, 315
  545. KNN fn, tp: 94, 2
  546. KNN f1 score: 0.010
  547. KNN cohens kappa score: 0.007
  548. ### Exercise is done.
  549. -----[ LR ]-----
  550. maximum:
  551. LR tn, fp: 56851, 64
  552. LR fn, tp: 32, 84
  553. LR f1 score: 0.838
  554. LR cohens kappa score: 0.837
  555. LR average precision score: 0.812
  556. average:
  557. LR tn, fp: 56838.16, 24.84
  558. LR fn, tp: 21.08, 77.32
  559. LR f1 score: 0.773
  560. LR cohens kappa score: 0.772
  561. LR average precision score: 0.701
  562. minimum:
  563. LR tn, fp: 56799, 12
  564. LR fn, tp: 15, 67
  565. LR f1 score: 0.675
  566. LR cohens kappa score: 0.674
  567. LR average precision score: 0.560
  568. -----[ GB ]-----
  569. maximum:
  570. GB tn, fp: 56858, 18
  571. GB fn, tp: 27, 83
  572. GB f1 score: 0.876
  573. GB cohens kappa score: 0.875
  574. average:
  575. GB tn, fp: 56852.0, 11.0
  576. GB fn, tp: 21.0, 77.4
  577. GB f1 score: 0.829
  578. GB cohens kappa score: 0.828
  579. minimum:
  580. GB tn, fp: 56845, 5
  581. GB fn, tp: 16, 72
  582. GB f1 score: 0.774
  583. GB cohens kappa score: 0.774
  584. -----[ KNN ]-----
  585. maximum:
  586. KNN tn, fp: 56608, 514
  587. KNN fn, tp: 98, 8
  588. KNN f1 score: 0.038
  589. KNN cohens kappa score: 0.035
  590. average:
  591. KNN tn, fp: 56518.52, 344.48
  592. KNN fn, tp: 94.72, 3.68
  593. KNN f1 score: 0.016
  594. KNN cohens kappa score: 0.014
  595. minimum:
  596. KNN tn, fp: 56349, 255
  597. KNN fn, tp: 88, 1
  598. KNN f1 score: 0.004
  599. KNN cohens kappa score: 0.002