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

Infinite boosting rounds with "logloss" loss function #51

Open
Harrison4192 opened this issue Nov 15, 2021 · 4 comments
Open

Infinite boosting rounds with "logloss" loss function #51

Harrison4192 opened this issue Nov 15, 2021 · 4 comments
Labels
bug Something isn't working

Comments

@Harrison4192
Copy link

Harrison4192 commented Nov 15, 2021

I was trying to predict a binary variable specifying the loss_function as "logloss", but instead of stopping early, it seems the boosting rounds continue even while improvement stops. I expected training on the iris dataset to be very quick (like with loss_function "mse") but it just keeps going. The same issue is happening with other loss functions (similar issue with "poisson") except "mse" which performs as expected. The example can be reproduced as below.

image

@Blunde1 Blunde1 added the bug Something isn't working label Nov 15, 2021
@Blunde1
Copy link
Owner

Blunde1 commented Nov 15, 2021

@Harrison4192 Thanks!
I assume this is with agtboost 0.9.2?

@Blunde1
Copy link
Owner

Blunde1 commented Nov 15, 2021

Just confirmed it also happens with 0.9.1
Will look into this

library(fastDummies)
library(dplyr)
require(devtools)
install_version("agtboost", version = "0.9.1", repos = "http://cran.us.r-project.org")
library(agtboost)

iris %>%
  dummy_cols(remove_selected_columns=T) -> iris1

iris1 %>%
  select(-Species_setosa) %>%
  as.matrix -> iris2

mod <- gbt.train(
  y=iris1$Species_setosa,
  x=iris2,
  loss_function = "logloss",
  verbose=1,
  nrounds=300,
)

@Blunde1
Copy link
Owner

Blunde1 commented Nov 15, 2021

  • Find issue
  • Solve issue
  • Setup tests in CI so that similar behavior will be detected in the future

@Harrison4192
Copy link
Author

Hi, yea i can confirm this issue on 0.9.1 and the current development version 0.9.2

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants