File tree Expand file tree Collapse file tree 1 file changed +9
-3
lines changed
ads/opctl/operator/lowcode/anomaly/model Expand file tree Collapse file tree 1 file changed +9
-3
lines changed Original file line number Diff line number Diff line change @@ -33,10 +33,16 @@ def _build_model(self) -> pd.DataFrame:
33
33
est = automl .Pipeline (task = "anomaly_detection" , ** self .spec .model_kwargs )
34
34
est .fit (
35
35
X = df ,
36
- X_valid = self .X_valid_dict [target ] if self .X_valid_dict is not None else None ,
37
- y_valid = self .y_valid_dict [target ] if self .y_valid_dict is not None else None ,
36
+ X_valid = self .X_valid_dict [target ]
37
+ if self .X_valid_dict is not None
38
+ else None ,
39
+ y_valid = self .y_valid_dict [target ]
40
+ if self .y_valid_dict is not None
41
+ else None ,
38
42
time_budget = time_budget ,
39
- contamination = self .spec .contamination ,
43
+ contamination = self .spec .contamination
44
+ if self .y_valid_dict is not None
45
+ else None ,
40
46
)
41
47
y_pred = est .predict (df )
42
48
scores = est .predict_proba (df )
You can’t perform that action at this time.
0 commit comments