| skipped 79 lines |
80 | 80 | | * loss = binary_crossentropy |
81 | 81 | | |
82 | 82 | | DNN results: |
83 | | - | | precision | recall | f1-score | support | |
| 83 | + | |
| 84 | + | precision recall f1-score support |
| 85 | + | |
84 | 86 | | 0 1.00 1.00 1.00 12833 |
85 | 87 | | 1 1.00 1.00 1.00 9711 |
86 | 88 | | |
| skipped 1 lines |
88 | 90 | | macro avg 1.00 1.00 1.00 22544 |
89 | 91 | | weighted avg 1.00 1.00 1.00 22544 |
90 | 92 | | |
91 | | - | Best score: 0.9999680776451911 |
92 | | - | Estimator time: 645.5822646617889 |
93 | | - | Prediction time: 0.7374951839447021 |
94 | | - | Total time for fit and predict: 646.3197634220123 seconds |
| 93 | + | * Best score: 0.9999680776451911 |
| 94 | + | * Estimator time: 645.5822646617889 |
| 95 | + | * Prediction time: 0.7374951839447021 |
| 96 | + | * Total time for fit and predict: 646.3197634220123 seconds |
95 | 97 | | |
96 | 98 | | |
97 | 99 | | ![](plots/cm_nn.png) |
| skipped 1 lines |
99 | 101 | | |
100 | 102 | | **NAD NN Network description and results:** |
101 | 103 | | LSTM : Long short term memory recurrent neural network. |
102 | | - | RandomSearchCV was used for training with cross validation and best parameters |
103 | | - | hidden_layers =4 |
| 104 | + | RandomSearchCV was used for training with cross validation and best parameters: |
| 105 | + | hidden_layers =4, |
104 | 106 | | learning_rate = 0.0002267 |
105 | 107 | | |
| 108 | + | Training data: |
| 109 | + | |
| 110 | + | * Epochs = 250 |
| 111 | + | * verbose =2 |
| 112 | + | * batch size = 2000 |
| 113 | + | * scoring = accuracy |
| 114 | + | * optimizer = Adam |
| 115 | + | * loss = binary_crossentropy |
| 116 | + | |
| 117 | + | |
106 | 118 | | LSTM results: |
| 119 | + | |
107 | 120 | | precision recall f1-score support |
108 | 121 | | |
109 | 122 | | 0 1.00 1.00 1.00 12833 |
| skipped 3 lines |
113 | 126 | | macro avg 1.00 1.00 1.00 22544 |
114 | 127 | | weighted avg 1.00 1.00 1.00 22544 |
115 | 128 | | |
116 | | - | Best score: 0.9998968032832433 |
117 | | - | Estimator time: 956.7115938663483 |
118 | | - | Prediction time: 1.4246132373809814 |
119 | | - | Total time for fit and predict: 958.1362102031708 seconds |
120 | | - | Confusion matrix: |
121 | | - | [[12825 8] |
122 | | - | [ 51 9660]] |
| 129 | + | * Best score: 0.9998968032832433 |
| 130 | + | * Estimator time: 956.7115938663483 |
| 131 | + | * Prediction time: 1.4246132373809814 |
| 132 | + | * Total time for fit and predict: 958.1362102031708 seconds |
| 133 | + | |
| 134 | + | |
123 | 135 | | ![](plots/cm_lstm.png) |