ksvmuralidhar commited on
Commit
9d973fa
1 Parent(s): 3361086

Update classification_model_monitor.py

Browse files
Files changed (1) hide show
  1. classification_model_monitor.py +5 -3
classification_model_monitor.py CHANGED
@@ -21,9 +21,11 @@ def filter_prediction_data(data: pd.DataFrame):
21
  if data is None:
22
  raise Exception("Input Prediction Data frame in None")
23
 
24
- filtered_prediction_data = data.loc[(data['y_true'].isin(['WEATHER', 'EDUCATION', 'ASTROLOGY', 'OTHERS']) == False) &
25
- (data['y_pred'].isin(['WEATHER', 'EDUCATION', 'ASTROLOGY', 'OTHERS']) == False) &
26
- (data['y_true_proba'] > CLASSIFIER_THRESHOLD)].copy()
 
 
27
 
28
  logging.info("Exiting filter_prediction_data()")
29
  return filtered_prediction_data
 
21
  if data is None:
22
  raise Exception("Input Prediction Data frame in None")
23
 
24
+ # filtered_prediction_data = data.loc[(data['y_true'].isin(['WEATHER', 'EDUCATION', 'ASTROLOGY', 'OTHERS']) == False) &
25
+ # (data['y_pred'].isin(['WEATHER', 'EDUCATION', 'ASTROLOGY', 'OTHERS']) == False) &
26
+ # (data['y_true_proba'] > CLASSIFIER_THRESHOLD)].copy()
27
+
28
+ filtered_prediction_data = data.loc[data['y_true_proba'] == 1].copy()
29
 
30
  logging.info("Exiting filter_prediction_data()")
31
  return filtered_prediction_data