186d05b75a91c7ec57b54da68783c2853ccbc706,examples/lightgbm_simple.py,,objective,#Any#,31

Before Change


        param["drop_rate"] = trial.suggest_loguniform("drop_rate", 1e-8, 1.0)
        param["skip_drop"] = trial.suggest_loguniform("skip_drop", 1e-8, 1.0)
    if param["boosting_type"] == "goss":
        param["top_rate"] = trial.suggest_uniform("top_rate", 0.0, 1.0)
        param["other_rate"] = trial.suggest_uniform("other_rate", 0.0, 1.0 - param["top_rate"])

    gbm = lgb.train(param, dtrain)
    preds = gbm.predict(test_x)
    pred_labels = np.rint(preds)

After Change


    train_x, test_x, train_y, test_y = train_test_split(data, target, test_size=0.25)
    dtrain = lgb.Dataset(train_x, label=train_y)

    param = {
        "objective": "binary",
        "metric": "binary_logloss",
        "verbosity": -1,
        "boosting_type": "gbdt",
        "lambda_l1": trial.suggest_loguniform("lambda_l1", 1e-8, 10.0),
        "lambda_l2": trial.suggest_loguniform("lambda_l2", 1e-8, 10.0),
        "num_leaves": trial.suggest_int("num_leaves", 2, 256),
        "feature_fraction": min(trial.suggest_uniform("feature_fraction", 0.4, 1.0 + EPS), 1.0),
        "bagging_fraction": min(trial.suggest_uniform("bagging_fraction", 0.4, 1.0 + EPS), 1.0),
        "bagging_freq": trial.suggest_int("bagging_freq", 1, 7),
        "min_child_samples": int(trial.suggest_uniform("min_child_samples", 5, 100 + EPS)),
    }

    gbm = lgb.train(param, dtrain)
    preds = gbm.predict(test_x)
    pred_labels = np.rint(preds)
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: pfnet/optuna
Commit Name: 186d05b75a91c7ec57b54da68783c2853ccbc706
Time: 2019-10-06
Author: eowner@gmail.com
File Name: examples/lightgbm_simple.py
Class Name:
Method Name: objective


Project Name: pfnet/optuna
Commit Name: 186d05b75a91c7ec57b54da68783c2853ccbc706
Time: 2019-10-06
Author: eowner@gmail.com
File Name: examples/pruning/lightgbm_integration.py
Class Name:
Method Name: objective


Project Name: ray-project/ray
Commit Name: 2fac66650d131b93041836c1566587a7a4800af6
Time: 2020-09-04
Author: krfricke@users.noreply.github.com
File Name: python/ray/tune/examples/optuna_example.py
Class Name:
Method Name: