mirror of
https://github.com/microsoft/autogen.git
synced 2026-02-17 11:03:15 -05:00
delete automl
This commit is contained in:
@@ -1,33 +0,0 @@
|
||||
from flaml import AutoML
|
||||
from flaml.data import load_openml_dataset
|
||||
|
||||
|
||||
def test_lexiflow():
|
||||
|
||||
X_train, X_test, y_train, y_test = load_openml_dataset(
|
||||
dataset_id=179, data_dir="test/data"
|
||||
)
|
||||
|
||||
lexico_objectives = {}
|
||||
lexico_objectives["metrics"] = ["val_loss", "pred_time"]
|
||||
lexico_objectives["tolerances"] = {"val_loss": 0.01, "pred_time": 0.0}
|
||||
lexico_objectives["targets"] = {"val_loss": 0.0, "pred_time": 0.0}
|
||||
lexico_objectives["modes"] = ["min", "min"]
|
||||
automl = AutoML()
|
||||
|
||||
settings = {
|
||||
"time_budget": 100,
|
||||
"lexico_objectives": lexico_objectives,
|
||||
"use_ray": False,
|
||||
"task": "classification",
|
||||
"max_iter": -1,
|
||||
"mem_thres": 128 * (1024**3),
|
||||
}
|
||||
automl.fit(X_train=X_train, y_train=y_train, X_val=X_test, y_val=y_test, **settings)
|
||||
print(automl.predict(X_train))
|
||||
print(automl.model)
|
||||
print(automl.config_history)
|
||||
print(automl.best_iteration)
|
||||
print(automl.best_estimator)
|
||||
if __name__ == "__main__":
|
||||
test_lexiflow()
|
||||
Reference in New Issue
Block a user