|
117 | 117 |
|
118 | 118 | proba = model.predict_proba(X_df_2018) |
119 | 119 | performance = metrics.roc_auc_score(y_df_2018, proba[:, 1]).round(5) |
120 | | - df_performance = df_performance.append({"annee": 2018, "mois": 1, "performance": performance}, ignore_index=True) |
| 120 | + df_performance = pd.concat([df_performance, pd.DataFrame([{'annee': 2018, 'mois': 1, 'performance': performance}])], ignore_index=True) |
121 | 121 |
|
122 | 122 | SD = SmartDrift(df_current=X_df_2019, df_baseline=X_df_learning, deployed_model=model, encoding=encoder) |
123 | 123 | SD.compile( |
|
128 | 128 |
|
129 | 129 | proba = model.predict_proba(X_df_2019) |
130 | 130 | performance = metrics.roc_auc_score(y_df_2019, proba[:, 1]).round(5) |
131 | | - df_performance = df_performance.append({"annee": 2019, "mois": 1, "performance": performance}, ignore_index=True) |
| 131 | + df_performance = pd.concat([df_performance, pd.DataFrame([{'annee': 2019, 'mois': 1, 'performance': performance}])], ignore_index=True) |
132 | 132 |
|
133 | 133 | SD = SmartDrift(df_current=X_df_2020, df_baseline=X_df_learning, deployed_model=model, encoding=encoder) |
134 | 134 | SD.compile( |
|
139 | 139 |
|
140 | 140 | proba = model.predict_proba(X_df_2020) |
141 | 141 | performance = metrics.roc_auc_score(y_df_2020, proba[:, 1]).round(5) |
142 | | - df_performance = df_performance.append({"annee": 2020, "mois": 1, "performance": performance}, ignore_index=True) |
| 142 | + df_performance = pd.concat([df_performance, pd.DataFrame([{'annee': 2020, 'mois': 1, 'performance': performance}])], ignore_index=True) |
143 | 143 |
|
144 | 144 | SD = SmartDrift(df_current=X_df_2021, df_baseline=X_df_learning, deployed_model=model, encoding=encoder) |
145 | 145 | SD.compile( |
|
150 | 150 |
|
151 | 151 | proba = model.predict_proba(X_df_2021) |
152 | 152 | performance = metrics.roc_auc_score(y_df_2021, proba[:, 1]).round(5) |
153 | | - df_performance = df_performance.append({"annee": 2021, "mois": 1, "performance": performance}, ignore_index=True) |
| 153 | + df_performance = pd.concat([df_performance, pd.DataFrame([{'annee': 2021, 'mois': 1, 'performance': performance}])], ignore_index=True) |
154 | 154 | SD.add_data_modeldrift(dataset=df_performance, metric="performance") |
155 | 155 |
|
156 | 156 | SD.generate_report( |
|
0 commit comments