Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[R-package] Random Forest crash #691

Closed
Laurae2 opened this issue Jul 14, 2017 · 1 comment · Fixed by #692
Closed

[R-package] Random Forest crash #691

Laurae2 opened this issue Jul 14, 2017 · 1 comment · Fixed by #692

Comments

@Laurae2
Copy link
Contributor

Laurae2 commented Jul 14, 2017

Random Forest mode in R crashes the R session when bagging_fraction or feature_fraction are 1.

library(lightgbm)
data(agaricus.train, package = "lightgbm")
train <- agaricus.train
dtrain <- lgb.Dataset(train$data, label = train$label)
data(agaricus.test, package = "lightgbm")
test <- agaricus.test
dtest <- lgb.Dataset.create.valid(dtrain, test$data, label = test$label)
params <- list(objective = "regression", metric = "l2", boosting_type = "rf", bagging_freq = 1, bagging_fraction = 0.632, feature_fraction = 0.632, boosting_type = "rf")
# params <- list(objective = "regression", metric = "l2", boosting_type = "rf", bagging_freq = 1, bagging_fraction = 0.632, boosting_type = "rf") # Crash
# params <- list(objective = "regression", metric = "l2", boosting_type = "rf", bagging_freq = 1, boosting_type = "rf") # Crash
valids <- list(test = dtest)
model <- lgb.train(params,
                   dtrain,
                   100,
                   valids,
                   min_data = 1,
                   learning_rate = 1,
                   early_stopping_rounds = 10)
@guolinke
Copy link
Collaborator

it is designed for this. it will throw a fatal error .

@lock lock bot locked as resolved and limited conversation to collaborators Mar 11, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants