@@ -67,7 +67,7 @@ pub async fn init_heart_disease_model(app: &App) -> Result<Id> {
67
67
pub async fn seed_events ( app : & App , examples_count : usize , model_id : Id ) -> Result < ( ) > {
68
68
let target = "diagnosis" ;
69
69
let class_names = Some ( & [ "Negative" , "Positive" ] ) ;
70
- let data_path = workspace_root ( ) . join ( "data" ) . join ( " heart_disease.csv") ;
70
+ let data_path = workspace_root ( ) . join ( "heart_disease.csv" ) ;
71
71
let table = tangram_table:: Table :: from_path ( & data_path, Default :: default ( ) , & mut |_| { } ) ?;
72
72
let mut idx = 0 ;
73
73
let events: Vec < MonitorEvent > = ( 0 ..examples_count)
@@ -231,7 +231,7 @@ enum Diagnosis {
231
231
}
232
232
/// Returns the ID of the prediction as well as the predicted value
233
233
pub async fn seed_single_prediction_event ( app : & App , model_id : Id ) -> Result < ( Id , String ) > {
234
- let data_path = workspace_root ( ) . join ( "data" ) . join ( " heart_disease.csv") ;
234
+ let data_path = workspace_root ( ) . join ( "heart_disease.csv" ) ;
235
235
let table = tangram_table:: Table :: from_path ( & data_path, Default :: default ( ) , & mut |_| { } ) ?;
236
236
237
237
let id = Id :: generate ( ) ;
@@ -366,8 +366,8 @@ pub async fn seed_monitors(app: &App, model_id: Id) -> Result<()> {
366
366
threshold : MonitorThreshold {
367
367
metric : AlertMetric :: Accuracy ,
368
368
mode : MonitorThresholdMode :: Absolute ,
369
- difference_lower : Some ( 0.5 ) ,
370
- difference_upper : Some ( 0.5 ) ,
369
+ difference_lower : Some ( 0.1 ) ,
370
+ difference_upper : Some ( 0.1 ) ,
371
371
} ,
372
372
title : None ,
373
373
} ,
@@ -376,7 +376,7 @@ pub async fn seed_monitors(app: &App, model_id: Id) -> Result<()> {
376
376
threshold : MonitorThreshold {
377
377
metric : AlertMetric :: Accuracy ,
378
378
mode : MonitorThresholdMode :: Percentage ,
379
- difference_lower : Some ( 0.3 ) ,
379
+ difference_lower : Some ( 20.0 ) ,
380
380
difference_upper : None ,
381
381
} ,
382
382
title : None ,
0 commit comments